Re: Programming in autoit question, How do you order things

  • From: "Littlefield, Tyler" <compgeek13@xxxxxxxxx>
  • To: <programmingblind@xxxxxxxxxxxxx>
  • Date: Sat, 6 Oct 2007 16:10:19 -0600

right where you put the others.
Then, in your if statement, just call the relevant function.
If ($key="a") then
eventA()
Endif
sorta like that.

Thanks,
Tyler Littlefield.
Vertigo head coder
"My programs don't have bugs, just randomly added features."
msn: compgeek134@xxxxxxxxxxx
email: compgeek13@xxxxxxxxx
aim: st8amnd2005
skype: st8amnd127
  ----- Original Message ----- 
  From: alex 
  To: programmingblind@xxxxxxxxxxxxx 
  Sent: Saturday, October 06, 2007 4:07 PM
  Subject: Re: Programming in autoit question, How do you order things


  Sorry if I am asking to much but can you show me where to put each Funcsion?
    ----- Original Message ----- 
    From: Littlefield, Tyler 
    To: programmingblind@xxxxxxxxxxxxx 
    Sent: Saturday, October 06, 2007 6:05 PM
    Subject: Re: Programming in autoit question, How do you order things


    that would be because you've got all the if statements in a row.
    Create functions for each room, and each event.
    HTH,
    Thanks,
    Tyler Littlefield.
    Vertigo head coder
    "My programs don't have bugs, just randomly added features."
    msn: compgeek134@xxxxxxxxxxx
    email: compgeek13@xxxxxxxxx
    aim: st8amnd2005
    skype: st8amnd127
      ----- Original Message ----- 
      From: alex 
      To: programmingblind@xxxxxxxxxxxxx 
      Sent: Saturday, October 06, 2007 4:02 PM
      Subject: Re: Programming in autoit question, How do you order things


      Thanks for actually offering to help. I have checked out all of the 
tutorials but cant figure it out.
      Wen you start the game it says press s to start, What i want is wen you 
press S it will start, and wen it prompts you to press Y or N  you can.
      But what is happening:
      Wen you start the game and press Y or N witch is supposed to be your 
second prompt it goes to its third audio but if you press S it will not let you 
press Y after the first prompt due to the fact that I do not know how to tell 
it the order of the events. (If you press the anser to the 4th prompt before 
you anser the first it jumps to that.
        ----- Original Message ----- 
        From: Littlefield, Tyler 
        To: programmingblind@xxxxxxxxxxxxx 
        Sent: Saturday, October 06, 2007 5:55 PM
        Subject: Re: Programming in autoit question, How do you order things


        what do you mean. I need to know what's happening before I help.

        Thanks,
        Tyler Littlefield.
        Vertigo head coder
        "My programs don't have bugs, just randomly added features."
        msn: compgeek134@xxxxxxxxxxx
        email: compgeek13@xxxxxxxxx
        aim: st8amnd2005
        skype: st8amnd127
          ----- Original Message ----- 
          From: alex 
          To: programmingblind@xxxxxxxxxxxxx 
          Sent: Saturday, October 06, 2007 3:45 PM
          Subject: Programming in autoit question, How do you order things


          Okay here is my script:
          ;creates a dummy window, and displays a message box when things are 
pressed.

          #include <GuiConstants.au3>

          #include <misc.au3>

          GuiCreate("Alien Obduction", 100, 100)

          ;create voice object

          GuiSetState()

          $sapi=ObjCreate("sapi.SpVoice")

          message()

          while (GuiGetMsg()<>$GUI_EVENT_CLOSE)

          if (_IsPressed("58")) then

          $sapi.speak("Good by.", 1).

          message()

          exit

          EndIf

          if (_IsPressed("53")) then

          $sapi.speak("Okay lets begin! You wake up in a strange place. Dimmly 
you become aware of your surroundings. You look around slowly. Where are you? 
What is going on? These are things that you plan to try and anser. You strech 
and look around. It seems to be some kind of operating room but you don't 
recognize any of the things you see. You do however notice an I V like device 
inserted in your arm. Do you dare pull it out? Press y for yes or n for no. ", 
1)

          message()

          EndIf

          if (_IsPressed("59")) then

          e1()

          EndIf


          wend

          exit

          func Message()

          $sapi.speak("Are you ready? Press s to start or press x to exit.", 1)

          EndFunc

          Func e1()

          $sapi.speak("You grab ahold and pull. Aww! It hurt but its over with 
now your free to stand up. Where would you like to go? The door d or the large 
machine m.", 1)

          EndFunc

          Okay I would like the events to happen in order. 

          What is currently happening is it is not running in stages,. Follow 
the gameline and listen to it. I can not explain everything that is happening.

Other related posts: