Danukem, on 28 October 2022 - 11:03 AM, said:
Alright thanks again. And this numsprites accounts for all the sprites that make up the 16384 sprites allowed in a map correct?
Danukem, on 28 October 2022 - 11:03 AM, said:
VGames, on 28 October 2022 - 11:23 AM, said:
Danukem, on 28 October 2022 - 11:33 AM, said:
This post has been edited by VGames: 28 October 2022 - 11:48 AM
VGames, on 28 October 2022 - 11:41 AM, said:
case COLA
ifpdistl FROZENQUICKKICKDIST
{
ifphealthl MAXPLAYERHEALTH
nullop
else
{
ifpinventory 9 0
{
ifpinventory 9 100
{
addinventory 9 30
killit
}
}
}
}
break
ifl player[].jetpack_amount JETPACK_AMOUNT addinventory GET_JETPACK JETPACK_AMOUNT
This post has been edited by VGames: 28 October 2022 - 03:59 PM
setp .jetpack_amount JETPACK_AMOUNT setp .boot_amount BOOT_AMOUNT etc.
onevent EVENT_LOOKUP // ************************************************************************************
setvar RETURN -1
ifvare EngageShrink 0
{
ifvare ShrinkDelay 0
{
setvar EngageShrink 1
setvar ShrinkDelay 100
}
}
else
{
ifvare ShrinkDelay 0
{
setvar EngageShrink 0
setvar ShrinkDelay 100
}
}
endevent // ************************************************************************************
ifvare EngageShrink 1
{
ifvare Shrunk 0
{
palfrom 48 0 48
move PSHRINKING
sound ACTOR_SHRINKING
cstat 0
sizeto 8 9
spawn FRAMEEFFECT1
setvar Shrunk 1
}
}
else ifvare EngageShrink 0
{
ifvare Shrunk 1
{
palfrom 48 0 48
sizeto 42 36
ifgapzl 24
{
strength 0
sound SQUISHED
palfrom 48 64
break
}
setvar Shrunk 0
}
}
ifmove PSHRINKING
{
ifcount 32
{
ifcount SHRUNKDONECOUNT
{
move 0
cstat 257
}
/*
else
ifcount SHRUNKCOUNT
{
sizeto 42 36
ifgapzl 24
{
strength 0
sound SQUISHED
palfrom 48 64
break
}
}
*/
else
ifp ponsteroids
count SHRUNKCOUNT
}
else
{
ifp ponsteroids
count SHRUNKCOUNT
else
{
sizeto 8 9
spawn FRAMEEFFECT1
}
}
}
VGames, on 29 October 2022 - 11:29 AM, said:
Danukem, on 29 October 2022 - 12:56 PM, said:
This post has been edited by VGames: 29 October 2022 - 06:04 PM
This post has been edited by lllllllllllllll: 29 October 2022 - 10:36 PM
state damage_pushback
ifvarg peractor6 0
{
cos xvel peractor5
sin yvel peractor5
setvarvar temp peractor6
ifvarg temp 768 setvar temp 768
mulvarvar xvel temp
mulvarvar yvel temp
shiftvarr xvel 13
shiftvarr yvel 13
setvar zvel 0
movesprite THISACTOR xvel yvel zvel CLIPMASK0 RETURN
ifvarn RETURN 0
{
addvar RETURN 16384
ifvarl RETURN 16384
ifvarg RETURN -1 // hit a sprite
{
getactor[RETURN].picnum picnum
ifvare picnum GLASS
{
setactor[RETURN].htextra peractor6
setactor[RETURN].htpicnum SHOTSPARK1 //RPG
}
}
}
shiftvarr peractor6 1
ifvarl peractor6 4 setvar peractor6 0
}
else
ifg sprite[].htextra 4
{
set tempb 8
geta[].htextra bleeding
ifl bleeding 32 set bleeding 32
//ifvare CURRWEAP 11 ifvare gravgun YES
ifwasweapon SHOTSPARK1 setvar bleeding 200
ifvarn tempb 0
ifvarn sprite[].htpicnum FREEZEBLAST
ifvarn sprite[].htpicnum DC_FLAME
{
getactor[THISACTOR].htang peractor5 // the angle monster will move in
setvarvar peractor6 bleeding
mulvarvar peractor6 tempb // peractor6 is the knockback force
setvarvar temp weight
shiftvarl temp 1
subvarvar peractor6 temp
ifvarl peractor6 0 setvar peractor6 0
}
}
ends
ifwasweapon SHOTSPARK1 state damage_pushback
This post has been edited by VGames: 30 October 2022 - 06:24 PM
Danukem, on 30 October 2022 - 07:08 PM, said:
ifactorsoundwill still result in a 'loop' whenever your firing rate scales neatly with the audio duration.
//state PAINCOUNT being whatever means of setting a count with a small random range
//(A) pain sound always plays if cry sound has finished, if unfinished only if count is met
ifactorsound THISACTOR PRED_PAIN
{
ifcount PAINCOUNT
{
sound PREDPAIN
state PAINCOUNT
}
}
else
{
sound PRED_PAIN
state PAINCOUNT
}
//(B) pain sound always plays if cry sound has finished, if unfinished only sometimes if count is met
ifactorsound THISACTOR PRED_PAIN
{
ifrnd 128 nullop
else
ifcount PAINCOUNT
{
sound PREDPAIN
state PAINCOUNT
}
}
else
{
sound PRED_PAIN
state PAINCOUNT
}
//(C) painsound only plays after count is met
ifcount PAINCOUNT
{
sound PREDPAIN
state PAINCOUNT
}
//(D) pain sound sometimes plays if cry sound has finished, otherwise only if count is met
ifactorsound THISACTOR PRED_PAIN
{
ifcount PAINCOUNT
{
sound PREDPAIN
state PAINCOUNT
}
}
else
{
ifrnd 128
{
sound PRED_PAIN
state PAINCOUNT
}
else
ifcount PAINCOUNT
{
sound PRED_PAIN
state PAINCOUNT
}
}
add PAINSOUNDCOUNT 1
ifcount 1 {
addvar COUNT 1
resetcount
} i did
ifcount 33 state somecode ifge sprite[].htg_t 0 33 state somecode
switch sprite[].htg_t 0
{
case 33
state somecode
break
}
endswitch
RPD Guy, on 24 May 2022 - 10:33 AM, said:
paldata[(pal number)].nofloorpal 1
set paldata[10].nofloorpal 1
Reaper_Man, on 08 November 2022 - 05:01 AM, said:
ifcount 33 state somecode ifge sprite[].htg_t 0 33 state somecode
switch sprite[].htg_t 0
{
case 33
state somecode
break
}
endswitch
useractor notenemy LOCKPLAYER
cstat 32768
getactor[].hitag FOUNDHITAG
// ifpdistl 1024 // remove remlines to make it non global!
{
setvar ONPARA 1 // gamevar ONPARA triggers a lockplayer situation wich was initially used for a descending with a "parachute" type of thing, but it works just as well when the player is already on the ground.
/*
ifcount 1 {
addvar COUNT 1 // the original "timer"
resetcount
}
*/
add COUNT 1
ife FOUNDHITAG COUNT { setvar ONPARA 0 killit }
else
ifcount 10240 { setvar ONPARA 0 killit } // used to kill the actor after a specific time in case HT wasnt set.
}
enda
ifvare ONPARA 1 { setp[].movement_lock 15 setp[].weapon_pos 20 } // if on parachute, dont move forward back or to the side and lower the weapon
else
ifvare ONPARA 0 { setp[].movement_lock 0 } // when on the ground give the player back controll.
gamevar ONPARA 0 1 gamevar COUNT 0 2 gamevar FOUNDHITAG 0 2
This post has been edited by jimbob: 09 November 2022 - 06:11 AM
appendevent EVENT_SPAWN
{
ifactor LOCKPLAYER
{
cstat 32768
set COUNT 0 // not necessary, but done for safety
geta .hitag FOUNDHITAG
seta .hitag 0
}
}
endeventdefstate killlock
{
set ONPARA 0
killit
}
ends
useractor notenemy LOCKPLAYER
{
add COUNT 1
set ONPARA 1
ife COUNT FOUNDHITAG
state killlock
else
ife COUNT 10240
state killlock
}
endaife ONPARA 1
{
setp .movement_lock 15
setp .weapon_pos 20
}
else
setp .movement_lock 0ife ONPARA 1
{
setp .movement_lock 15
setp .weapon_pos 20
}
else
ife ONPARA 0
{
setp .movement_lock 0
set ONPARA -1
}
Quote
This post has been edited by jimbob: 09 November 2022 - 07:18 AM