diff --git a/marble/client/scripts/default.bind.cs b/marble/client/scripts/default.bind.cs index edf5740..34fabe4 100644 --- a/marble/client/scripts/default.bind.cs +++ b/marble/client/scripts/default.bind.cs @@ -42,7 +42,7 @@ moveMap.bindCmd(keyboard, "escape", "", "escapeFromGame();"); // respawn key TODO: make this one remapable // usage: bindCmd(device, action, onDown, onUp) -moveMap.bindCmd(keyboard, "r", "", "if($Game::State !$= \"End\"){ClientGroup.getObject(0).respawnPlayer();}"); +moveMap.bindCmd(keyboard, "r", "", "if($gamePaused) {return;} if($Game::State !$= \"End\"){LocalClientConnection.respawnPlayer();}"); //------------------------------------------------------------------------------ // Movement Keys diff --git a/marble/client/scripts/game.cs b/marble/client/scripts/game.cs index bfad3a1..2969e1e 100644 --- a/marble/client/scripts/game.cs +++ b/marble/client/scripts/game.cs @@ -157,7 +157,7 @@ function formatTime(%time) //%hundredthOne = mFloor(%hundredth % 10); //%hundredthTen = mFloor(%hundredth / 10); %thousandthOne = mFloor(%thousandth % 10); - %thousandthTen = mFloor(mFloor(%thousandth / 10) % 10); + %thousandthTen = mFloor(%thousandth / 10) % 10; %thousandthHundred = mFloor(%thousandth / 100); return %isNeg @ %minutesTen @ %minutesOne @ ":" @ diff --git a/marble/client/scripts/playgui.cs b/marble/client/scripts/playgui.cs index d0999cb..9abec96 100644 --- a/marble/client/scripts/playgui.cs +++ b/marble/client/scripts/playgui.cs @@ -214,25 +214,27 @@ function PlayGui::updateControls(%this) %drawNeg = true; } - %hundredth = mFloor((%et % 1000) / 10); + %thousandth = mFloor(%et % 1000); %totalSeconds = mFloor(%et / 1000); %seconds = %totalSeconds % 60; - %minutes = (%totalSeconds - %seconds) / 60; + %minutes = %totalSeconds / 60; - %secondsOne = %seconds % 10; - %secondsTen = (%seconds - %secondsOne) / 10; - %minutesOne = %minutes % 10; - %minutesTen = (%minutes - %minutesOne) / 10; - %hundredthOne = %hundredth % 10; - %hundredthTen = (%hundredth - %hundredthOne) / 10; + %secondsOne = mFloor(%seconds % 10); + %secondsTen = mFloor(%seconds / 10); + %minutesOne = mFloor(%minutes % 10); + %minutesTen = mFloor(%minutes / 10); + %thousandthOne = mFloor(%thousandth % 10); + %thousandthTen = mFloor(%thousandth / 10) % 10; + %thousandthHundred = mFloor(%thousandth / 100); // Update the controls Min_Ten.setNumber(%minutesTen); Min_One.setNumber(%minutesOne); Sec_Ten.setNumber(%secondsTen); Sec_One.setNumber(%secondsOne); - Sec_Tenth.setNumber(%hundredthTen); - Sec_Hundredth.setNumber(%hundredthOne); + Sec_Tenth.setNumber(%thousandthHundred); + Sec_Hundredth.setNumber(%thousandthTen); + Sec_Thousandth.setNumber(%thousandthOne); PG_NegSign.setVisible(%drawNeg); } diff --git a/marble/client/scripts/tttimer.cs b/marble/client/scripts/tttimer.cs index f145b6f..70ea30b 100644 --- a/marble/client/scripts/tttimer.cs +++ b/marble/client/scripts/tttimer.cs @@ -53,7 +53,7 @@ function initTMTimer() { profile = "GuiDefaultProfile"; horizSizing = "center"; //HiGuy: Center it! - position = mfloor((getWord(PlayGui.getExtent(), 0) - 237) / 2) SPC "62"; + position = mfloor((getWord(PlayGui.getExtent(), 0) - 227) / 2) SPC "52"; extent = "237 46"; visible = "0"; @@ -105,6 +105,12 @@ function initTMTimer() { extent = "30 38"; bitmap = $Con::Root @ "/client/ui/game/numbers/0_green.png"; }; + new GuiBitmapCtrl(TMSec_Thousandth) { + profile = "GuiDefaultProfile"; + position = "172 3"; + extent = "30 38"; + bitmap = $Con::Root @ "/client/ui/game/numbers/0_green.png"; + }; }; //HiGuy: Add it to the PlayGui PlayGui.add(PG_TMTimer); @@ -154,25 +160,27 @@ package TMTimer { PG_TMTimer.setVisible(%bt); if (%bt) { - %hundredth = mFloor((%bt % 1000) / 10); + %thousandth = mFloor(%bt % 1000); %totalSeconds = mFloor(%bt / 1000); - %seconds = %totalSeconds % 60; - %minutes = (%totalSeconds - %seconds) / 60; + %seconds = mFloor(%totalSeconds % 60); + %minutes = mFloor(%totalSeconds / 60); - %secondsOne = %seconds % 10; - %secondsTen = (%seconds - %secondsOne) / 10; - %minutesOne = %minutes % 10; - %minutesTen = (%minutes - %minutesOne) / 10; - %hundredthOne = %hundredth % 10; - %hundredthTen = (%hundredth - %hundredthOne) / 10; + %secondsOne = mFloor(%seconds % 10); + %secondsTen = mFloor(%seconds / 10); + %minutesOne = mFloor(%minutes % 10); + %minutesTen = mFloor(%minutes / 10); + %thousandthOne = mFloor(%thousandth % 10); + %thousandthTen = mFloor(%thousandth / 10) % 10; + %thousandthHundred = mFloor(%thousandth / 100); // Update the controls TMMin_Ten.setTimeNumber(%minutesTen); TMMin_One.setTimeNumber(%minutesOne); TMSec_Ten.setTimeNumber(%secondsTen); TMSec_One.setTimeNumber(%secondsOne); - TMSec_Tenth.setTimeNumber(%hundredthTen); - TMSec_Hundredth.setTimeNumber(%hundredthOne); + TMSec_Tenth.setTimeNumber(%thousandthHundred); + TMSec_Hundredth.setTimeNumber(%thousandthTen); + TMSec_Thousandth.setTimeNumber(%thousandthOne); TMMinSec_Colon.setTimeNumber("colon"); TMMinSec_Point.setTimeNumber("point"); diff --git a/marble/client/ui/ExitGameDlg.gui b/marble/client/ui/ExitGameDlg.gui index 4a9a832..7c958bd 100644 --- a/marble/client/ui/ExitGameDlg.gui +++ b/marble/client/ui/ExitGameDlg.gui @@ -80,6 +80,7 @@ new GuiControl(ExitGameDlg) { command = "Canvas.popDialog(ExitGameDlg); resumeGame(); restartLevel();"; helpTag = "0"; text = "button"; + accelerator = "r"; groupNum = "-1"; buttonType = "PushButton"; bitmap = "common/ui/restart"; diff --git a/marble/client/ui/playGui.gui b/marble/client/ui/playGui.gui index 2bfd203..051d0e2 100644 --- a/marble/client/ui/playGui.gui +++ b/marble/client/ui/playGui.gui @@ -200,7 +200,7 @@ new GameTSCtrl(PlayGUI) { horizSizing = "center"; vertSizing = "bottom"; position = "215 1"; - extent = "210 58"; + extent = "230 58"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -301,6 +301,18 @@ new GameTSCtrl(PlayGUI) { bitmap = "./game/numbers/5.png"; wrap = "0"; }; + new GuiBitmapCtrl(Sec_Thousandth) { + profile = "GuiDefaultProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "192 0"; + extent = "43 55"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + bitmap = "./game/numbers/9.png"; + wrap = "0"; + }; new GuiBitmapCtrl(PG_NegSign) { profile = "GuiDefaultProfile"; horizSizing = "right"; diff --git a/marble/server/scripts/easterEgg.cs b/marble/server/scripts/easterEgg.cs index 15d54c8..5272341 100644 --- a/marble/server/scripts/easterEgg.cs +++ b/marble/server/scripts/easterEgg.cs @@ -22,7 +22,6 @@ datablock AudioProfile(GotThatEggAlready) function EasterEgg::onPickup(%this,%obj,%user,%amount) { - echo("onPickup"); Parent::onPickup(%this,%obj,%user,%amount); %user.client.onFoundEasterEgg(%amount); return true;