Hello,
So, I am working on a 2.5d game and I'm trying to make the character drop grenades.
The problem is that when I drop th grenade, it only drops left, so if I'm walking in right, it wil drop the grenade in the other side.
How can I fix it?
Cheers!
1 Answer
1
Try having a blank object as a child of your player object and position it in front of him were you want the grenade to appear. Then instantiate the grenade at its position. That way the grenade always spawns in front of your player object.
In short use a blank object in front of your player as a grenade spawn point.
Yes, I try that but I want to spawn the grenade in front or behind depending on the position of your player
– anon7488618you could have two spawn points or just instantiate at transform.position + offset where offset is a vector3 of how far in front or behind of the player you want the grenade to spawn
– anon85599651ok, I got it thank you for awnser
– anon7488618