Compare commits
89
Commits
fixuphwbsp
...
fixgnu23
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4f0cf44e78 | ||
|
|
2417647110 | ||
|
|
982cd7bde2 | ||
|
|
d6bd289fcf | ||
|
|
ba44e61733 | ||
|
|
845652cbfe | ||
|
|
ceafa06efc | ||
|
|
e6f487474b | ||
|
|
d8461bb44f | ||
|
|
e25d366728 | ||
|
|
2abf0b98ac | ||
|
|
0f087d13bb | ||
|
|
2e914c61d1 | ||
|
|
3f599d5a28 | ||
|
|
6ef1f73d4d | ||
|
|
38b84baf9d | ||
|
|
fae50c0e19 | ||
|
|
50f7e2084c | ||
|
|
67cc5402cf | ||
|
|
2259d4f309 | ||
|
|
f8d903e7d2 | ||
|
|
805cde8ae8 | ||
|
|
b23906e327 | ||
|
|
2052afdb66 | ||
|
|
d9c7a40d4a | ||
|
|
cb2e017bcf | ||
|
|
d91fbf5d36 | ||
|
|
9859e43be7 | ||
|
|
306fec6f9e | ||
|
|
3e8b3e868b | ||
|
|
9261d9c5b2 | ||
|
|
f97941f86e | ||
|
|
a4810bd6c8 | ||
|
|
93cbba218a | ||
|
|
e749346f0c | ||
|
|
a658883664 | ||
|
|
d94c10014f | ||
|
|
45629386bb | ||
|
|
ffec9d64d5 | ||
|
|
3e9f17af86 | ||
|
|
03ff2fc007 | ||
|
|
4492c00840 | ||
|
|
e15319ac9b | ||
|
|
fa012aefe1 | ||
|
|
e681d2d24d | ||
|
|
76e54762d8 | ||
|
|
3b7d517be2 | ||
|
|
f4da64e3fa | ||
|
|
384acf8e31 | ||
|
|
a423451383 | ||
|
|
66cfceedaf | ||
|
|
fe9107fa9d | ||
|
|
e4f2db54e7 | ||
|
|
2f5fe01ae0 | ||
|
|
1bb7bd0abc | ||
|
|
a84ec88bc3 | ||
|
|
4a2e78081a | ||
|
|
d09d2cb445 | ||
|
|
1faa585e83 | ||
|
|
7479c82691 | ||
|
|
cfab2236da | ||
|
|
d2ee344b22 | ||
|
|
b22737223e | ||
|
|
578158c060 | ||
|
|
8eda0f78f7 | ||
|
|
2c2c82dc1a | ||
|
|
d8c9522ec9 | ||
|
|
492aef2165 | ||
|
|
fc0409e967 | ||
|
|
8a89b57e48 | ||
|
|
0f6b9ba181 | ||
|
|
8f1b4004c9 | ||
|
|
bee5250940 | ||
|
|
c61a2e6ba2 | ||
|
|
d293bb9672 | ||
|
|
9fb3f4c9a3 | ||
|
|
efc4a513ce | ||
|
|
b13793b2a4 | ||
|
|
68cb96ab97 | ||
|
|
83bb908ff0 | ||
|
|
515c18c855 | ||
|
|
58de672915 | ||
|
|
16b5037486 | ||
|
|
bcec8b98f7 | ||
|
|
fa3dcdb24f | ||
|
|
311258dda0 | ||
|
|
a0f8816de7 | ||
|
|
c546b6225c | ||
|
|
f6c6621af8 |
No files matched your search
@@ -324,6 +324,7 @@ static void AM_initVariables(void)
|
||||
m_x = (plr->mo->x >> FRACTOMAPBITS) - m_w/2;
|
||||
m_y = (plr->mo->y >> FRACTOMAPBITS) - m_h/2;
|
||||
}
|
||||
|
||||
AM_changeWindowLoc();
|
||||
|
||||
// for saving & restoring
|
||||
|
||||
+20
-3
@@ -152,6 +152,8 @@ boolean dedicated = false;
|
||||
|
||||
boolean loaded_config = false; // true once config.cfg loaded AND executed
|
||||
|
||||
static void D_CleanFile(char **filearray);
|
||||
|
||||
//
|
||||
// D_PostEvent
|
||||
// Called by the I/O functions when input is detected
|
||||
@@ -896,9 +898,24 @@ void D_SRB2Loop(void)
|
||||
rendertimefrac_unpaused = FRACUNIT;
|
||||
}
|
||||
|
||||
if ((interp || doDisplay) && !frameskip)
|
||||
if (interp || doDisplay)
|
||||
{
|
||||
ranwipe = D_Display();
|
||||
if (!frameskip)
|
||||
{
|
||||
ranwipe = D_Display();
|
||||
}
|
||||
else if (!dedicated)
|
||||
{
|
||||
// always update console and hud
|
||||
// otherwise it may take minutes to open it
|
||||
CON_Drawer();
|
||||
|
||||
if (gamestate == GS_LEVEL)
|
||||
{
|
||||
ST_Drawer();
|
||||
HU_Drawer();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Only take screenshots after drawing.
|
||||
@@ -1215,7 +1232,7 @@ void D_AddPostloadFiles(void)
|
||||
postautoloaded = true;
|
||||
}
|
||||
|
||||
void D_CleanFile(char **filearray)
|
||||
static void D_CleanFile(char **filearray)
|
||||
{
|
||||
size_t pnumwadfiles;
|
||||
for (pnumwadfiles = 0; filearray[pnumwadfiles]; pnumwadfiles++)
|
||||
|
||||
@@ -85,8 +85,6 @@ void D_PostEvent(const event_t *ev);
|
||||
|
||||
void D_ProcessEvents(void);
|
||||
|
||||
void D_CleanFile(char **filearray);
|
||||
|
||||
const char *D_Home(void);
|
||||
|
||||
//
|
||||
|
||||
+6
-2
@@ -2110,14 +2110,18 @@ INT32 D_LookupPlayer(const char *s)
|
||||
static INT32 FindPlayerByPlace(INT32 place)
|
||||
{
|
||||
INT32 playernum;
|
||||
|
||||
for (playernum = 0; playernum < MAXPLAYERS; ++playernum)
|
||||
if (playeringame[playernum])
|
||||
{
|
||||
if (!playeringame[playernum])
|
||||
continue;
|
||||
|
||||
if (players[playernum].kartstuff[k_position] == place)
|
||||
{
|
||||
return playernum;
|
||||
}
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
@@ -5674,7 +5678,7 @@ static void Command_Archivetest_f(void)
|
||||
// assign mobjnum
|
||||
i = 1;
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
if (th->function.acp1 == (actionf_p1)P_MobjThinker)
|
||||
if (th->function == (actionf_p1)P_MobjThinker)
|
||||
((mobj_t *)th)->mobjnum = i++;
|
||||
|
||||
// allocate buffer
|
||||
|
||||
@@ -1185,6 +1185,18 @@ filestatus_t findfile(char *filename, const UINT8 *wantedmd5sum, boolean complet
|
||||
badmd5 = true;
|
||||
// if not found at all, just move on without doing anything
|
||||
|
||||
if (cv_addons_option.value == 3 && *cv_addons_folder.string != '\0')
|
||||
{
|
||||
// next, check any custom directory if specified
|
||||
homecheck = filesearch(filename, cv_addons_folder.string, wantedmd5sum, completepath, 10);
|
||||
|
||||
if (homecheck == FS_FOUND) // we found the file, so return that we have :)
|
||||
return FS_FOUND;
|
||||
else if (homecheck == FS_MD5SUMBAD) // file has a bad md5; move on and look for a file with the right md5
|
||||
badmd5 = true;
|
||||
// if not found at all, just move on without doing anything
|
||||
}
|
||||
|
||||
// finally check "." directory
|
||||
homecheck = filesearch(filename, ".", wantedmd5sum, completepath, 10);
|
||||
|
||||
|
||||
+1
-8
@@ -28,18 +28,11 @@
|
||||
// To compile this as "ANSI C with classes" we will need to handle the various
|
||||
// action functions cleanly.
|
||||
//
|
||||
typedef void (*actionf_v)();
|
||||
typedef void (*actionf_p1)(void *);
|
||||
|
||||
typedef union
|
||||
{
|
||||
actionf_v acv;
|
||||
actionf_p1 acp1;
|
||||
} actionf_t;
|
||||
|
||||
// Historically, "think_t" is yet another function pointer to a routine
|
||||
// to handle an actor.
|
||||
typedef actionf_t think_t;
|
||||
typedef actionf_p1 think_t;
|
||||
|
||||
// Doubly linked list of actors.
|
||||
typedef struct thinker_s
|
||||
|
||||
@@ -152,3 +152,8 @@ boolean I_UseNativeKeyboard(void)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
void I_SetBorderlessWindow(void)
|
||||
{
|
||||
|
||||
}
|
||||
+218
-217
@@ -1416,211 +1416,212 @@ static void readhuditem(MYFILE *f, INT32 num)
|
||||
// DO NOT FORGET TO SYNC THIS LIST WITH THE ACTIONNUM ENUM IN INFO.H
|
||||
actionpointer_t actionpointers[] =
|
||||
{
|
||||
{{A_Explode}, "A_EXPLODE"},
|
||||
{{A_Pain}, "A_PAIN"},
|
||||
{{A_Fall}, "A_FALL"},
|
||||
{{A_MonitorPop}, "A_MONITORPOP"},
|
||||
{{A_Look}, "A_LOOK"},
|
||||
{{A_Chase}, "A_CHASE"},
|
||||
{{A_FaceStabChase}, "A_FACESTABCHASE"},
|
||||
{{A_FaceTarget}, "A_FACETARGET"},
|
||||
{{A_FaceTracer}, "A_FACETRACER"},
|
||||
{{A_Scream}, "A_SCREAM"},
|
||||
{{A_BossDeath}, "A_BOSSDEATH"},
|
||||
{{A_CustomPower}, "A_CUSTOMPOWER"},
|
||||
{{A_GiveWeapon}, "A_GIVEWEAPON"},
|
||||
{{A_RingShield}, "A_RINGSHIELD"},
|
||||
{{A_RingBox}, "A_RINGBOX"},
|
||||
{{A_Invincibility}, "A_INVINCIBILITY"},
|
||||
{{A_SuperSneakers}, "A_SUPERSNEAKERS"},
|
||||
{{A_BunnyHop}, "A_BUNNYHOP"},
|
||||
{{A_BubbleSpawn}, "A_BUBBLESPAWN"},
|
||||
{{A_FanBubbleSpawn}, "A_FANBUBBLESPAWN"},
|
||||
{{A_BubbleRise}, "A_BUBBLERISE"},
|
||||
{{A_BubbleCheck}, "A_BUBBLECHECK"},
|
||||
{{A_AwardScore}, "A_AWARDSCORE"},
|
||||
{{A_ExtraLife}, "A_EXTRALIFE"},
|
||||
{{A_BombShield}, "A_BOMBSHIELD"},
|
||||
{{A_JumpShield}, "A_JUMPSHIELD"},
|
||||
{{A_WaterShield}, "A_WATERSHIELD"},
|
||||
{{A_ForceShield}, "A_FORCESHIELD"},
|
||||
{{A_PityShield}, "A_PITYSHIELD"},
|
||||
{{A_GravityBox}, "A_GRAVITYBOX"},
|
||||
{{A_ScoreRise}, "A_SCORERISE"},
|
||||
{{A_ParticleSpawn}, "A_PARTICLESPAWN"},
|
||||
{{A_AttractChase}, "A_ATTRACTCHASE"},
|
||||
{{A_DropMine}, "A_DROPMINE"},
|
||||
{{A_FishJump}, "A_FISHJUMP"},
|
||||
{{A_ThrownRing}, "A_THROWNRING"},
|
||||
{{A_GrenadeRing}, "A_GRENADERING"}, // SRB2kart
|
||||
{{A_SetSolidSteam}, "A_SETSOLIDSTEAM"},
|
||||
{{A_UnsetSolidSteam}, "A_UNSETSOLIDSTEAM"},
|
||||
{{A_SignPlayer}, "A_SIGNPLAYER"},
|
||||
{{A_OverlayThink}, "A_OVERLAYTHINK"},
|
||||
{{A_JetChase}, "A_JETCHASE"},
|
||||
{{A_JetbThink}, "A_JETBTHINK"},
|
||||
{{A_JetgThink}, "A_JETGTHINK"},
|
||||
{{A_JetgShoot}, "A_JETGSHOOT"},
|
||||
{{A_ShootBullet}, "A_SHOOTBULLET"},
|
||||
{{A_MinusDigging}, "A_MINUSDIGGING"},
|
||||
{{A_MinusPopup}, "A_MINUSPOPUP"},
|
||||
{{A_MinusCheck}, "A_MINUSCHECK"},
|
||||
{{A_ChickenCheck}, "A_CHICKENCHECK"},
|
||||
{{A_MouseThink}, "A_MOUSETHINK"},
|
||||
{{A_DetonChase}, "A_DETONCHASE"},
|
||||
{{A_CapeChase}, "A_CAPECHASE"},
|
||||
{{A_RotateSpikeBall}, "A_ROTATESPIKEBALL"},
|
||||
{{A_SlingAppear}, "A_SLINGAPPEAR"},
|
||||
{{A_MaceRotate}, "A_MACEROTATE"},
|
||||
{{A_UnidusBall}, "A_UNIDUSBALL"},
|
||||
{{A_RockSpawn}, "A_ROCKSPAWN"},
|
||||
{{A_SetFuse}, "A_SETFUSE"},
|
||||
{{A_CrawlaCommanderThink}, "A_CRAWLACOMMANDERTHINK"},
|
||||
{{A_SmokeTrailer}, "A_SMOKETRAILER"},
|
||||
{{A_RingExplode}, "A_RINGEXPLODE"},
|
||||
{{A_OldRingExplode}, "A_OLDRINGEXPLODE"},
|
||||
{{A_MixUp}, "A_MIXUP"},
|
||||
{{A_RecyclePowers}, "A_RECYCLEPOWERS"},
|
||||
{{A_Boss1Chase}, "A_BOSS1CHASE"},
|
||||
{{A_FocusTarget}, "A_FOCUSTARGET"},
|
||||
{{A_Boss2Chase}, "A_BOSS2CHASE"},
|
||||
{{A_Boss2Pogo}, "A_BOSS2POGO"},
|
||||
{{A_BossZoom}, "A_BOSSZOOM"},
|
||||
{{A_BossScream}, "A_BOSSSCREAM"},
|
||||
{{A_Boss2TakeDamage}, "A_BOSS2TAKEDAMAGE"},
|
||||
{{A_Boss7Chase}, "A_BOSS7CHASE"},
|
||||
{{A_GoopSplat}, "A_GOOPSPLAT"},
|
||||
{{A_Boss2PogoSFX}, "A_BOSS2POGOSFX"},
|
||||
{{A_Boss2PogoTarget}, "A_BOSS2POGOTARGET"},
|
||||
{{A_BossJetFume}, "A_BOSSJETFUME"},
|
||||
{{A_EggmanBox}, "A_EGGMANBOX"},
|
||||
{{A_TurretFire}, "A_TURRETFIRE"},
|
||||
{{A_SuperTurretFire}, "A_SUPERTURRETFIRE"},
|
||||
{{A_TurretStop}, "A_TURRETSTOP"},
|
||||
{{A_JetJawRoam}, "A_JETJAWROAM"},
|
||||
{{A_JetJawChomp}, "A_JETJAWCHOMP"},
|
||||
{{A_PointyThink}, "A_POINTYTHINK"},
|
||||
{{A_CheckBuddy}, "A_CHECKBUDDY"},
|
||||
{{A_HoodThink}, "A_HOODTHINK"},
|
||||
{{A_ArrowCheck}, "A_ARROWCHECK"},
|
||||
{{A_SnailerThink}, "A_SNAILERTHINK"},
|
||||
{{A_SharpChase}, "A_SHARPCHASE"},
|
||||
{{A_SharpSpin}, "A_SHARPSPIN"},
|
||||
{{A_VultureVtol}, "A_VULTUREVTOL"},
|
||||
{{A_VultureCheck}, "A_VULTURECHECK"},
|
||||
{{A_SkimChase}, "A_SKIMCHASE"},
|
||||
{{A_1upThinker}, "A_1UPTHINKER"},
|
||||
{{A_SkullAttack}, "A_SKULLATTACK"},
|
||||
{{A_LobShot}, "A_LOBSHOT"},
|
||||
{{A_FireShot}, "A_FIRESHOT"},
|
||||
{{A_SuperFireShot}, "A_SUPERFIRESHOT"},
|
||||
{{A_BossFireShot}, "A_BOSSFIRESHOT"},
|
||||
{{A_Boss7FireMissiles}, "A_BOSS7FIREMISSILES"},
|
||||
{{A_Boss1Laser}, "A_BOSS1LASER"},
|
||||
{{A_Boss4Reverse}, "A_BOSS4REVERSE"},
|
||||
{{A_Boss4SpeedUp}, "A_BOSS4SPEEDUP"},
|
||||
{{A_Boss4Raise}, "A_BOSS4RAISE"},
|
||||
{{A_SparkFollow}, "A_SPARKFOLLOW"},
|
||||
{{A_BuzzFly}, "A_BUZZFLY"},
|
||||
{{A_GuardChase}, "A_GUARDCHASE"},
|
||||
{{A_EggShield}, "A_EGGSHIELD"},
|
||||
{{A_SetReactionTime}, "A_SETREACTIONTIME"},
|
||||
{{A_Boss1Spikeballs}, "A_BOSS1SPIKEBALLS"},
|
||||
{{A_Boss3TakeDamage}, "A_BOSS3TAKEDAMAGE"},
|
||||
{{A_Boss3Path}, "A_BOSS3PATH"},
|
||||
{{A_LinedefExecute}, "A_LINEDEFEXECUTE"},
|
||||
{{A_PlaySeeSound}, "A_PLAYSEESOUND"},
|
||||
{{A_PlayAttackSound}, "A_PLAYATTACKSOUND"},
|
||||
{{A_PlayActiveSound}, "A_PLAYACTIVESOUND"},
|
||||
{{A_SpawnObjectAbsolute}, "A_SPAWNOBJECTABSOLUTE"},
|
||||
{{A_SpawnObjectRelative}, "A_SPAWNOBJECTRELATIVE"},
|
||||
{{A_ChangeAngleRelative}, "A_CHANGEANGLERELATIVE"},
|
||||
{{A_ChangeAngleAbsolute}, "A_CHANGEANGLEABSOLUTE"},
|
||||
{{A_PlaySound}, "A_PLAYSOUND"},
|
||||
{{A_FindTarget}, "A_FINDTARGET"},
|
||||
{{A_FindTracer}, "A_FINDTRACER"},
|
||||
{{A_SetTics}, "A_SETTICS"},
|
||||
{{A_SetRandomTics}, "A_SETRANDOMTICS"},
|
||||
{{A_ChangeColorRelative}, "A_CHANGECOLORRELATIVE"},
|
||||
{{A_ChangeColorAbsolute}, "A_CHANGECOLORABSOLUTE"},
|
||||
{{A_MoveRelative}, "A_MOVERELATIVE"},
|
||||
{{A_MoveAbsolute}, "A_MOVEABSOLUTE"},
|
||||
{{A_Thrust}, "A_THRUST"},
|
||||
{{A_ZThrust}, "A_ZTHRUST"},
|
||||
{{A_SetTargetsTarget}, "A_SETTARGETSTARGET"},
|
||||
{{A_SetObjectFlags}, "A_SETOBJECTFLAGS"},
|
||||
{{A_SetObjectFlags2}, "A_SETOBJECTFLAGS2"},
|
||||
{{A_RandomState}, "A_RANDOMSTATE"},
|
||||
{{A_RandomStateRange}, "A_RANDOMSTATERANGE"},
|
||||
{{A_DualAction}, "A_DUALACTION"},
|
||||
{{A_RemoteAction}, "A_REMOTEACTION"},
|
||||
{{A_ToggleFlameJet}, "A_TOGGLEFLAMEJET"},
|
||||
{{A_ItemPop}, "A_ITEMPOP"}, // SRB2kart
|
||||
{{A_JawzChase}, "A_JAWZCHASE"}, // SRB2kart
|
||||
{{A_JawzExplode}, "A_JAWZEXPLODE"}, // SRB2kart
|
||||
{{A_SPBChase}, "A_SPBCHASE"}, // SRB2kart
|
||||
{{A_MineExplode}, "A_MINEEXPLODE"}, // SRB2kart
|
||||
{{A_BallhogExplode}, "A_BALLHOGEXPLODE"}, // SRB2kart
|
||||
{{A_LightningFollowPlayer},"A_LIGHTNINGFOLLOWPLAYER"}, //SRB2kart
|
||||
{{A_FZBoomFlash}, "A_FZBOOMFLASH"}, //SRB2kart
|
||||
{{A_FZBoomSmoke}, "A_FZBOOMSMOKE"}, //SRB2kart
|
||||
{{A_RandomShadowFrame}, "A_RANDOMSHADOWFRAME"}, //SRB2kart
|
||||
{{A_RoamingShadowThinker}, "A_ROAMINGSHADOWTHINKER"}, //SRB2kart
|
||||
{{A_MayonakaArrow}, "A_MAYONAKAARROW"}, //SRB2kart
|
||||
{{A_ReaperThinker}, "A_REAPERTHINKER"}, //SRB2kart
|
||||
{{A_MementosTPParticles}, "A_MEMENTOSTPPARTICLES"}, //SRB2kart
|
||||
{{A_FlameParticle}, "A_FLAMEPARTICLE"}, // SRB2kart
|
||||
{{A_OrbitNights}, "A_ORBITNIGHTS"},
|
||||
{{A_GhostMe}, "A_GHOSTME"},
|
||||
{{A_SetObjectState}, "A_SETOBJECTSTATE"},
|
||||
{{A_SetObjectTypeState}, "A_SETOBJECTTYPESTATE"},
|
||||
{{A_KnockBack}, "A_KNOCKBACK"},
|
||||
{{A_PushAway}, "A_PUSHAWAY"},
|
||||
{{A_RingDrain}, "A_RINGDRAIN"},
|
||||
{{A_SplitShot}, "A_SPLITSHOT"},
|
||||
{{A_MissileSplit}, "A_MISSILESPLIT"},
|
||||
{{A_MultiShot}, "A_MULTISHOT"},
|
||||
{{A_InstaLoop}, "A_INSTALOOP"},
|
||||
{{A_Custom3DRotate}, "A_CUSTOM3DROTATE"},
|
||||
{{A_SearchForPlayers}, "A_SEARCHFORPLAYERS"},
|
||||
{{A_CheckRandom}, "A_CHECKRANDOM"},
|
||||
{{A_CheckTargetRings}, "A_CHECKTARGETRINGS"},
|
||||
{{A_CheckRings}, "A_CHECKRINGS"},
|
||||
{{A_CheckTotalRings}, "A_CHECKTOTALRINGS"},
|
||||
{{A_CheckHealth}, "A_CHECKHEALTH"},
|
||||
{{A_CheckRange}, "A_CHECKRANGE"},
|
||||
{{A_CheckHeight}, "A_CHECKHEIGHT"},
|
||||
{{A_CheckTrueRange}, "A_CHECKTRUERANGE"},
|
||||
{{A_CheckThingCount}, "A_CHECKTHINGCOUNT"},
|
||||
{{A_CheckAmbush}, "A_CHECKAMBUSH"},
|
||||
{{A_CheckCustomValue}, "A_CHECKCUSTOMVALUE"},
|
||||
{{A_CheckCusValMemo}, "A_CHECKCUSVALMEMO"},
|
||||
{{A_SetCustomValue}, "A_SETCUSTOMVALUE"},
|
||||
{{A_UseCusValMemo}, "A_USECUSVALMEMO"},
|
||||
{{A_RelayCustomValue}, "A_RELAYCUSTOMVALUE"},
|
||||
{{A_CusValAction}, "A_CUSVALACTION"},
|
||||
{{A_ForceStop}, "A_FORCESTOP"},
|
||||
{{A_ForceWin}, "A_FORCEWIN"},
|
||||
{{A_SpikeRetract}, "A_SPIKERETRACT"},
|
||||
{{A_InfoState}, "A_INFOSTATE"},
|
||||
{{A_Repeat}, "A_REPEAT"},
|
||||
{{A_SetScale}, "A_SETSCALE"},
|
||||
{{A_RemoteDamage}, "A_REMOTEDAMAGE"},
|
||||
{{A_HomingChase}, "A_HOMINGCHASE"},
|
||||
{{A_TrapShot}, "A_TRAPSHOT"},
|
||||
{{A_VileTarget}, "A_VILETARGET"},
|
||||
{{A_VileAttack}, "A_VILEATTACK"},
|
||||
{{A_VileFire}, "A_VILEFIRE"},
|
||||
{{A_BrakChase}, "A_BRAKCHASE"},
|
||||
{{A_BrakFireShot}, "A_BRAKFIRESHOT"},
|
||||
{{A_BrakLobShot}, "A_BRAKLOBSHOT"},
|
||||
{{A_NapalmScatter}, "A_NAPALMSCATTER"},
|
||||
{{A_SpawnFreshCopy}, "A_SPAWNFRESHCOPY"},
|
||||
{A_Explode, "A_EXPLODE"},
|
||||
{A_Pain, "A_PAIN"},
|
||||
{A_Fall, "A_FALL"},
|
||||
{A_MonitorPop, "A_MONITORPOP"},
|
||||
{A_Look, "A_LOOK"},
|
||||
{A_Chase, "A_CHASE"},
|
||||
{A_FaceStabChase, "A_FACESTABCHASE"},
|
||||
{A_FaceTarget, "A_FACETARGET"},
|
||||
{A_FaceTracer, "A_FACETRACER"},
|
||||
{A_Scream, "A_SCREAM"},
|
||||
{A_BossDeath, "A_BOSSDEATH"},
|
||||
{A_CustomPower, "A_CUSTOMPOWER"},
|
||||
{A_GiveWeapon, "A_GIVEWEAPON"},
|
||||
{A_RingShield, "A_RINGSHIELD"},
|
||||
{A_RingBox, "A_RINGBOX"},
|
||||
{A_Invincibility, "A_INVINCIBILITY"},
|
||||
{A_SuperSneakers, "A_SUPERSNEAKERS"},
|
||||
{A_BunnyHop, "A_BUNNYHOP"},
|
||||
{A_BubbleSpawn, "A_BUBBLESPAWN"},
|
||||
{A_FanBubbleSpawn, "A_FANBUBBLESPAWN"},
|
||||
{A_BubbleRise, "A_BUBBLERISE"},
|
||||
{A_BubbleCheck, "A_BUBBLECHECK"},
|
||||
{A_AwardScore, "A_AWARDSCORE"},
|
||||
{A_ExtraLife, "A_EXTRALIFE"},
|
||||
{A_BombShield, "A_BOMBSHIELD"},
|
||||
{A_JumpShield, "A_JUMPSHIELD"},
|
||||
{A_WaterShield, "A_WATERSHIELD"},
|
||||
{A_ForceShield, "A_FORCESHIELD"},
|
||||
{A_PityShield, "A_PITYSHIELD"},
|
||||
{A_GravityBox, "A_GRAVITYBOX"},
|
||||
{A_ScoreRise, "A_SCORERISE"},
|
||||
{A_ParticleSpawn, "A_PARTICLESPAWN"},
|
||||
{A_AttractChase, "A_ATTRACTCHASE"},
|
||||
{A_DropMine, "A_DROPMINE"},
|
||||
{A_FishJump, "A_FISHJUMP"},
|
||||
{A_ThrownRing, "A_THROWNRING"},
|
||||
{A_GrenadeRing, "A_GRENADERING"}, // SRB2kart
|
||||
{A_SetSolidSteam, "A_SETSOLIDSTEAM"},
|
||||
{A_UnsetSolidSteam, "A_UNSETSOLIDSTEAM"},
|
||||
{A_SignPlayer, "A_SIGNPLAYER"},
|
||||
{A_OverlayThink, "A_OVERLAYTHINK"},
|
||||
{A_JetChase, "A_JETCHASE"},
|
||||
{A_JetbThink, "A_JETBTHINK"},
|
||||
{A_JetgThink, "A_JETGTHINK"},
|
||||
{A_JetgShoot, "A_JETGSHOOT"},
|
||||
{A_ShootBullet, "A_SHOOTBULLET"},
|
||||
{A_MinusDigging, "A_MINUSDIGGING"},
|
||||
{A_MinusPopup, "A_MINUSPOPUP"},
|
||||
{A_MinusCheck, "A_MINUSCHECK"},
|
||||
{A_ChickenCheck, "A_CHICKENCHECK"},
|
||||
{A_MouseThink, "A_MOUSETHINK"},
|
||||
{A_DetonChase, "A_DETONCHASE"},
|
||||
{A_CapeChase, "A_CAPECHASE"},
|
||||
{A_RotateSpikeBall, "A_ROTATESPIKEBALL"},
|
||||
{A_SlingAppear, "A_SLINGAPPEAR"},
|
||||
{A_MaceRotate, "A_MACEROTATE"},
|
||||
{A_UnidusBall, "A_UNIDUSBALL"},
|
||||
{A_RockSpawn, "A_ROCKSPAWN"},
|
||||
{A_SetFuse, "A_SETFUSE"},
|
||||
{A_CrawlaCommanderThink, "A_CRAWLACOMMANDERTHINK"},
|
||||
{A_SmokeTrailer, "A_SMOKETRAILER"},
|
||||
{A_RingExplode, "A_RINGEXPLODE"},
|
||||
{A_OldRingExplode, "A_OLDRINGEXPLODE"},
|
||||
{A_MixUp, "A_MIXUP"},
|
||||
{A_RecyclePowers, "A_RECYCLEPOWERS"},
|
||||
{A_Boss1Chase, "A_BOSS1CHASE"},
|
||||
{A_FocusTarget, "A_FOCUSTARGET"},
|
||||
{A_Boss2Chase, "A_BOSS2CHASE"},
|
||||
{A_Boss2Pogo, "A_BOSS2POGO"},
|
||||
{A_BossZoom, "A_BOSSZOOM"},
|
||||
{A_BossScream, "A_BOSSSCREAM"},
|
||||
{A_Boss2TakeDamage, "A_BOSS2TAKEDAMAGE"},
|
||||
{A_Boss7Chase, "A_BOSS7CHASE"},
|
||||
{A_GoopSplat, "A_GOOPSPLAT"},
|
||||
{A_Boss2PogoSFX, "A_BOSS2POGOSFX"},
|
||||
{A_Boss2PogoTarget, "A_BOSS2POGOTARGET"},
|
||||
{A_BossJetFume, "A_BOSSJETFUME"},
|
||||
{A_EggmanBox, "A_EGGMANBOX"},
|
||||
{A_TurretFire, "A_TURRETFIRE"},
|
||||
{A_SuperTurretFire, "A_SUPERTURRETFIRE"},
|
||||
{A_TurretStop, "A_TURRETSTOP"},
|
||||
{A_JetJawRoam, "A_JETJAWROAM"},
|
||||
{A_JetJawChomp, "A_JETJAWCHOMP"},
|
||||
{A_PointyThink, "A_POINTYTHINK"},
|
||||
{A_CheckBuddy, "A_CHECKBUDDY"},
|
||||
{A_HoodThink, "A_HOODTHINK"},
|
||||
{A_ArrowCheck, "A_ARROWCHECK"},
|
||||
{A_SnailerThink, "A_SNAILERTHINK"},
|
||||
{A_SharpChase, "A_SHARPCHASE"},
|
||||
{A_SharpSpin, "A_SHARPSPIN"},
|
||||
{A_VultureVtol, "A_VULTUREVTOL"},
|
||||
{A_VultureCheck, "A_VULTURECHECK"},
|
||||
{A_SkimChase, "A_SKIMCHASE"},
|
||||
{A_1upThinker, "A_1UPTHINKER"},
|
||||
{A_SkullAttack, "A_SKULLATTACK"},
|
||||
{A_LobShot, "A_LOBSHOT"},
|
||||
{A_FireShot, "A_FIRESHOT"},
|
||||
{A_SuperFireShot, "A_SUPERFIRESHOT"},
|
||||
{A_BossFireShot, "A_BOSSFIRESHOT"},
|
||||
{A_Boss7FireMissiles, "A_BOSS7FIREMISSILES"},
|
||||
{A_Boss1Laser, "A_BOSS1LASER"},
|
||||
{A_Boss4Reverse, "A_BOSS4REVERSE"},
|
||||
{A_Boss4SpeedUp, "A_BOSS4SPEEDUP"},
|
||||
{A_Boss4Raise, "A_BOSS4RAISE"},
|
||||
{A_SparkFollow, "A_SPARKFOLLOW"},
|
||||
{A_BuzzFly, "A_BUZZFLY"},
|
||||
{A_GuardChase, "A_GUARDCHASE"},
|
||||
{A_EggShield, "A_EGGSHIELD"},
|
||||
{A_SetReactionTime, "A_SETREACTIONTIME"},
|
||||
{A_Boss1Spikeballs, "A_BOSS1SPIKEBALLS"},
|
||||
{A_Boss3TakeDamage, "A_BOSS3TAKEDAMAGE"},
|
||||
{A_Boss3Path, "A_BOSS3PATH"},
|
||||
{A_LinedefExecute, "A_LINEDEFEXECUTE"},
|
||||
{A_PlaySeeSound, "A_PLAYSEESOUND"},
|
||||
{A_PlayAttackSound, "A_PLAYATTACKSOUND"},
|
||||
{A_PlayActiveSound, "A_PLAYACTIVESOUND"},
|
||||
{A_SpawnObjectAbsolute, "A_SPAWNOBJECTABSOLUTE"},
|
||||
{A_SpawnObjectRelative, "A_SPAWNOBJECTRELATIVE"},
|
||||
{A_ChangeAngleRelative, "A_CHANGEANGLERELATIVE"},
|
||||
{A_ChangeAngleAbsolute, "A_CHANGEANGLEABSOLUTE"},
|
||||
{A_PlaySound, "A_PLAYSOUND"},
|
||||
{A_FindTarget, "A_FINDTARGET"},
|
||||
{A_FindTracer, "A_FINDTRACER"},
|
||||
{A_SetTics, "A_SETTICS"},
|
||||
{A_SetRandomTics, "A_SETRANDOMTICS"},
|
||||
{A_ChangeColorRelative, "A_CHANGECOLORRELATIVE"},
|
||||
{A_ChangeColorAbsolute, "A_CHANGECOLORABSOLUTE"},
|
||||
{A_MoveRelative, "A_MOVERELATIVE"},
|
||||
{A_MoveAbsolute, "A_MOVEABSOLUTE"},
|
||||
{A_Thrust, "A_THRUST"},
|
||||
{A_ZThrust, "A_ZTHRUST"},
|
||||
{A_SetTargetsTarget, "A_SETTARGETSTARGET"},
|
||||
{A_SetObjectFlags, "A_SETOBJECTFLAGS"},
|
||||
{A_SetObjectFlags2, "A_SETOBJECTFLAGS2"},
|
||||
{A_RandomState, "A_RANDOMSTATE"},
|
||||
{A_RandomStateRange, "A_RANDOMSTATERANGE"},
|
||||
{A_DualAction, "A_DUALACTION"},
|
||||
{A_RemoteAction, "A_REMOTEACTION"},
|
||||
{A_ToggleFlameJet, "A_TOGGLEFLAMEJET"},
|
||||
{A_ItemPop, "A_ITEMPOP"}, // SRB2kart
|
||||
{A_JawzChase, "A_JAWZCHASE"}, // SRB2kart
|
||||
{A_JawzExplode, "A_JAWZEXPLODE"}, // SRB2kart
|
||||
{A_SPBChase, "A_SPBCHASE"}, // SRB2kart
|
||||
{A_MineExplode, "A_MINEEXPLODE"}, // SRB2kart
|
||||
{A_BallhogExplode, "A_BALLHOGEXPLODE"}, // SRB2kart
|
||||
{A_LightningFollowPlayer,"A_LIGHTNINGFOLLOWPLAYER"}, //SRB2kart
|
||||
{A_FZBoomFlash, "A_FZBOOMFLASH"}, //SRB2kart
|
||||
{A_FZBoomSmoke, "A_FZBOOMSMOKE"}, //SRB2kart
|
||||
{A_RandomShadowFrame, "A_RANDOMSHADOWFRAME"}, //SRB2kart
|
||||
{A_RoamingShadowThinker, "A_ROAMINGSHADOWTHINKER"}, //SRB2kart
|
||||
{A_MayonakaArrow, "A_MAYONAKAARROW"}, //SRB2kart
|
||||
{A_ReaperThinker, "A_REAPERTHINKER"}, //SRB2kart
|
||||
{A_MementosTPParticles, "A_MEMENTOSTPPARTICLES"}, //SRB2kart
|
||||
{A_FlameParticle, "A_FLAMEPARTICLE"}, // SRB2kart
|
||||
{A_OrbitNights, "A_ORBITNIGHTS"},
|
||||
{A_GhostMe, "A_GHOSTME"},
|
||||
{A_SetObjectState, "A_SETOBJECTSTATE"},
|
||||
{A_SetObjectTypeState, "A_SETOBJECTTYPESTATE"},
|
||||
{A_KnockBack, "A_KNOCKBACK"},
|
||||
{A_PushAway, "A_PUSHAWAY"},
|
||||
{A_RingDrain, "A_RINGDRAIN"},
|
||||
{A_SplitShot, "A_SPLITSHOT"},
|
||||
{A_MissileSplit, "A_MISSILESPLIT"},
|
||||
{A_MultiShot, "A_MULTISHOT"},
|
||||
{A_InstaLoop, "A_INSTALOOP"},
|
||||
{A_Custom3DRotate, "A_CUSTOM3DROTATE"},
|
||||
{A_SearchForPlayers, "A_SEARCHFORPLAYERS"},
|
||||
{A_CheckRandom, "A_CHECKRANDOM"},
|
||||
{A_CheckTargetRings, "A_CHECKTARGETRINGS"},
|
||||
{A_CheckRings, "A_CHECKRINGS"},
|
||||
{A_CheckTotalRings, "A_CHECKTOTALRINGS"},
|
||||
{A_CheckHealth, "A_CHECKHEALTH"},
|
||||
{A_CheckRange, "A_CHECKRANGE"},
|
||||
{A_CheckHeight, "A_CHECKHEIGHT"},
|
||||
{A_CheckTrueRange, "A_CHECKTRUERANGE"},
|
||||
{A_CheckThingCount, "A_CHECKTHINGCOUNT"},
|
||||
{A_CheckAmbush, "A_CHECKAMBUSH"},
|
||||
{A_CheckCustomValue, "A_CHECKCUSTOMVALUE"},
|
||||
{A_CheckCusValMemo, "A_CHECKCUSVALMEMO"},
|
||||
{A_SetCustomValue, "A_SETCUSTOMVALUE"},
|
||||
{A_UseCusValMemo, "A_USECUSVALMEMO"},
|
||||
{A_RelayCustomValue, "A_RELAYCUSTOMVALUE"},
|
||||
{A_CusValAction, "A_CUSVALACTION"},
|
||||
{A_ForceStop, "A_FORCESTOP"},
|
||||
{A_ForceWin, "A_FORCEWIN"},
|
||||
{A_SpikeRetract, "A_SPIKERETRACT"},
|
||||
{A_InfoState, "A_INFOSTATE"},
|
||||
{A_Repeat, "A_REPEAT"},
|
||||
{A_SetScale, "A_SETSCALE"},
|
||||
{A_RemoteDamage, "A_REMOTEDAMAGE"},
|
||||
{A_HomingChase, "A_HOMINGCHASE"},
|
||||
{A_TrapShot, "A_TRAPSHOT"},
|
||||
{A_VileTarget, "A_VILETARGET"},
|
||||
{A_VileAttack, "A_VILEATTACK"},
|
||||
{A_VileFire, "A_VILEFIRE"},
|
||||
{A_BrakChase, "A_BRAKCHASE"},
|
||||
{A_BrakFireShot, "A_BRAKFIRESHOT"},
|
||||
{A_BrakLobShot, "A_BRAKLOBSHOT"},
|
||||
{A_NapalmScatter, "A_NAPALMSCATTER"},
|
||||
{A_SpawnFreshCopy, "A_SPAWNFRESHCOPY"},
|
||||
//{A_InvincSparkleRotate, "A_INVINCSPARKLEROTATE"},
|
||||
|
||||
{{NULL}, "NONE"},
|
||||
{NULL, "NONE"},
|
||||
|
||||
// This NULL entry must be the last in the list
|
||||
{{NULL}, NULL},
|
||||
{NULL, NULL},
|
||||
};
|
||||
|
||||
static void readframe(MYFILE *f, INT32 num)
|
||||
@@ -1702,7 +1703,7 @@ static void readframe(MYFILE *f, INT32 num)
|
||||
|
||||
for (z = 0; actionpointers[z].name; z++)
|
||||
{
|
||||
if (actionpointers[z].action.acv == states[num].action.acv)
|
||||
if (actionpointers[z].action == states[num].action)
|
||||
{
|
||||
break;
|
||||
}
|
||||
@@ -1711,17 +1712,17 @@ static void readframe(MYFILE *f, INT32 num)
|
||||
z = 0;
|
||||
found = LUA_SetLuaAction(&states[num], actiontocompare);
|
||||
if (!found)
|
||||
while (actionpointers[z].name)
|
||||
{
|
||||
if (fastcmp(actiontocompare, actionpointers[z].name))
|
||||
while (actionpointers[z].name)
|
||||
{
|
||||
states[num].action = actionpointers[z].action;
|
||||
states[num].action.acv = actionpointers[z].action.acv; // assign
|
||||
states[num].action.acp1 = actionpointers[z].action.acp1;
|
||||
found = true;
|
||||
break;
|
||||
if (fastcmp(actiontocompare, actionpointers[z].name))
|
||||
{
|
||||
states[num].action = actionpointers[z].action;
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
z++;
|
||||
}
|
||||
z++;
|
||||
}
|
||||
|
||||
if (!found)
|
||||
@@ -8524,13 +8525,13 @@ static inline int lib_freeslot(lua_State *L)
|
||||
// Arguments: mobj_t actor, int var1, int var2
|
||||
static inline int lib_action(lua_State *L)
|
||||
{
|
||||
actionf_t *action = lua_touserdata(L,lua_upvalueindex(1));
|
||||
actionf_p1 *action = lua_touserdata(L,lua_upvalueindex(1));
|
||||
mobj_t *actor = *((mobj_t **)luaL_checkudata(L,1,META_MOBJ));
|
||||
var1 = (INT32)luaL_optinteger(L,2,0);
|
||||
var2 = (INT32)luaL_optinteger(L,3,0);
|
||||
if (!actor)
|
||||
return LUA_ErrInvalid(L, "mobj_t");
|
||||
action->acp1(actor);
|
||||
(*action)(actor);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -9344,13 +9345,15 @@ int LUA_SOCLib(lua_State *L)
|
||||
|
||||
const char *LUA_GetActionName(void *action)
|
||||
{
|
||||
actionf_t *act = (actionf_t *)action;
|
||||
actionf_p1 *act = (actionf_p1 *)action;
|
||||
size_t z;
|
||||
|
||||
for (z = 0; actionpointers[z].name; z++)
|
||||
{
|
||||
if (actionpointers[z].action.acv == act->acv)
|
||||
if (actionpointers[z].action == *act)
|
||||
return actionpointers[z].name;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -9363,8 +9366,6 @@ void LUA_SetActionByName(void *state, const char *actiontocompare)
|
||||
if (fasticmp(actiontocompare, actionpointers[z].name))
|
||||
{
|
||||
st->action = actionpointers[z].action;
|
||||
st->action.acv = actionpointers[z].action.acv; // assign
|
||||
st->action.acp1 = actionpointers[z].action.acp1;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
+2
-2
@@ -111,8 +111,8 @@ extern char logfilename[1024];
|
||||
#else
|
||||
#define VERSION 1 // Game version
|
||||
#define SUBVERSION 6 // more precise version number
|
||||
#define VERSIONSTRING "Saturn v8.2"
|
||||
#define VERSIONSTRINGW L"Saturn v8.2"
|
||||
#define VERSIONSTRING "Saturn v8.3"
|
||||
#define VERSIONSTRINGW L"Saturn v8.3"
|
||||
// Hey! If you change this, add 1 to the MODVERSION below! Otherwise we can't force updates!
|
||||
// And change CMakeLists.txt (not src/, but in root), for CMake users!
|
||||
// AND appveyor.yml, for the build bots!
|
||||
|
||||
+3974
-33
File diff suppressed because it is too large.
Load diff
+9
-19
@@ -114,8 +114,7 @@ INT32 mousex, mousey;
|
||||
INT32 mlooky; // like mousey but with a custom sensitivity for mlook
|
||||
|
||||
// joystick values are repeated
|
||||
INT32 joyxmove[JOYAXISSET], joyymove[JOYAXISSET], joy2xmove[JOYAXISSET], joy2ymove[JOYAXISSET],
|
||||
joy3xmove[JOYAXISSET], joy3ymove[JOYAXISSET], joy4xmove[JOYAXISSET], joy4ymove[JOYAXISSET];
|
||||
INT32 joyxmove[MAXSPLITSCREENPLAYERS][JOYAXISSET], joyymove[MAXSPLITSCREENPLAYERS][JOYAXISSET];
|
||||
|
||||
// current state of the keys: true if pushed
|
||||
UINT8 gamekeydown[NUMINPUTS];
|
||||
@@ -187,32 +186,32 @@ void G_MapEventsToControls(event_t *ev)
|
||||
i = ev->data1;
|
||||
if (i >= JOYAXISSET || menuactive || CON_Ready() || chat_on)
|
||||
break;
|
||||
if (ev->data2 != INT32_MAX) joyxmove[i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joyymove[i] = ev->data3;
|
||||
if (ev->data2 != INT32_MAX) joyxmove[0][i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joyymove[0][i] = ev->data3;
|
||||
break;
|
||||
|
||||
case ev_joystick2: // buttons are virtual keys
|
||||
i = ev->data1;
|
||||
if (i >= JOYAXISSET || menuactive)
|
||||
break;
|
||||
if (ev->data2 != INT32_MAX) joy2xmove[i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joy2ymove[i] = ev->data3;
|
||||
if (ev->data2 != INT32_MAX) joyxmove[1][i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joyymove[1][i] = ev->data3;
|
||||
break;
|
||||
|
||||
case ev_joystick3:
|
||||
i = ev->data1;
|
||||
if (i >= JOYAXISSET)
|
||||
break;
|
||||
if (ev->data2 != INT32_MAX) joy3xmove[i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joy3ymove[i] = ev->data3;
|
||||
if (ev->data2 != INT32_MAX) joyxmove[2][i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joyymove[2][i] = ev->data3;
|
||||
break;
|
||||
|
||||
case ev_joystick4:
|
||||
i = ev->data1;
|
||||
if (i >= JOYAXISSET)
|
||||
break;
|
||||
if (ev->data2 != INT32_MAX) joy4xmove[i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joy4ymove[i] = ev->data3;
|
||||
if (ev->data2 != INT32_MAX) joyxmove[3][i] = ev->data2;
|
||||
if (ev->data3 != INT32_MAX) joyymove[3][i] = ev->data3;
|
||||
break;
|
||||
|
||||
default:
|
||||
@@ -258,15 +257,6 @@ void G_ResetControls(void)
|
||||
memset(joyxmove, 0, sizeof(joyxmove));
|
||||
memset(joyymove, 0, sizeof(joyymove));
|
||||
|
||||
memset(joy2xmove, 0, sizeof(joy2xmove));
|
||||
memset(joy2ymove, 0, sizeof(joy2ymove));
|
||||
|
||||
memset(joy3xmove, 0, sizeof(joy3xmove));
|
||||
memset(joy3ymove, 0, sizeof(joy3ymove));
|
||||
|
||||
memset(joy4xmove, 0, sizeof(joy4xmove));
|
||||
memset(joy4ymove, 0, sizeof(joy4ymove));
|
||||
|
||||
// reset those just in case the game missed the keyup event
|
||||
memset(dpadscrollstate, false, sizeof(dpadscrollstate));
|
||||
}
|
||||
|
||||
+8
-5
@@ -41,10 +41,12 @@ typedef enum
|
||||
KEY_DBLJOY1 = KEY_DBLMOUSE1 + MOUSEBUTTONS,
|
||||
KEY_DBLHAT1 = KEY_DBLJOY1 + JOYBUTTONS,
|
||||
|
||||
KEY_2JOY1 = KEY_DBLHAT1 + MOUSEBUTTONS,
|
||||
KEY_2MOUSE1 = KEY_DBLHAT1 + JOYHATS*4,
|
||||
KEY_2JOY1 = KEY_2MOUSE1 + MOUSEBUTTONS,
|
||||
KEY_2HAT1 = KEY_2JOY1 + JOYBUTTONS,
|
||||
|
||||
KEY_DBL2JOY1 = KEY_2HAT1 + MOUSEBUTTONS,
|
||||
KEY_DBL2MOUSE1 = KEY_2HAT1 + JOYHATS*4,
|
||||
KEY_DBL2JOY1 = KEY_DBL2MOUSE1 + MOUSEBUTTONS,
|
||||
KEY_DBL2HAT1 = KEY_DBL2JOY1 + JOYBUTTONS,
|
||||
|
||||
KEY_3JOY1 = KEY_DBL2HAT1 + JOYHATS*4,
|
||||
@@ -61,8 +63,10 @@ typedef enum
|
||||
|
||||
KEY_MOUSEWHEELUP = KEY_DBL4HAT1 + JOYHATS*4,
|
||||
KEY_MOUSEWHEELDOWN = KEY_MOUSEWHEELUP + 1,
|
||||
KEY_2MOUSEWHEELUP = KEY_MOUSEWHEELDOWN + 1,
|
||||
KEY_2MOUSEWHEELDOWN = KEY_2MOUSEWHEELUP + 1,
|
||||
|
||||
NUMINPUTS = KEY_MOUSEWHEELDOWN + 1,
|
||||
NUMINPUTS = KEY_2MOUSEWHEELDOWN + 1, // FIXME: all the mouse 2 stuff should be removed, but it screws up mappings somehow
|
||||
} key_input_e;
|
||||
|
||||
typedef enum
|
||||
@@ -113,8 +117,7 @@ extern consvar_t cv_gamepadled[MAXSPLITSCREENPLAYERS];
|
||||
extern INT32 mousex, mousey;
|
||||
extern INT32 mlooky; //mousey with mlookSensitivity
|
||||
|
||||
extern INT32 joyxmove[JOYAXISSET], joyymove[JOYAXISSET], joy2xmove[JOYAXISSET], joy2ymove[JOYAXISSET],
|
||||
joy3xmove[JOYAXISSET], joy3ymove[JOYAXISSET], joy4xmove[JOYAXISSET], joy4ymove[JOYAXISSET];
|
||||
extern INT32 joyxmove[MAXSPLITSCREENPLAYERS][JOYAXISSET], joyymove[MAXSPLITSCREENPLAYERS][JOYAXISSET];
|
||||
|
||||
// current state of the keys: true if pushed
|
||||
extern UINT8 gamekeydown[NUMINPUTS];
|
||||
|
||||
@@ -792,7 +792,7 @@ static void HWR_PrecacheLevelSprites(void)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo = (mobj_t *)th;
|
||||
|
||||
+6
-8
@@ -310,7 +310,7 @@ void HU_LoadGraphics(void)
|
||||
lt_font[0] = (patch_t *)W_CachePatchName("LTFNT039", PU_HUDGFX); /// \note fake start hack
|
||||
|
||||
// Number support
|
||||
lt_font[9] = (patch_t *)W_CachePatchName("LTFNT048", PU_HUDGFX);
|
||||
lt_font[9] = (patch_t *)W_CachePatchName("LTFNT048", PU_HUDGFX);
|
||||
lt_font[10] = (patch_t *)W_CachePatchName("LTFNT049", PU_HUDGFX);
|
||||
lt_font[11] = (patch_t *)W_CachePatchName("LTFNT050", PU_HUDGFX);
|
||||
lt_font[12] = (patch_t *)W_CachePatchName("LTFNT051", PU_HUDGFX);
|
||||
@@ -747,7 +747,7 @@ static void Command_CSay_f(void)
|
||||
return;
|
||||
}
|
||||
|
||||
if(!server && !IsPlayerAdmin(consoleplayer))
|
||||
if (!server && !IsPlayerAdmin(consoleplayer))
|
||||
{
|
||||
CONS_Alert(CONS_NOTICE, M_GetText("Only servers and admins can use csay.\n"));
|
||||
return;
|
||||
@@ -2881,13 +2881,11 @@ void HU_DoCEcho(const char *msg)
|
||||
*p = '\n';
|
||||
|
||||
CONS_Printf("%s\n", temp);
|
||||
|
||||
return;
|
||||
}
|
||||
else if (cv_cechotoggle.value)
|
||||
cechotimer = cechoduration;
|
||||
|
||||
I_OutputMsg("%s\n", msg); // print to log
|
||||
|
||||
if (!cv_cechotoggle.value)
|
||||
return;
|
||||
|
||||
cechotimer = cechoduration;
|
||||
I_OutputMsg("%s\n", msg); // ALWAYS print to log
|
||||
}
|
||||
@@ -145,6 +145,8 @@ boolean I_UseNativeKeyboard(void);
|
||||
|
||||
boolean I_CheckNativeRes(void);
|
||||
|
||||
void I_SetBorderlessWindow(void);
|
||||
|
||||
#ifdef USE_FBO_OGL
|
||||
|
||||
void RefreshOGLSDLSurface(void);
|
||||
|
||||
+2660
-2717
File diff suppressed because it is too large.
Load diff
+202
-205
@@ -26,7 +26,7 @@
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
actionf_t action; ///< Function pointer corresponding to the actual action.
|
||||
actionf_p1 action; ///< Function pointer corresponding to the actual action.
|
||||
const char *name; ///< Name of the action in ALL CAPS.
|
||||
} actionpointer_t;
|
||||
|
||||
@@ -246,209 +246,206 @@ struct mobj_s;
|
||||
|
||||
// IMPORTANT NOTE: If you add/remove from this list of action
|
||||
// functions, don't forget to update them in dehacked.c!
|
||||
void A_Explode(struct mobj_s *actor);
|
||||
void A_Pain(struct mobj_s *actor);
|
||||
void A_Fall(struct mobj_s *actor);
|
||||
void A_MonitorPop(struct mobj_s *actor);
|
||||
void A_Look(struct mobj_s *actor);
|
||||
void A_Chase(struct mobj_s *actor);
|
||||
void A_FaceStabChase(struct mobj_s *actor);
|
||||
void A_FaceTarget(struct mobj_s *actor);
|
||||
void A_FaceTracer(struct mobj_s *actor);
|
||||
void A_Scream(struct mobj_s *actor);
|
||||
void A_BossDeath(struct mobj_s *actor);
|
||||
void A_CustomPower(struct mobj_s *actor); // Use this for a custom power
|
||||
void A_GiveWeapon(struct mobj_s *actor); // Gives the player weapon(s)
|
||||
void A_JumpShield(struct mobj_s *actor); // Obtained Jump Shield
|
||||
void A_RingShield(struct mobj_s *actor); // Obtained Ring Shield
|
||||
void A_RingBox(struct mobj_s *actor); // Obtained Ring Box Tails
|
||||
void A_Invincibility(struct mobj_s *actor); // Obtained Invincibility Box
|
||||
void A_SuperSneakers(struct mobj_s *actor); // Obtained Super Sneakers Box
|
||||
void A_BunnyHop(struct mobj_s *actor); // have bunny hop tails
|
||||
void A_BubbleSpawn(struct mobj_s *actor); // Randomly spawn bubbles
|
||||
void A_FanBubbleSpawn(struct mobj_s *actor);
|
||||
void A_BubbleRise(struct mobj_s *actor); // Bubbles float to surface
|
||||
void A_BubbleCheck(struct mobj_s *actor); // Don't draw if not underwater
|
||||
void A_AwardScore(struct mobj_s *actor);
|
||||
void A_ExtraLife(struct mobj_s *actor); // Extra Life
|
||||
void A_BombShield(struct mobj_s *actor); // Obtained Bomb Shield
|
||||
void A_WaterShield(struct mobj_s *actor); // Obtained Water Shield
|
||||
void A_ForceShield(struct mobj_s *actor); // Obtained Force Shield
|
||||
void A_PityShield(struct mobj_s *actor); // Obtained Pity Shield. We're... sorry.
|
||||
void A_GravityBox(struct mobj_s *actor);
|
||||
void A_ScoreRise(struct mobj_s *actor); // Rise the score logo
|
||||
void A_ParticleSpawn(struct mobj_s *actor);
|
||||
void A_AttractChase(struct mobj_s *actor); // Ring Chase
|
||||
void A_DropMine(struct mobj_s *actor); // Drop Mine from Skim or Jetty-Syn Bomber
|
||||
void A_FishJump(struct mobj_s *actor); // Fish Jump
|
||||
void A_ThrownRing(struct mobj_s *actor); // Sparkle trail for red ring
|
||||
void A_GrenadeRing(struct mobj_s *actor); // SRB2kart
|
||||
void A_SetSolidSteam(struct mobj_s *actor);
|
||||
void A_UnsetSolidSteam(struct mobj_s *actor);
|
||||
void A_SignPlayer(struct mobj_s *actor);
|
||||
void A_OverlayThink(struct mobj_s *actor);
|
||||
void A_JetChase(struct mobj_s *actor);
|
||||
void A_JetbThink(struct mobj_s *actor); // Jetty-Syn Bomber Thinker
|
||||
void A_JetgThink(struct mobj_s *actor); // Jetty-Syn Gunner Thinker
|
||||
void A_JetgShoot(struct mobj_s *actor); // Jetty-Syn Shoot Function
|
||||
void A_ShootBullet(struct mobj_s *actor); // JetgShoot without reactiontime setting
|
||||
void A_MinusDigging(struct mobj_s *actor);
|
||||
void A_MinusPopup(struct mobj_s *actor);
|
||||
void A_MinusCheck(struct mobj_s *actor);
|
||||
void A_ChickenCheck(struct mobj_s *actor);
|
||||
void A_MouseThink(struct mobj_s *actor); // Mouse Thinker
|
||||
void A_DetonChase(struct mobj_s *actor); // Deton Chaser
|
||||
void A_CapeChase(struct mobj_s *actor); // Fake little Super Sonic cape
|
||||
void A_RotateSpikeBall(struct mobj_s *actor); // Spike ball rotation
|
||||
void A_SlingAppear(struct mobj_s *actor);
|
||||
void A_MaceRotate(struct mobj_s *actor);
|
||||
void A_UnidusBall(struct mobj_s *actor);
|
||||
void A_RockSpawn(struct mobj_s *actor);
|
||||
void A_SetFuse(struct mobj_s *actor);
|
||||
void A_CrawlaCommanderThink(struct mobj_s *actor); // Crawla Commander
|
||||
void A_SmokeTrailer(struct mobj_s *actor);
|
||||
void A_RingExplode(struct mobj_s *actor);
|
||||
void A_OldRingExplode(struct mobj_s *actor);
|
||||
void A_MixUp(struct mobj_s *actor);
|
||||
void A_RecyclePowers(struct mobj_s *actor);
|
||||
void A_BossScream(struct mobj_s *actor);
|
||||
void A_Boss2TakeDamage(struct mobj_s *actor);
|
||||
void A_GoopSplat(struct mobj_s *actor);
|
||||
void A_Boss2PogoSFX(struct mobj_s *actor);
|
||||
void A_Boss2PogoTarget(struct mobj_s *actor);
|
||||
void A_EggmanBox(struct mobj_s *actor);
|
||||
void A_TurretFire(struct mobj_s *actor);
|
||||
void A_SuperTurretFire(struct mobj_s *actor);
|
||||
void A_TurretStop(struct mobj_s *actor);
|
||||
void A_JetJawRoam(struct mobj_s *actor);
|
||||
void A_JetJawChomp(struct mobj_s *actor);
|
||||
void A_PointyThink(struct mobj_s *actor);
|
||||
void A_CheckBuddy(struct mobj_s *actor);
|
||||
void A_HoodThink(struct mobj_s *actor);
|
||||
void A_ArrowCheck(struct mobj_s *actor);
|
||||
void A_SnailerThink(struct mobj_s *actor);
|
||||
void A_SharpChase(struct mobj_s *actor);
|
||||
void A_SharpSpin(struct mobj_s *actor);
|
||||
void A_VultureVtol(struct mobj_s *actor);
|
||||
void A_VultureCheck(struct mobj_s *actor);
|
||||
void A_SkimChase(struct mobj_s *actor);
|
||||
void A_SkullAttack(struct mobj_s *actor);
|
||||
void A_LobShot(struct mobj_s *actor);
|
||||
void A_FireShot(struct mobj_s *actor);
|
||||
void A_SuperFireShot(struct mobj_s *actor);
|
||||
void A_BossFireShot(struct mobj_s *actor);
|
||||
void A_Boss7FireMissiles(struct mobj_s *actor);
|
||||
void A_Boss1Laser(struct mobj_s *actor);
|
||||
void A_FocusTarget(struct mobj_s *actor);
|
||||
void A_Boss4Reverse(struct mobj_s *actor);
|
||||
void A_Boss4SpeedUp(struct mobj_s *actor);
|
||||
void A_Boss4Raise(struct mobj_s *actor);
|
||||
void A_SparkFollow(struct mobj_s *actor);
|
||||
void A_BuzzFly(struct mobj_s *actor);
|
||||
void A_GuardChase(struct mobj_s *actor);
|
||||
void A_EggShield(struct mobj_s *actor);
|
||||
void A_SetReactionTime(struct mobj_s *actor);
|
||||
void A_Boss1Spikeballs(struct mobj_s *actor);
|
||||
void A_Boss3TakeDamage(struct mobj_s *actor);
|
||||
void A_Boss3Path(struct mobj_s *actor);
|
||||
void A_LinedefExecute(struct mobj_s *actor);
|
||||
void A_PlaySeeSound(struct mobj_s *actor);
|
||||
void A_PlayAttackSound(struct mobj_s *actor);
|
||||
void A_PlayActiveSound(struct mobj_s *actor);
|
||||
void A_1upThinker(struct mobj_s *actor);
|
||||
void A_BossZoom(struct mobj_s *actor); //Unused
|
||||
void A_Boss1Chase(struct mobj_s *actor);
|
||||
void A_Boss2Chase(struct mobj_s *actor);
|
||||
void A_Boss2Pogo(struct mobj_s *actor);
|
||||
void A_Boss7Chase(struct mobj_s *actor);
|
||||
void A_BossJetFume(struct mobj_s *actor);
|
||||
void A_SpawnObjectAbsolute(struct mobj_s *actor);
|
||||
void A_SpawnObjectRelative(struct mobj_s *actor);
|
||||
void A_ChangeAngleRelative(struct mobj_s *actor);
|
||||
void A_ChangeAngleAbsolute(struct mobj_s *actor);
|
||||
void A_RollAngle(struct mobj_s *actor);
|
||||
void A_ChangeRollAngleRelative(struct mobj_s *actor);
|
||||
void A_ChangeRollAngleAbsolute(struct mobj_s *actor);
|
||||
void A_PlaySound(struct mobj_s *actor);
|
||||
void A_FindTarget(struct mobj_s *actor);
|
||||
void A_FindTracer(struct mobj_s *actor);
|
||||
void A_SetTics(struct mobj_s *actor);
|
||||
void A_SetRandomTics(struct mobj_s *actor);
|
||||
void A_ChangeColorRelative(struct mobj_s *actor);
|
||||
void A_ChangeColorAbsolute(struct mobj_s *actor);
|
||||
void A_MoveRelative(struct mobj_s *actor);
|
||||
void A_MoveAbsolute(struct mobj_s *actor);
|
||||
void A_Thrust(struct mobj_s *actor);
|
||||
void A_ZThrust(struct mobj_s *actor);
|
||||
void A_SetTargetsTarget(struct mobj_s *actor);
|
||||
void A_SetObjectFlags(struct mobj_s *actor);
|
||||
void A_SetObjectFlags2(struct mobj_s *actor);
|
||||
void A_RandomState(struct mobj_s *actor);
|
||||
void A_RandomStateRange(struct mobj_s *actor);
|
||||
void A_DualAction(struct mobj_s *actor);
|
||||
void A_RemoteAction(struct mobj_s *actor);
|
||||
void A_ToggleFlameJet(struct mobj_s *actor);
|
||||
void A_ItemPop(struct mobj_s *actor); // SRB2kart
|
||||
void A_JawzChase(struct mobj_s *actor); // SRB2kart
|
||||
void A_JawzExplode(struct mobj_s *actor); // SRB2kart
|
||||
void A_SPBChase(struct mobj_s *actor); // SRB2kart
|
||||
void A_MineExplode(struct mobj_s *actor); // SRB2kart
|
||||
void A_BallhogExplode(struct mobj_s *actor); // SRB2kart
|
||||
void A_LightningFollowPlayer(struct mobj_s *actor); // SRB2kart: Lightning shield effect player chasing
|
||||
void A_FZBoomFlash(struct mobj_s *actor); // SRB2kart
|
||||
void A_FZBoomSmoke(struct mobj_s *actor); // SRB2kart
|
||||
void A_RandomShadowFrame(struct mobj_s *actor); //SRB2kart: Shadow spawner frame randomizer
|
||||
void A_RoamingShadowThinker(struct mobj_s *actor); // SRB2kart: Roaming Shadow moving + attacking players.
|
||||
void A_MayonakaArrow(struct mobj_s *actor); //SRB2kart: midnight channel arrow sign
|
||||
void A_ReaperThinker(struct mobj_s *actor); //SRB2kart: mementos reaper
|
||||
void A_MementosTPParticles(struct mobj_s *actor); //SRB2kart: mementos teleporter particles. Man that's a lot of actions for my shite.
|
||||
void A_FlameParticle(struct mobj_s *actor); // SRB2kart
|
||||
void A_OrbitNights(struct mobj_s *actor);
|
||||
void A_GhostMe(struct mobj_s *actor);
|
||||
void A_SetObjectState(struct mobj_s *actor);
|
||||
void A_SetObjectTypeState(struct mobj_s *actor);
|
||||
void A_KnockBack(struct mobj_s *actor);
|
||||
void A_PushAway(struct mobj_s *actor);
|
||||
void A_RingDrain(struct mobj_s *actor);
|
||||
void A_SplitShot(struct mobj_s *actor);
|
||||
void A_MissileSplit(struct mobj_s *actor);
|
||||
void A_MultiShot(struct mobj_s *actor);
|
||||
void A_InstaLoop(struct mobj_s *actor);
|
||||
void A_Custom3DRotate(struct mobj_s *actor);
|
||||
void A_SearchForPlayers(struct mobj_s *actor);
|
||||
void A_CheckRandom(struct mobj_s *actor);
|
||||
void A_CheckTargetRings(struct mobj_s *actor);
|
||||
void A_CheckRings(struct mobj_s *actor);
|
||||
void A_CheckTotalRings(struct mobj_s *actor);
|
||||
void A_CheckHealth(struct mobj_s *actor);
|
||||
void A_CheckRange(struct mobj_s *actor);
|
||||
void A_CheckHeight(struct mobj_s *actor);
|
||||
void A_CheckTrueRange(struct mobj_s *actor);
|
||||
void A_CheckThingCount(struct mobj_s *actor);
|
||||
void A_CheckAmbush(struct mobj_s *actor);
|
||||
void A_CheckCustomValue(struct mobj_s *actor);
|
||||
void A_CheckCusValMemo(struct mobj_s *actor);
|
||||
void A_SetCustomValue(struct mobj_s *actor);
|
||||
void A_UseCusValMemo(struct mobj_s *actor);
|
||||
void A_RelayCustomValue(struct mobj_s *actor);
|
||||
void A_CusValAction(struct mobj_s *actor);
|
||||
void A_ForceStop(struct mobj_s *actor);
|
||||
void A_ForceWin(struct mobj_s *actor);
|
||||
void A_SpikeRetract(struct mobj_s *actor);
|
||||
void A_InfoState(struct mobj_s *actor);
|
||||
void A_Repeat(struct mobj_s *actor);
|
||||
void A_SetScale(struct mobj_s *actor);
|
||||
void A_RemoteDamage(struct mobj_s *actor);
|
||||
void A_HomingChase(struct mobj_s *actor);
|
||||
void A_TrapShot(struct mobj_s *actor);
|
||||
void A_VileTarget(struct mobj_s *actor);
|
||||
void A_VileAttack(struct mobj_s *actor);
|
||||
void A_VileFire(struct mobj_s *actor);
|
||||
void A_BrakChase(struct mobj_s *actor);
|
||||
void A_BrakFireShot(struct mobj_s *actor);
|
||||
void A_BrakLobShot(struct mobj_s *actor);
|
||||
void A_NapalmScatter(struct mobj_s *actor);
|
||||
void A_SpawnFreshCopy(struct mobj_s *actor);
|
||||
void A_Explode(void *actor);
|
||||
void A_Pain(void *actor);
|
||||
void A_Fall(void *actor);
|
||||
void A_MonitorPop(void *actor);
|
||||
void A_Look(void *actor);
|
||||
void A_Chase(void *actor);
|
||||
void A_FaceStabChase(void *actor);
|
||||
void A_FaceTarget(void *actor);
|
||||
void A_FaceTracer(void *actor);
|
||||
void A_Scream(void *actor);
|
||||
void A_BossDeath(void *actor);
|
||||
void A_CustomPower(void *actor); // Use this for a custom power
|
||||
void A_GiveWeapon(void *actor); // Gives the player weapon(s)
|
||||
void A_JumpShield(void *actor); // Obtained Jump Shield
|
||||
void A_RingShield(void *actor); // Obtained Ring Shield
|
||||
void A_RingBox(void *actor); // Obtained Ring Box Tails
|
||||
void A_Invincibility(void *actor); // Obtained Invincibility Box
|
||||
void A_SuperSneakers(void *actor); // Obtained Super Sneakers Box
|
||||
void A_BunnyHop(void *actor); // have bunny hop tails
|
||||
void A_BubbleSpawn(void *actor); // Randomly spawn bubbles
|
||||
void A_FanBubbleSpawn(void *actor);
|
||||
void A_BubbleRise(void *actor); // Bubbles float to surface
|
||||
void A_BubbleCheck(void *actor); // Don't draw if not underwater
|
||||
void A_AwardScore(void *actor);
|
||||
void A_ExtraLife(void *actor); // Extra Life
|
||||
void A_BombShield(void *actor); // Obtained Bomb Shield
|
||||
void A_WaterShield(void *actor); // Obtained Water Shield
|
||||
void A_ForceShield(void *actor); // Obtained Force Shield
|
||||
void A_PityShield(void *actor); // Obtained Pity Shield. We're... sorry.
|
||||
void A_GravityBox(void *actor);
|
||||
void A_ScoreRise(void *actor); // Rise the score logo
|
||||
void A_ParticleSpawn(void *actor);
|
||||
void A_AttractChase(void *actor); // Ring Chase
|
||||
void A_DropMine(void *actor); // Drop Mine from Skim or Jetty-Syn Bomber
|
||||
void A_FishJump(void *actor); // Fish Jump
|
||||
void A_ThrownRing(void *actor); // Sparkle trail for red ring
|
||||
void A_GrenadeRing(void *actor); // SRB2kart
|
||||
void A_SetSolidSteam(void *actor);
|
||||
void A_UnsetSolidSteam(void *actor);
|
||||
void A_SignPlayer(void *actor);
|
||||
void A_OverlayThink(void *actor);
|
||||
void A_JetChase(void *actor);
|
||||
void A_JetbThink(void *actor); // Jetty-Syn Bomber Thinker
|
||||
void A_JetgThink(void *actor); // Jetty-Syn Gunner Thinker
|
||||
void A_JetgShoot(void *actor); // Jetty-Syn Shoot Function
|
||||
void A_ShootBullet(void *actor); // JetgShoot without reactiontime setting
|
||||
void A_MinusDigging(void *actor);
|
||||
void A_MinusPopup(void *actor);
|
||||
void A_MinusCheck(void *actor);
|
||||
void A_ChickenCheck(void *actor);
|
||||
void A_MouseThink(void *actor); // Mouse Thinker
|
||||
void A_DetonChase(void *actor); // Deton Chaser
|
||||
void A_CapeChase(void *actor); // Fake little Super Sonic cape
|
||||
void A_RotateSpikeBall(void *actor); // Spike ball rotation
|
||||
void A_SlingAppear(void *actor);
|
||||
void A_MaceRotate(void *actor);
|
||||
void A_UnidusBall(void *actor);
|
||||
void A_RockSpawn(void *actor);
|
||||
void A_SetFuse(void *actor);
|
||||
void A_CrawlaCommanderThink(void *actor); // Crawla Commander
|
||||
void A_SmokeTrailer(void *actor);
|
||||
void A_RingExplode(void *actor);
|
||||
void A_OldRingExplode(void *actor);
|
||||
void A_MixUp(void *actor);
|
||||
void A_RecyclePowers(void *actor);
|
||||
void A_BossScream(void *actor);
|
||||
void A_Boss2TakeDamage(void *actor);
|
||||
void A_GoopSplat(void *actor);
|
||||
void A_Boss2PogoSFX(void *actor);
|
||||
void A_Boss2PogoTarget(void *actor);
|
||||
void A_EggmanBox(void *actor);
|
||||
void A_TurretFire(void *actor);
|
||||
void A_SuperTurretFire(void *actor);
|
||||
void A_TurretStop(void *actor);
|
||||
void A_JetJawRoam(void *actor);
|
||||
void A_JetJawChomp(void *actor);
|
||||
void A_PointyThink(void *actor);
|
||||
void A_CheckBuddy(void *actor);
|
||||
void A_HoodThink(void *actor);
|
||||
void A_ArrowCheck(void *actor);
|
||||
void A_SnailerThink(void *actor);
|
||||
void A_SharpChase(void *actor);
|
||||
void A_SharpSpin(void *actor);
|
||||
void A_VultureVtol(void *actor);
|
||||
void A_VultureCheck(void *actor);
|
||||
void A_SkimChase(void *actor);
|
||||
void A_SkullAttack(void *actor);
|
||||
void A_LobShot(void *actor);
|
||||
void A_FireShot(void *actor);
|
||||
void A_SuperFireShot(void *actor);
|
||||
void A_BossFireShot(void *actor);
|
||||
void A_Boss7FireMissiles(void *actor);
|
||||
void A_Boss1Laser(void *actor);
|
||||
void A_FocusTarget(void *actor);
|
||||
void A_Boss4Reverse(void *actor);
|
||||
void A_Boss4SpeedUp(void *actor);
|
||||
void A_Boss4Raise(void *actor);
|
||||
void A_SparkFollow(void *actor);
|
||||
void A_BuzzFly(void *actor);
|
||||
void A_GuardChase(void *actor);
|
||||
void A_EggShield(void *actor);
|
||||
void A_SetReactionTime(void *actor);
|
||||
void A_Boss1Spikeballs(void *actor);
|
||||
void A_Boss3TakeDamage(void *actor);
|
||||
void A_Boss3Path(void *actor);
|
||||
void A_LinedefExecute(void *actor);
|
||||
void A_PlaySeeSound(void *actor);
|
||||
void A_PlayAttackSound(void *actor);
|
||||
void A_PlayActiveSound(void *actor);
|
||||
void A_1upThinker(void *actor);
|
||||
void A_BossZoom(void *actor); //Unused
|
||||
void A_Boss1Chase(void *actor);
|
||||
void A_Boss2Chase(void *actor);
|
||||
void A_Boss2Pogo(void *actor);
|
||||
void A_Boss7Chase(void *actor);
|
||||
void A_BossJetFume(void *actor);
|
||||
void A_SpawnObjectAbsolute(void *actor);
|
||||
void A_SpawnObjectRelative(void *actor);
|
||||
void A_ChangeAngleRelative(void *actor);
|
||||
void A_ChangeAngleAbsolute(void *actor);
|
||||
void A_PlaySound(void *actor);
|
||||
void A_FindTarget(void *actor);
|
||||
void A_FindTracer(void *actor);
|
||||
void A_SetTics(void *actor);
|
||||
void A_SetRandomTics(void *actor);
|
||||
void A_ChangeColorRelative(void *actor);
|
||||
void A_ChangeColorAbsolute(void *actor);
|
||||
void A_MoveRelative(void *actor);
|
||||
void A_MoveAbsolute(void *actor);
|
||||
void A_Thrust(void *actor);
|
||||
void A_ZThrust(void *actor);
|
||||
void A_SetTargetsTarget(void *actor);
|
||||
void A_SetObjectFlags(void *actor);
|
||||
void A_SetObjectFlags2(void *actor);
|
||||
void A_RandomState(void *actor);
|
||||
void A_RandomStateRange(void *actor);
|
||||
void A_DualAction(void *actor);
|
||||
void A_RemoteAction(void *actor);
|
||||
void A_ToggleFlameJet(void *actor);
|
||||
void A_ItemPop(void *actor); // SRB2kart
|
||||
void A_JawzChase(void *actor); // SRB2kart
|
||||
void A_JawzExplode(void *actor); // SRB2kart
|
||||
void A_SPBChase(void *actor); // SRB2kart
|
||||
void A_MineExplode(void *actor); // SRB2kart
|
||||
void A_BallhogExplode(void *actor); // SRB2kart
|
||||
void A_LightningFollowPlayer(void *actor); // SRB2kart: Lightning shield effect player chasing
|
||||
void A_FZBoomFlash(void *actor); // SRB2kart
|
||||
void A_FZBoomSmoke(void *actor); // SRB2kart
|
||||
void A_RandomShadowFrame(void *actor); //SRB2kart: Shadow spawner frame randomizer
|
||||
void A_RoamingShadowThinker(void *actor); // SRB2kart: Roaming Shadow moving + attacking players.
|
||||
void A_MayonakaArrow(void *actor); //SRB2kart: midnight channel arrow sign
|
||||
void A_ReaperThinker(void *actor); //SRB2kart: mementos reaper
|
||||
void A_MementosTPParticles(void *actor); //SRB2kart: mementos teleporter particles. Man that's a lot of actions for my shite.
|
||||
void A_FlameParticle(void *actor); // SRB2kart
|
||||
void A_OrbitNights(void *actor);
|
||||
void A_GhostMe(void *actor);
|
||||
void A_SetObjectState(void *actor);
|
||||
void A_SetObjectTypeState(void *actor);
|
||||
void A_KnockBack(void *actor);
|
||||
void A_PushAway(void *actor);
|
||||
void A_RingDrain(void *actor);
|
||||
void A_SplitShot(void *actor);
|
||||
void A_MissileSplit(void *actor);
|
||||
void A_MultiShot(void *actor);
|
||||
void A_InstaLoop(void *actor);
|
||||
void A_Custom3DRotate(void *actor);
|
||||
void A_SearchForPlayers(void *actor);
|
||||
void A_CheckRandom(void *actor);
|
||||
void A_CheckTargetRings(void *actor);
|
||||
void A_CheckRings(void *actor);
|
||||
void A_CheckTotalRings(void *actor);
|
||||
void A_CheckHealth(void *actor);
|
||||
void A_CheckRange(void *actor);
|
||||
void A_CheckHeight(void *actor);
|
||||
void A_CheckTrueRange(void *actor);
|
||||
void A_CheckThingCount(void *actor);
|
||||
void A_CheckAmbush(void *actor);
|
||||
void A_CheckCustomValue(void *actor);
|
||||
void A_CheckCusValMemo(void *actor);
|
||||
void A_SetCustomValue(void *actor);
|
||||
void A_UseCusValMemo(void *actor);
|
||||
void A_RelayCustomValue(void *actor);
|
||||
void A_CusValAction(void *actor);
|
||||
void A_ForceStop(void *actor);
|
||||
void A_ForceWin(void *actor);
|
||||
void A_SpikeRetract(void *actor);
|
||||
void A_InfoState(void *actor);
|
||||
void A_Repeat(void *actor);
|
||||
void A_SetScale(void *actor);
|
||||
void A_RemoteDamage(void *actor);
|
||||
void A_HomingChase(void *actor);
|
||||
void A_TrapShot(void *actor);
|
||||
void A_VileTarget(void *actor);
|
||||
void A_VileAttack(void *actor);
|
||||
void A_VileFire(void *actor);
|
||||
void A_BrakChase(void *actor);
|
||||
void A_BrakFireShot(void *actor);
|
||||
void A_BrakLobShot(void *actor);
|
||||
void A_NapalmScatter(void *actor);
|
||||
void A_SpawnFreshCopy(void *actor);
|
||||
|
||||
extern boolean actionsoverridden[NUMACTIONS];
|
||||
|
||||
@@ -4312,7 +4309,7 @@ typedef struct
|
||||
spritenum_t sprite;
|
||||
UINT32 frame; // we use the upper 16 bits for translucency and other shade effects
|
||||
INT32 tics;
|
||||
actionf_t action;
|
||||
actionf_p1 action;
|
||||
INT32 var1;
|
||||
INT32 var2;
|
||||
statenum_t nextstate;
|
||||
|
||||
+28
-25
@@ -522,6 +522,7 @@ void K_RainbowColormap(UINT8 *dest_colormap, UINT8 skincolor)
|
||||
dest_colormap[i] = (UINT8)i;
|
||||
continue;
|
||||
}
|
||||
|
||||
color = V_GetColor(i);
|
||||
SETBRIGHTNESS(brightness, color.s.red, color.s.green, color.s.blue);
|
||||
brightdif = 256;
|
||||
@@ -2440,7 +2441,7 @@ void K_SpinPlayer(player_t *player, mobj_t *source, INT32 type, mobj_t *inflicto
|
||||
|
||||
static void K_RemoveGrowShrink(player_t *player)
|
||||
{
|
||||
if (player->mo && !P_MobjWasRemoved(player->mo))
|
||||
if (!P_MobjWasRemoved(player->mo))
|
||||
{
|
||||
if (player->kartstuff[k_growshrinktimer] > 0) // Play Shrink noise
|
||||
S_StartSound(player->mo, sfx_kc59);
|
||||
@@ -2853,7 +2854,7 @@ void K_SpawnKartExplosion(fixed_t x, fixed_t y, fixed_t z, fixed_t radius, INT32
|
||||
mobj->momy = FixedMul(FixedDiv(mobjy - y, dist), FixedDiv(dist, 6*FRACUNIT));
|
||||
mobj->momz = FixedMul(FixedDiv(mobjz - z, dist), FixedDiv(dist, 6*FRACUNIT));
|
||||
|
||||
if (source && !P_MobjWasRemoved(source))
|
||||
if (!P_MobjWasRemoved(source))
|
||||
P_SetTarget(&mobj->target, source);
|
||||
}
|
||||
}
|
||||
@@ -3081,14 +3082,12 @@ static void K_SpawnDriftSparks(player_t *player)
|
||||
if (leveltime % 2 == 1)
|
||||
return;
|
||||
|
||||
if (cv_airsparks.value)
|
||||
goto skipground;
|
||||
const boolean onground = P_IsObjectOnGround(player->mo);
|
||||
|
||||
if (!P_IsObjectOnGround(player->mo))
|
||||
// kinda sketchy
|
||||
if (!cv_airsparks.value && !onground)
|
||||
return;
|
||||
|
||||
skipground: // idk im sleepy
|
||||
|
||||
if (!player->kartstuff[k_drift] || player->kartstuff[k_driftcharge] < K_GetKartDriftSparkValue(player))
|
||||
return;
|
||||
|
||||
@@ -3105,6 +3104,8 @@ skipground: // idk im sleepy
|
||||
newy = player->mo->y + P_ReturnThrustY(player->mo, thrustangle, smolscale);
|
||||
spark = P_SpawnMobj(newx, newy, player->mo->z, MT_DRIFTSPARK);
|
||||
|
||||
spark->islocal = cv_airsparks.value && !onground;
|
||||
|
||||
P_SetTarget(&spark->target, player->mo);
|
||||
spark->angle = travelangle-(ANGLE_45/5)*player->kartstuff[k_drift];
|
||||
|
||||
@@ -3666,7 +3667,7 @@ static mobj_t *K_FindLastTrailMobj(player_t *player)
|
||||
if (!player || !(trail = player->mo) || !player->mo->hnext || !player->mo->hnext->health)
|
||||
return NULL;
|
||||
|
||||
while (trail->hnext && !P_MobjWasRemoved(trail->hnext) && trail->hnext->health)
|
||||
while (!P_MobjWasRemoved(trail->hnext) && trail->hnext->health)
|
||||
{
|
||||
trail = trail->hnext;
|
||||
}
|
||||
@@ -3903,7 +3904,7 @@ void K_PuntMine(mobj_t *thismine, mobj_t *punter)
|
||||
fixed_t spd;
|
||||
mobj_t *mine;
|
||||
|
||||
if (!thismine || P_MobjWasRemoved(thismine))
|
||||
if (P_MobjWasRemoved(thismine))
|
||||
return;
|
||||
|
||||
//This guarantees you hit a mine being dragged
|
||||
@@ -3932,7 +3933,7 @@ void K_PuntMine(mobj_t *thismine, mobj_t *punter)
|
||||
else
|
||||
mine = thismine;
|
||||
|
||||
if (!mine || P_MobjWasRemoved(mine))
|
||||
if (P_MobjWasRemoved(mine))
|
||||
return;
|
||||
|
||||
spd = K_GetProjectileSpeed();
|
||||
@@ -4099,7 +4100,8 @@ void K_DoSneaker(player_t *player, INT32 type)
|
||||
if (player->mo->hnext)
|
||||
{
|
||||
mobj_t *cur = player->mo->hnext;
|
||||
while (cur && !P_MobjWasRemoved(cur))
|
||||
|
||||
while (!P_MobjWasRemoved(cur))
|
||||
{
|
||||
if (!cur->tracer)
|
||||
{
|
||||
@@ -4163,7 +4165,7 @@ static void K_DoShrink(player_t *user)
|
||||
K_DropItems(&players[i]);
|
||||
players[i].kartstuff[k_growshrinktimer] = -(20*TICRATE);
|
||||
|
||||
if (players[i].mo && !P_MobjWasRemoved(players[i].mo))
|
||||
if (!P_MobjWasRemoved(players[i].mo))
|
||||
{
|
||||
players[i].mo->scalespeed = mapobjectscale/TICRATE;
|
||||
players[i].mo->destscale = (6*mapobjectscale)/8;
|
||||
@@ -4293,7 +4295,7 @@ void K_DropHnextList(player_t *player)
|
||||
mobjtype_t type;
|
||||
boolean orbit, ponground, dropall = true;
|
||||
|
||||
if (!work || P_MobjWasRemoved(work))
|
||||
if (P_MobjWasRemoved(work))
|
||||
return;
|
||||
|
||||
flip = P_MobjFlip(player->mo);
|
||||
@@ -4432,7 +4434,7 @@ void K_DropItems(player_t *player)
|
||||
|
||||
K_DropHnextList(player);
|
||||
|
||||
if (player->mo && !P_MobjWasRemoved(player->mo) && player->kartstuff[k_itemamount])
|
||||
if (!P_MobjWasRemoved(player->mo) && player->kartstuff[k_itemamount])
|
||||
{
|
||||
mobj_t *drop = P_SpawnMobj(player->mo->x, player->mo->y, player->mo->z + player->mo->height/2, MT_FLOATINGITEM);
|
||||
P_SetScale(drop, drop->scale>>4);
|
||||
@@ -4461,7 +4463,7 @@ void K_DropRocketSneaker(player_t *player)
|
||||
fixed_t flingangle;
|
||||
boolean leftshoe = true; //left shoe is first
|
||||
|
||||
if (!(player->mo && !P_MobjWasRemoved(player->mo) && player->mo->hnext && !P_MobjWasRemoved(player->mo->hnext)))
|
||||
if (!(!P_MobjWasRemoved(player->mo) && player->mo->hnext && !P_MobjWasRemoved(player->mo->hnext)))
|
||||
return;
|
||||
|
||||
while ((shoe = shoe->hnext) && !P_MobjWasRemoved(shoe))
|
||||
@@ -4500,7 +4502,7 @@ void K_DropRocketSneaker(player_t *player)
|
||||
|
||||
void K_DropKitchenSink(player_t *player)
|
||||
{
|
||||
if (!(player->mo && !P_MobjWasRemoved(player->mo) && player->mo->hnext && !P_MobjWasRemoved(player->mo->hnext)))
|
||||
if (!(!P_MobjWasRemoved(player->mo) && player->mo->hnext && !P_MobjWasRemoved(player->mo->hnext)))
|
||||
return;
|
||||
|
||||
if (player->mo->hnext->type != MT_SINK_SHIELD)
|
||||
@@ -4517,13 +4519,13 @@ void K_RepairOrbitChain(mobj_t *orbit)
|
||||
mobj_t *cachenext = orbit->hnext;
|
||||
|
||||
// First, repair the chain
|
||||
if (orbit->hnext && orbit->hnext->health && !P_MobjWasRemoved(orbit->hnext))
|
||||
if (!P_MobjWasRemoved(orbit->hnext) && orbit->hnext->health)
|
||||
{
|
||||
P_SetTarget(&orbit->hnext->hprev, orbit->hprev);
|
||||
P_SetTarget(&orbit->hnext, NULL);
|
||||
}
|
||||
|
||||
if (orbit->hprev && orbit->hprev->health && !P_MobjWasRemoved(orbit->hprev))
|
||||
if (!P_MobjWasRemoved(orbit->hprev) && orbit->hprev->health)
|
||||
{
|
||||
P_SetTarget(&orbit->hprev->hnext, cachenext);
|
||||
P_SetTarget(&orbit->hprev, NULL);
|
||||
@@ -4538,7 +4540,7 @@ void K_RepairOrbitChain(mobj_t *orbit)
|
||||
mobj_t *cur = orbit->target->hnext;
|
||||
mobj_t *prev = NULL;
|
||||
|
||||
while (cur && !P_MobjWasRemoved(cur))
|
||||
while (!P_MobjWasRemoved(cur))
|
||||
{
|
||||
prev = cur;
|
||||
cur = cur->hnext;
|
||||
@@ -4738,7 +4740,7 @@ static void K_MoveHeldObjects(player_t *player)
|
||||
|
||||
player->kartstuff[k_bananadrag] = 0; // Just to make sure
|
||||
|
||||
while (cur && !P_MobjWasRemoved(cur))
|
||||
while (!P_MobjWasRemoved(cur))
|
||||
{
|
||||
const fixed_t radius = FixedHypot(player->mo->radius, player->mo->radius) + FixedHypot(cur->radius, cur->radius); // mobj's distance from its Target, or Radius.
|
||||
fixed_t z;
|
||||
@@ -4816,7 +4818,7 @@ static void K_MoveHeldObjects(player_t *player)
|
||||
if (P_IsObjectOnGround(player->mo) && player->speed > 0)
|
||||
player->kartstuff[k_bananadrag]++;
|
||||
|
||||
while (cur && !P_MobjWasRemoved(cur))
|
||||
while (!P_MobjWasRemoved(cur))
|
||||
{
|
||||
const fixed_t radius = FixedHypot(targ->radius, targ->radius) + FixedHypot(cur->radius, cur->radius);
|
||||
angle_t ang;
|
||||
@@ -4844,7 +4846,7 @@ static void K_MoveHeldObjects(player_t *player)
|
||||
else
|
||||
dist = cur->extravalue1/2;
|
||||
|
||||
if (!targ || P_MobjWasRemoved(targ))
|
||||
if (P_MobjWasRemoved(targ))
|
||||
continue;
|
||||
|
||||
// Shrink your items if the player shrunk too.
|
||||
@@ -4902,7 +4904,7 @@ static void K_MoveHeldObjects(player_t *player)
|
||||
mobj_t *cur = player->mo->hnext;
|
||||
INT32 num = 0;
|
||||
|
||||
while (cur && !P_MobjWasRemoved(cur))
|
||||
while (!P_MobjWasRemoved(cur))
|
||||
{
|
||||
const fixed_t radius = FixedHypot(player->mo->radius, player->mo->radius) + FixedHypot(cur->radius, cur->radius);
|
||||
boolean vibrate = ((leveltime & 1) && !cur->tracer);
|
||||
@@ -4967,7 +4969,7 @@ static void K_MoveHeldObjects(player_t *player)
|
||||
|
||||
}
|
||||
|
||||
if (cur->tracer && !P_MobjWasRemoved(cur->tracer))
|
||||
if (!P_MobjWasRemoved(cur->tracer))
|
||||
{
|
||||
fixed_t diffx, diffy, diffz;
|
||||
|
||||
@@ -5361,6 +5363,7 @@ FUNCINLINE static ATTRINLINE void K_SpawnNormalSpeedLines(player_t *player, bool
|
||||
fast->momx = 3*player->mo->momx/4;
|
||||
fast->momy = 3*player->mo->momy/4;
|
||||
fast->momz = 3*player->mo->momz/4;
|
||||
fast->islocal = !synched;
|
||||
P_SetTarget(&fast->target, player->mo); // easier lua access
|
||||
|
||||
K_MatchGenericExtraFlags(fast, player->mo);
|
||||
@@ -5707,7 +5710,7 @@ void K_KartPlayerAfterThink(player_t *player)
|
||||
else
|
||||
targ = K_FindJawzTarget(player->mo, player);
|
||||
|
||||
if (!targ || !targ->mo || P_MobjWasRemoved(targ->mo))
|
||||
if (!targ || P_MobjWasRemoved(targ->mo))
|
||||
{
|
||||
player->kartstuff[k_lastjawztarget] = -1;
|
||||
player->kartstuff[k_jawztargetdelay] = 0;
|
||||
|
||||
+7
-7
@@ -181,7 +181,7 @@ static int lib_setState(lua_State *L)
|
||||
switch(lua_type(L, 3))
|
||||
{
|
||||
case LUA_TNIL: // Null? Set the action to nothing, then.
|
||||
state->action.acp1 = NULL;
|
||||
state->action = NULL;
|
||||
break;
|
||||
case LUA_TSTRING: // It's a string, expect the name of a built-in action
|
||||
LUA_SetActionByName(state, lua_tostring(L, 3));
|
||||
@@ -193,7 +193,7 @@ static int lib_setState(lua_State *L)
|
||||
lua_pushvalue(L, 3); // Bring it to the top of the stack
|
||||
lua_rawset(L, -3); // Set it in the registry
|
||||
lua_pop(L, 1); // pop LREG_STATEACTION
|
||||
state->action.acp1 = (actionf_p1)A_Lua; // Set the action for the userdata.
|
||||
state->action = (actionf_p1)A_Lua; // Set the action for the userdata.
|
||||
break;
|
||||
default: // ?!
|
||||
return luaL_typerror(L, 3, "function");
|
||||
@@ -251,7 +251,7 @@ boolean LUA_SetLuaAction(void *stv, const char *action)
|
||||
lua_pop(gL, 1); // pop LREG_STATEACTION
|
||||
|
||||
lua_pop(gL, 2); // pop the function and LREG_ACTIONS
|
||||
st->action.acp1 = (actionf_p1)A_Lua; // Set the action for the userdata.
|
||||
st->action = (actionf_p1)A_Lua; // Set the action for the userdata.
|
||||
return true; // action successfully set.
|
||||
}
|
||||
|
||||
@@ -350,9 +350,9 @@ static int state_get(lua_State *L)
|
||||
case state_action:
|
||||
{
|
||||
const char *name;
|
||||
if (!st->action.acp1) // Action is NULL.
|
||||
if (!st->action) // Action is NULL.
|
||||
return 0; // return nil.
|
||||
if (st->action.acp1 == (actionf_p1)A_Lua) { // This is a Lua function?
|
||||
if (st->action == (actionf_p1)A_Lua) { // This is a Lua function?
|
||||
lua_getfield(L, LUA_REGISTRYINDEX, LREG_STATEACTION);
|
||||
I_Assert(lua_istable(L, -1));
|
||||
lua_pushlightuserdata(L, st); // Push the state pointer and
|
||||
@@ -428,7 +428,7 @@ static int state_set(lua_State *L)
|
||||
switch(lua_type(L, 3))
|
||||
{
|
||||
case LUA_TNIL: // Null? Set the action to nothing, then.
|
||||
st->action.acp1 = NULL;
|
||||
st->action = NULL;
|
||||
break;
|
||||
case LUA_TSTRING: // It's a string, expect the name of a built-in action
|
||||
LUA_SetActionByName(st, lua_tostring(L, 3));
|
||||
@@ -440,7 +440,7 @@ static int state_set(lua_State *L)
|
||||
lua_pushvalue(L, 3); // Bring it to the top of the stack
|
||||
lua_rawset(L, -3); // Set it in the registry
|
||||
lua_pop(L, 1); // pop LREG_STATEACTION
|
||||
st->action.acp1 = (actionf_p1)A_Lua; // Set the action for the userdata.
|
||||
st->action = (actionf_p1)A_Lua; // Set the action for the userdata.
|
||||
break;
|
||||
default: // ?!
|
||||
return luaL_typerror(L, 3, "function");
|
||||
|
||||
+1
-1
@@ -227,4 +227,4 @@ int LUA_MathLib(lua_State *L)
|
||||
lua_pushvalue(L, LUA_GLOBALSINDEX);
|
||||
luaL_register(L, NULL, lib);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
+2
-1
@@ -150,7 +150,8 @@ static const udata_field_t mobj_fields[] = {
|
||||
FIELD(mobj_t, cvmem, udatalib_getter_int32, udatalib_setter_int32),
|
||||
FIELD(mobj_t, standingslope, udatalib_getter_slope, mobj_standingslope_noset),
|
||||
FIELD(mobj_t, colorized, udatalib_getter_boolean, udatalib_setter_boolean),
|
||||
FIELD(mobj_t, mirrored, udatalib_getter_boolean, udatalib_setter_boolean),
|
||||
FIELD(mobj_t, mirrored, udatalib_getter_boolean, udatalib_setter_boolean),
|
||||
FIELD(mobj_t, islocal, udatalib_getter_boolean, udatalib_setter_boolean),
|
||||
{ NULL, 0, NULL, NULL },
|
||||
};
|
||||
#undef FIELD
|
||||
|
||||
+8
-5
@@ -1224,7 +1224,7 @@ void LUA_Archive(savebuffer_t *save, boolean network)
|
||||
{
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
// archive function will determine when to skip mobjs,
|
||||
@@ -1264,15 +1264,18 @@ void LUA_UnArchive(savebuffer_t *save, boolean network)
|
||||
{
|
||||
do {
|
||||
mobjnum = READUINT32(save->p); // read a mobjnum
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
if (((mobj_t *)th)->mobjnum == mobjnum) // find matching mobj
|
||||
UnArchiveExtVars(&save->p, th, network); // apply variables
|
||||
if (((mobj_t *)th)->mobjnum != mobjnum) // find matching mobj
|
||||
continue;
|
||||
UnArchiveExtVars(&save->p, th, network); // apply variables
|
||||
}
|
||||
} while(mobjnum != UINT32_MAX); // repeat until end of mobjs marker.
|
||||
|
||||
} while (mobjnum != UINT32_MAX); // repeat until end of mobjs marker.
|
||||
|
||||
LUA_HookNetArchive(NetUnArchive, save); // call the NetArchive hook in unarchive mode
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ struct iterationState {
|
||||
int next;
|
||||
};
|
||||
|
||||
static int iterationState_gc(lua_State *L)
|
||||
FUNCINLINE static ATTRINLINE int iterationState_gc(lua_State *L)
|
||||
{
|
||||
struct iterationState *it = luaL_checkudata(L, -1, META_ITERATIONSTATE);
|
||||
if (it->next != LUA_REFNIL)
|
||||
@@ -44,7 +44,7 @@ static int iterationState_gc(lua_State *L)
|
||||
}
|
||||
|
||||
#define push_thinker(th) {\
|
||||
if ((th)->function.acp1 == (actionf_p1)P_MobjThinker) \
|
||||
if ((th)->function == (actionf_p1)P_MobjThinker) \
|
||||
LUA_PushUserdata(L, (th), META_MOBJ); \
|
||||
else \
|
||||
lua_pushlightuserdata(L, (th)); \
|
||||
@@ -88,7 +88,7 @@ static int lib_iterateThinkers(lua_State *L)
|
||||
return luaL_error(L, "next thinker invalidated during iteration");
|
||||
|
||||
for (; next != &thinkercap; next = next->next)
|
||||
if (!it->filter || next->function.acp1 == it->filter)
|
||||
if (!it->filter || next->function == it->filter)
|
||||
{
|
||||
push_thinker(next);
|
||||
if (next->next != &thinkercap)
|
||||
@@ -130,4 +130,4 @@ int LUA_ThinkerLib(lua_State *L)
|
||||
lua_setfield(L, -2, "iterate");
|
||||
lua_setglobal(L, "thinkers");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -732,7 +732,7 @@ static mapthing_t *OP_CreateNewMapThing(player_t *player, UINT16 type, boolean c
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo = (mobj_t *)th;
|
||||
|
||||
+17
-13
@@ -1114,10 +1114,10 @@ static menuitem_t MP_PlayerSetupMenu[] =
|
||||
#ifndef NONET
|
||||
static menuitem_t MP_ConnectMenu[] =
|
||||
{
|
||||
{IT_STRING | IT_KEYHANDLER, NULL, "", M_HandleServerSearch,0},
|
||||
{IT_STRING | IT_CVAR, NULL, "Sort By", &cv_serversort, 16},
|
||||
{IT_STRING | IT_KEYHANDLER, NULL, "Page", M_HandleServerPage, 24},
|
||||
{IT_STRING | IT_CALL, NULL, "Refresh", M_Refresh, 32},
|
||||
{IT_STRING | IT_CVAR, NULL, "Sort By", &cv_serversort, 0},
|
||||
{IT_STRING | IT_KEYHANDLER, NULL, "Page", M_HandleServerPage, 8},
|
||||
{IT_STRING | IT_CALL, NULL, "Refresh", M_Refresh, 16},
|
||||
{IT_STRING | IT_KEYHANDLER, NULL, "", M_HandleServerSearch,25},
|
||||
|
||||
{IT_STRING | IT_SPACE, NULL, "", M_Connect, 48},
|
||||
{IT_STRING | IT_SPACE, NULL, "", M_Connect, 60},
|
||||
@@ -1133,10 +1133,10 @@ static menuitem_t MP_ConnectMenu[] =
|
||||
|
||||
enum
|
||||
{
|
||||
mp_connect_search,
|
||||
mp_connect_sort,
|
||||
mp_connect_page,
|
||||
mp_connect_refresh,
|
||||
mp_connect_search,
|
||||
FIRSTSERVERLINE
|
||||
};
|
||||
#endif
|
||||
@@ -6072,8 +6072,8 @@ static void M_AddonsOptions(INT32 choice)
|
||||
M_SetupNextMenu(&OP_AddonsOptionsDef);
|
||||
}
|
||||
|
||||
#define LOCATIONSTRING1 "Visit \x83SRB2.ORG/MODS\x80 to get & make addons!"
|
||||
#define LOCATIONSTRING2 "Visit \x88SRB2.ORG/MODS\x80 to get & make addons!"
|
||||
#define LOCATIONSTRING1 "Visit \x83mb.srb2.org/addons\x80 to get & make addons!"
|
||||
#define LOCATIONSTRING2 "Visit \x88mb.srb2.org/addons\x80 to get & make addons!"
|
||||
|
||||
static void M_AddonsInternal(void)
|
||||
{
|
||||
@@ -7768,7 +7768,10 @@ static void M_PlaybackRewind(INT32 choice)
|
||||
S_PauseAudio();
|
||||
}
|
||||
else
|
||||
demo.rewinding = paused = true;
|
||||
{
|
||||
demo.rewinding = true;
|
||||
paused = true;
|
||||
}
|
||||
}
|
||||
else if (lastconfirmtime + TICRATE/2 < I_GetTime())
|
||||
{
|
||||
@@ -9884,15 +9887,16 @@ static void M_DrawConnectMenu(void)
|
||||
M_DrawServerLines(currentMenu->x, serverlistpage);
|
||||
}
|
||||
|
||||
V_DrawFill(currentMenu->x, currentMenu->y, MAXSTRINGLENGTH*8+6, 8+6, 239);
|
||||
INT32 input_y = currentMenu->menuitems[mp_connect_search].alphaKey;
|
||||
|
||||
V_DrawFill(currentMenu->x, currentMenu->y+input_y, MAXSTRINGLENGTH*8+6, 8+6, 239);
|
||||
|
||||
const INT32 xoff = 3, yoff = 3;
|
||||
|
||||
|
||||
if (itemOn != 0)
|
||||
V_DrawString(currentMenu->x+xoff, currentMenu->y+yoff, V_ALLOWLOWERCASE, menuinput.buffer);
|
||||
if (itemOn != mp_connect_search)
|
||||
V_DrawString(currentMenu->x+xoff, currentMenu->y+yoff+input_y, V_ALLOWLOWERCASE, menuinput.buffer);
|
||||
else
|
||||
M_DrawTextInput(currentMenu->x+xoff, currentMenu->y+yoff, &menuinput, 0);
|
||||
M_DrawTextInput(currentMenu->x+xoff, currentMenu->y+yoff+input_y, &menuinput, 0);
|
||||
|
||||
localservercount = serverlistcount;
|
||||
|
||||
|
||||
+8
-8
@@ -590,9 +590,9 @@ static void PS_CountThinkers(void)
|
||||
{
|
||||
ps_thinkercount.value.i++;
|
||||
|
||||
if (thinker->function.acp1 == (actionf_p1)P_RemoveThinkerDelayed)
|
||||
if (thinker->function == (actionf_p1)P_RemoveThinkerDelayed)
|
||||
ps_removecount.value.i++;
|
||||
else if (thinker->function.acp1 == (actionf_p1)P_MobjThinker)
|
||||
else if (thinker->function == (actionf_p1)P_MobjThinker)
|
||||
{
|
||||
mobj_t *mobj = (mobj_t*)thinker;
|
||||
ps_mobjcount.value.i++;
|
||||
@@ -609,7 +609,7 @@ static void PS_CountThinkers(void)
|
||||
|
||||
for (thinker = precipcap.next; thinker != &precipcap; thinker = thinker->next)
|
||||
{
|
||||
if (thinker->function.acp1 != (actionf_p1)P_NullPrecipThinker)
|
||||
if (thinker->function != (actionf_p1)P_NullPrecipThinker)
|
||||
continue; // not a precipmobj thinker
|
||||
|
||||
ps_precipcount.value.i++;
|
||||
@@ -620,7 +620,7 @@ static void PS_CountThinkers(void)
|
||||
for (thinker = thlist[i].next; thinker != &thlist[i]; thinker = thinker->next)
|
||||
{
|
||||
ps_thinkercount.value.i++;
|
||||
if (thinker->function.acp1 == (actionf_p1)P_RemoveThinkerDelayed)
|
||||
if (thinker->function == (actionf_p1)P_RemoveThinkerDelayed)
|
||||
ps_removecount.value.i++;
|
||||
else if (i == THINK_POLYOBJ)
|
||||
ps_polythcount.value.i++;
|
||||
@@ -628,7 +628,7 @@ static void PS_CountThinkers(void)
|
||||
ps_mainthcount.value.i++;
|
||||
else if (i == THINK_MOBJ)
|
||||
{
|
||||
if (thinker->function.acp1 == (actionf_p1)P_MobjThinker)
|
||||
if (thinker->function == (actionf_p1)P_MobjThinker)
|
||||
{
|
||||
mobj_t *mobj = (mobj_t*)thinker;
|
||||
ps_mobjcount.value.i++;
|
||||
@@ -739,7 +739,7 @@ static void PS_DrawDescriptorHeader(void)
|
||||
int samples_left = max(ps_frame_samples_left, ps_tick_samples_left);
|
||||
int x, y;
|
||||
|
||||
if (cv_perfstats.value >= 3)
|
||||
if (cv_perfstats.value >= 3)
|
||||
{
|
||||
x = 2;
|
||||
y = 0;
|
||||
@@ -892,7 +892,7 @@ static void draw_think_frame_stats(int hook_length, ps_hookinfo_t *hook)
|
||||
|
||||
PS_DrawDescriptorHeader();
|
||||
|
||||
for (i = 0; i < hook_length; i++)
|
||||
for (i = 0; i < hook_length; i++)
|
||||
{
|
||||
#define NEXT_ROW() y += HEIGHT;
|
||||
|
||||
@@ -1010,7 +1010,7 @@ void M_DrawPerfStats(void)
|
||||
// tics when frame skips happen
|
||||
PS_DrawGameLogicStats();
|
||||
}
|
||||
else if (cv_perfstats.value >= 3) // lua thinkframe
|
||||
else if (cv_perfstats.value >= 3) // lua thinkframe
|
||||
{
|
||||
if (!PS_IsLevelActive())
|
||||
return;
|
||||
|
||||
+2
-2
@@ -412,7 +412,7 @@ INT32 EV_DoCeiling(line_t *line, ceiling_e type)
|
||||
ceiling = Z_Calloc(sizeof (*ceiling), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&ceiling->thinker);
|
||||
sec->ceilingdata = ceiling;
|
||||
ceiling->thinker.function.acp1 = (actionf_p1)T_MoveCeiling;
|
||||
ceiling->thinker.function = (actionf_p1)T_MoveCeiling;
|
||||
ceiling->sector = sec;
|
||||
ceiling->crush = false;
|
||||
ceiling->sourceline = (INT32)(line-lines);
|
||||
@@ -635,7 +635,7 @@ INT32 EV_DoCrush(line_t *line, ceiling_e type)
|
||||
ceiling = Z_Calloc(sizeof (*ceiling), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&ceiling->thinker);
|
||||
sec->ceilingdata = ceiling;
|
||||
ceiling->thinker.function.acp1 = (actionf_p1)T_CrushCeiling;
|
||||
ceiling->thinker.function = (actionf_p1)T_CrushCeiling;
|
||||
ceiling->sector = sec;
|
||||
ceiling->crush = true;
|
||||
ceiling->sourceline = (INT32)(line-lines);
|
||||
|
||||
+1007
-884
File diff suppressed because it is too large.
Load diff
+7
-7
@@ -2483,7 +2483,7 @@ void T_CameraScanner(elevator_t *elevator)
|
||||
|
||||
for (UINT8 i = 0; i <= splitscreen; i++)
|
||||
{
|
||||
if (!players[displayplayers[i]].mo || P_MobjWasRemoved(players[displayplayers[i]].mo))
|
||||
if (P_MobjWasRemoved(players[displayplayers[i]].mo))
|
||||
continue;
|
||||
|
||||
if (players[displayplayers[i]].mo->subsector->sector == elevator->actionsector)
|
||||
@@ -2545,7 +2545,7 @@ INT32 EV_DoFloor(line_t *line, floor_e floortype)
|
||||
sec->floordata = dofloor;
|
||||
|
||||
// set up some generic aspects of the floormove_t
|
||||
dofloor->thinker.function.acp1 = (actionf_p1)T_MoveFloor;
|
||||
dofloor->thinker.function = (actionf_p1)T_MoveFloor;
|
||||
dofloor->type = floortype;
|
||||
dofloor->crush = false; // default: types that crush will change this
|
||||
dofloor->sector = sec;
|
||||
@@ -2766,7 +2766,7 @@ INT32 EV_DoElevator(line_t *line, elevator_e elevtype, boolean customspeed)
|
||||
P_AddThinker(&elevator->thinker);
|
||||
sec->floordata = elevator;
|
||||
sec->ceilingdata = elevator;
|
||||
elevator->thinker.function.acp1 = (actionf_p1)T_MoveElevator;
|
||||
elevator->thinker.function = (actionf_p1)T_MoveElevator;
|
||||
elevator->type = elevtype;
|
||||
elevator->sourceline = line;
|
||||
elevator->distance = 1; // Always crush unless otherwise
|
||||
@@ -2954,7 +2954,7 @@ INT32 EV_BounceSector(sector_t *sec, fixed_t momz, line_t *sourceline)
|
||||
bouncer = Z_Calloc(sizeof (*bouncer), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&bouncer->thinker);
|
||||
sec->ceilingdata = bouncer;
|
||||
bouncer->thinker.function.acp1 = (actionf_p1)T_BounceCheese;
|
||||
bouncer->thinker.function = (actionf_p1)T_BounceCheese;
|
||||
|
||||
// set up the fields according to the type of elevator action
|
||||
bouncer->sector = sec;
|
||||
@@ -2991,7 +2991,7 @@ INT32 EV_DoContinuousFall(sector_t *sec, sector_t *backsector, fixed_t spd, bool
|
||||
// create and initialize new thinker
|
||||
faller = Z_Calloc(sizeof (*faller), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&faller->thinker);
|
||||
faller->thinker.function.acp1 = (actionf_p1)T_ContinuousFalling;
|
||||
faller->thinker.function = (actionf_p1)T_ContinuousFalling;
|
||||
|
||||
// set up the fields
|
||||
faller->sector = sec;
|
||||
@@ -3044,7 +3044,7 @@ INT32 EV_StartCrumble(sector_t *sec, ffloor_t *rover, boolean floating,
|
||||
// create and initialize new elevator thinker
|
||||
elevator = Z_Calloc(sizeof (*elevator), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&elevator->thinker);
|
||||
elevator->thinker.function.acp1 = (actionf_p1)T_StartCrumble;
|
||||
elevator->thinker.function = (actionf_p1)T_StartCrumble;
|
||||
|
||||
// Does this crumbler return?
|
||||
if (crumblereturn)
|
||||
@@ -3123,7 +3123,7 @@ INT32 EV_MarioBlock(sector_t *sec, sector_t *roversector, fixed_t topheight, mob
|
||||
P_AddThinker(&block->thinker);
|
||||
sec->floordata = block;
|
||||
sec->ceilingdata = block;
|
||||
block->thinker.function.acp1 = (actionf_p1)T_MarioBlock;
|
||||
block->thinker.function = (actionf_p1)T_MarioBlock;
|
||||
|
||||
// Set up the fields
|
||||
block->sector = sec;
|
||||
|
||||
+8
-8
@@ -473,7 +473,7 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||
if (player->spectator)
|
||||
return;
|
||||
|
||||
if (special->tracer && !P_MobjWasRemoved(special->tracer) && toucher == special->tracer)
|
||||
if (!P_MobjWasRemoved(special->tracer) && toucher == special->tracer)
|
||||
{
|
||||
mobj_t *spbexplode;
|
||||
|
||||
@@ -487,7 +487,7 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||
|
||||
spbexplode = P_SpawnMobj(toucher->x, toucher->y, toucher->z, MT_SPBEXPLOSION);
|
||||
spbexplode->extravalue1 = 1; // Tell K_ExplodePlayer to use extra knockback
|
||||
if (special->target && !P_MobjWasRemoved(special->target))
|
||||
if (!P_MobjWasRemoved(special->target))
|
||||
P_SetTarget(&spbexplode->target, special->target);
|
||||
|
||||
P_RemoveMobj(special);
|
||||
@@ -496,7 +496,7 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||
K_SpinPlayer(player, special->target, 0, special, false);
|
||||
return;
|
||||
case MT_SMK_MOLE:
|
||||
if (special->target && !P_MobjWasRemoved(special->target))
|
||||
if (!P_MobjWasRemoved(special->target))
|
||||
return;
|
||||
|
||||
if (special->health <= 0 || toucher->health <= 0)
|
||||
@@ -961,7 +961,7 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||
// scan the remaining thinkers to find koopa
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -1765,7 +1765,7 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source)
|
||||
case MT_SMK_ICEBLOCK:
|
||||
{
|
||||
mobj_t *cur = target->hnext;
|
||||
while (cur && !P_MobjWasRemoved(cur))
|
||||
while (!P_MobjWasRemoved(cur))
|
||||
{
|
||||
P_SetMobjState(cur, S_SMK_ICEBLOCK2);
|
||||
cur = cur->hnext;
|
||||
@@ -1816,7 +1816,7 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source)
|
||||
// this can happen if the boss was hurt earlier than expected
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo = (mobj_t *)th;
|
||||
@@ -1838,14 +1838,14 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source)
|
||||
// kill tracer
|
||||
if (target->type == MT_FROGGER)
|
||||
{
|
||||
if (target->tracer && !P_MobjWasRemoved(target->tracer))
|
||||
if (!P_MobjWasRemoved(target->tracer))
|
||||
P_KillMobj(target->tracer, inflictor, source);
|
||||
}
|
||||
|
||||
if (target->type == MT_FROGGER || target->type == MT_ROBRA_HEAD || target->type == MT_BLUEROBRA_HEAD) // clean hnext list
|
||||
{
|
||||
mobj_t *cur = target->hnext;
|
||||
while (cur && !P_MobjWasRemoved(cur))
|
||||
while (!P_MobjWasRemoved(cur))
|
||||
{
|
||||
P_KillMobj(cur, inflictor, source);
|
||||
cur = cur->hnext;
|
||||
|
||||
+6
-6
@@ -78,7 +78,7 @@ fireflicker_t *P_SpawnAdjustableFireFlicker(sector_t *minsector, sector_t *maxse
|
||||
|
||||
P_AddThinker(&flick->thinker);
|
||||
|
||||
flick->thinker.function.acp1 = (actionf_p1)T_FireFlicker;
|
||||
flick->thinker.function = (actionf_p1)T_FireFlicker;
|
||||
flick->sector = maxsector;
|
||||
flick->maxlight = maxsector->lightlevel;
|
||||
flick->minlight = minsector->lightlevel;
|
||||
@@ -140,7 +140,7 @@ void P_SpawnLightningFlash(sector_t *sector)
|
||||
|
||||
if (sector->lightingdata)
|
||||
{
|
||||
if (((lightflash_t *)sector->lightingdata)->thinker.function.acp1
|
||||
if (((lightflash_t *)sector->lightingdata)->thinker.function
|
||||
== (actionf_p1)T_LightningFlash)
|
||||
{
|
||||
// lightning was already flashing in this sector
|
||||
@@ -157,7 +157,7 @@ void P_SpawnLightningFlash(sector_t *sector)
|
||||
|
||||
P_AddThinker(&flash->thinker);
|
||||
|
||||
flash->thinker.function.acp1 = (actionf_p1)T_LightningFlash;
|
||||
flash->thinker.function = (actionf_p1)T_LightningFlash;
|
||||
flash->sector = sector;
|
||||
flash->maxlight = 255;
|
||||
flash->minlight = minlight;
|
||||
@@ -219,7 +219,7 @@ strobe_t *P_SpawnAdjustableStrobeFlash(sector_t *minsector, sector_t *maxsector,
|
||||
flash->sector = maxsector;
|
||||
flash->darktime = darktime;
|
||||
flash->brighttime = brighttime;
|
||||
flash->thinker.function.acp1 = (actionf_p1)T_StrobeFlash;
|
||||
flash->thinker.function = (actionf_p1)T_StrobeFlash;
|
||||
flash->maxlight = maxsector->lightlevel;
|
||||
flash->minlight = minsector->lightlevel;
|
||||
|
||||
@@ -301,7 +301,7 @@ glow_t *P_SpawnAdjustableGlowingLight(sector_t *minsector, sector_t *maxsector,
|
||||
g->minlight = g->maxlight;
|
||||
g->maxlight = oops;
|
||||
}
|
||||
g->thinker.function.acp1 = (actionf_p1)T_Glow;
|
||||
g->thinker.function = (actionf_p1)T_Glow;
|
||||
g->direction = 1;
|
||||
g->speed = length/4;
|
||||
if (g->speed > (g->maxlight - g->minlight)/2) // don't make it ridiculous speed
|
||||
@@ -347,7 +347,7 @@ void P_FadeLight(INT16 tag, INT32 destvalue, INT32 speed)
|
||||
|
||||
P_RemoveLighting(sector); // remove the old lighting effect first
|
||||
ll = Z_Calloc(sizeof (*ll), PU_LEVSPEC, NULL);
|
||||
ll->thinker.function.acp1 = (actionf_p1)T_LightFade;
|
||||
ll->thinker.function = (actionf_p1)T_LightFade;
|
||||
sector->lightingdata = ll; // set it to the lightlevel_t
|
||||
|
||||
P_AddThinker(&ll->thinker); // add thinker
|
||||
|
||||
+1
-1
@@ -279,7 +279,7 @@ void P_SceneryThinker(mobj_t *mobj);
|
||||
// To test it in Lua, check mobj.valid
|
||||
FUNCINLINE static ATTRINLINE boolean P_MobjWasRemoved(const mobj_t *mobj)
|
||||
{
|
||||
return (!mobj || mobj->thinker.function.acp1 != (actionf_p1)P_MobjThinker);
|
||||
return (!mobj || mobj->thinker.function != (actionf_p1)P_MobjThinker);
|
||||
}
|
||||
|
||||
fixed_t P_MobjFloorZ(mobj_t *mobj, sector_t *sector, sector_t *boundsec, fixed_t x, fixed_t y, line_t *line, boolean lowest, boolean perfect);
|
||||
|
||||
+2
-2
@@ -321,7 +321,7 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||
return true;
|
||||
|
||||
// Ignore... things.
|
||||
if (!tmthing || !thing || P_MobjWasRemoved(thing))
|
||||
if (!tmthing || P_MobjWasRemoved(thing))
|
||||
return true;
|
||||
|
||||
I_Assert(!P_MobjWasRemoved(tmthing));
|
||||
@@ -3626,7 +3626,7 @@ static boolean PIT_ChangeSector(mobj_t *thing, boolean realcrush)
|
||||
|
||||
for (think = thinkercap.next; think != &thinkercap; think = think->next)
|
||||
{
|
||||
if (think->function.acp1 != (actionf_p1)T_StartCrumble)
|
||||
if (think->function != (actionf_p1)T_StartCrumble)
|
||||
continue;
|
||||
|
||||
crumbler = (elevator_t *)think;
|
||||
|
||||
+1548
-1473
File diff suppressed because it is too large.
Load diff
@@ -414,6 +414,7 @@ typedef struct mobj_s
|
||||
boolean init_salty;
|
||||
|
||||
// WARNING: New fields must be added separately to savegame and Lua.
|
||||
boolean islocal; // BEWARE: islocal does not exist in vanilla, strictly to be used for locally loaded addons to not cause desynchs with the mobj linedef trigger check. DO NOT USE THIS IN ACTUAL ADDONS YOU INTEND TO USE ON YOUR SERVER
|
||||
} mobj_t;
|
||||
|
||||
//
|
||||
|
||||
+13
-13
@@ -1557,7 +1557,7 @@ void Polyobj_InitLevel(void)
|
||||
// the mobj_t pointers on a queue for use below.
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mobj_t *mo = (mobj_t *)th;
|
||||
@@ -1832,7 +1832,7 @@ void T_PolyObjWaypoint(polywaypoint_t *th)
|
||||
// We redo this each tic to make savegame compatibility easier.
|
||||
for (wp = thinkercap.next; wp != &thinkercap; wp = wp->next)
|
||||
{
|
||||
if (wp->function.acp1 != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
if (wp->function != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)wp;
|
||||
@@ -1916,7 +1916,7 @@ void T_PolyObjWaypoint(polywaypoint_t *th)
|
||||
// Find next waypoint
|
||||
for (wp = thinkercap.next; wp != &thinkercap; wp = wp->next)
|
||||
{
|
||||
if (wp->function.acp1 != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
if (wp->function != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)wp;
|
||||
@@ -1955,7 +1955,7 @@ void T_PolyObjWaypoint(polywaypoint_t *th)
|
||||
|
||||
for (wp = thinkercap.next; wp != &thinkercap; wp = wp->next)
|
||||
{
|
||||
if (wp->function.acp1 != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
if (wp->function != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)wp;
|
||||
@@ -1992,7 +1992,7 @@ void T_PolyObjWaypoint(polywaypoint_t *th)
|
||||
|
||||
for (wp = thinkercap.next; wp != &thinkercap; wp = wp->next)
|
||||
{
|
||||
if (wp->function.acp1 != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
if (wp->function != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)wp;
|
||||
@@ -2357,7 +2357,7 @@ INT32 EV_DoPolyObjRotate(polyrotdata_t *prdata)
|
||||
|
||||
// create a new thinker
|
||||
th = Z_Malloc(sizeof(polyrotate_t), PU_LEVSPEC, NULL);
|
||||
th->thinker.function.acp1 = (actionf_p1)T_PolyObjRotate;
|
||||
th->thinker.function = (actionf_p1)T_PolyObjRotate;
|
||||
PolyObj_AddThinker(&th->thinker);
|
||||
po->thinker = &th->thinker;
|
||||
|
||||
@@ -2425,7 +2425,7 @@ INT32 EV_DoPolyObjMove(polymovedata_t *pmdata)
|
||||
|
||||
// create a new thinker
|
||||
th = Z_Malloc(sizeof(polymove_t), PU_LEVSPEC, NULL);
|
||||
th->thinker.function.acp1 = (actionf_p1)T_PolyObjMove;
|
||||
th->thinker.function = (actionf_p1)T_PolyObjMove;
|
||||
PolyObj_AddThinker(&th->thinker);
|
||||
po->thinker = &th->thinker;
|
||||
|
||||
@@ -2491,7 +2491,7 @@ INT32 EV_DoPolyObjWaypoint(polywaypointdata_t *pwdata)
|
||||
|
||||
// create a new thinker
|
||||
th = Z_Malloc(sizeof(polywaypoint_t), PU_LEVSPEC, NULL);
|
||||
th->thinker.function.acp1 = (actionf_p1)T_PolyObjWaypoint;
|
||||
th->thinker.function = (actionf_p1)T_PolyObjWaypoint;
|
||||
PolyObj_AddThinker(&th->thinker);
|
||||
po->thinker = &th->thinker;
|
||||
|
||||
@@ -2512,7 +2512,7 @@ INT32 EV_DoPolyObjWaypoint(polywaypointdata_t *pwdata)
|
||||
// Find the first waypoint we need to use
|
||||
for (wp = thinkercap.next; wp != &thinkercap; wp = wp->next)
|
||||
{
|
||||
if (wp->function.acp1 != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
if (wp->function != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)wp;
|
||||
@@ -2627,7 +2627,7 @@ static void Polyobj_doSlideDoor(polyobj_t *po, polydoordata_t *doordata)
|
||||
|
||||
// allocate and add a new slide door thinker
|
||||
th = Z_Malloc(sizeof(polyslidedoor_t), PU_LEVSPEC, NULL);
|
||||
th->thinker.function.acp1 = (actionf_p1)T_PolyDoorSlide;
|
||||
th->thinker.function = (actionf_p1)T_PolyDoorSlide;
|
||||
PolyObj_AddThinker(&th->thinker);
|
||||
|
||||
// point the polyobject to this thinker
|
||||
@@ -2678,7 +2678,7 @@ static void Polyobj_doSwingDoor(polyobj_t *po, polydoordata_t *doordata)
|
||||
|
||||
// allocate and add a new swing door thinker
|
||||
th = Z_Malloc(sizeof(polyswingdoor_t), PU_LEVSPEC, NULL);
|
||||
th->thinker.function.acp1 = (actionf_p1)T_PolyDoorSwing;
|
||||
th->thinker.function = (actionf_p1)T_PolyDoorSwing;
|
||||
PolyObj_AddThinker(&th->thinker);
|
||||
|
||||
// point the polyobject to this thinker
|
||||
@@ -2763,7 +2763,7 @@ INT32 EV_DoPolyObjDisplace(polydisplacedata_t *prdata)
|
||||
|
||||
// create a new thinker
|
||||
th = Z_Malloc(sizeof(polydisplace_t), PU_LEVSPEC, NULL);
|
||||
th->thinker.function.acp1 = (actionf_p1)T_PolyObjDisplace;
|
||||
th->thinker.function = (actionf_p1)T_PolyObjDisplace;
|
||||
PolyObj_AddThinker(&th->thinker);
|
||||
po->thinker = &th->thinker;
|
||||
|
||||
@@ -2867,7 +2867,7 @@ INT32 EV_DoPolyObjFlag(line_t *pfdata)
|
||||
|
||||
// create a new thinker
|
||||
th = Z_Malloc(sizeof(polymove_t), PU_LEVSPEC, NULL);
|
||||
th->thinker.function.acp1 = (actionf_p1)T_PolyObjFlag;
|
||||
th->thinker.function = (actionf_p1)T_PolyObjFlag;
|
||||
PolyObj_AddThinker(&th->thinker);
|
||||
po->thinker = &th->thinker;
|
||||
|
||||
|
||||
+67
-67
@@ -1677,194 +1677,194 @@ static void P_NetArchiveThinkers(savebuffer_t *save)
|
||||
// save off the current thinkers
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 == (actionf_p1)P_RemoveThinkerDelayed)
|
||||
if (th->function == (actionf_p1)P_RemoveThinkerDelayed)
|
||||
continue;
|
||||
|
||||
numsaved++;
|
||||
|
||||
if (th->function.acp1 == (actionf_p1)P_MobjThinker)
|
||||
if (th->function == (actionf_p1)P_MobjThinker)
|
||||
{
|
||||
SaveMobjThinker(save, th, tc_mobj);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_MoveCeiling)
|
||||
else if (th->function == (actionf_p1)T_MoveCeiling)
|
||||
{
|
||||
SaveCeilingThinker(save, th, tc_ceiling);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_CrushCeiling)
|
||||
else if (th->function == (actionf_p1)T_CrushCeiling)
|
||||
{
|
||||
SaveCeilingThinker(save, th, tc_crushceiling);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_MoveFloor)
|
||||
else if (th->function == (actionf_p1)T_MoveFloor)
|
||||
{
|
||||
SaveFloormoveThinker(save, th, tc_floor);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_LightningFlash)
|
||||
else if (th->function == (actionf_p1)T_LightningFlash)
|
||||
{
|
||||
SaveLightflashThinker(save, th, tc_flash);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_StrobeFlash)
|
||||
else if (th->function == (actionf_p1)T_StrobeFlash)
|
||||
{
|
||||
SaveStrobeThinker(save, th, tc_strobe);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_Glow)
|
||||
else if (th->function == (actionf_p1)T_Glow)
|
||||
{
|
||||
SaveGlowThinker(save, th, tc_glow);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_FireFlicker)
|
||||
else if (th->function == (actionf_p1)T_FireFlicker)
|
||||
{
|
||||
SaveFireflickerThinker(save, th, tc_fireflicker);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_MoveElevator)
|
||||
else if (th->function == (actionf_p1)T_MoveElevator)
|
||||
{
|
||||
SaveElevatorThinker(save, th, tc_elevator);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_ContinuousFalling)
|
||||
else if (th->function == (actionf_p1)T_ContinuousFalling)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_continuousfalling);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_ThwompSector)
|
||||
else if (th->function == (actionf_p1)T_ThwompSector)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_thwomp);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_NoEnemiesSector)
|
||||
else if (th->function == (actionf_p1)T_NoEnemiesSector)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_noenemies);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_EachTimeThinker)
|
||||
else if (th->function == (actionf_p1)T_EachTimeThinker)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_eachtime);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_RaiseSector)
|
||||
else if (th->function == (actionf_p1)T_RaiseSector)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_raisesector);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_CameraScanner)
|
||||
else if (th->function == (actionf_p1)T_CameraScanner)
|
||||
{
|
||||
SaveElevatorThinker(save, th, tc_camerascanner);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_Scroll)
|
||||
else if (th->function == (actionf_p1)T_Scroll)
|
||||
{
|
||||
SaveScrollThinker(save, th, tc_scroll);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_Friction)
|
||||
else if (th->function == (actionf_p1)T_Friction)
|
||||
{
|
||||
SaveFrictionThinker(save, th, tc_friction);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_Pusher)
|
||||
else if (th->function == (actionf_p1)T_Pusher)
|
||||
{
|
||||
SavePusherThinker(save, th, tc_pusher);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_BounceCheese)
|
||||
else if (th->function == (actionf_p1)T_BounceCheese)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_bouncecheese);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_StartCrumble)
|
||||
else if (th->function == (actionf_p1)T_StartCrumble)
|
||||
{
|
||||
SaveElevatorThinker(save, th, tc_startcrumble);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_MarioBlock)
|
||||
else if (th->function == (actionf_p1)T_MarioBlock)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_marioblock);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_MarioBlockChecker)
|
||||
else if (th->function == (actionf_p1)T_MarioBlockChecker)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_marioblockchecker);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_SpikeSector)
|
||||
else if (th->function == (actionf_p1)T_SpikeSector)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_spikesector);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_FloatSector)
|
||||
else if (th->function == (actionf_p1)T_FloatSector)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_floatsector);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_BridgeThinker)
|
||||
else if (th->function == (actionf_p1)T_BridgeThinker)
|
||||
{
|
||||
SaveSpecialLevelThinker(save, th, tc_bridgethinker);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_LaserFlash)
|
||||
else if (th->function == (actionf_p1)T_LaserFlash)
|
||||
{
|
||||
SaveLaserThinker(save, th, tc_laserflash);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_LightFade)
|
||||
else if (th->function == (actionf_p1)T_LightFade)
|
||||
{
|
||||
SaveLightlevelThinker(save, th, tc_lightfade);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_ExecutorDelay)
|
||||
else if (th->function == (actionf_p1)T_ExecutorDelay)
|
||||
{
|
||||
SaveExecutorThinker(save, th, tc_executor);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_Disappear)
|
||||
else if (th->function == (actionf_p1)T_Disappear)
|
||||
{
|
||||
SaveDisappearThinker(save, th, tc_disappear);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_PolyObjRotate)
|
||||
else if (th->function == (actionf_p1)T_PolyObjRotate)
|
||||
{
|
||||
SavePolyrotatetThinker(save, th, tc_polyrotate);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_PolyObjMove)
|
||||
else if (th->function == (actionf_p1)T_PolyObjMove)
|
||||
{
|
||||
SavePolymoveThinker(save, th, tc_polymove);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_PolyObjWaypoint)
|
||||
else if (th->function == (actionf_p1)T_PolyObjWaypoint)
|
||||
{
|
||||
SavePolywaypointThinker(save, th, tc_polywaypoint);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_PolyDoorSlide)
|
||||
else if (th->function == (actionf_p1)T_PolyDoorSlide)
|
||||
{
|
||||
SavePolyslidedoorThinker(save, th, tc_polyslidedoor);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_PolyDoorSwing)
|
||||
else if (th->function == (actionf_p1)T_PolyDoorSwing)
|
||||
{
|
||||
SavePolyswingdoorThinker(save, th, tc_polyswingdoor);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_PolyObjFlag)
|
||||
else if (th->function == (actionf_p1)T_PolyObjFlag)
|
||||
{
|
||||
SavePolymoveThinker(save, th, tc_polyflag);
|
||||
continue;
|
||||
}
|
||||
else if (th->function.acp1 == (actionf_p1)T_PolyObjDisplace)
|
||||
else if (th->function == (actionf_p1)T_PolyObjDisplace)
|
||||
{
|
||||
SavePolydisplaceThinker(save, th, tc_polydisplace);
|
||||
continue;
|
||||
}
|
||||
#ifdef PARANOIA
|
||||
else if (th->function.acp1 != (actionf_p1)P_RemoveThinkerDelayed) // wait garbage collection
|
||||
I_Error("unknown thinker type %p", th->function.acp1);
|
||||
else if (th->function != (actionf_p1)P_RemoveThinkerDelayed) // wait garbage collection
|
||||
I_Error("unknown thinker type %p", th->function);
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -1884,7 +1884,7 @@ mobj_t *P_FindNewPosition(UINT32 oldposition)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mobj = (mobj_t *)th;
|
||||
@@ -1983,7 +1983,7 @@ static void LoadMobjThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
mobj = AllocMobj();
|
||||
|
||||
// declare this as a valid mobj as soon as possible.
|
||||
mobj->thinker.function.acp1 = thinker;
|
||||
mobj->thinker.function = thinker;
|
||||
|
||||
mobj->z = z;
|
||||
mobj->floorz = floorz;
|
||||
@@ -2216,7 +2216,7 @@ static void LoadSpecialLevelThinker(savebuffer_t *save, actionf_p1 thinker, UINT
|
||||
{
|
||||
levelspecthink_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
size_t i;
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
for (i = 0; i < 16; i++)
|
||||
{
|
||||
ht->vars[i] = READFIXED(save->p); //var[16]
|
||||
@@ -2244,7 +2244,7 @@ static void LoadSpecialLevelThinker(savebuffer_t *save, actionf_p1 thinker, UINT
|
||||
static void LoadCeilingThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
ceiling_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->type = READUINT8(save->p);
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->bottomheight = READFIXED(save->p);
|
||||
@@ -2273,7 +2273,7 @@ static void LoadCeilingThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static void LoadFloormoveThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
floormove_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->type = READUINT8(save->p);
|
||||
ht->crush = READUINT8(save->p);
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
@@ -2297,7 +2297,7 @@ static void LoadFloormoveThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static void LoadLightflashThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
lightflash_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->maxlight = READINT32(save->p);
|
||||
ht->minlight = READINT32(save->p);
|
||||
@@ -2314,7 +2314,7 @@ static void LoadLightflashThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static void LoadStrobeThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
strobe_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->count = READINT32(save->p);
|
||||
ht->minlight = READINT32(save->p);
|
||||
@@ -2334,7 +2334,7 @@ static void LoadStrobeThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static void LoadGlowThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
glow_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->minlight = READINT32(save->p);
|
||||
ht->maxlight = READINT32(save->p);
|
||||
@@ -2353,7 +2353,7 @@ static void LoadGlowThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static void LoadFireflickerThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
fireflicker_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->count = READINT32(save->p);
|
||||
ht->resetcount = READINT32(save->p);
|
||||
@@ -2372,7 +2372,7 @@ static void LoadFireflickerThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static void LoadElevatorThinker(savebuffer_t *save, actionf_p1 thinker, UINT8 floorOrCeiling)
|
||||
{
|
||||
elevator_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->type = READUINT8(save->p);
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->actionsector = LoadSector(READUINT32(save->p));
|
||||
@@ -2410,7 +2410,7 @@ static void LoadElevatorThinker(savebuffer_t *save, actionf_p1 thinker, UINT8 fl
|
||||
static void LoadScrollThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
scroll_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->dx = READFIXED(save->p);
|
||||
ht->dy = READFIXED(save->p);
|
||||
ht->affectee = READINT32(save->p);
|
||||
@@ -2432,7 +2432,7 @@ static void LoadScrollThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static inline void LoadFrictionThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
friction_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->friction = READINT32(save->p);
|
||||
ht->movefactor = READINT32(save->p);
|
||||
ht->affectee = READINT32(save->p);
|
||||
@@ -2449,7 +2449,7 @@ static inline void LoadFrictionThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static void LoadPusherThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
pusher_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->type = READUINT8(save->p);
|
||||
ht->x_mag = READINT32(save->p);
|
||||
ht->y_mag = READINT32(save->p);
|
||||
@@ -2476,7 +2476,7 @@ static inline void LoadLaserThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
laserthink_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ffloor_t *rover = NULL;
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->sec = LoadSector(READUINT32(save->p));
|
||||
ht->sourceline = LoadLine(READUINT32(save->p));
|
||||
@@ -2495,7 +2495,7 @@ static inline void LoadLaserThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
FUNCINLINE static ATTRINLINE void LoadLightlevelThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
lightlevel_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
ht->destlevel = READINT32(save->p);
|
||||
ht->speed = READINT32(save->p);
|
||||
@@ -2512,7 +2512,7 @@ FUNCINLINE static ATTRINLINE void LoadLightlevelThinker(savebuffer_t *save, acti
|
||||
static inline void LoadExecutorThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
executor_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->line = LoadLine(READUINT32(save->p));
|
||||
ht->caller = LoadMobj(READUINT32(save->p));
|
||||
ht->sector = LoadSector(READUINT32(save->p));
|
||||
@@ -2528,7 +2528,7 @@ static inline void LoadExecutorThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static inline void LoadDisappearThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
disappear_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->appeartime = READUINT32(save->p);
|
||||
ht->disappeartime = READUINT32(save->p);
|
||||
ht->offset = READUINT32(save->p);
|
||||
@@ -2547,7 +2547,7 @@ static inline void LoadDisappearThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static inline void LoadPolyrotatetThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
polyrotate_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->polyObjNum = READINT32(save->p);
|
||||
ht->speed = READINT32(save->p);
|
||||
ht->distance = READINT32(save->p);
|
||||
@@ -2563,7 +2563,7 @@ static inline void LoadPolyrotatetThinker(savebuffer_t *save, actionf_p1 thinker
|
||||
static void LoadPolymoveThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
polymove_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->polyObjNum = READINT32(save->p);
|
||||
ht->speed = READINT32(save->p);
|
||||
ht->momx = READFIXED(save->p);
|
||||
@@ -2581,7 +2581,7 @@ static void LoadPolymoveThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
static inline void LoadPolywaypointThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
polywaypoint_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->polyObjNum = READINT32(save->p);
|
||||
ht->speed = READINT32(save->p);
|
||||
ht->sequence = READINT32(save->p);
|
||||
@@ -2605,7 +2605,7 @@ static inline void LoadPolywaypointThinker(savebuffer_t *save, actionf_p1 thinke
|
||||
static inline void LoadPolyslidedoorThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
polyslidedoor_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->polyObjNum = READINT32(save->p);
|
||||
ht->delay = READINT32(save->p);
|
||||
ht->delayCount = READINT32(save->p);
|
||||
@@ -2630,7 +2630,7 @@ static inline void LoadPolyslidedoorThinker(savebuffer_t *save, actionf_p1 think
|
||||
static inline void LoadPolyswingdoorThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
polyswingdoor_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->polyObjNum = READINT32(save->p);
|
||||
ht->delay = READINT32(save->p);
|
||||
ht->delayCount = READINT32(save->p);
|
||||
@@ -2650,7 +2650,7 @@ static inline void LoadPolyswingdoorThinker(savebuffer_t *save, actionf_p1 think
|
||||
static inline void LoadPolydisplaceThinker(savebuffer_t *save, actionf_p1 thinker)
|
||||
{
|
||||
polydisplace_t *ht = Z_Malloc(sizeof (*ht), PU_LEVSPEC, NULL);
|
||||
ht->thinker.function.acp1 = thinker;
|
||||
ht->thinker.function = thinker;
|
||||
ht->polyObjNum = READINT32(save->p);
|
||||
ht->controlSector = LoadSector(READUINT32(save->p));
|
||||
ht->dx = READFIXED(save->p);
|
||||
@@ -2680,7 +2680,7 @@ static void P_NetUnArchiveThinkers(savebuffer_t *save)
|
||||
{
|
||||
next = currentthinker->next;
|
||||
|
||||
if (currentthinker->function.acp1 == (actionf_p1)P_MobjThinker)
|
||||
if (currentthinker->function == (actionf_p1)P_MobjThinker)
|
||||
P_RemoveSavegameMobj((mobj_t *)currentthinker); // item isn't saved, don't remove it
|
||||
else
|
||||
{
|
||||
@@ -2874,7 +2874,7 @@ static void P_NetUnArchiveThinkers(savebuffer_t *save)
|
||||
for (currentthinker = thinkercap.next; currentthinker != &thinkercap;
|
||||
currentthinker = currentthinker->next)
|
||||
{
|
||||
if (currentthinker->function.acp1 != (actionf_p1)T_ExecutorDelay)
|
||||
if (currentthinker->function != (actionf_p1)T_ExecutorDelay)
|
||||
continue;
|
||||
|
||||
delay = (void *)currentthinker;
|
||||
@@ -2989,7 +2989,7 @@ static inline void P_FinishMobjs(void)
|
||||
for (currentthinker = thinkercap.next; currentthinker != &thinkercap;
|
||||
currentthinker = currentthinker->next)
|
||||
{
|
||||
if (currentthinker->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (currentthinker->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mobj = (mobj_t *)currentthinker;
|
||||
@@ -3014,7 +3014,7 @@ static void P_RelinkPointers(void)
|
||||
for (currentthinker = thinkercap.next; currentthinker != &thinkercap;
|
||||
currentthinker = currentthinker->next)
|
||||
{
|
||||
if (currentthinker->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (currentthinker->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mobj = (mobj_t *)currentthinker;
|
||||
@@ -3431,7 +3431,7 @@ void P_SaveNetGame(savebuffer_t *save, boolean resending)
|
||||
{
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mobj = (mobj_t *)th;
|
||||
|
||||
+34
-33
@@ -1302,7 +1302,7 @@ static void P_AddExecutorDelay(line_t *line, mobj_t *mobj, sector_t *sector)
|
||||
|
||||
e = Z_Calloc(sizeof (*e), PU_LEVSPEC, NULL);
|
||||
|
||||
e->thinker.function.acp1 = (actionf_p1)T_ExecutorDelay;
|
||||
e->thinker.function = (actionf_p1)T_ExecutorDelay;
|
||||
e->line = line;
|
||||
e->sector = sector;
|
||||
e->timer = (line->backsector->ceilingheight>>FRACBITS)+(line->backsector->floorheight>>FRACBITS);
|
||||
@@ -2602,7 +2602,7 @@ static void P_ProcessLineSpecial(line_t *line, mobj_t *mo, sector_t *callsec)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)T_Scroll)
|
||||
if (th->function != (actionf_p1)T_Scroll)
|
||||
continue;
|
||||
|
||||
scroller = (scroll_t *)th;
|
||||
@@ -2937,7 +2937,7 @@ void P_SetupSignExit(player_t *player)
|
||||
// spin all signposts in the level then.
|
||||
for (think = thinkercap.next; think != &thinkercap; think = think->next)
|
||||
{
|
||||
if (think->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (think->function != (actionf_p1)P_MobjThinker)
|
||||
continue; // not a mobj thinker
|
||||
|
||||
thing = (mobj_t *)think;
|
||||
@@ -2986,7 +2986,7 @@ boolean P_IsFlagAtBase(mobjtype_t flag)
|
||||
|
||||
for (think = thinkercap.next; think != &thinkercap; think = think->next)
|
||||
{
|
||||
if (think->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (think->function != (actionf_p1)P_MobjThinker)
|
||||
continue; // not a mobj thinker
|
||||
|
||||
mo = (mobj_t *)think;
|
||||
@@ -3419,7 +3419,7 @@ void P_ProcessSpecialSector(player_t *player, sector_t *sector, sector_t *rovers
|
||||
// The chimps are my friends.. heeheeheheehehee..... - LouisJM
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -3760,7 +3760,7 @@ DoneSection2:
|
||||
// to find the first waypoint
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -3833,7 +3833,7 @@ DoneSection2:
|
||||
// to find the last waypoint
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -3889,6 +3889,7 @@ DoneSection2:
|
||||
{
|
||||
if (!playeringame[i] || players[i].spectator)
|
||||
continue;
|
||||
|
||||
nump++;
|
||||
}
|
||||
|
||||
@@ -4044,7 +4045,7 @@ DoneSection2:
|
||||
// to find the first waypoint
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -4082,7 +4083,7 @@ DoneSection2:
|
||||
// Find waypoint before this one (waypointlow)
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -4109,7 +4110,7 @@ DoneSection2:
|
||||
// Find waypoint after this one (waypointhigh)
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -4799,7 +4800,7 @@ static ffloor_t *P_AddFakeFloor(sector_t *sec, sector_t *sec2, line_t *master, f
|
||||
break;
|
||||
|
||||
// Should this FOF have spikeness?
|
||||
if (th->function.acp1 == (actionf_p1)T_SpikeSector)
|
||||
if (th->function == (actionf_p1)T_SpikeSector)
|
||||
{
|
||||
lst = (levelspecthink_t *)th;
|
||||
|
||||
@@ -4807,7 +4808,7 @@ static ffloor_t *P_AddFakeFloor(sector_t *sec, sector_t *sec2, line_t *master, f
|
||||
P_AddSpikeThinker(sec, (INT32)sec2num);
|
||||
}
|
||||
// Should this FOF have friction?
|
||||
else if(th->function.acp1 == (actionf_p1)T_Friction)
|
||||
else if(th->function == (actionf_p1)T_Friction)
|
||||
{
|
||||
f = (friction_t *)th;
|
||||
|
||||
@@ -4815,7 +4816,7 @@ static ffloor_t *P_AddFakeFloor(sector_t *sec, sector_t *sec2, line_t *master, f
|
||||
Add_Friction(f->friction, f->movefactor, (INT32)(sec-sectors), f->affectee);
|
||||
}
|
||||
// Should this FOF have wind/current/pusher?
|
||||
else if(th->function.acp1 == (actionf_p1)T_Pusher)
|
||||
else if(th->function == (actionf_p1)T_Pusher)
|
||||
{
|
||||
p = (pusher_t *)th;
|
||||
|
||||
@@ -4906,7 +4907,7 @@ static void P_AddSpikeThinker(sector_t *sec, INT32 referrer)
|
||||
spikes = Z_Calloc(sizeof (*spikes), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&spikes->thinker);
|
||||
|
||||
spikes->thinker.function.acp1 = (actionf_p1)T_SpikeSector;
|
||||
spikes->thinker.function = (actionf_p1)T_SpikeSector;
|
||||
|
||||
spikes->sector = sec;
|
||||
spikes->vars[0] = referrer;
|
||||
@@ -4928,7 +4929,7 @@ static void P_AddFloatThinker(sector_t *sec, INT32 tag, line_t *sourceline)
|
||||
floater = Z_Calloc(sizeof (*floater), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&floater->thinker);
|
||||
|
||||
floater->thinker.function.acp1 = (actionf_p1)T_FloatSector;
|
||||
floater->thinker.function = (actionf_p1)T_FloatSector;
|
||||
|
||||
floater->sector = sec;
|
||||
floater->vars[0] = tag;
|
||||
@@ -4957,7 +4958,7 @@ static void P_AddBlockThinker(sector_t *sec, line_t *sourceline)
|
||||
block = Z_Calloc(sizeof (*block), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&block->thinker);
|
||||
|
||||
block->thinker.function.acp1 = (actionf_p1)T_MarioBlockChecker;
|
||||
block->thinker.function = (actionf_p1)T_MarioBlockChecker;
|
||||
block->sourceline = sourceline;
|
||||
|
||||
block->sector = sec;
|
||||
@@ -4986,7 +4987,7 @@ static void P_AddRaiseThinker(sector_t *sec, line_t *sourceline)
|
||||
raise = Z_Calloc(sizeof (*raise), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&raise->thinker);
|
||||
|
||||
raise->thinker.function.acp1 = (actionf_p1)T_RaiseSector;
|
||||
raise->thinker.function = (actionf_p1)T_RaiseSector;
|
||||
|
||||
if (sourceline->flags & ML_BLOCKMONSTERS)
|
||||
raise->vars[0] = 1;
|
||||
@@ -5029,7 +5030,7 @@ static void P_AddOldAirbob(sector_t *sec, line_t *sourceline, boolean noadjust)
|
||||
airbob = Z_Calloc(sizeof (*airbob), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&airbob->thinker);
|
||||
|
||||
airbob->thinker.function.acp1 = (actionf_p1)T_RaiseSector;
|
||||
airbob->thinker.function = (actionf_p1)T_RaiseSector;
|
||||
|
||||
// set up the fields
|
||||
airbob->sector = sec;
|
||||
@@ -5094,7 +5095,7 @@ static inline void P_AddThwompThinker(sector_t *sec, sector_t *actionsector, lin
|
||||
thwomp = Z_Calloc(sizeof (*thwomp), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&thwomp->thinker);
|
||||
|
||||
thwomp->thinker.function.acp1 = (actionf_p1)T_ThwompSector;
|
||||
thwomp->thinker.function = (actionf_p1)T_ThwompSector;
|
||||
|
||||
// set up the fields according to the type of elevator action
|
||||
thwomp->sector = sec;
|
||||
@@ -5135,7 +5136,7 @@ static inline void P_AddNoEnemiesThinker(sector_t *sec, line_t *sourceline)
|
||||
nobaddies = Z_Calloc(sizeof (*nobaddies), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&nobaddies->thinker);
|
||||
|
||||
nobaddies->thinker.function.acp1 = (actionf_p1)T_NoEnemiesSector;
|
||||
nobaddies->thinker.function = (actionf_p1)T_NoEnemiesSector;
|
||||
|
||||
nobaddies->sector = sec;
|
||||
nobaddies->sourceline = sourceline;
|
||||
@@ -5157,7 +5158,7 @@ static inline void P_AddEachTimeThinker(sector_t *sec, line_t *sourceline)
|
||||
eachtime = Z_Calloc(sizeof (*eachtime), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&eachtime->thinker);
|
||||
|
||||
eachtime->thinker.function.acp1 = (actionf_p1)T_EachTimeThinker;
|
||||
eachtime->thinker.function = (actionf_p1)T_EachTimeThinker;
|
||||
|
||||
eachtime->sector = sec;
|
||||
eachtime->sourceline = sourceline;
|
||||
@@ -5179,7 +5180,7 @@ static inline void P_AddCameraScanner(sector_t *sourcesec, sector_t *actionsecto
|
||||
elevator = Z_Calloc(sizeof (*elevator), PU_LEVSPEC, NULL);
|
||||
P_AddThinker(&elevator->thinker);
|
||||
|
||||
elevator->thinker.function.acp1 = (actionf_p1)T_CameraScanner;
|
||||
elevator->thinker.function = (actionf_p1)T_CameraScanner;
|
||||
elevator->type = elevateBounce;
|
||||
|
||||
// set up the fields according to the type of elevator action
|
||||
@@ -5268,7 +5269,7 @@ static inline void EV_AddLaserThinker(sector_t *sec, sector_t *sec2, line_t *lin
|
||||
|
||||
P_AddThinker(&flash->thinker);
|
||||
|
||||
flash->thinker.function.acp1 = (actionf_p1)T_LaserFlash;
|
||||
flash->thinker.function = (actionf_p1)T_LaserFlash;
|
||||
flash->ffloor = ffloor;
|
||||
flash->sector = sec; // For finding mobjs
|
||||
flash->sec = sec2;
|
||||
@@ -5382,11 +5383,11 @@ void P_SpawnSpecials(INT32 fromnetsave, boolean reloadinggamestate)
|
||||
// Firstly, find out how many there are in each sector
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 == (actionf_p1)T_SpikeSector)
|
||||
if (th->function == (actionf_p1)T_SpikeSector)
|
||||
secthinkers[((levelspecthink_t *)th)->sector - sectors].count++;
|
||||
else if (th->function.acp1 == (actionf_p1)T_Friction)
|
||||
else if (th->function == (actionf_p1)T_Friction)
|
||||
secthinkers[((friction_t *)th)->affectee].count++;
|
||||
else if (th->function.acp1 == (actionf_p1)T_Pusher)
|
||||
else if (th->function == (actionf_p1)T_Pusher)
|
||||
secthinkers[((pusher_t *)th)->affectee].count++;
|
||||
}
|
||||
|
||||
@@ -5404,11 +5405,11 @@ void P_SpawnSpecials(INT32 fromnetsave, boolean reloadinggamestate)
|
||||
{
|
||||
size_t secnum = (size_t)-1;
|
||||
|
||||
if (th->function.acp1 == (actionf_p1)T_SpikeSector)
|
||||
if (th->function == (actionf_p1)T_SpikeSector)
|
||||
secnum = ((levelspecthink_t *)th)->sector - sectors;
|
||||
else if (th->function.acp1 == (actionf_p1)T_Friction)
|
||||
else if (th->function == (actionf_p1)T_Friction)
|
||||
secnum = ((friction_t *)th)->affectee;
|
||||
else if (th->function.acp1 == (actionf_p1)T_Pusher)
|
||||
else if (th->function == (actionf_p1)T_Pusher)
|
||||
secnum = ((pusher_t *)th)->affectee;
|
||||
|
||||
if (secnum != (size_t)-1)
|
||||
@@ -6632,7 +6633,7 @@ void T_Scroll(scroll_t *s)
|
||||
static void Add_Scroller(INT32 type, fixed_t dx, fixed_t dy, INT32 control, INT32 affectee, INT32 accel, INT32 exclusive)
|
||||
{
|
||||
scroll_t *s = Z_Calloc(sizeof *s, PU_LEVSPEC, NULL);
|
||||
s->thinker.function.acp1 = (actionf_p1)T_Scroll;
|
||||
s->thinker.function = (actionf_p1)T_Scroll;
|
||||
s->type = type;
|
||||
s->dx = dx;
|
||||
s->dy = dy;
|
||||
@@ -6802,7 +6803,7 @@ static void Add_MasterDisappearer(tic_t appeartime, tic_t disappeartime, tic_t o
|
||||
{
|
||||
disappear_t *d = Z_Malloc(sizeof *d, PU_LEVSPEC, NULL);
|
||||
|
||||
d->thinker.function.acp1 = (actionf_p1)T_Disappear;
|
||||
d->thinker.function = (actionf_p1)T_Disappear;
|
||||
d->appeartime = appeartime;
|
||||
d->disappeartime = disappeartime;
|
||||
d->offset = offset;
|
||||
@@ -6887,7 +6888,7 @@ static void Add_Friction(INT32 friction, INT32 movefactor, INT32 affectee, INT32
|
||||
{
|
||||
friction_t *f = Z_Calloc(sizeof *f, PU_LEVSPEC, NULL);
|
||||
|
||||
f->thinker.function.acp1 = (actionf_p1)T_Friction;
|
||||
f->thinker.function = (actionf_p1)T_Friction;
|
||||
f->friction = friction;
|
||||
f->movefactor = movefactor;
|
||||
f->affectee = affectee;
|
||||
@@ -7042,7 +7043,7 @@ static void Add_Pusher(pushertype_e type, fixed_t x_mag, fixed_t y_mag, mobj_t *
|
||||
{
|
||||
pusher_t *p = Z_Calloc(sizeof *p, PU_LEVSPEC, NULL);
|
||||
|
||||
p->thinker.function.acp1 = (actionf_p1)T_Pusher;
|
||||
p->thinker.function = (actionf_p1)T_Pusher;
|
||||
p->source = source;
|
||||
p->type = type;
|
||||
p->x_mag = x_mag>>FRACBITS;
|
||||
|
||||
+17
-13
@@ -115,7 +115,7 @@ void Command_Numthinkers_f(void)
|
||||
|
||||
for (think = listtype->next; think != listtype; think = think->next)
|
||||
{
|
||||
if (think->function.acp1 != action)
|
||||
if (think->function != action)
|
||||
continue;
|
||||
|
||||
count++;
|
||||
@@ -152,7 +152,7 @@ void Command_CountMobjs_f(void)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
if (((mobj_t *)th)->type == i)
|
||||
@@ -172,7 +172,7 @@ void Command_CountMobjs_f(void)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
if (((mobj_t *)th)->type == i)
|
||||
@@ -207,7 +207,7 @@ void P_AddThinker(thinker_t *thinker)
|
||||
|
||||
thinker->references = 0; // killough 11/98: init reference counter to 0
|
||||
|
||||
thinker->cachable = (thinker->function.acp1 == (actionf_p1)P_MobjThinker);
|
||||
thinker->cachable = (thinker->function == (actionf_p1)P_MobjThinker);
|
||||
#ifdef PARANOIA
|
||||
thinker->debug_mobjtype = MT_NULL;
|
||||
#endif
|
||||
@@ -235,7 +235,7 @@ void P_AddPrecipThinker(thinker_t *thinker)
|
||||
#ifdef PARANOIA
|
||||
static const char *MobjTypeName(const mobj_t *mobj)
|
||||
{
|
||||
actionf_p1 p1 = mobj->thinker.function.acp1;
|
||||
actionf_p1 p1 = mobj->thinker.function;
|
||||
|
||||
if (p1 == (actionf_p1)P_MobjThinker)
|
||||
{
|
||||
@@ -254,7 +254,7 @@ static const char *MobjTypeName(const mobj_t *mobj)
|
||||
|
||||
static const char *MobjThinkerName(const mobj_t *mobj)
|
||||
{
|
||||
actionf_p1 p1 = mobj->thinker.function.acp1;
|
||||
actionf_p1 p1 = mobj->thinker.function;
|
||||
|
||||
if (p1 == (actionf_p1)P_MobjThinker)
|
||||
{
|
||||
@@ -371,7 +371,7 @@ void P_UnlinkThinker(thinker_t *thinker)
|
||||
void P_RemoveThinker(thinker_t *thinker)
|
||||
{
|
||||
LUA_InvalidateUserdata(thinker);
|
||||
thinker->function.acp1 = (actionf_p1)P_RemoveThinkerDelayed;
|
||||
thinker->function = (actionf_p1)P_RemoveThinkerDelayed;
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -455,9 +455,9 @@ static inline void P_RunThinkers(void)
|
||||
for (currentthinker = thinkercap.next; currentthinker != &thinkercap; currentthinker = currentthinker->next)
|
||||
{
|
||||
#ifdef PARANOIA
|
||||
I_Assert(currentthinker->function.acp1 != NULL);
|
||||
I_Assert(currentthinker->function != NULL);
|
||||
#endif
|
||||
currentthinker->function.acp1(currentthinker);
|
||||
currentthinker->function(currentthinker);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -610,7 +610,7 @@ static inline void P_ResetSpriteStuff(void)
|
||||
{
|
||||
mobj_t *mo;
|
||||
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker) // not a mobj
|
||||
if (th->function != (actionf_p1)P_MobjThinker) // not a mobj
|
||||
continue;
|
||||
|
||||
mo = (mobj_t *)th;
|
||||
@@ -734,8 +734,10 @@ void P_Ticker(boolean run)
|
||||
|
||||
PS_START_TIMING(ps_playerthink_time);
|
||||
for (i = 0; i < MAXPLAYERS; i++)
|
||||
if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo))
|
||||
{
|
||||
if (playeringame[i] && !P_MobjWasRemoved(players[i].mo))
|
||||
P_PlayerThink(&players[i]);
|
||||
}
|
||||
PS_STOP_TIMING(ps_playerthink_time);
|
||||
}
|
||||
|
||||
@@ -754,8 +756,10 @@ void P_Ticker(boolean run)
|
||||
|
||||
// Run any "after all the other thinkers" stuff
|
||||
for (i = 0; i < MAXPLAYERS; i++)
|
||||
if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo))
|
||||
{
|
||||
if (playeringame[i] && !P_MobjWasRemoved(players[i].mo))
|
||||
P_PlayerAfterThink(&players[i]);
|
||||
}
|
||||
|
||||
// Apply rumble to local players
|
||||
if (!demo.playback)
|
||||
@@ -957,7 +961,7 @@ void P_PreTicker(INT32 frames)
|
||||
if (!playeringame[i])
|
||||
continue;
|
||||
|
||||
if (!players[i].mo || P_MobjWasRemoved(players[i].mo))
|
||||
if (P_MobjWasRemoved(players[i].mo))
|
||||
continue;
|
||||
|
||||
P_PlayerAfterThink(&players[i]);
|
||||
|
||||
+15
-11
@@ -552,9 +552,13 @@ static UINT8 getPlayerPos(player_t *player)
|
||||
{
|
||||
UINT8 pos = 1;
|
||||
|
||||
for (int i = 0; i < MAXPLAYERS; ++i) {
|
||||
if (!playeringame[i] || players[i].spectator) continue;
|
||||
if (players[i].marescore > player->marescore) ++pos;
|
||||
for (UINT8 i = 0; i < MAXPLAYERS; ++i)
|
||||
{
|
||||
if (!playeringame[i] || players[i].spectator)
|
||||
continue;
|
||||
|
||||
if (players[i].marescore > player->marescore)
|
||||
++pos;
|
||||
}
|
||||
|
||||
return pos;
|
||||
@@ -1064,7 +1068,7 @@ void P_SpawnShieldOrb(player_t *player)
|
||||
// blaze through the thinkers to see if an orb already exists!
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
shieldobj = (mobj_t *)th;
|
||||
@@ -1780,7 +1784,7 @@ void P_Telekinesis(player_t *player, fixed_t thrust, fixed_t range)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -2506,7 +2510,7 @@ static void P_DoZoomTube(player_t *player)
|
||||
// Find next waypoint
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
if (th->function != (actionf_p1)P_MobjThinker) // Not a mobj thinker
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -2596,7 +2600,7 @@ void P_NukeEnemies(mobj_t *inflictor, mobj_t *source, fixed_t radius)
|
||||
|
||||
for (think = thinkercap.next; think != &thinkercap; think = think->next)
|
||||
{
|
||||
if (think->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (think->function != (actionf_p1)P_MobjThinker)
|
||||
continue; // not a mobj thinker
|
||||
|
||||
mo = (mobj_t *)think;
|
||||
@@ -2673,7 +2677,7 @@ boolean P_LookForEnemies(player_t *player)
|
||||
|
||||
for (think = thinkercap.next; think != &thinkercap; think = think->next)
|
||||
{
|
||||
if (think->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (think->function != (actionf_p1)P_MobjThinker)
|
||||
continue; // not a mobj thinker
|
||||
|
||||
mo = (mobj_t *)think;
|
||||
@@ -2797,7 +2801,7 @@ void P_FindEmerald(void)
|
||||
// to find all emeralds
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
@@ -4245,7 +4249,7 @@ static void P_CalcPostImg(player_t *player, camera_t *thiscam)
|
||||
else
|
||||
pviewheight = player->mo->z + player->viewheight;
|
||||
|
||||
if (player->awayviewtics && player->awayviewmobj && !P_MobjWasRemoved(player->awayviewmobj))
|
||||
if (player->awayviewtics && !P_MobjWasRemoved(player->awayviewmobj))
|
||||
{
|
||||
sector = player->awayviewmobj->subsector->sector;
|
||||
pviewheight = player->awayviewmobj->z + 20*FRACUNIT;
|
||||
@@ -4776,7 +4780,7 @@ void P_PlayerThink(player_t *player)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
mo2 = (mobj_t *)th;
|
||||
|
||||
+1
-1
@@ -1865,7 +1865,7 @@ static void R_PrecacheLevelSprites(void)
|
||||
|
||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||
{
|
||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||
if (th->function != (actionf_p1)P_MobjThinker)
|
||||
continue;
|
||||
|
||||
spritepresent[((mobj_t *)th)->sprite] = 1;
|
||||
|
||||
+8
-20
@@ -42,13 +42,13 @@ static CV_PossibleValue_t fpscap_cons_t[] = {
|
||||
{0, NULL}
|
||||
};
|
||||
|
||||
consvar_t cv_fpscap = {"fpscap", "Match refresh rate", CV_SAVE, fpscap_cons_t, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_fpscap = {"fpscap", "Match refresh rate", CV_SAVE, fpscap_cons_t, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_fpscapbg = {"fpscapbackground", "Match refresh rate", CV_SAVE, fpscap_cons_t, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
consvar_t cv_precipinterp = {"precipinterpolation", "On", CV_SAVE, CV_OnOff, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
ps_metric_t ps_interp_frac = {0};
|
||||
ps_metric_t ps_interp_lag = {0};
|
||||
ps_metric_t ps_interp_lag = {0};
|
||||
|
||||
static boolean R_UseBackgroundFramerateCap(void)
|
||||
{
|
||||
@@ -67,21 +67,21 @@ static boolean R_UseBackgroundFramerateCap(void)
|
||||
return false;
|
||||
}
|
||||
|
||||
static UINT32 R_GetBackgroundFramerateCap(void)
|
||||
static UINT32 R_GetFrameCap(INT32 val)
|
||||
{
|
||||
if (cv_fpscapbg.value == 0)
|
||||
if (val == 0)
|
||||
{
|
||||
// 0: Match refresh rate
|
||||
return I_GetRefreshRate();
|
||||
}
|
||||
|
||||
if (cv_fpscapbg.value < 0)
|
||||
if (val < 0)
|
||||
{
|
||||
// -1: Unlimited
|
||||
return 0;
|
||||
}
|
||||
|
||||
return cv_fpscapbg.value;
|
||||
return val;
|
||||
}
|
||||
|
||||
UINT32 R_GetFramerateCap(void)
|
||||
@@ -95,22 +95,10 @@ UINT32 R_GetFramerateCap(void)
|
||||
|
||||
if (R_UseBackgroundFramerateCap())
|
||||
{
|
||||
return R_GetBackgroundFramerateCap();
|
||||
return R_GetFrameCap(cv_fpscapbg.value);
|
||||
}
|
||||
|
||||
if (cv_fpscap.value == 0)
|
||||
{
|
||||
// 0: Match refresh rate
|
||||
return I_GetRefreshRate();
|
||||
}
|
||||
|
||||
if (cv_fpscap.value < 0)
|
||||
{
|
||||
// -1: Unlimited
|
||||
return 0;
|
||||
}
|
||||
|
||||
return cv_fpscap.value;
|
||||
return R_GetFrameCap(cv_fpscap.value);
|
||||
}
|
||||
|
||||
boolean R_UsingFrameInterpolation(void)
|
||||
|
||||
+34
-32
@@ -1133,7 +1133,6 @@ static void R_SetupSkyScale(player_t *player, camera_t *thiscam, mapheader_t *mh
|
||||
{
|
||||
if (skyboxmo[1])
|
||||
{
|
||||
angle_t ang;
|
||||
fixed_t x = 0, y = 0;
|
||||
|
||||
if (mh->skybox_scalex > 0)
|
||||
@@ -1165,8 +1164,8 @@ static void R_SetupSkyScale(player_t *player, camera_t *thiscam, mapheader_t *mh
|
||||
newview->y -= x;
|
||||
break;
|
||||
default:
|
||||
ang = viewmobj->angle>>ANGLETOFINESHIFT;
|
||||
newview->x += FixedMul(x,FINECOSINE(ang)) - FixedMul(y, FINESINE(ang));
|
||||
angle_t ang = viewmobj->angle>>ANGLETOFINESHIFT;
|
||||
newview->x += FixedMul(x,FINECOSINE(ang)) - FixedMul(y, FINESINE(ang));
|
||||
newview->y += FixedMul(x, FINESINE(ang)) + FixedMul(y,FINECOSINE(ang));
|
||||
break;
|
||||
}
|
||||
@@ -1192,14 +1191,14 @@ static void R_SetupSkyScale(player_t *player, camera_t *thiscam, mapheader_t *mh
|
||||
}
|
||||
}
|
||||
|
||||
void R_SkyboxFrame(int s)
|
||||
void R_SkyboxFrame(UINT8 pnum)
|
||||
{
|
||||
player_t *player = &players[displayplayers[s]];
|
||||
camera_t *thiscam = &camera[s];
|
||||
subsector_t *subsector = NULL;
|
||||
player_t *player = &players[displayplayers[pnum]];
|
||||
camera_t *thiscam = &camera[pnum];
|
||||
sector_t *viewsec = NULL;
|
||||
mapheader_t *mh = mapheaderinfo[gamemap-1];
|
||||
|
||||
R_SetViewContext(static_cast<viewcontext_e>(VIEWCONTEXT_SKY1 + s));
|
||||
R_SetViewContext(static_cast<viewcontext_e>(VIEWCONTEXT_SKY1 + pnum));
|
||||
|
||||
// cut-away view stuff
|
||||
newview->sky = true;
|
||||
@@ -1215,35 +1214,38 @@ void R_SkyboxFrame(int s)
|
||||
|
||||
R_SetupAimingFrame(player, thiscam);
|
||||
|
||||
newview->angle += viewmobj->angle;
|
||||
if (!P_MobjWasRemoved(viewmobj))
|
||||
{
|
||||
newview->angle += viewmobj->angle;
|
||||
|
||||
newview->x = viewmobj->x;
|
||||
newview->y = viewmobj->y;
|
||||
newview->z = (viewmobj->spawnpoint) ? (((fixed_t)viewmobj->spawnpoint->angle)<<FRACBITS) : 0;
|
||||
newview->x = viewmobj->x;
|
||||
newview->y = viewmobj->y;
|
||||
newview->z = (viewmobj->spawnpoint) ? (((fixed_t)viewmobj->spawnpoint->angle) << FRACBITS) : 0;
|
||||
|
||||
if (viewmobj->subsector)
|
||||
viewsec = viewmobj->subsector->sector;
|
||||
}
|
||||
|
||||
if (mh)
|
||||
{
|
||||
R_SetupSkyScale(player, thiscam, mh);
|
||||
}
|
||||
|
||||
if (!P_MobjWasRemoved(viewmobj) && viewmobj->subsector && viewmobj->subsector->sector)
|
||||
subsector = viewmobj->subsector;
|
||||
|
||||
R_SetupCommonFrame(player, subsector->sector);
|
||||
R_SetupCommonFrame(player, viewsec);
|
||||
}
|
||||
|
||||
void R_SetupFrame(int s, boolean skybox)
|
||||
void R_SetupFrame(UINT8 pnum, boolean skybox)
|
||||
{
|
||||
player_t *player = &players[displayplayers[s]];
|
||||
camera_t *thiscam = &camera[s];
|
||||
boolean chasecam = (cv_chasecam[s].value);
|
||||
sector_t * sector = NULL;
|
||||
player_t *player = &players[displayplayers[pnum]];
|
||||
camera_t *thiscam = &camera[pnum];
|
||||
boolean chasecam = (cv_chasecam[pnum].value);
|
||||
sector_t *viewsec = NULL;
|
||||
|
||||
R_SetViewContext(static_cast<viewcontext_e>(VIEWCONTEXT_PLAYER1 + s));
|
||||
R_SetViewContext(static_cast<viewcontext_e>(VIEWCONTEXT_PLAYER1 + pnum));
|
||||
|
||||
if (thiscam->reset)
|
||||
{
|
||||
R_ResetViewInterpolation(s);
|
||||
R_ResetViewInterpolation(pnum);
|
||||
thiscam->reset = false;
|
||||
}
|
||||
|
||||
@@ -1278,10 +1280,10 @@ void R_SetupFrame(int s, boolean skybox)
|
||||
newview->y = viewmobj->y;
|
||||
newview->z = viewmobj->z + 20*FRACUNIT;
|
||||
|
||||
if (viewmobj->subsector && viewmobj->subsector->sector)
|
||||
sector = viewmobj->subsector->sector;
|
||||
if (viewmobj->subsector)
|
||||
viewsec = viewmobj->subsector->sector;
|
||||
|
||||
R_SetupCommonFrame(player, sector);
|
||||
R_SetupCommonFrame(player, viewsec);
|
||||
}
|
||||
else if (thiscam && chasecam) // use outside cam view
|
||||
{
|
||||
@@ -1292,10 +1294,10 @@ void R_SetupFrame(int s, boolean skybox)
|
||||
newview->y = thiscam->y;
|
||||
newview->z = thiscam->z + (thiscam->height>>1);
|
||||
|
||||
if (thiscam->subsector && thiscam->subsector->sector)
|
||||
sector = thiscam->subsector->sector;
|
||||
if (thiscam->subsector)
|
||||
viewsec = thiscam->subsector->sector;
|
||||
|
||||
R_SetupCommonFrame(player, sector);
|
||||
R_SetupCommonFrame(player, viewsec);
|
||||
}
|
||||
else if (player->mo) // use the player's eyes view
|
||||
{
|
||||
@@ -1306,10 +1308,10 @@ void R_SetupFrame(int s, boolean skybox)
|
||||
newview->y = viewmobj->y;
|
||||
newview->z = player->viewz;
|
||||
|
||||
if (viewmobj->subsector && viewmobj->subsector->sector)
|
||||
sector = viewmobj->subsector->sector;
|
||||
if (viewmobj->subsector)
|
||||
viewsec = viewmobj->subsector->sector;
|
||||
|
||||
R_SetupCommonFrame(player, sector);
|
||||
R_SetupCommonFrame(player, viewsec);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -215,8 +215,8 @@ void R_SetViewSize(void);
|
||||
void R_ExecuteSetViewSize(void);
|
||||
|
||||
fixed_t R_GetPlayerFov(player_t *player);
|
||||
void R_SkyboxFrame(int s);
|
||||
void R_SetupFrame(int s, boolean skybox);
|
||||
void R_SkyboxFrame(UINT8 pnum);
|
||||
void R_SetupFrame(UINT8 pnum, boolean skybox);
|
||||
|
||||
// Called by G_Drawer.
|
||||
void R_RenderPlayerView(player_t *player);
|
||||
|
||||
+5
-1
@@ -66,7 +66,9 @@ static void Highreshudscale_OnChange(void)
|
||||
|
||||
static void SCR_ChangeFullscreen (void);
|
||||
|
||||
consvar_t cv_fullscreen = {"fullscreen", "Yes", CV_SAVE|CV_CALL, CV_YesNo, SCR_ChangeFullscreen, 0, NULL, NULL, 0, 0, NULL};
|
||||
static CV_PossibleValue_t fullscreen_cons_t[] = {{0, "No"}, {1, "Yes"}, {2, "Borderless Window"}, {0, NULL}};
|
||||
|
||||
consvar_t cv_fullscreen = {"fullscreen", "Yes", CV_SAVE|CV_CALL, fullscreen_cons_t, SCR_ChangeFullscreen, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
static CV_PossibleValue_t accuratefps_cons_t[] = {{0, "Inaccurate"}, {1, "Accurate"}, {0, NULL}};
|
||||
consvar_t cv_accuratefps = {"fpssampling", "1", CV_SAVE, accuratefps_cons_t, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
@@ -325,6 +327,8 @@ void SCR_SetDefaultMode(void)
|
||||
void SCR_ChangeFullscreen(void)
|
||||
{
|
||||
#ifdef DIRECTFULLSCREEN
|
||||
I_SetBorderlessWindow(); // Running this here so we can have borderless window at startup
|
||||
|
||||
// allow_fullscreen is set by VID_PrepareModeList
|
||||
// it is used to prevent switching to fullscreen during startup
|
||||
if (!allow_fullscreen)
|
||||
|
||||
+8
-1
@@ -150,7 +150,7 @@ UINT8 graphics_started = 0; // Is used in console.c and screen.c
|
||||
// To disable fullscreen at startup; is set in VID_PrepareModeList
|
||||
boolean allow_fullscreen = false;
|
||||
static SDL_bool disable_fullscreen = SDL_FALSE;
|
||||
#define USE_FULLSCREEN (disable_fullscreen||!allow_fullscreen)?0:cv_fullscreen.value
|
||||
#define USE_FULLSCREEN (disable_fullscreen||!allow_fullscreen)? 0: (cv_fullscreen.value == 1)
|
||||
static SDL_bool disable_mouse = SDL_FALSE;
|
||||
#define USE_MOUSEINPUT (!disable_mouse && cv_usemouse.value && havefocus)
|
||||
#define MOUSE_MENU false //(!disable_mouse && cv_usemouse.value && menuactive && !USE_FULLSCREEN)
|
||||
@@ -1353,6 +1353,7 @@ static void SDLSetMode(INT32 width, INT32 height, SDL_bool fullscreen)
|
||||
{
|
||||
wasfullscreen = SDL_TRUE;
|
||||
SDL_SetWindowFullscreen(window, SDL_WINDOW_FULLSCREEN_DESKTOP);
|
||||
I_SetBorderlessWindow();
|
||||
}
|
||||
else // windowed mode
|
||||
{
|
||||
@@ -2157,4 +2158,10 @@ static void Impl_SetVsync(void)
|
||||
#endif
|
||||
}
|
||||
|
||||
void I_SetBorderlessWindow(void)
|
||||
{
|
||||
SDL_bool borderless = (cv_fullscreen.value == 2) ? SDL_FALSE : SDL_TRUE;
|
||||
SDL_SetWindowBordered(window, borderless);
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -80,7 +80,7 @@ write netcode into the sound code, OKAY?
|
||||
#define GME_BASS 1.0f
|
||||
#endif // HAVE_GME
|
||||
|
||||
|
||||
|
||||
//static UINT16 BUFFERSIZE = 2048;
|
||||
static UINT16 SAMPLERATE = 44100;
|
||||
|
||||
@@ -710,7 +710,7 @@ static void mix_gme(void *udata, Uint8 *stream, int len)
|
||||
|
||||
// play gme into stream
|
||||
gme_play(gme, len/2, (short *)stream);
|
||||
|
||||
|
||||
// Limiter to prevent music from being disorted with some formats
|
||||
if (music_volume >= 18)
|
||||
music_volume = 18;
|
||||
@@ -726,7 +726,7 @@ static void mix_openmpt(void *udata, Uint8 *stream, int len)
|
||||
{
|
||||
int i;
|
||||
short *p;
|
||||
|
||||
|
||||
(void)udata;
|
||||
|
||||
if (!openmpt_mhandle || songpaused)
|
||||
@@ -734,7 +734,7 @@ static void mix_openmpt(void *udata, Uint8 *stream, int len)
|
||||
|
||||
// Play module into stream
|
||||
openmpt_module_read_interleaved_stereo(openmpt_mhandle, SAMPLERATE, cv_audbuffersize.value, (short *)stream);
|
||||
|
||||
|
||||
// Limiter to prevent music from being disorted with some formats
|
||||
if (music_volume >= 18)
|
||||
music_volume = 18;
|
||||
@@ -823,7 +823,7 @@ boolean I_SetSongSpeed(float speed)
|
||||
#endif
|
||||
#ifdef HAVE_OPENMPT
|
||||
if (openmpt_mhandle)
|
||||
{
|
||||
{
|
||||
if (speed > 4.0f)
|
||||
speed = 4.0f; // Limit this to 4x to prevent crashing, stupid fix but... ~SteelT 27/9/19
|
||||
#if OPENMPT_API_VERSION_MAJOR < 1 && OPENMPT_API_VERSION_MINOR < 5
|
||||
|
||||
+17
-16
@@ -419,27 +419,28 @@ static void ST_drawDebugInfo(void)
|
||||
|
||||
static void ST_drawLevelTitle(void)
|
||||
{
|
||||
char *lvlttl = mapheaderinfo[gamemap-1]->lvlttl;
|
||||
char *subttl = mapheaderinfo[gamemap-1]->subttl;
|
||||
char *zonttl = mapheaderinfo[gamemap-1]->zonttl; // SRB2kart
|
||||
char *actnum = mapheaderinfo[gamemap-1]->actnum;
|
||||
INT32 lvlttlxpos;
|
||||
INT32 ttlnumxpos;
|
||||
INT32 zonexpos;
|
||||
INT32 dupcalc = (vid.width/vid.dupx);
|
||||
UINT8 gtc = G_GetGametypeColor(gametype);
|
||||
char *lvlttl, *subttl, *zonttl, *actnum;
|
||||
INT32 lvlttlxpos, ttlnumxpos, zonexpos;
|
||||
INT32 dupcalc;
|
||||
UINT8 gtc;
|
||||
INT32 sub = 0;
|
||||
INT32 bary = (splitscreen)
|
||||
? BASEVIDHEIGHT/2
|
||||
: 163;
|
||||
INT32 bary;
|
||||
INT32 lvlw;
|
||||
|
||||
if (!cv_stagetitle.value)
|
||||
if (!cv_stagetitle.value || (timeinmap > 113))
|
||||
return;
|
||||
|
||||
if (timeinmap > 113)
|
||||
if (*mapheaderinfo[gamemap-1]->lvlttl == '\0')
|
||||
return;
|
||||
|
||||
lvlttl = mapheaderinfo[gamemap-1]->lvlttl;
|
||||
subttl = mapheaderinfo[gamemap-1]->subttl;
|
||||
zonttl = mapheaderinfo[gamemap-1]->zonttl; // SRB2kart
|
||||
actnum = mapheaderinfo[gamemap-1]->actnum;
|
||||
dupcalc = (vid.width/vid.dupx);
|
||||
gtc = G_GetGametypeColor(gametype);
|
||||
bary = (splitscreen) ? BASEVIDHEIGHT/2 : 163;
|
||||
|
||||
lvlw = V_LevelNameWidth(lvlttl);
|
||||
|
||||
if (actnum[0])
|
||||
@@ -603,7 +604,7 @@ static void ST_overlayDrawer(void)
|
||||
}
|
||||
|
||||
// draw level title Tails
|
||||
if (*mapheaderinfo[gamemap-1]->lvlttl != '\0' && !(hu_showscores && (netgame || multiplayer) && !mapreset) && LUA_HudEnabled(hud_stagetitle) && !forceshowhud)
|
||||
if (!(hu_showscores && (netgame || multiplayer) && !mapreset) && LUA_HudEnabled(hud_stagetitle) && !forceshowhud)
|
||||
ST_drawLevelTitle();
|
||||
|
||||
if (!hu_showscores && netgame && !mapreset)
|
||||
@@ -740,7 +741,7 @@ void ST_Drawer(void)
|
||||
UINT8 i;
|
||||
|
||||
#ifdef SEENAMES
|
||||
if (cv_seenames.value && cv_allowseenames.value && displayplayers[0] == consoleplayer && seenplayer && seenplayer->mo && !mapreset)
|
||||
if (UNLIKELY(cv_seenames.value && cv_allowseenames.value && displayplayers[0] == consoleplayer && seenplayer && seenplayer->mo && !mapreset))
|
||||
{
|
||||
if (cv_seenames.value == 1)
|
||||
V_DrawCenteredString(BASEVIDWIDTH/2, BASEVIDHEIGHT/2 + 15, V_HUDTRANSHALF, player_names[seenplayer-players]);
|
||||
|
||||
Reference in new issue
Block a user