#1581 closed enhancement (fixed)
Construction visual enhancement: Scaffolds during construction
Reported by: | michael | Owned by: | historic_bruno |
---|---|---|---|
Priority: | Nice to Have | Milestone: | Alpha 13 |
Component: | Core engine | Keywords: | |
Cc: | Patch: |
Description (last modified by )
Currently, the player clicks the building icon in the unit UI, then places a foundation. Then the unit walks to the foundation, smacks on it for a bit, some dust rises, then the building pops into existence.
The desired enhancement should go like this (the enhancements for this ticket are bolded):
- Player/unit places foundation.
- Walks up to it, starts building.
- Scaffold actor appears (or rises very quickly into place), and dust starts appearing.
- Building rises up slowly through this as a percentage complete.
- At 100% complete, the foundation actor disappears, and the scaffold actor either just disappears or drops down quickly (as if dying).
I could see something like this in the building templates:
<VisualActor> <Actor>structures/athenians/barracks.xml</Actor> <FoundationActor>structures/fndn_5x5.xml</FoundationActor> <ScaffoldActor>structures/construction/scaffold_5x5.xml</ScaffoldActor> </VisualActor>
Attachments (3)
Change History (16)
comment:1 by , 12 years ago
Description: | modified (diff) |
---|
comment:2 by , 12 years ago
Description: | modified (diff) |
---|---|
Priority: | Should Have → Nice to Have |
Summary: | Scaffolds during Construction → Construction visual enhancement: Scaffolds during construction |
Type: | defect → enhancement |
comment:3 by , 12 years ago
Description: | modified (diff) |
---|
by , 12 years ago
Attachment: | const_1.jpg added |
---|
by , 12 years ago
Attachment: | const_2.jpg added |
---|
Builders begin building. Scaffold quickly rises (or pops) into place. Building will begin rising into place as it is built.
by , 12 years ago
Attachment: | const_3.jpg added |
---|
Building is nearly completed and is nearly 100% risen.
follow-up: 5 comment:4 by , 12 years ago
I was just looking into the building rising part, right before you created this ticket :) It's not too difficult but there are a few visual glitches I've encountered:
- The rising building can't be the final real building because we don't want to allow full interaction (no attack, training, etc.) That means we start with a "preview" entity and then create the real one when construction is finished. Due to random variations, there may be differences between the preview and the final entity, e.g. different props. We probably need some way to copy the variations between entities.
- How to determine the height of the building, this is needed to adjust the height of the preview as it progresses. I'm using the footprint height which looks good for some buildings, but not for others that use default values. The alternative would be using the actor's bounding box (based on the model).
comment:5 by , 12 years ago
Replying to historic_bruno:
there are a few visual glitches I've encountered
I believe I've solved these issues, in the process I also found a solution for promoted units and corpses potentially having different random variations than the original entity. Here is a video showing the constructed buildings rising from the foundation (without the scaffold):
http://youtu.be/BVAd20jYGGw
IMO it looks pretty good, but the buildings do seem to "jump" into position due to how unevenly the construction progresses. Next I'll try adding the scaffolds.
comment:6 by , 12 years ago
That's great Ben. Does the preview/final entity changes required for this in any way help with solving the issue with you being able to see changes to enemy buildings in FoW?
comment:8 by , 12 years ago
Ok, I just thought there might be parts of the "preview"/real entities implementation that could be relevant/reused :)
comment:9 by , 12 years ago
I've had to reanalyze my approach.
At first I thought to use a local entity to avoid sync problems (since the position of the entity would be changed based on the "unsafe" model height) The problem is local entities are not serialized either in multiplayer or saved games, so the beautiful new rising construction entities would disappear when loading a saved game (the way corpses do). Now I'm thinking the actual rising behavior will need to be part of CmpVisualActor or similar, and a purely visual non-simulation effect.
Also I don't like the idea of creating separate entities for the foundation, scaffold and rising building - seems like to much waste of resources. At the same time CmpVisualActor
is set up to deal with a single model and I'm not sure it's a great idea to break that concept.
comment:10 by , 11 years ago
Owner: | set to |
---|---|
Status: | new → assigned |
comment:11 by , 11 years ago
This and #1174 are connected, so I'm working on both.
For scaffolding, I think the best approach is to make it a non-random actor variation, rather than a separate actor. If it's a separate actor, the code needs to create and manage another entity. With a variation, it's as simple as selecting that variation in the foundation script. The scaffold variant would appear instantly when the builder(s) began construction.
What this would mean for artists is going through the foundation actors and creating a scaffold variant for each (with frequency=0), maybe called "building-scaffold". I think this would allow nicer results anyway, since the scaffolding could be more integrated with the foundation rather than stuck on top of it.
This could be worked on gradually or ignored entirely if we don't have time, but it's probably the simplest implementation.
comment:13 by , 11 years ago
Milestone: | Backlog → Alpha 13 |
---|
Foundation placed (already a feature)