Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Helipad tutorial for renegade modders
Helipad tutorial for renegade modders [message #485851] Sun, 09 February 2014 02:24 Go to next message
jonwil is currently offline  jonwil
Messages: 3557
Registered: February 2003
Karma: 0
General (3 Stars)

In scripts 4.1, it is possible to have a building in your map that works as a helipad. It will be totally separate from the weapons factory/airstrip in that you will be able to buy helicopters even if the war factory/airstrip is down and you will be able to buy ground vehicles if the helipad is down. You can even have someone buying a helicopter and someone else buying a ground vehicle at the same time.

Firstly, in order to use this functionality you need to be using the sidebar in your map.
Follow this tutorial http://www.renegadeforums.com/index.php?t=msg&goto=485846&#msg_485846 to set up the sidebar (make sure to read part 2 and follow that)
You also require scripts 4.1 so make sure you have it installed and working in leveledit

You also need the attached helipad_cinematic.txt file in your map mix file (it relies on the XG_HD_HTraj.w3d file from the stock renegade always.dat file)

Also, open the C&C_blah_tt.ini file you made in the sidebar tutorial and add the following:
VehicleFactoryVehicleLimit=x
AirFactoryVehicleLimit=y
x being the number of ground vehicles players are allowed to build and y being the number of air vehicles players are allowed to build (and yes the numbers are separate)

To set up the helipads, firstly you need to put a building on your map to act as the helipad. Create it like any other building (give it MCTs, PTs, damage aggregates and whatever else you want for it)
Then open leveledit and open your map.
Create a new preset underneath "simple". This will be the helipad fly-in cinematic object. Untick the "DefaultHibernationEnable" checkbox. Tick the "NotTargetable" checkbox. Tick the "IsEditorObject" checkbox. Tick the "IsHiddenObject" checkbox. Leave all the other settings at the default. Attach the script Test_Cinematic to this object and give it the parameter helipad_cinematic.txt

Next, you need to create a landing position object. This will determine where the helicopters will fly in at.
You will need one for GDI and one for Nod. (the fly-in cinematic object is used for both teams).
Make this one a copy of the Dave's Arrow preset with no changes to the settings.

Next, go to buildings and then air factory. Create an instance of this (one for each team). If you dont see air factory in the list it means you dont have 4.1 installed properly.

Set this preset up as for any other building with all the usual settings and scripts.
Make sure to set the building type to "helipad"
Set LandingPosDistance to 1000
Set CinematicTimer to 14.0
Set CinematicSlotIndex to 4
Set Landing Position Object to the landing position object preset created earlier.
Set fly-in Cinematic Object to the fly-in cinematic object preset created earlier.
No special scripts are required for this building.

Once you have done this, place the helipad building controllers as per normal for buildings. Then place several (2 or 3 works good) of the landing position objects (for the right team) around the helipad at ground level. (these will determine where the helicopters land at).

No you cant have more than one helipad per team, the logic doesn't support it.

Now you need to set up the war factory/airstrip to not build helicopters anymore and to have them be built at the helipad.
Create temp presets of the war factory and airstrip (or if you are already using temp presets, open them). The only change you need to make is to tick the BuildGroundOnly checkbox.

If you have any questions (or cant get this to work), post in this thread or hit me up on IRC/IM and I will do my best to answer them.


Jonathan Wilson aka Jonwil
Creator and Lead Coder of the Custom scripts.dll
Renegade Engine Guru
Creator and Lead Coder of TT.DLL
Official member of Tiberian Technologies
Re: Helipad tutorial for renegade modders [message #485852 is a reply to message #485851] Sun, 09 February 2014 02:38 Go to previous messageGo to next message
jonwil is currently offline  jonwil
Messages: 3557
Registered: February 2003
Karma: 0
General (3 Stars)

Also, when using this you need to tick the allow flying vehicles checkbox under edit-level settings in LE, generate flight data (as part of pathfinding) and have a proper flight roof (i.e. all the things you normally need for a flying map).


Jonathan Wilson aka Jonwil
Creator and Lead Coder of the Custom scripts.dll
Renegade Engine Guru
Creator and Lead Coder of TT.DLL
Official member of Tiberian Technologies
Re: Helipad tutorial for renegade modders [message #485876 is a reply to message #485851] Sun, 09 February 2014 12:17 Go to previous messageGo to next message
Mauler
Messages: 448
Registered: May 2003
Location: Alberta, Canada
Karma: 0
Commander
http://www.youtube.com/watch?v=QvVuJrKnCOc&feature=youtu.be

there it is in action... had some bugs loading the mix on the FDS... worked on LAN but crashes the client on load..
Re: Helipad tutorial for renegade modders [message #485882 is a reply to message #485851] Sun, 09 February 2014 14:18 Go to previous messageGo to next message
jonwil is currently offline  jonwil
Messages: 3557
Registered: February 2003
Karma: 0
General (3 Stars)

If you are getting crashes on load on the client, try this:
Load the map into leveledit.
Choose "object - fix ID collisions"
Then re-export the map and test it again.

If its still crashing, get me the map mix file, the mod folder (or lvl file and bits) and the crashdump.


Jonathan Wilson aka Jonwil
Creator and Lead Coder of the Custom scripts.dll
Renegade Engine Guru
Creator and Lead Coder of TT.DLL
Official member of Tiberian Technologies
Re: Helipad tutorial for renegade modders [message #485886 is a reply to message #485851] Sun, 09 February 2014 14:49 Go to previous message
Mauler
Messages: 448
Registered: May 2003
Location: Alberta, Canada
Karma: 0
Commander
Yes that fixed it!! Thanks Thumbs Up
Previous Topic: Changes to leveledit (including temp presets) in scripts 4.1
Next Topic: level edit strings are gone!
Goto Forum:
  


Current Time: Wed Dec 18 00:49:11 MST 2024

Total time taken to generate the page: 0.00782 seconds