HOW TO MAKE EVENT ABLE TO PASS THROUGH THE PLAYER BUT STILL AFFECT THE PLAYER WHEN THE EVENT TOUCHES THEM?
Posts
Pages:
1
Im making a game where the player must dodge hazardous enemies and objects inorder to get to the exit and move to the next level but i ran into a problem
I need to make events that can pass through the player but they still affect the player whne it touches them.
Any way i can do this?
I need to make events that can pass through the player but they still affect the player whne it touches them.
Any way i can do this?
The underlying answer probably lies in setting the "Through" flag, and having either an "On Event Touch" or "On Player Touch" trigger for the events in question. I think "On Player Touch" refers to the player attempts to move into the postion of the event, whereas "On Event Touch" is when the event attempts to move into the player's position?
author=Marrend
The underlying answer probably lies in setting the "Through" flag, and having either an "On Event Touch" or "On Player Touch" trigger for the events in question. I think "On Player Touch" refers to the player attempts to move into the postion of the event, whereas "On Event Touch" is when the event attempts to move into the player's position?
Having the Through option on just makes them pass through the player and not trigger the event regardless of whether or not Event touch or player touch is on.
There should be a pretty simple fix for this. Make a parallel process event.
Make two variables. Call them Event X and Event Y. Set them to the following things:
Event X = Event (event number)'s X coordinate
Event Y = Event (event number)'s Y coordinate
Make two more variables. Player X and Player Y.
Player X = Event (Player)'s X coordinate
Player Y = Event (Player)'s Y coordinate
After doing both of these, make a conditional branch.
>If Event X = Player X
>> If Event Y = Player Y
>> (Insert whatever happens when you want the event to catch the player)
>> else
>>(empty)
>else
>(empty)
If there are multiple events, then you might have to do a seperate set of variables and conditional branch for each of them.
Here's an image of how the event should look in 2k3. For pretty much any of the engines it should look the same as this, I think, but I haven't used anything MV onwards, so I'm not 100% sure.

Make two variables. Call them Event X and Event Y. Set them to the following things:
Event X = Event (event number)'s X coordinate
Event Y = Event (event number)'s Y coordinate
Make two more variables. Player X and Player Y.
Player X = Event (Player)'s X coordinate
Player Y = Event (Player)'s Y coordinate
After doing both of these, make a conditional branch.
>If Event X = Player X
>> If Event Y = Player Y
>> (Insert whatever happens when you want the event to catch the player)
>> else
>>(empty)
>else
>(empty)
If there are multiple events, then you might have to do a seperate set of variables and conditional branch for each of them.
Here's an image of how the event should look in 2k3. For pretty much any of the engines it should look the same as this, I think, but I haven't used anything MV onwards, so I'm not 100% sure.

Pages:
1















