Jump to content

New UnitTypes flags


Iran

Recommended Posts

This is an EXE with extended UnitTypeClass and a system to clear memory properly for the extensions. It comes with a new Crusher=(Yes/No) flag, which should be usable with everything that functions as a RULES.INI kind of file (maps etc).

 

; heavy tank

[3TNK]

Crusher=No ; Can this unit crush infantry?

 

https://dl.dropboxusercontent.com/u/21865790/ra95.exe

 

TODO is adding a function/system to extend TechnoTypeClass.

 

Please test if the Crusher=(Yes/No) flag works correctly and whether the memory is cleared correctly.

Link to comment
Share on other sites

  • Replies 68
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

Crash at start up from

 

[unitTypes]

0=DERP

 

If I remove the [unitTypes] from the rules.ini the crash stops.

 

With no Crusher= key in the rules.ini I made a saved game and made sure the Mine layer crushed infantry like it dose normaly. Next I exited the game and gave Mine layer Crusher=no and started a new mission and the Mine layer quit crushing infantry.

 

Without exiting the game I load the saved game that would let the Mine layer crush infantry but the Mine layer was unable to. It looks like saved games dose not save if the unit had Crusher=no.

 

Basically if the Crusher=no is added to a unit it will be applyed to that unit even if the unit didn't have it when the game was saved.  This is also true when adding Crusher=yes to the Ranger.

ra95crash.dmp.zip

Link to comment
Share on other sites

Saved games are working fine. I was able to load even old Westwood 3.03s just fine. The Crusher= key is working fine with the saved game.

 

As for the 'DERP' crash I had. I have

 

[unitTypes]

0=DERP

 

and the unit

 

; Test Unit 1

[DERP]

Image=APC

Prerequisite=weap,tent

Primary=M60mg

Strength=200

Armor=heavy

TechLevel=5

Sight=5

Speed=10

Owner=allies

Cost=800

Points=25

ROT=5

Tracked=yes

Passengers=5

 

but the game crashes at start up if [unitTypes] is listed in the rules.ini. This was working fine with the .exe from the other thread.

Link to comment
Share on other sites

Suggestion, make a tag tthat will allow a unit to hover.

 

Not sure that the engine would allow that particular sorcery. From what I can see it would involve editing all of the terrain characteristics too, which is a whole new can of worms.

Link to comment
Share on other sites

Maybe not as hard as you would think Echo. Tib Sun was build from RA1. The work Iran has done in the Unhardcoded internal (type) lists thread is also what WestWood did for Tib Sun. I never expected Iran to duplaced any thing from Tib Sun but there is hope that a number of things from Tib Sun could be done in RA1 now. This could be one that could be done.

 

 

I know Tracked= [yes/no] is a current key in RA1 If Iran could make clone of Tracked= logic and name it Hovers= [yes/no] half the prob would be done. Land characteristics is definded in the rules.ini at ; ******* Land Characteristics ******* I'll quote one of the land characteristics.

 

 

; ******* Land Characteristics *******

; This section specifies the characteristics of the various

; terrain types. The primary purpose is to differentiate the

; movement capabilities.

 

; Float = % of full speed for ships [0 means impassable] (def=100)

; Foot = % of full speed for foot soldiers [0 means impassable] (def=100)

; Track = % of full speed for tracked vehicles [0 means impassable] (def=100)

; Wheel = % of full speed for wheeled vehicles [0 means impassable] (def=100)

; Buildable = Can buildings be built upon this terrain (def=no)?

 

[Clear]

Foot=90%

Track=80%

Wheel=60%

Float=0%

Buildable=yes

 

As you can see the clear land characteristic each movement type is listed. In Tib Sun 2 new movement types were added Amphibious = and Hover =. If Iran can clone the Track= and name it Hover= than tie it back to the Hovers= key that is attached to a unit we would have a working hover logic.

Link to comment
Share on other sites

Those are called LandTypes internally and it should be possible to add new ones. Could you test if modifying an existing landtype allows for hover behavior?

 

I know it was done once. A mod called RA2TS or RA to Tiberian Sun http://cnc-comm.com/community/index.php?topic=2177.0 made all of the ships into hover units by using Float=100% on all Land Characteristics. This was slightly flawed since the Hover MLRS could go over any thing like walls cliffs and rocks but had to be done or the JumpJet Infantry couldn't fly over walls cliffs and rocks.

 

If you are able to do Hover set up it would also be nice if you could do a Fly set up as well. JumpJet Infantry in RA would be somthing else. :laugh: but that dose have the flaw of SAM Sites and AA Guns wound't shoot at it since to the game the guy is on the ground.... :(

Link to comment
Share on other sites

Can't you just edit the default RULES.INI values to set float to 100% on land types?

 

Yes that was done in RA2TS and it worked fine but RA2TS had to sacrifice all ships to do so. This also ment thing like the Hover MLRS that should have been built at the War Factory was built at some other building.

 

If someone could try doing tank clones and giving countries their own tanks using Owner= with a country name that could be interesting.

 

Owner=country always did work. Now that more tanks can be added to one country.

Link to comment
Share on other sites

  • 3 weeks later...
  • 3 weeks later...

If someone could try doing tank clones and giving countries their own tanks using Owner= with a country name that could be interesting.

 

Funny you say that, if you keep hacking this enough, I'll make my mod have all countries with different units. 2 Major teams still, but then with some little different additions and subtractions to each. I really want to be able to have people play as USA and get M1A1 and England and get Challengers.

 

Still, you're a little off allowing my mod to be implemented... but not that far. Mostly turret placement logic, that's the big one. To say if the turret is offset like a ranger, or if the turret is on the rear, like a mobile gap.

 

Not sure if you've read over the massive ARDA list of stuff that Alex_B put in, but you've hit the main points, good stuff :D

 

  -Liam

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...