mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-03-22 19:02:45 +00:00
New ring sparkles
This commit is contained in:
parent
b77780e1e7
commit
58b56b2867
4 changed files with 30 additions and 40 deletions
|
@ -2418,6 +2418,7 @@ static actionpointer_t actionpointers[] =
|
|||
{{A_SnapperThinker}, "A_SNAPPERTHINKER"},
|
||||
{{A_SaloonDoorSpawn}, "A_SALOONDOORSPAWN"},
|
||||
{{A_MinecartSparkThink}, "A_MINECARTSPARKTHINK"},
|
||||
{{A_ModuloToState}, "A_ModuloToState"},
|
||||
{{NULL}, "NONE"},
|
||||
|
||||
// This NULL entry must be the last in the list
|
||||
|
@ -7134,18 +7135,6 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
|
|||
"S_SPRK2",
|
||||
"S_SPRK3",
|
||||
"S_SPRK4",
|
||||
"S_SPRK5",
|
||||
"S_SPRK6",
|
||||
"S_SPRK7",
|
||||
"S_SPRK8",
|
||||
"S_SPRK9",
|
||||
"S_SPRK10",
|
||||
"S_SPRK11",
|
||||
"S_SPRK12",
|
||||
"S_SPRK13",
|
||||
"S_SPRK14",
|
||||
"S_SPRK15",
|
||||
"S_SPRK16",
|
||||
|
||||
// Robot Explosion
|
||||
"S_XPLD_FLICKY",
|
||||
|
|
20
src/info.c
20
src/info.c
|
@ -3827,22 +3827,10 @@ state_t states[NUMSTATES] =
|
|||
{SPR_NULL, 0, 105, {A_Scream}, 0, 0, S_NULL}, // S_CRUMBLE2
|
||||
|
||||
// Spark
|
||||
{SPR_SPRK, FF_TRANS40 , 1, {NULL}, 0, 0, S_SPRK2}, // S_SPRK1
|
||||
{SPR_SPRK, FF_TRANS50|1, 1, {NULL}, 0, 0, S_SPRK3}, // S_SPRK2
|
||||
{SPR_SPRK, FF_TRANS50|2, 1, {NULL}, 0, 0, S_SPRK4}, // S_SPRK3
|
||||
{SPR_SPRK, FF_TRANS50|3, 1, {NULL}, 0, 0, S_SPRK5}, // S_SPRK4
|
||||
{SPR_SPRK, FF_TRANS60 , 1, {NULL}, 0, 0, S_SPRK6}, // S_SPRK5
|
||||
{SPR_SPRK, FF_TRANS60|1, 1, {NULL}, 0, 0, S_SPRK7}, // S_SPRK6
|
||||
{SPR_SPRK, FF_TRANS60|2, 1, {NULL}, 0, 0, S_SPRK8}, // S_SPRK7
|
||||
{SPR_SPRK, FF_TRANS70|3, 1, {NULL}, 0, 0, S_SPRK9}, // S_SPRK8
|
||||
{SPR_SPRK, FF_TRANS70 , 1, {NULL}, 0, 0, S_SPRK10}, // S_SPRK9
|
||||
{SPR_SPRK, FF_TRANS70|1, 1, {NULL}, 0, 0, S_SPRK11}, // S_SPRK10
|
||||
{SPR_SPRK, FF_TRANS80|2, 1, {NULL}, 0, 0, S_SPRK12}, // S_SPRK11
|
||||
{SPR_SPRK, FF_TRANS80|3, 1, {NULL}, 0, 0, S_SPRK13}, // S_SPRK12
|
||||
{SPR_SPRK, FF_TRANS80 , 1, {NULL}, 0, 0, S_SPRK14}, // S_SPRK13
|
||||
{SPR_SPRK, FF_TRANS90|1, 1, {NULL}, 0, 0, S_SPRK15}, // S_SPRK14
|
||||
{SPR_SPRK, FF_TRANS90|2, 1, {NULL}, 0, 0, S_SPRK16}, // S_SPRK15
|
||||
{SPR_SPRK, FF_TRANS90|3, 1, {NULL}, 0, 0, S_NULL}, // S_SPRK16
|
||||
{SPR_SPRK, FF_TRANS80|18, 1, {NULL}, 0, 0, S_SPRK4}, // S_SPRK1
|
||||
{SPR_SPRK, FF_TRANS20|FF_ANIMATE|0, 18, {NULL}, 8, 2, S_NULL}, // S_SPRK2
|
||||
{SPR_SPRK, FF_TRANS20|FF_ANIMATE|9, 1, {NULL}, 8, 2, S_NULL}, // S_SPRK3
|
||||
{SPR_SPRK, FF_TRANS50|1, 0, {A_ModuloToState}, 2, S_SPRK2, S_SPRK3}, // S_SPRK4
|
||||
|
||||
// Robot Explosion
|
||||
{SPR_BOM1, 0, 0, {A_FlickySpawn}, 0, 0, S_XPLD1}, // S_XPLD_FLICKY
|
||||
|
|
13
src/info.h
13
src/info.h
|
@ -265,6 +265,7 @@ void A_SnapperSpawn();
|
|||
void A_SnapperThinker();
|
||||
void A_SaloonDoorSpawn();
|
||||
void A_MinecartSparkThink();
|
||||
void A_ModuloToState();
|
||||
|
||||
// ratio of states to sprites to mobj types is roughly 6 : 1 : 1
|
||||
#define NUMMOBJFREESLOTS 512
|
||||
|
@ -3893,18 +3894,6 @@ typedef enum state
|
|||
S_SPRK2,
|
||||
S_SPRK3,
|
||||
S_SPRK4,
|
||||
S_SPRK5,
|
||||
S_SPRK6,
|
||||
S_SPRK7,
|
||||
S_SPRK8,
|
||||
S_SPRK9,
|
||||
S_SPRK10,
|
||||
S_SPRK11,
|
||||
S_SPRK12,
|
||||
S_SPRK13,
|
||||
S_SPRK14,
|
||||
S_SPRK15,
|
||||
S_SPRK16,
|
||||
|
||||
// Robot Explosion
|
||||
S_XPLD_FLICKY,
|
||||
|
|
|
@ -37,6 +37,7 @@ boolean LUA_CallAction(const char *action, mobj_t *actor);
|
|||
player_t *stplyr;
|
||||
INT32 var1;
|
||||
INT32 var2;
|
||||
INT32 Modulothing;
|
||||
|
||||
//
|
||||
// P_NewChaseDir related LUT.
|
||||
|
@ -294,6 +295,8 @@ void A_SnapperSpawn(mobj_t *actor);
|
|||
void A_SnapperThinker(mobj_t *actor);
|
||||
void A_SaloonDoorSpawn(mobj_t *actor);
|
||||
void A_MinecartSparkThink(mobj_t *actor);
|
||||
void A_ModuloToState(mobj_t *actor);
|
||||
|
||||
//for p_enemy.c
|
||||
|
||||
//
|
||||
|
@ -13647,4 +13650,25 @@ void A_MinecartSparkThink(mobj_t *actor)
|
|||
P_SetScale(trail, trail->scale/4);
|
||||
trail->destscale = trail->scale;
|
||||
}
|
||||
}
|
||||
|
||||
// Function: A_MinecartSparkThink
|
||||
//
|
||||
// Description: Modulo operation to state
|
||||
//
|
||||
// var1 = Modulo
|
||||
// var2 = State
|
||||
//
|
||||
void A_ModuloToState(mobj_t *actor)
|
||||
{
|
||||
INT32 locvar1 = var1;
|
||||
INT32 locvar2 = var2;
|
||||
#ifdef HAVE_BLUA
|
||||
if (LUA_CallAction("A_ModuloToState", actor))
|
||||
return;
|
||||
#endif
|
||||
|
||||
if ((Modulothing % locvar1 == 0))
|
||||
P_SetMobjState(actor, (locvar2));
|
||||
Modulothing = Modulothing + 1;
|
||||
}
|
Loading…
Reference in a new issue