Why is this not working?

0 favourites
  • 6 posts
From the Asset Store
2D fighting template based in the game that defined the fighting games genre.
  • Hey folks, I have this events set up:

    I don't know why it is not working. The door is suppose to open when either hero or box is on the button and returns back when none of them is overlapping it. But it only works only with hero, nothing happens when I push the box on it. Not even box alone triggers the action. Dont know why. Can it be because of the hysics behaviour? It should not affect it, as long as the collision polygons collide it should be triggered. but its not, only with the player. Any ideas? I am getting a headache from this :(

    Thanks for help

    Tagged:

  • Does it work if you make two separate On Collision events for the hero and the box?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • No it does not, it only worked for both when I disabled the door return action. Then it opens on colision of both. But once I have the door closing event in place it works on player only

  • I'd suggest there is an error somewhere else in your events causing the issue. I have just replicated your exact code and it works perfectly, although you have no redundancy for if both the player and box are overlapping the button, which will cause it to move twice. You could fix this by moving the door to var_doorYvalue+200 instead of self+200.

    Also check that you have collisions enabled on your box sprite

    Post your project file if not.

  • Thanks for reply,

    I have also thought there might be problem somewhere else in the code. I was also considering the possibility of different behaviors - that they might affect it. Players behavior is "fine" with the event but boxes is not. I will try to examine ret of the code and see if I find something.

    How do I post the project file here? I am new here and never did it before...

    Thanks again

  • To post your project file you'll need to upload or save your project file to a cloud service like google drive etc. then create a shareable link and copy that link into a post in this thread.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)