Skip to content

Commit

Permalink
turf animations can go in another PR
Browse files Browse the repository at this point in the history
  • Loading branch information
amylizzle committed Oct 20, 2024
1 parent 7d98138 commit 80da1ea
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions OpenDreamRuntime/AtomManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,6 @@ public void AnimateAppearance(DreamObject atom, TimeSpan duration, AnimationEasi
appearance = MustGetAppearance(atom).ToMutable();
} else if (atom is DreamObjectTurf turf) {
targetEntity = EntityUid.Invalid;
turfId = turf.Appearance.GetHashCode() + 1;
appearance = turf.Appearance.ToMutable();
} else if (atom is DreamObjectArea area) {

Check warning

Code scanning / InspectCode

Unused local variable Warning

Local variable 'area' is never used
return;
Expand All @@ -573,9 +572,9 @@ public void AnimateAppearance(DreamObject atom, TimeSpan duration, AnimationEasi
// Don't send the updated appearance to clients, they will animate it
DMISpriteSystem.SetSpriteAppearance(new(targetEntity, targetComponent), appearance, dirty: false);
} else if (atom is DreamObjectTurf turf) {
//this is basically the only time it's okay to set turf.Appearance outside of DreamMapManager.SetTurfAppearance()
//because we don't want to notify the client of the appearance change
turf.Appearance = AppearanceSystem!.AddAppearance(appearance);
//TODO: turf appearances are just set to the end appearance, they do not get properly animated
_dreamMapManager.SetTurfAppearance(turf, appearance);
turfId = appearance.GetHashCode()+1;
} else if (atom is DreamObjectArea area) {

Check warning

Code scanning / InspectCode

Unused local variable Warning

Local variable 'area' is never used
//fuck knows, this will trigger a bunch of turf updates to? idek
}
Expand Down

0 comments on commit 80da1ea

Please sign in to comment.