How do I make the AI get a specific variable on collision?

0 favourites
  • 1 posts
From the Asset Store
Easily store, modify, read and manipulate colors with Color Variables!
  • In order to guide an AI controlled player I've set up invisible boxes that tell it which direction to move and when to jump and all that. I've set an instance variable called JumpStrength to tell the AI how high to jump on the individual boxes (by default the strength is set to 350).

    I set down two jump boxes, and changed the second one's strength to 650 while leaving the original one at 350, but when the AI collided with it the jump was only a 350, the same as the original. I think the AI isn't reading the instance variable of the one it collided with, but rather the value the object as a whole has. How do I get it to read the individual boxes' variable?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)