#1166 closed enhancement (fixed)
[PATCH] Add <RubbleActor> tag in <VisualActor> Element for Building Templates
Reported by: | michael | Owned by: | ben |
---|---|---|---|
Priority: | Nice to Have | Milestone: | Alpha 12 |
Component: | Core engine | Keywords: | patch simple |
Cc: | Patch: |
Description (last modified by )
It would be nice to have a <RubbleActor> tag added for the <VisualActor> element in building entity templates, like so:
<VisualActor> <FoundationActor>structures/fndn_2x2.xml</FoundationActor> <Actor>props/special/palisade_rocks_outpost.xml</Actor> <RubbleActor>structures/rubble_2x2.xml</RubbleActor> </VisualActor>
The specified Rubble actor would appear on the ground when a building dies and collapses. It would then "decay" sink or fade at some specified rate. Perhaps with another new element, like:
<RubbleDecay> <DelayTime>30.0</DelayTime> <SinkRate>0.5</SinkRate> <SinkAccel>0.5</SinkAccel> </RubbleDecay>
The above is similar to the <Decay> element, but specifically for the <RubbleActor>.
Like animal or human corpses, these "Rubble" actors can be built over. They have no obstruction or footprint.
This ticket has been split off from ticket #131.
Ticket #819 (Destruction dust) is related, but will possibly need a different solution.
Attachments (2)
Change History (21)
comment:1 by , 12 years ago
Description: | modified (diff) |
---|
comment:2 by , 12 years ago
Description: | modified (diff) |
---|
comment:3 by , 12 years ago
Description: | modified (diff) |
---|---|
Keywords: | Rubble Building Death added |
comment:4 by , 12 years ago
Description: | modified (diff) |
---|
comment:5 by , 12 years ago
Description: | modified (diff) |
---|
by , 12 years ago
Attachment: | screen14.jpg added |
---|
comment:6 by , 12 years ago
Keywords: | simple added |
---|
Sounds basically fine. I think it would be best for each type of rubble to be a new entity (with a standard <VisualActor>
and <Decay>
component), and to add something like <Health><DeathRemnant>other/rubble_2x2</...>
and make simulation/components/Health.js
spawn an instance of that entity when the unit dies (as well as spawning the corpse entity as normal). (Rubble should be handled through a different method to corpses because they're very different problems - corpses need to copy most of the appearance of the original entity (so they copy its whole template and activate its Decay
component), whereas rubble doesn't need that and can be simpler.)
follow-up: 11 comment:7 by , 12 years ago
-Added rubble template using foundation actors
-Added <DeathRemnant> field to <Health>
-On death if <DeathRemnant> is set it spawns it
We need actors for rubble, now it uses foundation actors, so it looks quite strange.
comment:8 by , 12 years ago
Keywords: | review added |
---|---|
Summary: | Add <RubbleActor> tag in <VisualActor> Element for Building Templates → [PATCH] Add <RubbleActor> tag in <VisualActor> Element for Building Templates |
comment:9 by , 12 years ago
Keywords: | patch added; Rubble Building Death removed |
---|---|
Milestone: | Backlog → Alpha 12 |
comment:10 by , 12 years ago
Priority: | Should Have → Nice to Have |
---|
comment:11 by , 12 years ago
Replying to quonter:
-Added rubble template using foundation actors
-Added <DeathRemnant> field to <Health>
-On death if <DeathRemnant> is set it spawns itWe need actors for rubble, now it uses foundation actors, so it looks quite strange.
Thanks for the patch. It looks basically good to me, I'll test it soon. It should probably be left for Alpha 12 though, so the art team has time to create decent rubble actors. Or as a temporary work around we could use decals that don't sink, if we have the necessary variety of decals available.
comment:12 by , 12 years ago
Keywords: | review removed |
---|
I've tested the patch and it works well. All I've had to is refactor a few things, like using SpawnEntityOnDeath
instead of the ambiguous DeathRemnant
. I'll be committing it in a few moments.
The art dept. will make rubble objects like these.