Search Result

Collapse
2 results in 0.0045 seconds.
Keywords
Members
Tags
adventure
  •  

  • matt murray
    started a topic How do you simulate a dice roll in python?

    How do you simulate a dice roll in python?

    I'm writing a text based adventure game and was wondering if there was a way to "Roll Dice". An example of what i am trying to use this for would be attacking or defending in the game. If they get above or equal to a certain number It would be considered a hit. I would also need this same automated dice rolling for the enemies in the game.

    Thanks

    Matt.
    See more | Go to post

  • matt murray
    started a topic Is there something similar to GOTO in python?

    Is there something similar to GOTO in python?

    So I'm trying to write a text based adventure game and there are going to be points where you'll have to travel back to previous rooms. I wasn't really sure of the best way to go about this. Also along the way you'll collect 3 keys and various loot. any help would be great. thanks -Matt


    Code:
    #Doors test
    
    def main():
    
        endprogram = 'no'
    
        while endprogram == "no"
    ...
    See more | Go to post
    Last edited by bvdet; Nov 30 '10, 01:49 PM. Reason: Add code tags
Working...