Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Windows / convert 3d angle to object position

Author
Message
46n4364
6
Years of Service
User Offline
Joined: 2nd Sep 2018
Location:
Posted: 2nd Feb 2019 05:39
how convert 3d angle to 3d object position
want even have it rotate to nearest angle there object is so it will be faster to rotate to 3d object
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 13th Feb 2019 08:10
not sure what your asking but il have a go
SetObjectRotation(id,angX,angY,AngZ) will set a object to any angle
then moveObjectZ(id,1) will move in the direction you have rotated towards

if you want to fire a bullet at a given angle in 3D space there is vector mathematics required
fortunately AppGameKit has some methods that make this easier by simply setting your bullet at the
desired angle and using the move command to determine the next position vector the method
below uses this


PS This is how its done in AppGameKit there is no mention on what language you would like to do this ine
fubar

Login to post a reply

Server time is: 2024-11-17 22:26:44
Your offset time is: 2024-11-17 22:26:44