User Tag List

Results 1 to 4 of 4

Thread: Having trouble linking objects together (Especially without alterable values)

  1. #1
    Clicker Fusion 2.5 (Steam)

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

    Having trouble linking objects together (Especially without alterable values)

    Kind of hard to explain, but basically I want to make it so that enemies in my game use the "Platform Movement Object" to move around and collide with walls. The problem is, I don't know how to arrange the code to work properly. I tried making it so that each enemy had a flag that, when off, would create a platform movement object and then set an alterable value on the enemy to match the fixed value of the Platform Movement Object. I don't know how well that would work, but it seemed it wasn't doing anything right. I suspect the problem is in the coding, as I am having a hard time figuring out how to set up the conditions so it knows which enemy goes with which Platform Movement Object and whatnot. I was hoping I could do something like
    Alterable Value A of "Enemy" == Fixed value of "Platform movement object"
    (Platform Movement Object) Test for obstacle overlap
    (Enemy) Is overlapping a backdrop
    >(Platform Movement Object) Selected Object Overlaps an Obstacle

    But the enemies just fell through the platforms, very inconsistently too, like something was colliding at some point?
    How can I more consistently link these? This would help out with stuff like vision cones as well.

  2. #2
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Popcorn's Avatar
    Join Date
    Jun 2006
    Location
    Norway, Bergen
    Posts
    2,350
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    I'm pretty sure you can actually just use automatic pairing for this.
    Jus make sure you have an equal ammount of enemies and Platform Movement Objects, and use it as normal, without have to worry about id's or anything like that.

    For example:

    * Start of frame
    - Create Platform Movement Object a 0,0 from Enemy

    * Start of frame
    - PMO: Set object to Enemy

    * PMO: Test for obstacle overlap
    + Enemy is overlapping platform
    - PMO: Collisions -> Object does overlap with an obstacle

    It is important you know how automatic pairing works. For instance you need to be careful when using conditions, and often have to find workarounds. I'm sure there are articles or forum topics on the subject that you can read. Another way, instead of making one pmo for each enemy, is to always loop through each enemy and assign the one pmo object to them as needed. I guess you'll have to find the approach that suits you the best

  3. #3
    Clicker Fusion 2.5 (Steam)

    Join Date
    Jan 2018
    Posts
    9
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I tried that. It didn't quite work but it got me going in the right direction! It turns out the system is way better at picking up what I'm trying to tell it than I thought! Also, the PMO does have flags and alterable values. Though there were some annoyances, like you have to make the Platform Movement Objects one at a time to get them to link properly, but you can't pick PMOs at random, but other than that it works! Thanks

    Also, in reference for the future, the PMO needs to set its object to Enemy as soon as it is created, doing it in another event does not seem to work

  4. #4
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Popcorn's Avatar
    Join Date
    Jun 2006
    Location
    Norway, Bergen
    Posts
    2,350
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    I suggest you read up on automatic pairing of objects. Check out this thread: https://community.clickteam.com/threads/63801-Automatic-pairing

    The most important thing to know is that there should be a one-way communication between the linked objects. One object should be the main object which contains the data and that you can interact with, and the other one should be a dummy object that gets all its data from the main object. What object the main object is linked to shouldn't matter, as the dummy objects should all be the same. So if the enemy object is the main object, and you want to change it's speed, set the speed in one of the enemy object's alterable value and always set the PMO's speed to that value. Don't interact with the dummy object directly as an individual object.

Similar Threads

  1. Keep various objects Alterable Values over frames?
    By AndyBazooka in forum Fusion 2.5
    Replies: 3
    Last Post: 3rd November 2017, 05:06 PM
  2. Adding alterable values of multiple objects
    By Digitalic in forum Multimedia Fusion 2 - Technical Support
    Replies: 9
    Last Post: 11th June 2010, 02:40 PM
  3. Alterable values in ALL objects
    By waffles in forum Multimedia Fusion 2 - Technical Support
    Replies: 5
    Last Post: 23rd August 2006, 07:42 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
  •