How to Script an Object to turn off it's Animation While No Player is Inside the Boundary?

Discussion in 'Halo and Forge Discussion' started by #993, Dec 13, 2016.

  1. #993

    #993 Legendary

    Messages:
    1
    Likes Received:
    0
    I'm currently working on Barrens, and I'm trying to figure out how to turn off an FX's animation whilst no player is in the boundary. The FX I am working with is Fire [Human Jet; X-Small], if that helps in any way.
     
  2. Egggnog

    Egggnog Game Crashers

    Messages:
    267
    Likes Received:
    331
    Set the FX to despawn when the player enters its boundary maybe? Make sure you've got your boundary at a decent size too.
     
  3. CrystalEggnog

    CrystalEggnog Legendary

    Messages:
    17
    Likes Received:
    17
    Is the boundary attached to the FX itself, or a nearby object? If it's attached to the FX itself, you only need two scripts: One for Boundary Check - Players - Continuous - DO Despawn, and one for Boundary Check - Players - Exit - DO Spawn.

    If the boundary is tied to something else, have it set up so when a player is CONTINUOUSLY in the boundary, it'll set a power channel to ON, and when a player exits the boundary, it sets the power to OFF. Then, script the FX so when the power is ON, it despawns, and when the power is OFF, it spawns.

    You'll want the CONTINUOUS boundary check because if you otherwise have it set to ENTER, let's imagine two people enter the boundary, and the FX turns off...but then one player leaves the boundary, and it turns back on, with the second player still in the boundary. You want it to continually be searching for a player so it remains OFF while someone is in the boundary.
     
    ExTerrestr1al likes this.
  4. ZORO

    ZORO Spartan III

    Messages:
    15
    Likes Received:
    3
    Great solution
     

Share This Page