Page 1 of 2 1 2 LastLast
Results 1 to 10 of 11

Thread: Active Object Perimeter movement

  1. #1
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)
    alexexhowl's Avatar
    Join Date
    Jan 2015
    Location
    Yakutsk
    Posts
    72
    Blog Entries
    1

    Active Object Perimeter movement

    Did abybody knows how to realize perimeter object movement? object 1 moves all along edges of object 2

    23.png

  2. #2
    Are you trying to make it trace any object or just a set object?

  3. #3
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)
    alexexhowl's Avatar
    Join Date
    Jan 2015
    Location
    Yakutsk
    Posts
    72
    Blog Entries
    1
    tryin to make mario game circular saw path movement. Where Saw moves along the checkpoints. Using only 2 actives - circular saw and checkpoint.

  4. #4
    ouch just wrote a reply and it didn't take >
    oh well,

    Anyway, I'll give you the short version of what I said.

    put the hotspot in the center of the saw
    move the saw in the direction of the checkpoint
    when the checkpoint is overlapped, switch it to the next point on the perimeter

  5. #5
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)
    alexexhowl's Avatar
    Join Date
    Jan 2015
    Location
    Yakutsk
    Posts
    72
    Blog Entries
    1
    Quote Originally Posted by dascribe View Post
    ouch just wrote a reply and it didn't take >
    oh well,

    Anyway, I'll give you the short version of what I said.

    put the hotspot in the center of the saw
    move the saw in the direction of the checkpoint
    when the checkpoint is overlapped, switch it to the next point on the perimeter
    Geez... is that possible with 2 actives?

  6. #6
    You are moving the checkpoint each time it is reached.
    So if there were 5 points in the perimeter of your object, you would move the checkpoint like : 1-->2-->3-->4-->5-->1
    codeish ex:
    make a var for current checkpoint

    if current checkpoint =1
    then set checkpoint xpos to 123
    set checkpoint y pos to 123

    if current checkpoint =2
    then set checkpoint xpos to 123
    set checkpoint y pos to 246

    etc...

    then

    if xpos of saw =xpos of checkpoint and
    if ypos of saw =ypos of checkpoint and
    checkpoint counter <5 (total number of points)
    then add 1 to checkpoint counter

    if xpos of saw =xpos of checkpoint and
    if ypos of saw =ypos of checkpoint and
    checkpoint counter = 5 (total number of points)
    then set checkpoint counter to 1

  7. #7
    k,

    Made a quick demo
    code looks a bit bulky lol
    but I like bulky and solid vs streamlined and quirky
    the reason I added <=x +2 etc, is because it makes it less picky about moving on to the next point if it has a bigger criteria target to hit.
    Attached files Attached files

  8. #8
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)
    alexexhowl's Avatar
    Join Date
    Jan 2015
    Location
    Yakutsk
    Posts
    72
    Blog Entries
    1
    wow, how complicated is your code. Looks like you don't understand me.
    Recently i made this example: circular saw examples.mfa
    But my example works only on simple cube-shape, i dunno how make them move along complicated shapes.

    23.png

    Quote Originally Posted by dascribe View Post
    k,

    Made a quick demo
    code looks a bit bulky lol
    but I like bulky and solid vs streamlined and quirky
    the reason I added <=x +2 etc, is because it makes it less picky about moving on to the next point if it has a bigger criteria target to hit.

  9. #9
    Lol,

    Did you run it?
    So you didn't want the object to keep going around the perimeter?

    Just take a look at the code. It's not as bad as it looks on the surface and if you play around with it, you may be able to reduce it a bit.
    Bottom line, code just says to change the direction of the "saw" every time it meets a condition.
    If you are planning on running multiple saws around the same perimeter or over lapping perimeters, you may want to make a method for switching which checkpoint is the target for the saw when the saw reaches a checkpoint.

  10. #10
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)
    alexexhowl's Avatar
    Join Date
    Jan 2015
    Location
    Yakutsk
    Posts
    72
    Blog Entries
    1
    it's uses binded coordinates right? it will be a little messy to find/check coordinates in frame editor and put em to events. What if "saw thing" objects will be 10 in 1 frame? i must find x,y of everything?

Page 1 of 2 1 2 LastLast

Similar Threads

  1. Replies: 1
    Last Post: 7th December 2016, 02:22 AM
  2. Replies: 2
    Last Post: 5th October 2016, 09:45 AM
  3. Replies: 4
    Last Post: 14th April 2014, 10:47 AM
  4. Beta 15, Testing backdrop object, active object and drag and drop movement
    By Fernando in forum Android Export Module Version 2.0
    Replies: 3
    Last Post: 9th February 2012, 11:57 PM
  5. A possible bug? With active object movement change
    By ionside in forum iOS Export Module Version 2.0
    Replies: 1
    Last Post: 8th August 2011, 01:49 PM

Posting Permissions

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