Gleb Mazovetskiy
7fede6c4cb
Clean up owned/unowned CelSprite ambiguity
...
Makes `CelSprite` unowned and adds a new `OwnedCelSprite` class for
owned sprites.
This clarifies ownership and makes the code cleaner in a number of
places.
Additionally, because the `CelSprite` class is now tiny (1 less
pointer), we can pass it by-value instead of by-reference, removing a
pointer indirection in the rendering functions.
4 years ago
obligaron
75760382ef
Regard preview frame in AnimationInfo
4 years ago
obligaron
a7f361de41
AnimationInfo: Change TicksSinceSequenceStarted and relevantAnimationTicksWithSkipping to float
4 years ago
Gleb Mazovetskiy
7e1fea6f76
clang-format all files in {Source,test}/
...
Also includes a few manual tweaks to comments and newlines for better results.
Co-authored-by: Anders Jenbo <anders@jenbo.dk>
4 years ago
obligaron
551645060b
Fix item swapping and AnimationInfo::ChangeAnimationData
5 years ago
obligaron
54d63e2edd
Change AnimationInfo.pCelSprite to const
5 years ago
Anders Jenbo
2ca6e37c46
Clean up sub folders using clang-tidy/Android Studio
5 years ago
obligaron
3a9cc631c7
Rename DelayLen -> TicksPerFrame
...
Rename DelayCounter -> TickCounterOfCurrentFrame
5 years ago
obligaron
d4bda3c13e
ADL: correct comment typo
5 years ago
obligaron
fb23521288
Introduce AnimationInfo.IsPetrified to handle Stone Curse Spell
5 years ago
obligaron
a4cacfbcbe
Enable ADL for Monsters
5 years ago
Gleb Mazovetskiy
e40b1963f9
🚚 engine.h: Extract `CelSprite` and file loading
5 years ago
obligaron
61ba5009ac
Convert to CelSprite
5 years ago
obligaron
a295586636
Support changing animation data on-the-fly even if the number of frames differ
5 years ago
obligaron
19615c6976
AnimationInfo: Add GetAnimationProgress()
5 years ago
Anders Jenbo
c11945e62b
🎨 Fix line endings
5 years ago
obligaron
e3e3d02da7
Correct Doxygen comments
5 years ago
Anders Jenbo
f579b2f287
Handle cel/cl2 files as byte arrays
5 years ago
obligaron
cb7819a75c
Introduce AnimationDistributionFlags::RepeatedAction
5 years ago
obligaron
b5954eb34b
Change AnimationDistributionParams to AnimationDistributionFlags
5 years ago
obligaron
b08e0c20dc
In repeated Animations show skipped Frames from previous Animation (repeated Attack/RangeAttack/Spell)
5 years ago
obligaron
401a820998
Rename GameTick to Tick (for variables)
5 years ago
obligaron
26601c98dc
Simplify GetFrameToUseForRendering (remove local variables and use member variables)
5 years ago
obligaron
ff995adc2b
Move ProcessPlayerAnimation to AnimationInfo
5 years ago
obligaron
16b3b38908
Move NewPlrAnim logic to AnimationInfo
...
Adjust SetNewAnimation-Parameter Names to Class Member
Adjust NewPlrAnim-Parameter Names to SetNewAnimation-Parameter Names
5 years ago
obligaron
3b87433fc2
Move GetFrameToUseForPlayerRendering to AnimationInfo
5 years ago
obligaron
1de46a8495
Rename member variables
5 years ago
obligaron
0b5183f63e
Introduce AnimationInfo
...
Update AnimationInfo.DelayLen comment
5 years ago