d2jsp
Log InRegister
d2jsp Forums > Off-Topic > Computers & IT > Programming & Development > Python Questions
Add Reply New Topic New Poll
Member
Posts: 35,078
Joined: Jun 18 2008
Gold: 0.00
May 7 2014 06:41am
Python is my first programming language and i'm still learning from various tutorials but I am wondering about a few things that I haven't gotten to yet... Curiosity is a bitch...

Questions:
1) This will likely end up in a future tutorial... But anyone know of an easy-to-understand guide that explains how to assign code to buttons in a simple window/program?
2) Anyone know of an easy-to-understand guide that will explain how to make an online "lobby" to connect players to a simple server side program to play games like pong/checkers/text-based-games?
3) What programs would you guys recommend for a beginner with this language who wishes to make simple games?

My short term goal (and motivation) is to be able to make extremely basic online games (think server side text games or checkers) by some time next month.
Member
Posts: 62,215
Joined: Jun 3 2007
Gold: 9,039.20
May 7 2014 07:31am
Quote (Metalkon @ May 7 2014 06:41am)
Python is my first programming language and i'm still learning from various tutorials but I am wondering about a few things that I haven't gotten to yet... Curiosity is a bitch...

Questions:
1) This will likely end up in a future tutorial... But anyone know of an easy-to-understand guide that explains how to assign code to buttons in a simple window/program?


Look into Tkinter, terrible example code from: http://effbot.org/tkinterbook/button.htm

Code
from Tkinter import *

master = Tk()

def callback():
print "click!"

b = Button(master, text="OK", command=callback)
b.pack()

mainloop()


Quote (Metalkon @ May 7 2014 06:41am)
2) Anyone know of an easy-to-understand guide that will explain how to make an online "lobby" to connect players to a simple server side program to play games like pong/checkers/text-based-games?


Network programming isn't exactly “easy-to-understand” so this may have to come much later, Python may also not be the best language for what you are trying to do specifically here but maybe I misread your intentions.

If you insist, check here for something: https://wiki.python.org/moin/PythonGames

Quote (Metalkon @ May 7 2014 06:41am)
3) What programs would you guys recommend for a beginner with this language who wishes to make simple games?

My short term goal (and motivation) is to be able to make extremely basic online games (think server side text games or checkers) by some time next month.


I would suggest PyGame, maybe read: http://inventwithpython.com/makinggames.pdf

Making games in Python doesn't interest me, good luck with it though and don't ask me for help because I suck.


Member
Posts: 1,208
Joined: Aug 1 2013
Gold: 50.00
May 7 2014 11:44am
If your goal is to make a basic game and you're not dead set on using Python, you could check out Unity coded in C#
Go Back To Programming & Development Topic List
Add Reply New Topic New Poll