On 4 Jan 2013, at 19:20, Francesco Loffredo wrote:
> Ciaran Mooney wrote:
>> Thanks for the feedback.
>>
>> Steve, If I set the FPS to a default of say 30, the game seems to run at
>> this default FPS=30 regardless of the key pressed in the function.
>>
>> Dave, If I remove the the default v
Ciaran Mooney wrote:
Thanks for the feedback.
Steve, If I set the FPS to a default of say 30, the game seems to run at this default FPS=30 regardless of the key pressed in the
function.
Dave, If I remove the the default value at the start of the function and add it
to elif in the loop I get
Ciaran Mooney wrote:
> Sent: Thursday, December 20, 2012 3:35 PM
> To: d...@davea.name
> Cc: tutor@python.org
> Subject: Re: [Tutor] invalid literal for int error in Game loop
>
> Thanks for the feedback.
>
> Steve, If I set the FPS to a default of say 30, the g
On 12/20/2012 04:34 PM, Ciaran Mooney wrote:
> Thanks for the feedback.
>
> Steve, If I set the FPS to a default of say 30, the game seems to run at this
> default FPS=30 regardless of the key pressed in the function.
>
> Dave, If I remove the the default value at the start of the function and a
Thanks for the feedback.
Steve, If I set the FPS to a default of say 30, the game seems to run at this
default FPS=30 regardless of the key pressed in the function.
Dave, If I remove the the default value at the start of the function and add it
to elif in the loop I get the following error:
T
On 12/20/2012 03:51 PM, Steven D'Aprano wrote:
> On 21/12/12 07:40, Ciaran Mooney wrote:
>
>> def difficultyLevel():
>> FPS = ''
>
> Here you set the variable FPS to the empty string.
>
>> if event.type == KEYDOWN:
>> if event.key == ord('b'):
>> FPS = 30
On 21/12/12 07:40, Ciaran Mooney wrote:
def difficultyLevel():
FPS = ''
Here you set the variable FPS to the empty string.
if event.type == KEYDOWN:
if event.key == ord('b'):
FPS = 30
elif event.key == ord('m'):
FPS =
HI All,
Was hoping someone could help me with a problem I am having programming a game
using pygame.
I am trying to return a variable with a integer value defined by user input
from a function.
Basically the idea is to allow the player to select the level of difficulty by
selecting from a cho