• Hey! Guest! The 40th (!!!) GMC Jam will take place between February 25th, 12:00 UTC to March 1st 12:00 UTC. Why not join in this very special anniversary jam! Click here to find out more!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

infant runner wall crushed player on silde of screen



I trying to make an infant runner. I am having trouble when my player gets crushed because of a moving wall.
What I need is help with is killing the player when they are up against the screen and a moving platform crushing them. What happens now is he gets pushed back a little and hit the wall again till floor. Then you jump over the wall. If you don't make it and get pinched between wall and screen you just go stay put and the wall just keeps going. You can move after the wall through. Oh and I gotta lot of enemies gotta lot of enemies and they trying to shoot me down of my energy....... LOL

x += hsp
xmo = moving platform speed. I use this venerable cause when the game gets faster as time goes on. I should say that I have not tested this yet.... but I have it set up that in mind. The theory is as the game timer (what you see when you play the game, timer) increases the xmo will increase. I am using an alarm to call the random floorgen script. So I will set alarm0 off turn on alarm1 which will have a shorter timer. You get get where I'm thinking. I bet there is a better way of doing this and I'm all ears. I feel like it should work but idk?

This is what my collision code looks like.

if (place_meeting(x+hsp+xmo,y,obj_solid)
if (hsp!=0)
while (!place_meeting(x+sign(hsp+xmo),y,obj_solid))
motionspd = 0;

Is anybody able to help with this?