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.

AppGameKit Studio Chat / Throwing Object

Author
Message
MateiSoft
11
Years of Service
User Offline
Joined: 22nd Oct 2012
Location:
Posted: 1st Jan 2020 17:17
Hello guys,

I am trying to simulate a grenade throwing method and I came up with this:



The problem is that when I rotate the camera, which the dummy object is attached like:


The cloned object slightly rotates depending on the camera's angle and it deviates the object's direction.

Can someone, kindly, provide me with some tips or some correction on how can I throw the object without altering it's rotation like that?

Thank you very much!
www.alexmatei.com
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 1st Jan 2020 17:46
I think the problem is you need to use a camera dolly, I have seen threads with this done ( I think blink had one)
that way the camera is actually fixed to your player just offset and may rotate etc around
the player
MerryChristmas Everyone
fubarpk on Itch...………...https://fubarpk.itch.io/
fubarpk on googleplay..https://play.google.com/store/apps/developer?id=fubarpk
MateiSoft
11
Years of Service
User Offline
Joined: 22nd Oct 2012
Location:
Posted: 1st Jan 2020 18:51
Problem solved! I tested out your theory and it worked, also. The main problem was that I was testing out the camera movement with RotateCameraLocalY instead of SetCameraRotation. That gave different values fof yone and ytwo.

Thank you!
www.alexmatei.com

Login to post a reply

Server time is: 2024-04-26 05:12:09
Your offset time is: 2024-04-26 05:12:09