@12Tyrant - Targeting bullets to the mouse position
SlickZero
Houston, TexasMember, Sous Chef Posts: 2,870
This discussion was created from comments split from: Question on GameSalad Limitations.
Comments
Hi, I have been having a lot of trouble figuring out how to use mouse position in order to shoot bullets. I have been working for hours on how to make it work. I have my actor facing my mouse and whenever i click the mouse, bullets come out. but the bullets don't go in the direction where the mouse is. The bullets just go in the direction where they are told to go when they spawn, but every tutorial i watch just seems to work out perfectly no matter which direction they are told. Thank you for reading
I Split this post into it's own topic.
how do i do that
i don't want to make a conference i just want an answer
if someone would like me to post the project on here and take a look just tell me
In the bullet actor, place two 'real' attributes, 1 & 2.
Then make two change attribute behaviours.
Change Attribute 1 to mouse X
Change Attribute 2 to mouse Y
Then send the bullet towards these two coordinates.
Is this what you are trying to do?
I know I'm not really good at explaining over typing i will try again. There is a gunman that is controlled with the wads keys. Where the mouse is the gunman actor is facing. Whenever the mouse is clicked bullets come out but instead of the bullets going in the direction where the mouse is they go in one direction.