Gun not working

so I’m trying to remake the 1993 DOOM game but its top down, the gun wont face the way Doom Guy is facing. help Flowlab Game Creator - DOOM (1993) but top down

how about making the gun be the one with the doom guy, like the gun and the doom guy be in 1 object

I don’t want to do that cause I’m adding the other guns too

Animation can actually solve it, if you want to keep the gun animation with doom guy to the next level, tell me and I will send the example one in my new project game.

ok, when I get to that point I will say it

little nice tip: you can make your character like that one child I forgot the name in undertale, it can help you make the gun and model of the player better. (just little bit same)

1 Like

nah btw their name is frisk

1 Like

thanks to remind me, buddy

1 Like

I would probably do something like the example I made below, which changes the gun’s rotation based on what direction the player object, “DoomGuy” is moving.

I also recommend that you make the gun sprite slightly larger using a method below. The yellow lines on either side help add a larger hitbox, so when the gun is attached onto the player, it is placed infront of where the player is facing instead of on top. Then make an animation for the gun that doesn’t have the yellow lines and have it Always loop so that way the gun only appears as a gun without the yellow lines being visible, since Animations don’t change the objects hitbox, but the original sprite is what determines it.

Another tip, you can remove the original gun that’s on the level, since the Attach behavior spawns a new one on top of the player anyway, that way you don’t have to have the collision check to delete the gun on the level.

about the thing with the yellow lines, can I get something more simpiler, I cant handle alot of coding stuff, I just need simple and easy

looks nice, I will try it with this option for my game.

You technically don’t have to use the yellow line method since the gun still aims in the direction of the player object, but I would highly recommend using it since the gun is just directly ontop of the player and not infront of them.

I’ll just keep it, less work for me

I don’t want to be rude since it’s your game and I don’t want to overwhelm you, but anytime you can add just a slight extra code to make the game more appealing, I would recommend you take it. As I’ve seen many games come and go on flowlab, I will admit, even the smallest details help in most cases.

Plus:


You just need a single animation like this, while the original object is the one with the yellow lines on either end.

And then just two behaviors to have the animation trigger. Just make sure the animation is on loop or remain on last frame so it doesn’t only appear for half a second and return back to the original object.

1 Like