Posted: Sat Jun 13, 2020 7:05 pm Post subject:
Possible to destroy terrain objects?
As you know some of terrain objects can be destroyed by removing the immune=yes
But I don't see a way to remove a rocks and some other stuff. I am just curious and really want to know.
For example.A Rock
[SROCK02]
Name=Sand Rock #2
LegalTarget=true
Armor=concrete
Explosion=TWLT070,S_BANG48,S_BRNL58,S_CLSN58,S_TUMU60
Strength=100
;Immune=yes
Land=Rock
RadarColor=64,64,64
NoUseTileLandType=true
DrawFlat=false
IsARock=true ;WST 6/21/99 all pesky rocks need to have this
I added the health and armor to this but I can't get rid of it. While this works really well with bridge hut, ore drill etc... QUICK_EDIT
Overlays are by default invincible. Only a few keys make them destroyable.
Wall=yes -also applies special damage stages, change graphic according to adjacent walls to connect them
Tiberium=yes -applies several frames for growth logic
Explodes=yes -instantly destroyed when hit by weapon, uses BarrelExplode, BarrelDebris, BarrelParticle from [General] section when destroyed
Crushable=yes -can be removed by Crusher vehicles (IIRC weapon fire still can't destroy it)
Overlays do not have any Strength or Armor property and don't work like buildings or other destroyable objects.
Walls are a special case, as they start as a building [GAWALL], then in art.ini are told to change to the overlay [GAWALL] (see art.ini the ToOverlay key)
WW simply used the same [GAWALL] section in rules.ini to declare the building and the overlay.
From all the keys in rules.ini [GAWALL], only the key Wall=yes is read for the overlay. The other keys are only used temporarily for the construction and placement before the building is instantly converted via ToOverlay into an Overlay.
Wall=yes is also hardcoded to use unittem.pal, while your rock is using the default isotem.pal for normal overlays.
The rock is also missing the necessary amount of frames to work as wall overlay.
Mr.Hymn wrote:
Isn’t wall also overlay? Do I also need to declare them as building similar to wall does?
so no, that would not solve your issue.
The easiest would be to create a normal building and give it the Image of the rock, and don't use the overlay rock at all. _________________ SHP Artist of Twisted Insurrection: Nod buildings
Overlays are by default invincible. Only a few keys make them destroyable.
Wall=yes -also applies special damage stages, change graphic according to adjacent walls to connect them
Tiberium=yes -applies several frames for growth logic
Explodes=yes -instantly destroyed when hit by weapon, uses BarrelExplode, BarrelDebris, BarrelParticle from [General] section when destroyed
Crushable=yes -can be removed by Crusher vehicles (IIRC weapon fire still can't destroy it)
Overlays do not have any Strength or Armor property and don't work like buildings or other destroyable objects.
Walls are a special case, as they start as a building [GAWALL], then in art.ini are told to change to the overlay [GAWALL] (see art.ini the ToOverlay key)
WW simply used the same [GAWALL] section in rules.ini to declare the building and the overlay.
From all the keys in rules.ini [GAWALL], only the key Wall=yes is read for the overlay. The other keys are only used temporarily for the construction and placement before the building is instantly converted via ToOverlay into an Overlay.
Wall=yes is also hardcoded to use unittem.pal, while your rock is using the default isotem.pal for normal overlays.
The rock is also missing the necessary amount of frames to work as wall overlay.
Mr.Hymn wrote:
Isn’t wall also overlay? Do I also need to declare them as building similar to wall does?
so no, that would not solve your issue.
The easiest would be to create a normal building and give it the Image of the rock, and don't use the overlay rock at all.
Thank you for your clarification. I understand a lo more. However I've seen some people actually done it. It's chinese people they actually did something more crazy by destroying the terrain like ice or land and see the water tiles coming out instead which have property become unbuildable on top and even blocking and enemies. Mine just destroying rocks because it's good to expand the base without using PlaceAnywhere=yes logic. It doesn't seems to apply to AI. QUICK_EDIT
I've done it now I can destroy any rocks I wanted. All I did is put the Explodes=yes and put them in the [buildingTypes] Now they all destroyed while being fired upon QUICK_EDIT
But not the ones pre-placed on the map as overlay?
Preplaced. I can destroy any rocks on the map that preplaced. I did not build them myself they still act like overlay no healthbat and see any info just like tree or ore drill but I can force fire on them and destroy them QUICK_EDIT
Explodes=yes is what makes them destroyable, not this wrong/redundant entry in the BuildingTypes list. _________________ SHP Artist of Twisted Insurrection: Nod buildings
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum