User Tag List

Results 1 to 6 of 6

Thread: Majora attempts scripting.

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Lynel Majora's Avatar
    Join Date
    Mar 2006
    Age
    32
    Posts
    1,197
    Mentioned
    24 Post(s)
    Tagged
    7 Thread(s)
    vBActivity - Stats
    Points
    4,391
    Level
    20
    vBActivity - Bars
    Lv. Percent
    94.67%

    Majora attempts scripting.

    Code:
    ffc script Patrol{
        void run(){
        while(true){
            if (this->X == Link->X+8 || Link->X-8) {
                this->Vx = 0;
                }
            if (this->X != Link->X+8 || Link->X-8) {
                this->Vx = 1;
                }
                
           Waitframe(); 
    }
    }
    }
    What this is supposed to do is move the FFC at a constant speed, stopping if it bumps into link. I have a vague idea of what i'm doing but naturally, it's not working. The FFC moves, sure, but it just zooms right by link. Before I made some edits the FFC would stop if it was completely overlapped with link. It was odd. I put link against a corner (of solid combos) and the FFC would stop. but it wouldn't stop no matter what otherwise. The lack of intuition to this backwoods game engine will be the aneurysm of me.

    This is a WIP script, taking it one step at a time. I don't want this to turn into a 300-line block of code for something as simple as moving a FFC between two points and being wary of link. However, the following behavior is what I'd like to achieve after working on this script some more:

    FFC moving between two points (specified with those scripting combo flags).
    ------ When it reaches that point, the FFC switches combos or tiles. They will be consecutive either way.

    Stops moving when Link bumps into the FFC. Resumes moving after he moves away.

    I think that's it. I would love to be able to have guards that move between more than 2 points but I don't want to incur the wrath of Zscript. Siiiiiiiiigh. @_@
    Last edited by Majora; 10-05-2012 at 01:58 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Armageddon Games is a game development group founded in 1997. We are extremely passionate about our work and our inspirations are mostly drawn from games of the 8-bit and 16-bit era.
Social