Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Mod-related changes in scripts 4.1
Mod-related changes in scripts 4.1 [message #484631] Wed, 27 November 2013 22:18 Go to next message
jonwil is currently offline  jonwil
Messages: 3555
Registered: February 2003
Karma: 0
General (3 Stars)

Here is a list of changes in scripts 4.1 (which has just entered private beta testing) that modders and scripters might care about: (note that some of these new changes will require 4.1 on the client, I dont have time to analyze each change and figure out if it does or doesn't need 4.1)

We are now using Visual C++ 2012 to compile scripts.dll. Anyone who wants to be able to continue to do scripts.dll coding once the next build comes out (whenever that is) should obtain Visual Studio 2012 and install the updates for it (yes the Express Edition of Visual Studio 2012 will work for compiling scripts 4.1)

Support for a new file called e.g. C&C_City_surface.ini (or whatever for each map). This is read per-map and if it exists should be a full copy of surfaceeffects.ini with any desired per-map changes. This file IS cheat checked just like surfaceeffects.ini.

Changes to make Commands->Set_Obj_Radar_Blip_Color and Commands->Set_Obj_Radar_Blip_Shape work over the network (the old obsolete broken code for doing this is gone and as such Set_Obj_Radar_Blip_Shape_Player/Set_Obj_Radar_Blip_Color_Player are also gone)

Support for a new file called e.g. C&C_City_tt.ini (or whatever for each map). This is read per-map and allows you to use the sidebar, Air Factory objects, Naval Factory objects and a few other things on a per-map basis. Yes this means you can have a separate helipad which controls whether you can build helicopters (i.e. if its dead, you cant build helicopters anymore, if its alive and the war factory is dead, you can still build helicopters even though you cant build ground vehicles)
The following keywords are valid in the per-map ini file:
AirFactoryVehicleLimit
NavalFactoryVehicleLimit
VehicleFactoryVehicleLimit
BuildingRefillDisable
NodBuildingRefillDisable
GDIBuildingRefillDisable
NewTechLevel
GDIUpArrowTexture
GDIDownArrowTexture
GDIBackgroundTexture1
GDIBackgroundTexture2
NODUpArrowTexture
NODDownArrowTexture
NODBackgroundTexture1
NODBackgroundTexture2
AlternateSelectEnabled
GDIAlternateSelectTexture1
GDIAlternateSelectTexture2
GDIAlternateSelectTexture3
GDIAlternateSelectTexture4
NODAlternateSelectTexture1
NODAlternateSelectTexture2
NODAlternateSelectTexture3
NODAlternateSelectTexture4
Sidebar
SidebarSoundsEnabled
SidebarRefillSound
SidebarInfantrySound
SidebarVehicleSound

This per-map tt.ini file IS cheat checked (just like the global tt.ini file)

A new engine call (Set_Stealth_Active) on SmartGameObj objects that allows you to basically "deactivate" stealth (i.e. you set this flag and it turns on/off the stealth without affecting its enable/disable state etc)

A special Custom you can listen for called CUSTOM_EVENT_REFILL to detect when someone refills so you can do things if you want. No you dont get to block the refill, just detect that its happened.

A new hud.ini keyword CenterMainMenu. Setting this will cause the main menu options to be centered instead of left-justified.

Some logic for Underground units (as seen in C&C: Reborn).

A new Force_Vehicle_Entry engine call that will force a player into a vehicle (you pass in the soldier and the vehicle). For vehicle exit, keep using the Soldier_Transition_Vehicle engine call as normal.

New flag in LE for per-team visibility. Set the "Team Visibility Mode" to "Default" and everyone can see it. Set it to "Visible Only To Friendlies" and only units on the same team as the object can see it. Set it to "Visible Only To Enemies" and only units not on the same team can see it.

New engine call (Set_Can_Drive) for VehicleGameObj objects. Set this to false and this will cause the vehicle to ignore any movement commands.

New engine call Create_Lightning which is used to create a lightning bolt through code (similar to the lightning bolt effect used by e.g. the Volt Auto Rifle)

New value in LE CollisionDamageMultiplier on explosions. This lets you change the collision damage multiplier that gets used for certain things in the explosion logic (i.e. when an explosion goes through walls and does less damage to stuff on the other side than would have happened had the wall not been there)

New engine call (Get_Bounds) for BuildingGameObj objects. This returns an AABox representing the bounding box of the building.

Smooth skinning support (I dont know the exact details other than that its something Saberhawk wrote and that it relies on certain features in the W3D export plugin for 3DS MAX)

Add support for some new radar blip shape types (these only work if you are using the hud.ini custom HUD to override the stock radar)

New flag in LE RequiresSilo on beacons. If this is set, the beacon wont be able to be deployed unless the team has a building of type "Shrine" and that building is still alive.

New engine call Set_Global_Stealth_Disable which will disable/enable stealth on a global basis.

New building type "Superweapon". This is mostly intended to allow you to have an animated missile silo door, ion canon satellite dish or other animated bit that animates when the superweapon is fired but which is still part of the building and will do damage to the building when you shoot it.

New command line options for level edit to allow it to be used in a "batch" mode. Pass -mod <name> to load a specific mod automatically. Pass -map <name> to load a specific map automatically. Pass -save to force an auto-save. Pass -light to force it to do "compute vertex solve" before saving.
This (combined with makemix.exe) is intended so you can build a map automatically (or even an entire mod/TC)

New tt.ini keyword NoPowerCostMultiplier which lets you set the cost multiplier that gets applied when the power plant is dead.

Rewrite/improve makemix

Improvements to the way LE handles temp presets. temps20.ddb is now gone and each map in a mod package has its own set of temp presets (the intent is to make things less likely to screw up or go wrong)

Support for giving projectiles a width/height/depth

Support for vehicles to use the same hitbox/bones.ini logic as infantry (so you can have some parts of a vehicle being weaker than others)

New tool called w3dviewer that basically exists as a way to display a w3d file outside of the engine but using all the rewritten rendering engine code we have.

Add a "cost" field to Team Purchase Settings (the infantry that are normally free)


New tool called lsdview that basically exists as a way to display an lsd file outside of the engine but using all the rewritten rendering engine code we have. (the lsd file contains all the terrain and tiles and static data)

New value in LE on vehicles, FactoryRideHeight. Use this to set the right height used when the vehicle is first spawned. Mostly this exists to avoid some issues with certain vehicles in C&C: Reborn.

Add tt.ini keyword DisableSP to disable the single player button (for stand-alone mods that have no single player)

Increase the number of engine/rotor bones for VTOL vehicles from 4 to 6.

New values in LE on powerups, GrantShieldStrengthMaxIsScaled and GrantHealthMaxIsScaled. When turned off, it makes the max health/max shield strength granted by powerups linear instead of scaled.

New values in LE on "General" settings, "GDI Spawn Character" and "Nod Spawn Character". Use these to override the default multiplayer spawn characters for each team.

Add new engine call Wake_Up_Objects_In_Box (this is used for destroyable bridge logic in various mods so that the objects that are on the bridge when its destroyed will properly run their physics logic and will fall through the bridge if necessary)

Made Commands->Set_Is_Visible support vehicles and removed Set_Vehicle_Is_Visible.

Anyone with any questions about these features feel free to ask in here and I will do my best to answer them as time permits.


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: Mod-related changes in scripts 4.1 [message #484639 is a reply to message #484631] Thu, 28 November 2013 05:50 Go to previous messageGo to next message
Neijwiert is currently offline  Neijwiert
Messages: 124
Registered: October 2009
Karma: 0
Recruit
Nice, keep up the good work!

Quote:


Force_Vehicle_Entry
Commands->Set_Is_Visible



I like these in particular Smile

EDIT: oh wait thought it was Commands->Set_Is_Rendered Sad

[Updated on: Thu, 28 November 2013 06:08]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #484678 is a reply to message #484631] Fri, 29 November 2013 23:34 Go to previous messageGo to next message
Dethdeath is currently offline  Dethdeath
Messages: 297
Registered: February 2004
Karma: 0
Recruit
Some questions about the changes to temps20.ddb:
1. Where is the data that usually gets stored in the temps20.ddb going to be saved now from LE's perspective?
2. Is the temp data still stored in the map's .ddb file? For example C&C_City.ddb?
3. How does the compatibility to older scripts users stand to this change? Will 4.0 users and scripts users prior to 4.0 be able to play a map made with scripts 4.1?
4. Considering that temps20.ddb is going to be removed, how would that affect existing mod folders, since all temps are stored in them?



http://www.exoduscommunity.com/images/Sigx.jpg
Re: Mod-related changes in scripts 4.1 [message #484681 is a reply to message #484631] Sat, 30 November 2013 00:59 Go to previous messageGo to next message
jonwil is currently offline  jonwil
Messages: 3555
Registered: February 2003
Karma: 0
General (3 Stars)

What used to happen is that temp presets were stored in temps20.ddb which was then copied when you saved the level (i.e. temps20.ddb got copied to e.g. C&C_City.ddb by leveledit).
What the code does now is to write the temps straight to the map ddb file.
The game never read temps20.ddb, it only read the map ddb file.

So yes all maps (old and new) will be compatible with all versions of the game. Loading a pre-4.1 mod folder will work just fine in 4.1 leveledit. Only thing that wont work is loading a 4.1 mod folder/map in a pre-4.1 leveledit if that mod folder/map has temp presets.


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: Mod-related changes in scripts 4.1 [message #484695 is a reply to message #484681] Sat, 30 November 2013 10:15 Go to previous messageGo to next message
Gen_Blacky is currently offline  Gen_Blacky
Messages: 3250
Registered: September 2006
Karma: 1
General (3 Stars)
Thumbs Up

jonwil wrote on Sat, 30 November 2013 00:59

What used to happen is that temp presets were stored in temps20.ddb which was then copied when you saved the level (i.e. temps20.ddb got copied to e.g. C&C_City.ddb by leveledit).
What the code does now is to write the temps straight to the map ddb file.
The game never read temps20.ddb, it only read the map ddb file.

So yes all maps (old and new) will be compatible with all versions of the game. Loading a pre-4.1 mod folder will work just fine in 4.1 leveledit. Only thing that wont work is loading a 4.1 mod folder/map in a pre-4.1 leveledit if that mod folder/map has temp presets.



Good. I had the same question.


http://s18.postimage.org/jc6qbn4k9/bricks3.png
Re: Mod-related changes in scripts 4.1 [message #484731 is a reply to message #484631] Sat, 30 November 2013 18:11 Go to previous messageGo to next message
Dethdeath is currently offline  Dethdeath
Messages: 297
Registered: February 2004
Karma: 0
Recruit
Thanks for the response.

Something else that's unclear:
How will LE determine which temp presets to load if there are multiple level's ddb files in the same mod folder?



http://www.exoduscommunity.com/images/Sigx.jpg
Re: Mod-related changes in scripts 4.1 [message #484745 is a reply to message #484631] Sun, 01 December 2013 07:53 Go to previous messageGo to next message
jonwil is currently offline  jonwil
Messages: 3555
Registered: February 2003
Karma: 0
General (3 Stars)

It wont load any temp presets until you load a .lvl file.


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: Mod-related changes in scripts 4.1 [message #484812 is a reply to message #484745] Fri, 06 December 2013 16:25 Go to previous messageGo to next message
Jerad2142 is currently offline  Jerad2142
Messages: 3805
Registered: July 2006
Location: USA
Karma: 6
General (3 Stars)
Is smooth skinning like what modern games are able to use where one bone can apply different "weights" to a mesh point, like so you could have a bicep that is affected by the rotation of the lower arm and shoulder? Or is this something to do with texturing?

Re: Mod-related changes in scripts 4.1 [message #484827 is a reply to message #484812] Sun, 08 December 2013 12:12 Go to previous messageGo to next message
Jerad2142 is currently offline  Jerad2142
Messages: 3805
Registered: July 2006
Location: USA
Karma: 6
General (3 Stars)
I see you've made the ability to disable controlling vehicles, I'd like to request the same be made for infantry; In Rp2:ECW when you exceed your weapon inventory weight I lock you in place with good old Attach_Object_To_Bone, but if I could simply disable the players ability to control their character that'd be loads better as other things would then be able to push you around and so forth.

Re: Mod-related changes in scripts 4.1 [message #484830 is a reply to message #484631] Sun, 08 December 2013 16:23 Go to previous messageGo to next message
jonwil is currently offline  jonwil
Messages: 3555
Registered: February 2003
Karma: 0
General (3 Stars)

The Reborn EMP effect uses Set_Freeze on infantry units which causes the infantry unit to not be able to use any of its controls.
Although that may not work for what you want.
Will have to see about something similar for just blocking movement.


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: Mod-related changes in scripts 4.1 [message #484835 is a reply to message #484631] Mon, 09 December 2013 06:03 Go to previous messageGo to next message
Neijwiert is currently offline  Neijwiert
Messages: 124
Registered: October 2009
Karma: 0
Recruit
Commands->Control_Enable(GameObject * obj, bool enable)

Does what you need it to do. Works fine in multiplayer. Altough I'm not sure if it works properly after creation of an object. I only used it at that point.
Re: Mod-related changes in scripts 4.1 [message #484836 is a reply to message #484631] Mon, 09 December 2013 06:41 Go to previous messageGo to next message
danpaul88 is currently offline  danpaul88
Messages: 5795
Registered: June 2004
Location: England
Karma: 0
General (5 Stars)
Control_Enable in multiplayer (at least, last time I tried it) isn't great... on your local machine you can still walk around and stuff but you keep warping back to the original spot when the server corrects your position... and as I recall I could still use my weapons too.

But this was with scripts 2.x a long time ago when I was testing things out, it might have been fixed since then so it actually works?


http://steamsignature.com/card/1/76561197975867233.png
Re: Mod-related changes in scripts 4.1 [message #484837 is a reply to message #484836] Mon, 09 December 2013 11:18 Go to previous messageGo to next message
Xpert is currently offline  Xpert
Messages: 1588
Registered: December 2005
Location: New York City
Karma: 0
General (1 Star)
danpaul88 wrote on Mon, 09 December 2013 08:41

Control_Enable in multiplayer (at least, last time I tried it) isn't great... on your local machine you can still walk around and stuff but you keep warping back to the original spot when the server corrects your position... and as I recall I could still use my weapons too.

But this was with scripts 2.x a long time ago when I was testing things out, it might have been fixed since then so it actually works?


I used that on SSGM 2.0.2 with scripts 3.4.4 so it's probably the same effect still. The way you describe it is exactly how it worked back then. You could even get in a vehicle if you were next to one.


http://i32.photobucket.com/albums/d42/XpertMaverick/xpertyankee.jpg

Creator of NetGuard, an IRC network regulator.
Developer of the CloudyServ 0.982-X project.
Developer of the CloudyServ Ren-X bot.

Part time streamer - https://twitch.tv/gg_wonder
Re: Mod-related changes in scripts 4.1 [message #484841 is a reply to message #484631] Mon, 09 December 2013 19:37 Go to previous messageGo to next message
jonwil is currently offline  jonwil
Messages: 3555
Registered: February 2003
Karma: 0
General (3 Stars)

Not sure whats up with that. There IS code (in the latest scripts at least) that sends Control_Enable over the network. (so if its not working I have no clue why)
I have thought of a way to do it better (that would work 100% if all players have 4.1) but A.I dont have the time to implement it and B.I dont know how risky the change would be at this late stage in the development of 4.1 (its a netcode change and netcode changes are always somewhat risky)


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

[Updated on: Mon, 09 December 2013 19:37]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #484971 is a reply to message #484812] Mon, 23 December 2013 14:36 Go to previous messageGo to next message
Jerad2142 is currently offline  Jerad2142
Messages: 3805
Registered: July 2006
Location: USA
Karma: 6
General (3 Stars)
I'll try flipping control_enable off client side via shaders for now, and if it works in 4.1 it'll be easy to rip out, if not it'll be a place holder.

Didn't you guys also make it so projectiles can now be fired at rates faster than 400m/s?

Jerad Gray wrote on Fri, 06 December 2013 16:25

Is smooth skinning like what modern games are able to use where one bone can apply different "weights" to a mesh point, like so you could have a bicep that is affected by the rotation of the lower arm and shoulder? Or is this something to do with texturing?

Anyone know anything about this, or do we have to wait for Saberhawk to respond?


[Updated on: Mon, 23 December 2013 14:55]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #485140 is a reply to message #484631] Mon, 06 January 2014 02:37 Go to previous messageGo to next message
Mauler
Messages: 448
Registered: May 2003
Location: Alberta, Canada
Karma: 0
Commander
I was wondering if the makemix can package an entire directory of my map.. including folders located inside that directory.. to out put something like this...

http://i.imgur.com/2aYz7cA.jpg

http://i.imgur.com/5trspaF.jpg

last time i tried to do this if failed to work properly..


Re: Mod-related changes in scripts 4.1 [message #485142 is a reply to message #484631] Mon, 06 January 2014 08:21 Go to previous messageGo to next message
danpaul88 is currently offline  danpaul88
Messages: 5795
Registered: June 2004
Location: England
Karma: 0
General (5 Stars)
MIX files have no concept of a folder hierarchy... hence why all file names must be unique within a map, because once the folder structure is stripped away they suddenly become "the same file" as far as the MIX archive is concerned.

From the screenshot you've shown it looks like whatever tool you're using to generate that directory structure is malfunctioning. The engine strips folder paths off the paths you provide in LE before searching for files so it'd probably never be able to find those anyway...


http://steamsignature.com/card/1/76561197975867233.png

[Updated on: Mon, 06 January 2014 08:23]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #485147 is a reply to message #485142] Mon, 06 January 2014 14:00 Go to previous messageGo to next message
Gen_Blacky is currently offline  Gen_Blacky
Messages: 3250
Registered: September 2006
Karma: 1
General (3 Stars)
danpaul88 wrote on Mon, 06 January 2014 08:21


From the screenshot you've shown it looks like whatever tool you're using to generate that directory structure is malfunctioning. The engine strips folder paths off the paths you provide in LE before searching for files so it'd probably never be able to find those anyway...


That's how renegade loads the lightmaps for the map terrain model.
Look at the stock renegade maps.


Mauler wrote on Mon, 06 January 2014 02:37

I was wondering if the makemix can package an entire directory of my map.. including folders located inside that directory.. to out put something like this...

http://i.imgur.com/2aYz7cA.jpg

http://i.imgur.com/5trspaF.jpg

last time i tried to do this if failed to work properly..





add them manually and use RenegadeEx


http://s18.postimage.org/jc6qbn4k9/bricks3.png

[Updated on: Mon, 06 January 2014 14:02]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #485149 is a reply to message #484631] Mon, 06 January 2014 15:01 Go to previous messageGo to next message
Mauler
Messages: 448
Registered: May 2003
Location: Alberta, Canada
Karma: 0
Commander
I did use RenegadeEX.. It worked on getting the filename just like the the image i posted but failed to load textures ingame Huh since i work with lightmap textures it would be an asset to use the same method westwood used..
Re: Mod-related changes in scripts 4.1 [message #485155 is a reply to message #485149] Mon, 06 January 2014 18:31 Go to previous messageGo to next message
Gen_Blacky is currently offline  Gen_Blacky
Messages: 3250
Registered: September 2006
Karma: 1
General (3 Stars)
Mauler wrote on Mon, 06 January 2014 15:01

I did use RenegadeEX.. It worked on getting the filename just like the the image i posted but failed to load textures ingame Huh since i work with lightmap textures it would be an asset to use the same method westwood used..


I know you can because I have done it before several times just cant remember how from the top of my head.

Play around with RenegadEx and XCC mixer or its with the leveledit editor cache.


http://s18.postimage.org/jc6qbn4k9/bricks3.png

[Updated on: Mon, 06 January 2014 18:32]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #485811 is a reply to message #484631] Fri, 07 February 2014 20:38 Go to previous messageGo to next message
jonwil is currently offline  jonwil
Messages: 3555
Registered: February 2003
Karma: 0
General (3 Stars)

I would like to add that yes all the features described in this thread ARE in 4.1RC



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

[Updated on: Fri, 07 February 2014 20:38]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #485817 is a reply to message #484631] Sat, 08 February 2014 02:45 Go to previous messageGo to next message
Mauler
Messages: 448
Registered: May 2003
Location: Alberta, Canada
Karma: 0
Commander
Awesome cannot wait to finally add helipads etc... thanks!!

Re: Mod-related changes in scripts 4.1 [message #485818 is a reply to message #484631] Sat, 08 February 2014 02:45 Go to previous messageGo to next message
Mauler
Messages: 448
Registered: May 2003
Location: Alberta, Canada
Karma: 0
Commander
No Message Body

[Updated on: Sat, 08 February 2014 02:51]

Report message to a moderator

Re: Mod-related changes in scripts 4.1 [message #485821 is a reply to message #484631] Sat, 08 February 2014 06:04 Go to previous messageGo to next message
zunnie is currently offline  zunnie
Messages: 2959
Registered: September 2003
Location: Netherlands
Karma: 0
General (2 Stars)

Can you change the way temps are handled so it accepts subfolders?
I have to copy the map's lvl,ldd,lsd,ddb to the /Levels/ folder now or else it won't load.
This is a pain in the butt if you have many maps in your Levels folder. To keep things organized we use subfolders :/
And now the maps won't load until you move those files up 1 folder.............Work on it, then save it, copy it back to subfolder to yet again organize it lol...

Plz change it so it accepts subfolders Very Happy

index.php?t=getfile&id=14856&private=0


https://multiplayerforums.com/uploads/monthly_2018_03/TCW2_Signature.png.6236a0dbc6e1e53472a18fe8cd15e47b.png
Re: Mod-related changes in scripts 4.1 [message #485833 is a reply to message #484631] Sat, 08 February 2014 18:37 Go to previous messageGo to previous message
Stallion is currently offline  Stallion
Messages: 222
Registered: April 2006
Karma: 0
Recruit
I get a "failed to connect to the update server. Please check your internet connection and firewall." as well as level editor having no presets and crashes when I try to load a project.

Could this be related or just really bad coincidence?

(I've already uninstalled ren, reinstalled, updated with a fresh scripts and level editor download, and corrected my ren path in regedit.)

Any ideas on how to fix it?


Level edit is my play ground
Previous Topic: compile error with visual c++ 2010 express
Next Topic: Construction Yard tutorial for renegade modders
Goto Forum:
  


Current Time: Tue Jun 18 02:02:48 MST 2024

Total time taken to generate the page: 0.01647 seconds