Skip to content

Commit

Permalink
zzre: Stop city doors from wiggling
Browse files Browse the repository at this point in the history
  • Loading branch information
Helco committed Jan 21, 2024
1 parent 5b317b3 commit 955b5a1
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion zzre/game/systems/model/ModelLoader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,16 @@ private void HandleSceneLoaded(in messages.SceneLoaded message)

LoadMaterialsFor(entity, FOModelRenderType.Solid, model.color, model.surfaceProps);
SetCollider(entity);
SetPlantWiggle(entity, model.wiggleAmpl, plantWiggleDelay);
if (behaviors.TryGetValue(model.idx, out var behaviour))
{
SetBehaviour(entity, behaviour, model.idx);
if (model.wiggleAmpl > 0)
{
model.wiggleAmpl = 0;
Console.WriteLine($"Warning: Model {model.idx} with a {behaviour} behaviour also has a plant wiggle set.");
}
}
SetPlantWiggle(entity, model.wiggleAmpl, plantWiggleDelay);
if (entity.Has<components.Collidable>())
SetIntersectionable(entity);

Expand Down

0 comments on commit 955b5a1

Please sign in to comment.