Skip to content

Commit

Permalink
Add unit sprites for unpromoted Anna: Mercenary (F) Axe
Browse files Browse the repository at this point in the history
  • Loading branch information
laqieer committed Sep 10, 2024
1 parent 2933ff7 commit 3bc2f3c
Show file tree
Hide file tree
Showing 9 changed files with 32 additions and 0 deletions.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,3 +110,10 @@ Supported emulators:
### [References](.gitmodules)

### [Musics](music/appeared_musics.json)

### Map Sprites

Mercenary (F) Axe {Pushwall, Argo, Flasuban, ArcherBias}

![Mercenary (F) Axe {Pushwall, Argo, Flasuban, ArcherBias}-stand.png](gfx/misc/Unit_Sprite_Mercenary_F_Axe_Stand.png)
![Mercenary (F) Axe {Pushwall, Argo, Flasuban, ArcherBias}-walk.png](gfx/misc/Unit_Sprite_Mercenary_F_Axe_Walk.png)
4 changes: 4 additions & 0 deletions gfx/misc/Unit_Sprite_Mercenary_F_Axe_Stand.grit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-gB4
-gzl
-gu8
-p!
Binary file added gfx/misc/Unit_Sprite_Mercenary_F_Axe_Stand.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions gfx/misc/Unit_Sprite_Mercenary_F_Axe_Walk.grit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-gB4
-gzl
-gu8
-p!
Binary file added gfx/misc/Unit_Sprite_Mercenary_F_Axe_Walk.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions ldscript/hack.lds
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,4 @@ INCLUDE ../ldscript/item.lds
INCLUDE ../ldscript/mapwork.lds
INCLUDE ../ldscript/banim_dragon.lds
INCLUDE ../ldscript/banim_dragonfx_manakete.lds
INCLUDE ../ldscript/unitsprites.lds
2 changes: 2 additions & 0 deletions ldscript/unitsprites.lds
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
. = UnitSpriteTable + 8 * 2;
.rodata.UnitSpriteAxeMercenaryF : {*(.rodata.UnitSpriteAxeMercenaryF)}
5 changes: 5 additions & 0 deletions source/mu.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
#include "jobs.h"
#include "log.h"

#include "gfx_misc.h"

int getMuId(int jid)
{
Assertf(jid < JID_COUNT, "jid=%d, JID_COUNT=%d", jid, JID_COUNT);
Expand All @@ -26,6 +28,9 @@ int getMuId(int jid)

u8 const * GetMuImgNew(struct MuProc * mu)
{
if (mu->jid == JID_MERCENARY_F)
return Unit_Sprite_Mercenary_F_Axe_WalkTiles;

return MuInfoTable[getMuId(mu->jid) - 1].img;
}

Expand Down
9 changes: 9 additions & 0 deletions source/unitsprites.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#include "unitsprite.h"

#include "gfx_misc.h"

const struct UnitSpriteInfo UnitSpriteAxeMercenaryF = {
.unk_00 = 2,
.size = UNITSPRITE_16x16,
.img = Unit_Sprite_Mercenary_F_Axe_StandTiles,
};

0 comments on commit 3bc2f3c

Please sign in to comment.