Data Realms Fan Forums
http://45.55.195.193/

Script: Restricting Aim Angle to for a turret.
http://45.55.195.193/viewtopic.php?f=75&t=25397
Page 1 of 1

Author:  Kettenkrad [ Fri Sep 02, 2011 1:39 pm ]
Post subject:  Script: Restricting Aim Angle to for a turret.

Hello, .lua scripters of DRLFF.

Once again, I envy your ability to make weird ♥♥♥♥ happen in Cortex Command, and I seek guidance from your brilliant, logical minds.

Using some of Witty's scripts to attach ACrabs to a dropship, I have a hulking troop transport with a couple of MG mounts. What I would like to do is restrict their aim range to something like what's in the diagram below:
Image
Script so far (all of this is Witty's)

Any help would be appreciated!

Author:  Mehman [ Fri Sep 02, 2011 2:31 pm ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

I'd like to help you but for that I would need the whole .rte to be able to make tests.

Author:  Roast Veg [ Fri Sep 02, 2011 2:41 pm ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

Start off by defining two turrets, one for left and one for right. Then attach these scripts to them.

Left:
Right:
Credits to Abdul Alhazred for the original.

Sadly, these restrictions do only apply to an equal rotation above and below the horizon. I'll come back if I find a way to do it otherwise.

Author:  Kettenkrad [ Fri Sep 02, 2011 3:36 pm ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

Thanks for the help guys, Roast, that script says that the 'gun' is a nil value or something, I attached the separate ones to the two turrets. Mehman, I'll upload the .rte in the morning, well, later on today. Its quite late here.
Thanks again for the help, both of you.

Author:  Gotcha! [ Fri Sep 02, 2011 3:44 pm ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

UFO's! I wish the Zealots would have a ship like that. My compliments on this awesome looking device. :grin:

Author:  Roast Veg [ Fri Sep 02, 2011 5:57 pm ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

Are the turrets HitsMos = 1?

Author:  Kettenkrad [ Sat Sep 03, 2011 4:59 am ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

Roast Veg wrote:
Are the turrets HitsMos = 1?


Yeah, it's located in Wehrmacht.rte/Actors/Craft, it still throws errors :(

Attachment:
Wehrmacht.rte.7z [8.38 MiB]
Downloaded 174 times

Author:  Mehman [ Sat Sep 03, 2011 6:00 pm ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

Attachment:
Wehrmacht.rte.7z [8.37 MiB]
Downloaded 175 times

Author:  Kettenkrad [ Sun Sep 04, 2011 3:17 am ]
Post subject:  Re: Script: Restricting Aim Angle to for a turret.

Mehman have I ever told you that I love you you're a cool dude? Thanks for the help, works great now.

Page 1 of 1 All times are UTC [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/