How do I create a 3D rotating tank turret?

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Post Reply
User avatar
BLACKWIDOW
Posts: 11
Joined: Sat Apr 15, 2017 1:14 pm

How do I create a 3D rotating tank turret?

Post by BLACKWIDOW »

After looking into Russian Overkill's Warpocalypse code I still cannot understand how a 3D rotating tank turret would work.
Can anyone explain how would it work and what would it look like please?

Thanks! :)
User avatar
kodi
 
 
Posts: 1361
Joined: Mon May 06, 2013 8:02 am

Re: How do I create a 3D rotating tank turret?

Post by kodi »

You probably want to take a multi-actor approach, so the chassis is one actor which spawns the turret as soon as it enters play. The turret will then constantly adjust its position to be over the chassis. This way they can turn independently by simple setting angle.
Post Reply

Return to “Scripting”