Closed vulcandth closed 11 months ago
Related to #1016
Looks great! This is essentially what I was aiming for, yeah.
Great! I'll just wait for Rangi to have time to take a quick look as well and then i'll merge this and work on pokegold as well.
So, we have this for sprite animations:
SPRITE_ANIM_INDEX_*
constants are indexes into SpriteAnimSeqData
(see data/sprite_anims/sequences.asm) (SpriteAnimSeqData
should be renamed!)SPRITE_ANIM_SEQ_*
constants are indexes into DoAnimFrame.Jumptable
(see engine/gfx/sprite_anims.asm)SPRITE_ANIM_FRAMESET_*
constants are indexes into SpriteAnimFrameData
(see data/sprite_anims/framesets.asm)SPRITE_ANIM_OAMSET_*
constants are indexes into SpriteAnimOAMData
(see data/sprite_anims/oam.asm)And for battle animations, with this PR:
BATTLE_ANIM_INDEX_*
constants are indexes into BattleAnimObjects
(see data/battle_anims/objects.asm) (BattleAnimObjects
should be renamed!)BATTLE_ANIM_SEQ_*
constants are indexes into DoBattleAnimFrame.Jumptable
(see engine/battle_anims/functions.asm)BATTLE_ANIM_FRAMESET_*
constants are indexes into BattleAnimFrameData
(see data/battle_anims/framesets.asm)BATTLE_ANIM_OAMSET_*
constants are indexes into BattleAnimOAMData
(see data/battle_anims/oam.asm)This is mostly good. I would consider getting rid of the whole "seq(uence)" terminology, and just having indexes, functions, framesets, and oamsets.
Going to draft this for now until I have a chance to work on it again.. and after SourApple's PR is merged.
Alright I completely reworked this PR... so the old feedback is mostly irrelevant now. Look at the first comment for updated information on what this PR has changed.
I'd prefer SpriteAnimFunc_
and BattleAnimFunc_
over spelling out the full Function
. I also wonder if InitSpriteAnimStruct
could be renamed into something else, maybe SpawnSprite
or AddSprite
.
Bumping to confirm that this may be merged.
Thanks! I'll merge this; this weekend. So I have time to do it for pokegold as well.
Is it intended that SPRITEANIMSTRUCT_ANIM_SEQ_ID
has not been renamed to SPRITEANIMSTRUCT_FUNC_ID
(and idem for the associated WRAM addresses from the wSpriteAnim
macro) even though SPRITE_ANIM_SEQ_*
have been renamed to SPRITE_ANIM_FUNC_*
?
resolves #765
I'm fairly confident this is what we wanted to accomplish here. I think this is much more consistent. Let me know what you think Rangi / Mid-kid.
Edit:
What this PR has done:
Battle Animations
BattleAnimObjects:
(seedata/battle_anims_objects.asm
)ANIM_OBJ_*
renamed toBATTLE_ANIM_OBJ_*
NUM_ANIM_OBJS
renamed toNUM_BATTLE_ANIM_OBJS
DoBattleAnimFrame:
(seeengine/battle_anims/functions.asm
)BATTLEANIMFUNC_*
renamed toBATTLE_ANIM_FUNC_*
NUM_BATTLEANIMFUNCS
renamed toNUM_BATTLE_ANIM_FUNCS
BattleAnimFrameData:
(seedata/battle_anims/framsets.asm
)BATTLEANIMFRAMESET_*
renamed toBATTLE_ANIM_FRAMSET_*
NUM_BATTLEANIMFRAMESETS
renamed toNUM_BATTLE_ANIM_FRAMESETS
BattleAnimOAMData:
(seedata/battle_anim/oam.asm
)BATTLEANIMOAMSET_*
renamed toBATTLE_ANIM_OAMSET_*
NUM_BATTLEANIMOAMSETS
renamed toNUM_BATTLE_ANIM_OAMSETS
BattleBGEffects:
(seeengine/battle_anims/bg_effects.asm
)ANIM_BG_*
renamed toBATTLE_BG_EFFECT_*
NUM_ANIM_BGS
renamed toNUM_BATTLE_BG_EFFECTS
AnimObjGFX:
(seedata/battle_anims/object_gfx.asm
)ANIM_GFX_*
renamed toBATTLE_ANIM_GFX_
NUM_ANIM_GFX
renamed toNUM_BATTLE_ANIM_GFX
Sprite Animations
SpriteAnimSeqData:
renamed toSpriteAnimObjects:
(data/sprite_anims/sequences.asm
renamed todata/sprite_anims/objects.asm
)SPRITE_ANIM_INDEX_*
renamed toSPRITE_ANIM_OBJ_*
NUM_SPRITE_ANIM_INDEXES
renamed toNUM_SPRITE_ANIM_OBJS
DoAnimFrame:
renamed toDoSpriteAnimFrame:
(engine/gfx/sprite_anims.asm
moved/renamed toengine/sprite_anims/functions.asm
)SPRITE_ANIM_SEQ_*
renamed toSPRITE_ANIM_FUNC_*
NUM_SPRITE_ANIM_SEQS
renamed toNUM_SPRITE_ANIM_FUNCS
SpriteAnimFrameData:
(seedata/sprite_anims/framesets.asm
)SPRITE_ANIM_FRAMESET_*
unchanged.SpriteAnimOAMData:
(seedata/sprite_anims/oam.asm
)SPRITE_ANIM_OAMSET_*
unchanged.MISC
; 00
comments.NUM_ANIM_OBJECTS
toNUM_BATTLE_ANIM_STRUCTS