User Tag List

Results 1 to 7 of 7

Thread: Destroy if you make a wrong turn in a maze...?

  1. #1
    Clicker Fusion 2.5

    Join Date
    Jan 2018
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Talking Destroy if you make a wrong turn in a maze...?

    Hi guys!

    I'm working on a maze game where you have to follow a "leader" through a complex series of turns and crossroads. I've got my Leader set up with Path Movement, moving on a path through the maze, and my Player has 8-direction movement - the Leader and Player seem to be working well.

    Here's the part that's hurting my brain:
    I want the Player to be Destroyed if they make a wrong turn, and I don't know how to do that.
    The Leader path crosses over itself and re-travels the same path in some places, so I can't just use collision walls to trigger the Destroy because the paths can't be permanently blocked.

    Basically, you have to follow the exact path that the Leader goes, in sequence.

    So if you're on a grid, and the leader goes up 2 spaces, then right 6 spaces, then down 3 spaces, then left 3 spaces...
    and the Player goes up 2 spaces, then right 6 spaces...but MISSES the down turn (either fails to make the turn at that intersection or turns the wrong way) - DEATH!!!! and Restart!

    Does that make sense?

    Anyone have any ideas for how to accomplish this?

    The second tricky part:
    I'd also like the Player to be able to turn off the path in certain places to grab Bonus tokens. The tokens would be on"offshoot" dead-end paths that the Leader never goes down, but that the Player can quickly zip into, grab the token, then get back to following the Leader. In that case, when the Player takes a turn that is not on the Leader's route, I DON'T want to Destroy the Player. So maybe I can designate those Bonus Offshoot areas as "safe" somehow?

    I plan on making each level a new maze with a new path to follow and jump to the next frame when you reach the end, so it only has to run through the path sequence once per frame.

    PS: I'm a noob, just starting to get the hang of fusion 2.5 - never really coded before, but I'm learning!

    Any ideas, examples, etc. for how to do this stuff would be much appreciated!

  2. #2
    Clicker Fusion 2.5 DeveloperHTML5 Export Module

    Join Date
    Jun 2006
    Posts
    1,436
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    Sounds like what an ant does to follow another ant. The lead ant will leave a scent trail of droplets that evaporate with time to mark a trail for other ants to follow. The next ant will smell the scent and try to follow unless the scent has evaporated and it gets lost or killed.

    As the lead person moves over a space set a integer for the space that is then counting backwards to zero. The next player will follow if the space is not zero. If it is zero ... well then the following player will die.

  3. #3
    Clicker Fusion 2.5 DeveloperHTML5 Export Module

    Join Date
    Jun 2006
    Posts
    1,436
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    For the tokens mark the token trails spaces at the start of game with a fixed integer (like 5) that "does not count backwards" with time to zero. Instead, wait until the "following" person takes the trail and the "token trail spaces" start the countdown for "the spaces of the trail leading to the token" to zero. That way, if in the future the "following" person tries to take the trail they will die since the trail spaces will be marked as zero.

    Well you get the ideas I hope.

  4. #4
    Clicker Fusion 2.5

    Join Date
    Jan 2018
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thank you, droberson! I'll try to wrap my head around that - unfortunately, I am a visual artist with a remedial grasp of math, so this is largely Greek to me!
    However, after doing some more fiddling, I think perhaps it would play better (and be simpler) to allow players to take wrong turns, but die if they get too far behind. So maybe when the Leader reaches the end of the maze, it'll wait for several seconds and if you don't catch up and get to the end within that time frame, you'll have to restart.

  5. #5
    Clicker Fusion 2.5 DeveloperHTML5 Export Module

    Join Date
    Jun 2006
    Posts
    1,436
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    I am visual myself also. I agree with you ... I think allowing the players to take wrong turns or even traps in the maze would be fun. A very cool idea.

  6. #6
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export ModuleSWF Export Module
    Popcorn's Avatar
    Join Date
    Jun 2006
    Location
    Norway, Bergen
    Posts
    2,283
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    Create an active object and duplicate it all over the place in the Maze where the Leader can move. Name it Trigger. It must be big enough that you can't miss it. Rename one of Trigger's flags to LeaderWasHere. When the leader overlaps Trigger, set Trigger's LeaderWasHere on.
    Now create an event that destroy the player if it overlaps Trigger and LeaderWasHere is off.

  7. #7
    Clicker Fusion 2.5

    Join Date
    Jan 2018
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Oooo..I like that!

Similar Threads

  1. Whats a Way I can Make a Turn Based game movement...
    By Epic_Elephant in forum Fusion 2.5
    Replies: 4
    Last Post: 2nd May 2015, 05:07 PM
  2. Trick to make object turn slowly toward a target
    By Michael_Gummelt in forum Multimedia Fusion 2 - Technical Support
    Replies: 23
    Last Post: 22nd May 2012, 10:51 PM
  3. How do i make my car be able to drift (180 turn)?
    By GaryFreeman in forum The Games Factory 2 - Technical Support
    Replies: 1
    Last Post: 25th August 2011, 02:33 PM
  4. How to make NPCs move randomly throughout a maze
    By RickyRombo in forum Multimedia Fusion 2 - Technical Support
    Replies: 12
    Last Post: 9th September 2009, 11:59 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •