diff --git a/wadsrc/static/zscript/actors/actor.zs b/wadsrc/static/zscript/actors/actor.zs index fe8feefc3c..dae1176bd4 100644 --- a/wadsrc/static/zscript/actors/actor.zs +++ b/wadsrc/static/zscript/actors/actor.zs @@ -86,7 +86,7 @@ class Actor : Thinker native const LARGE_MASS = 10000000; // not INT_MAX on purpose const ORIG_FRICTION = (0xE800/65536.); // original value const ORIG_FRICTION_FACTOR = (2048/65536.); // original value - const DEFMORPHTICS = 40 * TICRATE; + //const DEFMORPHTICS = 40 * TICRATE; const MELEEDELTA = 20; @@ -1146,8 +1146,8 @@ class Actor : Thinker native native void A_FadeOut(double reduce = 0.1, int flags = 1); //bool remove == true native void A_FadeTo(double target, double amount = 0.1, int flags = 0); native void A_SpawnDebris(class spawntype, bool transfer_translation = false, double mult_h = 1, double mult_v = 1); - native void A_SpawnParticle(color color1, int flags = 0, int lifetime = TICRATE, double size = 1, double angle = 0, double xoff = 0, double yoff = 0, double zoff = 0, double velx = 0, double vely = 0, double velz = 0, double accelx = 0, double accely = 0, double accelz = 0, double startalphaf = 1, double fadestepf = -1, double sizestep = 0); - native void A_SpawnParticleEx(color color1, TextureID texture, int style = STYLE_None, int flags = 0, int lifetime = TICRATE, double size = 1, double angle = 0, double xoff = 0, double yoff = 0, double zoff = 0, double velx = 0, double vely = 0, double velz = 0, double accelx = 0, double accely = 0, double accelz = 0, double startalphaf = 1, double fadestepf = -1, double sizestep = 0, double startroll = 0, double rollvel = 0, double rollacc = 0); + native void A_SpawnParticle(color color1, int flags = 0, int lifetime = DEFAULT_TICRATE, double size = 1, double angle = 0, double xoff = 0, double yoff = 0, double zoff = 0, double velx = 0, double vely = 0, double velz = 0, double accelx = 0, double accely = 0, double accelz = 0, double startalphaf = 1, double fadestepf = -1, double sizestep = 0); + native void A_SpawnParticleEx(color color1, TextureID texture, int style = STYLE_None, int flags = 0, int lifetime = DEFAULT_TICRATE, double size = 1, double angle = 0, double xoff = 0, double yoff = 0, double zoff = 0, double velx = 0, double vely = 0, double velz = 0, double accelx = 0, double accely = 0, double accelz = 0, double startalphaf = 1, double fadestepf = -1, double sizestep = 0, double startroll = 0, double rollvel = 0, double rollacc = 0); native void A_ExtChase(bool usemelee, bool usemissile, bool playactive = true, bool nightmarefast = false); native void A_DropInventory(class itemtype, int amount = -1); native void A_SetBlend(color color1, double alpha, int tics, color color2 = 0, double alpha2 = 0.); diff --git a/wadsrc/static/zscript/actors/heretic/ironlich.zs b/wadsrc/static/zscript/actors/heretic/ironlich.zs index b7831f0457..e0bc9b0d19 100644 --- a/wadsrc/static/zscript/actors/heretic/ironlich.zs +++ b/wadsrc/static/zscript/actors/heretic/ironlich.zs @@ -123,7 +123,7 @@ class Ironlich : Actor { mo.AddZ(-32); mo.tracer = targ; - mo.health = 20*TICRATE; // Duration + mo.health = 20*GameTicRate; // Duration A_StartSound ("ironlich/attack3", CHAN_BODY); } } diff --git a/wadsrc/static/zscript/actors/heretic/weaponphoenix.zs b/wadsrc/static/zscript/actors/heretic/weaponphoenix.zs index 3300c43d35..bdfbf0be14 100644 --- a/wadsrc/static/zscript/actors/heretic/weaponphoenix.zs +++ b/wadsrc/static/zscript/actors/heretic/weaponphoenix.zs @@ -66,7 +66,7 @@ class PhoenixRod : Weapon class PhoenixRodPowered : PhoenixRod { - const FLAME_THROWER_TICS = (10*TICRATE); + //const FLAME_THROWER_TICS = (10*TICRATE); private int FlameCount; // for flamethrower duration @@ -113,7 +113,7 @@ class PhoenixRodPowered : PhoenixRod PhoenixRodPowered flamethrower = PhoenixRodPowered(player.ReadyWeapon); if (flamethrower != null) { - flamethrower.FlameCount = FLAME_THROWER_TICS; + flamethrower.FlameCount = (10*GameTicRate) /*FLAME_THROWER_TICS*/; } } } diff --git a/wadsrc/static/zscript/actors/hexen/heresiarch.zs b/wadsrc/static/zscript/actors/hexen/heresiarch.zs index b62c6f3659..ec432bf8ab 100644 --- a/wadsrc/static/zscript/actors/hexen/heresiarch.zs +++ b/wadsrc/static/zscript/actors/hexen/heresiarch.zs @@ -26,7 +26,7 @@ class Heresiarch : Actor const SORCBALL_SPEED_ROTATIONS = 5; const SORC_DEFENSE_TIME = 255; const SORC_DEFENSE_HEIGHT = 45; - const BOUNCE_TIME_UNIT = (35/2); + //const BOUNCE_TIME_UNIT = (35/2); const SORCFX4_RAPIDFIRE_TIME = (6*3); // 3 seconds const SORCFX4_SPREAD_ANGLE = 20; @@ -453,7 +453,7 @@ class SorcBall : Actor Actor mo = parent.SpawnMissileAngle("SorcFX4", ang1, 0); if (mo) { - mo.special2 = 35*5/2; // 5 seconds + mo.special2 = (gameTicRate * 5) /2; // 5 seconds double dist = mo.DistanceBySpeed(dest, mo.Speed); mo.Vel.Z = (dest.pos.z - mo.pos.z) / dist; } @@ -532,7 +532,7 @@ class SorcBall : Actor Vel.X = random[Heresiarch](-5, 4); Vel.Y = random[Heresiarch](-5, 4); Vel.Z = random[Heresiarch](2, 4); - args[4] = Heresiarch.BOUNCE_TIME_UNIT; // Bounce time unit + args[4] = (GameTicRate / 2) /*BOUNCE_TIME_UNIT*/; args[3] = 5; // Bounce time in seconds } @@ -553,7 +553,7 @@ class SorcBall : Actor } else { - args[4] = Heresiarch.BOUNCE_TIME_UNIT; + args[4] = (GameTicRate / 2) /*BOUNCE_TIME_UNIT*/; } } } @@ -608,7 +608,7 @@ class SorcBall1 : SorcBall { mo.target = parent; mo.tracer = parent.target; - mo.args[4] = Heresiarch.BOUNCE_TIME_UNIT; + mo.args[4] = (GameTicRate / 2) /*BOUNCE_TIME_UNIT*/; mo.args[3] = 15; // Bounce time in seconds } mo = parent.SpawnMissileAngle (cls, ang2, 0); @@ -616,7 +616,7 @@ class SorcBall1 : SorcBall { mo.target = parent; mo.tracer = parent.target; - mo.args[4] = Heresiarch.BOUNCE_TIME_UNIT; + mo.args[4] = (GameTicRate / 2) /*BOUNCE_TIME_UNIT*/; mo.args[3] = 15; // Bounce time in seconds } } @@ -823,7 +823,7 @@ class SorcFX1 : Actor } else { - args[4] = Heresiarch.BOUNCE_TIME_UNIT; + args[4] = (GameTicRate / 2) /*BOUNCE_TIME_UNIT*/; } } A_SeekerMissile(2, 6); diff --git a/wadsrc/static/zscript/actors/hexen/korax.zs b/wadsrc/static/zscript/actors/hexen/korax.zs index fc4c3efd3a..49e6985dc6 100644 --- a/wadsrc/static/zscript/actors/hexen/korax.zs +++ b/wadsrc/static/zscript/actors/hexen/korax.zs @@ -36,7 +36,7 @@ class Korax : Actor const KORAX_COMMAND_HEIGHT = 120; const KORAX_COMMAND_OFFSET = 27; - const KORAX_SPIRIT_LIFETIME = 5*TICRATE/5; // 5 seconds + //const KORAX_SPIRIT_LIFETIME = 5*TICRATE/5; // 5 seconds Default { @@ -226,7 +226,7 @@ class Korax : Actor private void KSpiritInit (Actor spirit) { - spirit.health = KORAX_SPIRIT_LIFETIME; + spirit.health = (5*GameTicRate/5) /*KORAX_SPIRIT_LIFETIME*/; spirit.tracer = self; // Swarm around korax spirit.WeaveIndexZ = random[Kspiritnit](32, 39); // Float bob index diff --git a/wadsrc/static/zscript/actors/inventory/powerups.zs b/wadsrc/static/zscript/actors/inventory/powerups.zs index d257a9b203..2301fbd30f 100644 --- a/wadsrc/static/zscript/actors/inventory/powerups.zs +++ b/wadsrc/static/zscript/actors/inventory/powerups.zs @@ -1353,7 +1353,7 @@ class PowerTargeter : Powerup let player = Owner.player; PositionAccuracy (); - if (EffectTics < 5*TICRATE) + if (EffectTics < 5*GameTicRate) { let stat = FindState("Targeter"); diff --git a/wadsrc/static/zscript/actors/morph.zs b/wadsrc/static/zscript/actors/morph.zs index 1dcfb31faf..cc571e4f3a 100644 --- a/wadsrc/static/zscript/actors/morph.zs +++ b/wadsrc/static/zscript/actors/morph.zs @@ -128,7 +128,7 @@ extend class Actor morphed.RenderStyle = RenderStyle; morphed.Score = Score; - morphed.UnmorphTime = level.time + ((duration) ? duration : DEFMORPHTICS) + random[morphmonst](); + morphed.UnmorphTime = level.time + ((duration) ? duration : (40 * GameTicRate) /*DEFMORPHTICS*/) + random[morphmonst](); morphed.MorphStyle = style; morphed.MorphExitFlash = (exit_flash) ? exit_flash : (class)("TeleportFog"); morphed.FlagsSave = bSolid * 2 + bShootable * 4 + bInvisible * 0x40; // The factors are for savegame compatibility diff --git a/wadsrc/static/zscript/actors/player/player.zs b/wadsrc/static/zscript/actors/player/player.zs index bd5710e685..f4980d6f4f 100644 --- a/wadsrc/static/zscript/actors/player/player.zs +++ b/wadsrc/static/zscript/actors/player/player.zs @@ -14,7 +14,7 @@ class PlayerPawn : Actor { const CROUCHSPEED = (1./12); // [RH] # of ticks to complete a turn180 - const TURN180_TICKS = ((TICRATE / 4) + 1); + //const TURN180_TICKS = ((TICRATE / 4) + 1); // 16 pixels of bob const MAXBOB = 16.; @@ -1250,7 +1250,7 @@ class PlayerPawn : Actor if (player.turnticks) { player.turnticks--; - Angle += (180. / TURN180_TICKS); + Angle += (180. / ((GameTicRate / 4) + 1) /*TURN180_TICKS*/); } else { @@ -1486,7 +1486,7 @@ class PlayerPawn : Actor // [RH] Check for fast turn around if (player.cmd.buttons & BT_TURN180 && !(player.oldbuttons & BT_TURN180)) { - player.turnticks = TURN180_TICKS; + player.turnticks = ((GameTicRate / 4) + 1) /*TURN180_TICKS*/; } // Handle movement diff --git a/wadsrc/static/zscript/actors/player/player_inventory.zs b/wadsrc/static/zscript/actors/player/player_inventory.zs index 76593d2d2e..290e3e1710 100644 --- a/wadsrc/static/zscript/actors/player/player_inventory.zs +++ b/wadsrc/static/zscript/actors/player/player_inventory.zs @@ -78,7 +78,7 @@ extend class PlayerPawn } if (InvSel) InvSel.DisplayNameTag(); } - player.inventorytics = 5*TICRATE; + player.inventorytics = 5*GameTicRate; if (old != InvSel) { A_StartSound("misc/invchange", CHAN_AUTO, CHANF_DEFAULT, 1., ATTN_NONE); diff --git a/wadsrc/static/zscript/actors/player/player_morph.zs b/wadsrc/static/zscript/actors/player/player_morph.zs index 77df1ef269..857a934f3a 100644 --- a/wadsrc/static/zscript/actors/player/player_morph.zs +++ b/wadsrc/static/zscript/actors/player/player_morph.zs @@ -120,7 +120,7 @@ extend class PlayerPawn if (player.morphTics) { // Player is already a beast if ((GetClass() == spawntype) && bCanSuperMorph - && (player.morphTics < (((duration) ? duration : DEFMORPHTICS) - TICRATE)) + && (player.morphTics < (((duration) ? duration : (40 * GameTicRate) /*DEFMORPHTICS*/) - GameTicRate)) && FindInventory('PowerWeaponLevel2', true) == null) { // Make a super chicken GiveInventoryType ('PowerWeaponLevel2'); @@ -192,7 +192,7 @@ extend class PlayerPawn bUnmorphed = true; bInvisible = true; - p.morphTics = (duration) ? duration : DEFMORPHTICS; + p.morphTics = (duration) ? duration : (40 * GameTicRate) /*DEFMORPHTICS*/; // [MH] Used by SBARINFO to speed up face drawing p.MorphedPlayerClass = spawntype; @@ -261,7 +261,7 @@ extend class PlayerPawn { // Didn't fit altmo.bSolid = false; bSolid = true; - player.morphTics = 2*TICRATE; + player.morphTics = 2*GameTicRate; return false; } diff --git a/wadsrc/static/zscript/actors/raven/minotaur.zs b/wadsrc/static/zscript/actors/raven/minotaur.zs index 6060672761..9a8f20cfb6 100644 --- a/wadsrc/static/zscript/actors/raven/minotaur.zs +++ b/wadsrc/static/zscript/actors/raven/minotaur.zs @@ -1,6 +1,6 @@ class Minotaur : Actor { - const MAULATORTICS = 25 * TICRATE; + //const MAULATORTICS = 25 * TICRATE; const MNTR_CHARGE_SPEED =13.; const MINOTAUR_LOOK_DIST = 16*54.; @@ -223,7 +223,7 @@ class Minotaur : Actor } A_FaceTarget (); VelFromAngle(MNTR_CHARGE_SPEED); - special1 = TICRATE/2; // Charge duration + special1 = GameTicRate/2; // Charge duration } else if (target.pos.z == target.floorz && dist < 9*64. @@ -396,7 +396,7 @@ class Minotaur : Actor let mf = MinotaurFriend(self); if (mf) { - if (mf.StartTime >= 0 && (level.maptime - mf.StartTime) >= MAULATORTICS) + if (mf.StartTime >= 0 && (level.maptime - mf.StartTime) >= (25 * GameTicRate) /*MAULATORTICS*/) { DamageMobj (null, null, TELEFRAG_DAMAGE, 'None'); return; @@ -517,7 +517,7 @@ class Minotaur : Actor // In case pain caused him to skip his fade in. A_SetRenderStyle(1, STYLE_Normal); - if (mf.StartTime >= 0 && (level.maptime - mf.StartTime) >= MAULATORTICS) + if (mf.StartTime >= 0 && (level.maptime - mf.StartTime) >= (25 * GameTicRate) /*MAULATORTICS*/) { DamageMobj (null, null, TELEFRAG_DAMAGE, 'None'); return; @@ -628,7 +628,7 @@ class MinotaurFriend : Minotaur // [RH] Minotaurs can't be morphed, so this isn't needed //if (!(mo.flags&MF_COUNTKILL)) continue; // for morphed minotaurs if (mo.bCorpse) continue; - if (mo.StartTime >= 0 && (level.maptime - StartTime) >= MAULATORTICS) continue; + if (mo.StartTime >= 0 && (level.maptime - StartTime) >= (25 * GameTicRate) /*MAULATORTICS*/) continue; if (mo.tracer != null && mo.tracer.player == tracer.player) break; } diff --git a/wadsrc/static/zscript/actors/shared/bridge.zs b/wadsrc/static/zscript/actors/shared/bridge.zs index cbaf49925c..05e37d4f61 100644 --- a/wadsrc/static/zscript/actors/shared/bridge.zs +++ b/wadsrc/static/zscript/actors/shared/bridge.zs @@ -56,8 +56,8 @@ class BridgeBall : Actor // If the bridge is custom, set non-default values if any. // Set angular speed; 1--128: counterclockwise rotation ~=1--180°; 129--255: clockwise rotation ~= 180--1° - if (target.args[3] > 128) rotationspeed = 45. / 32 * (target.args[3] - 256) / TICRATE; - else if (target.args[3] > 0) rotationspeed = 45. / 32 * (target.args[3]) / TICRATE; + if (target.args[3] > 128) rotationspeed = 45. / 32 * (target.args[3] - 256) / GameTicRate; + else if (target.args[3] > 0) rotationspeed = 45. / 32 * (target.args[3]) / GameTicRate; // Set rotation radius if (target.args[4]) rotationradius = ((target.args[4] * target.radius) / 100); diff --git a/wadsrc/static/zscript/actors/shared/camera.zs b/wadsrc/static/zscript/actors/shared/camera.zs index d7826c0517..d2a89badfd 100644 --- a/wadsrc/static/zscript/actors/shared/camera.zs +++ b/wadsrc/static/zscript/actors/shared/camera.zs @@ -30,7 +30,7 @@ class SecurityCamera : Actor Super.PostBeginPlay (); Center = Angle; if (args[2]) - Delta = 360. / (args[2] * TICRATE / 8); + Delta = 360. / (args[2] * GameTicRate / 8); else Delta = 0.; if (args[1]) @@ -63,8 +63,8 @@ class AimingCamera : SecurityCamera args[2] = 0; Super.PostBeginPlay (); - MaxPitchChange = double(changepitch) / TICRATE; - Range /= TICRATE; + MaxPitchChange = double(changepitch) / GameTicRate; + Range /= GameTicRate; ActorIterator it = Level.CreateActorIterator(args[3]); tracer = it.Next (); diff --git a/wadsrc/static/zscript/actors/shared/ice.zs b/wadsrc/static/zscript/actors/shared/ice.zs index ecf5194246..774094a1c9 100644 --- a/wadsrc/static/zscript/actors/shared/ice.zs +++ b/wadsrc/static/zscript/actors/shared/ice.zs @@ -122,7 +122,7 @@ extend class Actor { if (Vel != (0,0,0) && !bShattering) { - tics = 3*TICRATE; + tics = 3*GameTicRate; return; } Vel = (0,0,0); diff --git a/wadsrc/static/zscript/actors/shared/movingcamera.zs b/wadsrc/static/zscript/actors/shared/movingcamera.zs index 8f76bd1790..8448753054 100644 --- a/wadsrc/static/zscript/actors/shared/movingcamera.zs +++ b/wadsrc/static/zscript/actors/shared/movingcamera.zs @@ -269,7 +269,7 @@ class PathFollower : Actor bJustStepped = false; if (CurrNode.args[2]) { - HoldTime = Level.maptime + CurrNode.args[2] * TICRATE / 8; + HoldTime = Level.maptime + CurrNode.args[2] * GameTicRate / 8; SetXYZ(CurrNode.Pos); } } @@ -293,7 +293,7 @@ class PathFollower : Actor if (Interpolate ()) { - Time += (8. / (max(1, CurrNode.args[1]) * TICRATE)); + Time += (8. / (max(1, CurrNode.args[1]) * GameTicRate)); if (Time > 1.) { Time -= 1.; diff --git a/wadsrc/static/zscript/actors/strife/programmer.zs b/wadsrc/static/zscript/actors/strife/programmer.zs index 4a364f23f5..6e737a1504 100644 --- a/wadsrc/static/zscript/actors/strife/programmer.zs +++ b/wadsrc/static/zscript/actors/strife/programmer.zs @@ -207,7 +207,7 @@ class ProgLevelEnder : Inventory { if (special2 == 0) { // fade out over .66 second - special1 += 255 / (TICRATE*2/3); + special1 += 255 / (GameTicRate*2/3); if (++special1 >= 255) { special1 = 255; @@ -217,7 +217,7 @@ class ProgLevelEnder : Inventory } else { // fade in over two seconds - special1 -= 255 / (TICRATE*2); + special1 -= 255 / (GameTicRate*2); if (special1 <= 0) { Destroy (); diff --git a/wadsrc/static/zscript/doombase.zs b/wadsrc/static/zscript/doombase.zs index 58677b8ca1..710c423e45 100644 --- a/wadsrc/static/zscript/doombase.zs +++ b/wadsrc/static/zscript/doombase.zs @@ -185,7 +185,7 @@ class Thinker : Object native play static clearscope int Tics2Seconds(int tics) { - return int(tics / TICRATE); + return int(tics / GameTicRate); } } diff --git a/wadsrc/static/zscript/engine/base.zs b/wadsrc/static/zscript/engine/base.zs index ea6440bbc6..f059e6725c 100644 --- a/wadsrc/static/zscript/engine/base.zs +++ b/wadsrc/static/zscript/engine/base.zs @@ -710,7 +710,10 @@ struct SystemTime class Object native { - const TICRATE = 35; + const DEFAULT_TICRATE = 35; + + /*deprecated("4.11","Use GameTicRate instead")*/ const TICRATE = 35; + native bool bDestroyed; // These must be defined in some class, so that the compiler can find them. Object is just fine, as long as they are private to external code. diff --git a/wadsrc/static/zscript/ui/statusbar/strife_sbar.zs b/wadsrc/static/zscript/ui/statusbar/strife_sbar.zs index f52195be42..46e1bedc2c 100644 --- a/wadsrc/static/zscript/ui/statusbar/strife_sbar.zs +++ b/wadsrc/static/zscript/ui/statusbar/strife_sbar.zs @@ -3,13 +3,13 @@ class StrifeStatusBar : BaseStatusBar { // Number of tics to move the popscreen up and down. - const POP_TIME = (Thinker.TICRATE/8); + //const POP_TIME = (GameTicRate/8); // Popscreen height when fully extended const POP_HEIGHT = 104; // Number of tics to scroll keys left - const KEY_TIME = (Thinker.TICRATE/3); + //const KEY_TIME = (GameTicRate/3); enum eImg { @@ -167,8 +167,8 @@ class StrifeStatusBar : BaseStatusBar { if (PopHeight < 0) { - PopHeightChange = POP_HEIGHT / POP_TIME; - PopHeight += POP_HEIGHT / POP_TIME; + PopHeightChange = POP_HEIGHT / (GameTicRate/8) /*POP_TIME*/; + PopHeight += POP_HEIGHT / (GameTicRate/8) /*POP_TIME*/; } else { @@ -184,19 +184,19 @@ class StrifeStatusBar : BaseStatusBar } else if (PopHeight > -POP_HEIGHT) { - PopHeight -= POP_HEIGHT / POP_TIME; + PopHeight -= POP_HEIGHT / (GameTicRate/8) /*POP_TIME*/; if (PopHeight < -POP_HEIGHT) { PopHeight = -POP_HEIGHT; } else { - PopHeightChange = -POP_HEIGHT / POP_TIME; + PopHeightChange = -POP_HEIGHT / (GameTicRate/8) /*POP_TIME*/; } } if (KeyPopScroll > 0) { - KeyPopScroll -= 280 / KEY_TIME; + KeyPopScroll -= 280 / (GameTicRate/3) /*KEY_TIME*/; if (KeyPopScroll < 0) { KeyPopScroll = 0; @@ -318,10 +318,10 @@ class StrifeStatusBar : BaseStatusBar int flags = item.Amount <= 0? DI_ITEM_OFFSETS|DI_DIM : DI_ITEM_OFFSETS; if (item == CPlayer.mo.InvSel) { - DrawTexture (Images[CursorImage], (42 + TICRATE*i, 180), flags, 1. - itemflashFade); + DrawTexture (Images[CursorImage], (42 + GameTicRate*i, 180), flags, 1. - itemflashFade); } - DrawInventoryIcon (item, (48 + TICRATE*i, 182), flags); - DrawString(mYelFont, FormatNumber(item.Amount, 3, 5), (75 + TICRATE*i, 191), DI_TEXT_ALIGN_RIGHT); + DrawInventoryIcon (item, (48 + GameTicRate*i, 182), flags); + DrawString(mYelFont, FormatNumber(item.Amount, 3, 5), (75 + GameTicRate*i, 191), DI_TEXT_ALIGN_RIGHT); i++; } } @@ -388,13 +388,13 @@ class StrifeStatusBar : BaseStatusBar { if (item == CPlayer.mo.InvSel) { - DrawTexture(Images[CursorImage], (-90+i*TICRATE, -3), DI_SCREEN_CENTER_BOTTOM, 0.75); + DrawTexture(Images[CursorImage], (-90+i*GameTicRate, -3), DI_SCREEN_CENTER_BOTTOM, 0.75); } if (item.Icon.isValid()) { - DrawInventoryIcon(item, (-90+i*TICRATE, -5), DI_SCREEN_CENTER_BOTTOM|DI_DIMDEPLETED, 0.75); + DrawInventoryIcon(item, (-90+i*GameTicRate, -5), DI_SCREEN_CENTER_BOTTOM|DI_DIMDEPLETED, 0.75); } - DrawString(mYelFont, FormatNumber(item.Amount, 3, 5), (-72 + i*TICRATE, -8), DI_TEXT_ALIGN_RIGHT|DI_SCREEN_CENTER_BOTTOM); + DrawString(mYelFont, FormatNumber(item.Amount, 3, 5), (-72 + i*GameTicRate, -8), DI_TEXT_ALIGN_RIGHT|DI_SCREEN_CENTER_BOTTOM); ++i; } } @@ -456,7 +456,7 @@ class StrifeStatusBar : BaseStatusBar if (KeyPopScroll > 0) { // Extrapolate the scroll position for smoother scrolling - int scroll = MAX (0, KeyPopScroll - int(TicFrac * (280./KEY_TIME))); + int scroll = MAX (0, KeyPopScroll - int(TicFrac * (280./(GameTicRate/3) /*KEY_TIME*/))); pos -= 10; leftcol = leftcol - 280 + scroll; }