sm64/data/p/pathwaterripple.p
2022-12-04 22:27:02 -05:00

127 lines
2.7 KiB
OpenEdge ABL

/********************************************************************************
-------------------------
Ultra 64 MARIO Brothers
-------------------------
File : pathwaterripple.s
Description :
Date : 1995.
Author : H.yajima
********************************************************************************/
/*################*/
#ifdef ASSEMBLER
/*################*/
/*--------------------------------------------------------------*/
e_smalldropripple:
p_initialize(option)
p_setbit(flag,stf_moveON)
p_setd(animeangleX,0)
p_setd(animeangleY,0)
p_setd(animeangleZ,0)
p_program(s_smallripple_init)
p_addf(worldY,5)
p_animereset
p_do(6)
p_animeinc
p_next
p_killshape
/*--------------------------------------------------------------*/
e_dropripple:
p_initialize(option)
p_setbit(flag,stf_moveON)
p_setd(animeangleX,0)
p_setd(animeangleY,0)
p_setd(animeangleZ,0)
p_animereset
p_program(s_dropripple_init)
p_do(6)
p_animeinc
p_next
p_killshape
/*------------------------------------------------------------------------------*/
e_waterrippleB:
p_initialize(option)
p_setbit(flag,stf_moveON)
p_setd(animeangleX,0)
p_setd(animeangleY,0)
p_setd(animeangleZ,0)
p_animereset
p_animeinc
p_while
p_program(s_playerripple_main)
p_animeinc
p_do(6)
p_program(s_playerripple_main)
p_next
p_program(s_playerripple_main)
p_loop
/*------------------------------------------------------------------------------*/
e_rippleA:
p_initialize(effect)
p_setbit(flag,stf_moveON)
p_setd(animeangleX,0)
p_setd(animeangleY,0)
p_setd(animeangleZ,0)
p_animereset
p_do(6)
p_animeinc
p_next
p_killshape
/*################*/
#else
/*################*/
/*------------------------------------------------------------------------------*/
extern void s_playerripple_main(void)
{
s_copy_worldXYZ(execstp,player1stp);
execstp->s[stw_worldY].f = playerWorks[0].water + 5;
if ( ( player1stp->s[stw_work0].d & PLAYER_RIPPLE ) == 0 ){
player1stp->s[stw_effect].d = player1stp->s[stw_effect].d & (stf_ripple^0xffff );
execstp->status = 0; /* Shape Remove */
}
}
/********************************************************************************/
extern void s_smallripple_init(void)
{
s_set_scale( 1.5+Randomf() );
}
/********************************************************************************/
extern void s_dropripple_init(void)
{
float water = mcWaterCheck(obj_worldX,obj_worldZ);
stSetScale(execstp,0.5,1.0,0.5);
obj_worldY = water+5;
}
/*################*/
#endif
/*################*/
/*===============================================================================
end end end end end end end end
===============================================================================*/