diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..2abefcc --- /dev/null +++ b/.gitignore @@ -0,0 +1,33 @@ +*.exe +*.dll +*.ini +*.pub +*.asi +*.dr7 +*.jpg +*.png +*.bm8 +*.ico +*.vl2 +*.ml +*.mp3 +*.wav +*.avi +*.ifr +*.ifl +*.gft +*.ter +*.nav +*.spn +*.db* +*.dif +*.dsq +*.PNG +*.JPG +*.dml +*.dts +*.WAV +*.cfg +*EULA.txt +*UKEULA.txt +*UpdatePatch.txt diff --git a/LinuxCardProfiles.cs b/LinuxCardProfiles.cs index 94e0de8..bb854ed 100644 --- a/LinuxCardProfiles.cs +++ b/LinuxCardProfiles.cs @@ -1,26 +1,26 @@ -// Explicit card profiles -// -// SafeMode -- forces destruction of rendering context before resolution change -// LockArray -- inhibits compiled vertex arrays if available -// SubImage -- inhibits glTexSubImage* -// FogTexture -- require bound texture for combine extension -// NoEnvColor -- card doesn't support texture environment color -// ClipHigh -- clip off high resolutions (> 1152x864) -// DeleteContext -- delete rendering context (ignored for all OSs except W2K) -// TexCompress -- inhibits texture compression if available -// InteriorLock -- lock arrays rendering Interiors -// SkipFirstFog -- skip first two-pass fog (dumb 3Dfx hack) -// Only16 -- inhibit the 32-bit resolutions -// NoArraysAlpha -- don't use glDrawArrays with a GL_ALPHA texture -// ProFile -- explicit file of graphic settings -// -// Vendor Renderer SafeMode LockArray SubImage FogTexture NoEnvColor ClipHigh DeleteContext TexCompress InteriorLock SkipFirstFog Only16 NoArraysAlpha ProFile -//--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -addCardProfile("VA Linux Systems, Inc.", "Banshee", true, true, true, true, true, false, false, true, true, true, false, true, "Voodoo3"); -addCardProfile("VA Linux Systems, Inc.", "Voodoo3", true, true, true, true, true, false, true, true, true, true, false, true, "Voodoo3"); -addCardProfile("VA Linux Systems, Inc.", "Voodoo4", true, false, true, false, true, false, false, true, true, false, false, false, "Voodoo5"); -addCardProfile("VA Linux Systems, Inc.", "Voodoo5", true, false, true, false, true, false, false, true, true, false, false, false, "Voodoo5"); -addCardProfile("VA Linux Systems, Inc.", "Rage128", true, true, true, true, true, false, true, true, true, false, false, false, "Rage128"); -addCardProfile("VA Linux Systems, Inc.", "Radeon", true, true, true, false, false, false, true, false, true, false, false, false, "Radeon"); -addCardProfile("VA Linux Systems, Inc.", "G400", true, true, false, false, true, false, true, true, true, false, false, false, "Matrox"); -addCardProfile("VA Linux Systems, Inc.", "G450", true, true, false, false, true, false, true, true, true, false, false, false, "Matrox"); +// Explicit card profiles +// +// SafeMode -- forces destruction of rendering context before resolution change +// LockArray -- inhibits compiled vertex arrays if available +// SubImage -- inhibits glTexSubImage* +// FogTexture -- require bound texture for combine extension +// NoEnvColor -- card doesn't support texture environment color +// ClipHigh -- clip off high resolutions (> 1152x864) +// DeleteContext -- delete rendering context (ignored for all OSs except W2K) +// TexCompress -- inhibits texture compression if available +// InteriorLock -- lock arrays rendering Interiors +// SkipFirstFog -- skip first two-pass fog (dumb 3Dfx hack) +// Only16 -- inhibit the 32-bit resolutions +// NoArraysAlpha -- don't use glDrawArrays with a GL_ALPHA texture +// ProFile -- explicit file of graphic settings +// +// Vendor Renderer SafeMode LockArray SubImage FogTexture NoEnvColor ClipHigh DeleteContext TexCompress InteriorLock SkipFirstFog Only16 NoArraysAlpha ProFile +//--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- +addCardProfile("VA Linux Systems, Inc.", "Banshee", true, true, true, true, true, false, false, true, true, true, false, true, "DRI-Voodoo3"); +addCardProfile("VA Linux Systems, Inc.", "Voodoo3", true, true, true, true, true, false, true, true, true, true, false, true, "DRI-Voodoo3"); +addCardProfile("VA Linux Systems, Inc.", "Voodoo4", true, false, true, false, true, false, false, true, true, false, false, false, "DRI-Voodoo5"); +addCardProfile("VA Linux Systems, Inc.", "Voodoo5", true, false, true, false, true, false, false, true, true, false, false, false, "DRI-Voodoo5"); +addCardProfile("VA Linux Systems, Inc.", "Rage128", true, true, true, true, true, false, true, true, true, false, false, false, "DRI-Rage128"); +addCardProfile("VA Linux Systems, Inc.", "Radeon", true, true, true, false, false, false, true, false, true, false, false, false, "DRI-Radeon"); +addCardProfile("VA Linux Systems, Inc.", "G400", true, true, false, false, true, false, true, true, true, false, false, false, "DRI-Matrox"); +addCardProfile("VA Linux Systems, Inc.", "G450", true, true, false, false, true, false, true, true, true, false, false, false, "DRI-Matrox"); diff --git a/SierraUp.cfg b/SierraUp.cfg index 93a57e0..4b355b7 100644 --- a/SierraUp.cfg +++ b/SierraUp.cfg @@ -1,7 +1,7 @@ ProductName "Tribes2" DisplayName "Tribes 2" PatchFolder .\patch -CurrentVersion 0.21570.0.0 +CurrentVersion 0.22002.0.0 AutoStart MonitorPatch LaunchExe "tribes2.exe" @@ -10,7 +10,7 @@ MotdTimeout 30000 VersionTimeout 45000 PatchTimeout 45000 ValidateVersionFile ".\zz.ini" -ResourceDllFile "Tribes2Res.dll" +ResourceDllFile "T2Res.dll" DirectoryServer "tribes2.west.won.net:15104" DirectoryServer "tribes2.east.won.net:15104" DirectoryServer "tribes2.central.won.net:15104" diff --git a/Voodoo5.cs b/Voodoo5.cs index bb11a6f..9c78735 100644 --- a/Voodoo5.cs +++ b/Voodoo5.cs @@ -4,7 +4,7 @@ $pref::Video::resolution = "800 600 16"; $pref::OpenGL::mipReduction = 0; $pref::shadows = 0.5; $pref::Terrain::enableDetails = 1; -$pref::environmentMaps = 1; +$pref::environmentMaps = 0; $pref::Interior::DynamicLights = 0; $pref::Interior::ShowEnvironmentMaps = 0; $pref::precipitationOn = 1; diff --git a/base/console_end.cs b/base/console_end.cs index a232a4a..8ded399 100644 --- a/base/console_end.cs +++ b/base/console_end.cs @@ -34,18 +34,6 @@ if ($CmdLineBotCount !$= "") exec("scripts/message.cs"); -function repaintCanvas() -{ - if ( isObject( Canvas ) ) - Canvas.repaint(); -} - -function resetCanvas() -{ - if ( isObject( Canvas ) ) - Canvas.reset(); -} - //function to be called when the game exits function onExit() { @@ -62,7 +50,6 @@ function onExit() exec("scripts/LaunchLanGui.cs"); exec("scripts/GameGui.cs"); exec("scripts/ChooseFilterDlg.cs"); -exec("scripts/ChatGui.cs"); exec("scripts/TrainingGui.cs"); exec("scripts/webstuff.cs"); exec("scripts/webforums.cs"); @@ -93,6 +80,7 @@ exec("scripts/targetManager.cs"); exec("scripts/gameCanvas.cs"); exec("scripts/centerPrint.cs"); exec("scripts/CreditsGui.cs"); +exec("scripts/ChatGui.cs"); // see if the mission and type are valid // if they are they will be assigned into $Host::Map and $Host::MissionType @@ -181,7 +169,6 @@ loadGui("CommonLoadDlg"); loadGui("CommonSaveDlg"); loadGui("FrameOverlayGui"); loadGui("TribeAdminMemberDlg"); -loadGui("TribeAttribDlg"); loadGui("TSShowGui"); loadGui("TSShowLoadDlg"); loadGui("TSShowMiscDlg"); @@ -231,6 +218,7 @@ loadGui("AdvancedHostDlg"); loadGui("NewWarriorDlg"); loadGui("JoinChatDlg"); loadGui("ChannelKeyDlg"); +loadGui("ChatOptionsDlg"); loadGui("ChannelOptionsDlg"); loadGui("ChannelBanDlg"); loadGui("FilterEditDlg"); @@ -576,8 +564,9 @@ function DispatchLaunchMode() else MessageBoxOK( "FILE NOT FOUND", "You do not have the interior test mission in your mission folder.\nTalk to Brad or Tom to get it.", "quit();" ); case "Connect": + OnlineLogIn(); setNetPort(0); - JoinSelectedGame(); + JoinGame($JoinGameAddress); case "HostGame": $ServerName = $Host::GameName; $Host::MissionType = $MissionType; diff --git a/base/gui/BrowserEditInfoDlg.gui b/base/gui/BrowserEditInfoDlg.gui index f716cc6..f5e85ae 100644 --- a/base/gui/BrowserEditInfoDlg.gui +++ b/base/gui/BrowserEditInfoDlg.gui @@ -30,7 +30,7 @@ new GuiControl(BrowserEditInfoDlg) { extent = "128 38"; minExtent = "32 38"; visible = "1"; - command = "TribePropertiesDlg.pendingChanges = \"\";Canvas.popDialog(BrowserEditInfoDlg);"; + command = "TribePropertiesDlg.pendingChanges = \"\";WarriorPropertiesDlg.pendingChanges = \"\";Canvas.popDialog(BrowserEditInfoDlg);"; accelerator = "escape"; helpTag = "0"; text = "CANCEL"; diff --git a/base/gui/ChannelKeyDlg.gui b/base/gui/ChannelKeyDlg.gui index 1caf8ae..b12e17c 100644 --- a/base/gui/ChannelKeyDlg.gui +++ b/base/gui/ChannelKeyDlg.gui @@ -77,6 +77,7 @@ new GuiControl(ChannelKeyDlg) { maxLength = "255"; password = "1"; glowOffset = "9 9"; + altCommand = "keyChannelJoin();"; }; new ShellBitmapButton() { profile = "ShellButtonProfile"; diff --git a/base/gui/ChatDlg.gui b/base/gui/ChatDlg.gui index 2b8454b..2e7cc77 100644 --- a/base/gui/ChatDlg.gui +++ b/base/gui/ChatDlg.gui @@ -34,7 +34,19 @@ new GuiControl(MainChatHud) { position = "6 2"; extent = "244 3"; minExtent = "2 2"; - visible = "0"; + visible = "1"; + }; + + new GuiBitmapCtrl(passHash) + { + profile = "GuiDefaultProfile"; + horizSizing = "left"; + vertSizing = "bottom"; + position = "151 -1"; + extent = "5 10"; + minExtent = "1 1"; + visible = "1"; + bitmap = "gui/voteMeterPassBar.png"; }; }; diff --git a/base/gui/ChatGui.gui b/base/gui/ChatGui.gui index 0b3e00c..a67d018 100644 --- a/base/gui/ChatGui.gui +++ b/base/gui/ChatGui.gui @@ -215,6 +215,19 @@ new GuiChunkedBitmapCtrl(ChatGui) { text = "CHANNEL OPTIONS"; simpleStyle = "0"; }; + new ShellBitmapButton(ChatEditOptionsBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "15 -5"; + extent = "128 38"; + minExtent = "32 38"; + visible = "0"; + command = "EditChatOptions();"; + helpTag = "0"; + text = "CHAT OPTIONS"; + simpleStyle = "0"; + }; }; }; //--- OBJECT WRITE END --- diff --git a/base/gui/ChatOptionsDlg.gui b/base/gui/ChatOptionsDlg.gui new file mode 100644 index 0000000..c059f02 --- /dev/null +++ b/base/gui/ChatOptionsDlg.gui @@ -0,0 +1,191 @@ +//--- OBJECT WRITE BEGIN --- +new GuiControl(ChatOptionsDlg) { + profile = "DlgBackProfile"; + horizSizing = "width"; + vertSizing = "height"; + position = "0 0"; + extent = "640 480"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + + new ShellPaneCtrl() { + profile = "ShellDlgPaneProfile"; + horizSizing = "center"; + vertSizing = "center"; + position = "75 102"; + extent = "490 276"; + minExtent = "48 92"; + visible = "1"; + helpTag = "0"; + text = "CHAT OPTIONS"; + maxLength = "255"; + noTitleBar = "0"; + + new ShellToggleButton(ButtonChatShowJoin) { + profile = "ShellRadioProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "270 57"; + extent = "177 30"; + minExtent = "26 27"; + visible = "1"; + variable = ""; + command = "ChatHideJoinMessage();"; + helpTag = "0"; + text = "Hide \"Join Server\" Messages"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "22 146"; + extent = "88 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Away Message:"; + maxLength = "255"; + }; + new ShellTextEditCtrl(EditChatAwayMessage) { + profile = "NewTextEditProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "104 138"; + extent = "366 38"; + minExtent = "32 38"; + visible = "1"; + helpTag = "0"; + maxLength = "64"; + historySize = "0"; + password = "0"; + glowOffset = "9 9"; + variable = "$tempAwayMsg"; + }; + new ShellToggleButton(ButtonChatHighlight) { + profile = "ShellRadioProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "47 32"; + extent = "150 30"; + minExtent = "26 27"; + visible = "1"; + variable = ""; + command = "ToggleChatHiglight();"; + helpTag = "0"; + text = "Highlight text with my nick"; + maxLength = "255"; + }; + new ShellToggleButton(ButtonChatChannelHighlight) { + profile = "ShellRadioProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "47 57"; + extent = "150 30"; + minExtent = "26 27"; + visible = "1"; + variable = ""; + command = "ToggleChatHiglightChannel();"; + helpTag = "0"; + text = "Highlight Channel"; + maxLength = "255"; + }; + new ShellToggleButton(ButtonChatNameLinkToggle) { + profile = "ShellRadioProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "270 32"; + extent = "176 30"; + minExtent = "26 27"; + visible = "1"; + variable = ""; + command = "ToggleChatLinkedNicks();"; + helpTag = "0"; + text = "Names are not links"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "22 174"; + extent = "88 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Kick Message:"; + maxLength = "255"; + }; + new ShellTextEditCtrl(EditChatKickMessage) { + profile = "NewTextEditProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "104 166"; + extent = "366 38"; + minExtent = "32 38"; + visible = "1"; + helpTag = "0"; + maxLength = "64"; + historySize = "0"; + password = "0"; + glowOffset = "9 9"; + variable = "$tempKickmsg"; + }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "22 200"; + extent = "88 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Ban Message:"; + maxLength = "255"; + }; + new ShellTextEditCtrl(EditChatBanMessage) { + profile = "NewTextEditProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "104 194"; + extent = "366 38"; + minExtent = "32 38"; + visible = "1"; + helpTag = "0"; + maxLength = "64"; + historySize = "0"; + password = "0"; + glowOffset = "9 9"; + variable = "$tempBanmsg"; + }; + new ShellBitmapButton(ButtonChatOptionsAccept) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "top"; + position = "284 221"; + extent = "128 38"; + minExtent = "32 38"; + visible = "1"; + command = "AcceptChatOptions();"; + helpTag = "0"; + text = "ACCEPT"; + simpleStyle = "0"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "top"; + position = "78 221"; + extent = "128 38"; + minExtent = "32 38"; + visible = "1"; + command = "CancelChatOptions();"; + accelerator = "escape"; + helpTag = "0"; + text = "CANCEL"; + simpleStyle = "0"; + }; + }; +}; +//--- OBJECT WRITE END --- diff --git a/base/gui/ConsoleDlg.gui b/base/gui/ConsoleDlg.gui index 652459a..2cd1173 100644 --- a/base/gui/ConsoleDlg.gui +++ b/base/gui/ConsoleDlg.gui @@ -65,6 +65,8 @@ function ToggleConsole(%make) $ConsoleActive = false; if(!ConsoleDlg.mouseOn) CursorOff(); + if ( $enableDirectInput ) + activateKeyboard(); } else { @@ -73,6 +75,7 @@ function ToggleConsole(%make) $ConsoleActive = true; if(!ConsoleDlg.mouseOn) CursorOn(); + deactivateKeyboard(); } } } diff --git a/base/gui/ForumsGui.gui b/base/gui/ForumsGui.gui index 36d97d7..4de2479 100644 --- a/base/gui/ForumsGui.gui +++ b/base/gui/ForumsGui.gui @@ -10,16 +10,6 @@ new GuiChunkedBitmapCtrl(ForumsGui) { variable = "$ShellBackground"; helpTag = "0"; useVariable = "1"; - eid = "979"; - key = "93"; - state = "done"; - ebstat = "1"; - initialized = "1"; - refreshTarget = "1"; - TextCheck = "0"; - refreshFlag = "0"; - forumCount = "-1"; - bflag = "4"; new ShellPaneCtrl(ForumShell) { profile = "ShellPaneProfile"; @@ -162,12 +152,6 @@ new GuiChunkedBitmapCtrl(ForumsGui) { drawSeparators = "0"; headerSort = "0"; allowReposition = "0"; - updateCount = "0"; - key = "71"; - state = "replyPost"; - lastId = "16480"; - highestUpdate = "16480"; - bflag = "1"; }; }; new ShellScrollCtrl() { @@ -361,7 +345,6 @@ new GuiChunkedBitmapCtrl(ForumsGui) { columns = "0"; fitParentWidth = "1"; clipColumnText = "0"; - forum = "58"; }; }; }; @@ -441,14 +424,6 @@ new GuiChunkedBitmapCtrl(ForumsGui) { drawSeparators = "0"; headerSort = "1"; allowReposition = "0"; - key = "43"; - state = "lines"; - selId = "0"; - count = "0"; - refreshFlag = "0"; - forum = "0"; - autoSelect = "1"; - FirstCount = "0"; }; }; new GuiTextCtrl() { diff --git a/base/gui/InteriorPreviewGui.gui b/base/gui/InteriorPreviewGui.gui index d7e7dd7..f049280 100644 --- a/base/gui/InteriorPreviewGui.gui +++ b/base/gui/InteriorPreviewGui.gui @@ -31,17 +31,6 @@ new GuiControl(interiorPreviewGui) { beaconLineWidth = "2.5"; beaconTextYOffset = "14"; showAlternateTarget = "0"; - - new GameOverlayCtrl() { - profile = "GuiDefaultProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "0 0"; - extent = "640 480"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - }; }; new GuiButtonCtrl() { profile = "GuiButtonProfile"; diff --git a/base/gui/JoystickConfigDlg.gui b/base/gui/JoystickConfigDlg.gui index 026e3bf..ddee113 100644 --- a/base/gui/JoystickConfigDlg.gui +++ b/base/gui/JoystickConfigDlg.gui @@ -62,7 +62,7 @@ new GuiControl(JoystickConfigDlg) { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "26 50"; + position = "6 50"; extent = "60 22"; minExtent = "8 8"; visible = "1"; @@ -73,8 +73,8 @@ new GuiControl(JoystickConfigDlg) { profile = "ShellPopupProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "83 41"; - extent = "140 36"; + position = "63 41"; + extent = "200 36"; minExtent = "49 36"; visible = "1"; helpTag = "0"; diff --git a/base/gui/LobbyGui.gui b/base/gui/LobbyGui.gui index 5e6cf44..6577e9b 100644 --- a/base/gui/LobbyGui.gui +++ b/base/gui/LobbyGui.gui @@ -171,6 +171,7 @@ new GuiChunkedBitmapCtrl(LobbyGui) { drawSeparators = "0"; headerSort = "1"; allowReposition = "0"; + noSelect = "1"; }; }; new GuiControl() { diff --git a/base/gui/LoginDlg.gui b/base/gui/LoginDlg.gui index 9a40ccf..b405355 100644 --- a/base/gui/LoginDlg.gui +++ b/base/gui/LoginDlg.gui @@ -13,38 +13,40 @@ new GuiControl(LoginDlg) { profile = "ShellDlgPaneProfile"; horizSizing = "center"; vertSizing = "center"; - position = "90 156"; - extent = "460 167"; + position = "72 143"; + extent = "495 194"; minExtent = "48 92"; visible = "1"; helpTag = "0"; text = "LOGIN"; + maxLength = "255"; noTitleBar = "0"; new GuiTextCtrl() { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "30 47"; + position = "37 47"; extent = "85 22"; minExtent = "8 8"; visible = "1"; helpTag = "0"; text = "Account Name:"; + maxLength = "255"; }; new ShellTextEditCtrl(LoginEditBox) { profile = "NewTextEditProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "111 39"; + position = "118 39"; extent = "180 38"; minExtent = "32 38"; visible = "1"; variable = "$LoginName"; altCommand = "LoginProcess();"; helpTag = "0"; - historySize = "0"; maxLength = "16"; + historySize = "0"; password = "0"; glowOffset = "9 9"; }; @@ -52,50 +54,39 @@ new GuiControl(LoginDlg) { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "30 77"; + position = "37 77"; extent = "85 22"; minExtent = "8 8"; visible = "1"; helpTag = "0"; text = "Password:"; + maxLength = "255"; }; new GuiLoginPasswordCtrl(LoginPasswordBox) { profile = "NewTextEditProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "111 68"; + position = "118 69"; extent = "180 38"; minExtent = "32 38"; visible = "1"; variable = "$LoginPassword"; altCommand = "LoginProcess();"; helpTag = "0"; - historySize = "0"; maxLength = "16"; + historySize = "0"; password = "1"; glowOffset = "9 9"; }; - new ShellToggleButton() { - profile = "ShellRadioProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "118 106"; - extent = "160 27"; - minExtent = "26 27"; - visible = "1"; - variable = "$pref::RememberPassword"; - helpTag = "0"; - text = "REMEMBER PASSWORD"; - }; new ShellBitmapButton() { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "291 39"; - extent = "144 38"; + position = "300 39"; + extent = "147 38"; minExtent = "32 38"; visible = "1"; - command = "LoginProcess();"; + command = "LoginProcess(false);"; helpTag = "0"; text = "LOG IN"; simpleStyle = "0"; @@ -104,8 +95,8 @@ new GuiControl(LoginDlg) { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "291 70"; - extent = "144 38"; + position = "300 69"; + extent = "147 38"; minExtent = "32 38"; visible = "1"; command = "CreateAccount();"; @@ -117,27 +108,54 @@ new GuiControl(LoginDlg) { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "290 102"; - extent = "144 38"; + position = "300 99"; + extent = "147 38"; minExtent = "32 38"; visible = "1"; - command = "EditAccount();"; + command = "LoginProcess(true);"; helpTag = "0"; text = "EDIT ACCOUNT"; simpleStyle = "0"; }; - new ShellBitmapButton(LaunchToolbarCloseButton) { - profile = "CloseButtonProfile"; - horizSizing = "left"; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; vertSizing = "bottom"; - position = "411 0"; - extent = "33 26"; - minExtent = "33 26"; + position = "300 129"; + extent = "147 38"; + minExtent = "32 38"; visible = "1"; command = "quit();"; accelerator = "escape"; helpTag = "0"; - simpleStyle = "1"; + text = "QUIT"; + simpleStyle = "0"; + }; + new ShellToggleButton() { + profile = "ShellRadioProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "122 104"; + extent = "167 27"; + minExtent = "26 27"; + visible = "1"; + variable = "$pref::RememberPassword"; + helpTag = "0"; + text = "REMEMBER PASSWORD"; + maxLength = "255"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "118 129"; + extent = "180 38"; + minExtent = "32 38"; + visible = "1"; + command = "PasswordProcess(true);"; + helpTag = "0"; + text = "EMAIL ME MY PASSWORD"; + simpleStyle = "0"; }; }; }; diff --git a/base/gui/OptionsDlg.gui b/base/gui/OptionsDlg.gui index 466c4a4..e2d8913 100644 --- a/base/gui/OptionsDlg.gui +++ b/base/gui/OptionsDlg.gui @@ -92,7 +92,7 @@ new GuiControl(OptionsDlg) { maxLength = "255"; simpleStyle = "0"; }; - new ShellTabButton(OP_ControlsTab) { + new ShellTabButton(OP_VoiceTab) { profile = "ShellTabProfile"; horizSizing = "right"; vertSizing = "bottom"; @@ -100,6 +100,20 @@ new GuiControl(OptionsDlg) { extent = "108 38"; minExtent = "48 38"; visible = "1"; + command = "OptionsDlg.setPane(Voice);"; + helpTag = "0"; + text = "VOICE"; + maxLength = "255"; + simpleStyle = "0"; + }; + new ShellTabButton(OP_ControlsTab) { + profile = "ShellTabProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "19 196"; + extent = "108 38"; + minExtent = "48 38"; + visible = "1"; command = "OptionsDlg.setPane(Controls);"; helpTag = "0"; text = "CONTROLS"; @@ -110,7 +124,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTabProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "19 196"; + position = "19 226"; extent = "108 38"; minExtent = "48 38"; visible = "1"; @@ -124,7 +138,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTabProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "19 226"; + position = "19 256"; extent = "108 38"; minExtent = "48 38"; visible = "1"; @@ -154,7 +168,7 @@ new GuiControl(OptionsDlg) { position = "138 42"; extent = "437 316"; minExtent = "16 18"; - visible = "1"; + visible = "0"; helpTag = "0"; new GuiTextCtrl() { @@ -415,11 +429,65 @@ new GuiControl(OptionsDlg) { value = "0"; usePlusMinus = "1"; }; + new GuiTextCtrl() { + profile = "ShellTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "27 88"; + extent = "72 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Interior Detail:"; + maxLength = "255"; + }; + new ShellSliderCtrl(OP_InteriorDetailSlider) { + profile = "ShellSliderProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "37 103"; + extent = "170 24"; + minExtent = "12 24"; + visible = "1"; + variable = "value"; + helpTag = "0"; + range = "0.300000 1.000000"; + ticks = "1000"; + value = "1"; + usePlusMinus = "1"; + }; + new GuiTextCtrl() { + profile = "ShellTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "231 88"; + extent = "85 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Visible Distance:"; + maxLength = "255"; + }; + new ShellSliderCtrl(OP_VisibleDistanceSlider) { + profile = "ShellSliderProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "241 103"; + extent = "170 24"; + minExtent = "12 24"; + visible = "1"; + variable = "value"; + helpTag = "0"; + range = "0.600000 1.000000"; + ticks = "400"; + value = "1"; + usePlusMinus = "1"; + }; new GuiTextCtrl() { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "79 100"; + position = "79 137"; extent = "70 22"; minExtent = "8 8"; visible = "1"; @@ -431,7 +499,7 @@ new GuiControl(OptionsDlg) { profile = "ShellPopupProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "146 91"; + position = "146 128"; extent = "200 36"; minExtent = "49 36"; visible = "1"; @@ -448,7 +516,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "35 130"; + position = "35 167"; extent = "114 22"; minExtent = "8 8"; visible = "1"; @@ -460,7 +528,7 @@ new GuiControl(OptionsDlg) { profile = "ShellPopupProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "146 121"; + position = "146 158"; extent = "200 36"; minExtent = "49 36"; visible = "1"; @@ -477,7 +545,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "31 165"; + position = "31 196"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -490,7 +558,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "236 165"; + position = "236 196"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -503,7 +571,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "31 195"; + position = "31 226"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -516,7 +584,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "236 195"; + position = "236 226"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -529,7 +597,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "31 225"; + position = "31 256"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -542,7 +610,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "236 225"; + position = "236 256"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -554,7 +622,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "31 255"; + position = "133 286"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -562,33 +630,6 @@ new GuiControl(OptionsDlg) { text = "VERTEX LIGHTING"; maxLength = "255"; }; - new GuiTextCtrl() { - profile = "ShellTextProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "231 262"; - extent = "85 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "Visible Distance:"; - maxLength = "255"; - }; - new ShellSliderCtrl(OP_VisibleDistanceSlider) { - profile = "ShellSliderProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "241 277"; - extent = "170 24"; - minExtent = "12 24"; - visible = "1"; - variable = "value"; - helpTag = "0"; - range = "0.600000 1.000000"; - ticks = "400"; - value = "1"; - usePlusMinus = "1"; - }; }; new ShellFieldCtrl(OP_TexturesPane) { profile = "ShellFieldProfile"; @@ -678,9 +719,9 @@ new GuiControl(OptionsDlg) { visible = "1"; variable = "value"; helpTag = "0"; - range = "0.000000 5.000000"; + range = "0.000000 1.000000"; ticks = "6"; - value = "4"; + value = "1"; usePlusMinus = "1"; }; new GuiTextCtrl() { @@ -705,9 +746,9 @@ new GuiControl(OptionsDlg) { visible = "1"; variable = "value"; helpTag = "0"; - range = "0.000000 5.000000"; + range = "0.000000 1.000000"; ticks = "6"; - value = "4"; + value = "1"; usePlusMinus = "1"; }; new GuiTextCtrl() { @@ -732,9 +773,9 @@ new GuiControl(OptionsDlg) { visible = "1"; variable = "value"; helpTag = "0"; - range = "0.000000 5.000000"; + range = "0.000000 1.000000"; ticks = "6"; - value = "4"; + value = "1"; usePlusMinus = "1"; }; new GuiTextCtrl(OP_CompressLabel) { @@ -899,8 +940,8 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "252 43"; - extent = "152 30"; + position = "249 42"; + extent = "160 30"; minExtent = "26 27"; visible = "1"; variable = "$pref::Audio::environmentEnabled"; @@ -912,7 +953,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "10 47"; + position = "10 46"; extent = "72 22"; minExtent = "8 8"; visible = "1"; @@ -924,7 +965,7 @@ new GuiControl(OptionsDlg) { profile = "ShellPopupProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "79 38"; + position = "79 37"; extent = "169 36"; minExtent = "49 36"; visible = "1"; @@ -937,11 +978,98 @@ new GuiControl(OptionsDlg) { selectedBarBitmap = "gui/shll_pulldownbar_act"; noButtonStyle = "0"; }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "11 97"; + extent = "72 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Frequency:"; + maxLength = "255"; + }; + new ShellPopupMenu(OP_AudioFrequencyMenu) { + profile = "ShellPopupProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "80 88"; + extent = "169 36"; + minExtent = "49 36"; + visible = "1"; + helpTag = "0"; + text = "Select Frequency"; + maxLength = "255"; + maxPopupHeight = "200"; + buttonBitmap = "gui/shll_pulldown"; + rolloverBarBitmap = "gui/shll_pulldownbar_rol"; + selectedBarBitmap = "gui/shll_pulldownbar_act"; + noButtonStyle = "0"; + }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "11 127"; + extent = "72 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Bit Rate:"; + maxLength = "255"; + }; + new ShellPopupMenu(OP_AudioBitRateMenu) { + profile = "ShellPopupProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "80 118"; + extent = "100 36"; + minExtent = "49 36"; + visible = "1"; + helpTag = "0"; + text = "Select Bit Rate"; + maxLength = "255"; + maxPopupHeight = "200"; + buttonBitmap = "gui/shll_pulldown"; + rolloverBarBitmap = "gui/shll_pulldownbar_rol"; + selectedBarBitmap = "gui/shll_pulldownbar_act"; + noButtonStyle = "0"; + }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "221 127"; + extent = "60 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Channels:"; + maxLength = "255"; + }; + new ShellPopupMenu(OP_AudioChannelsMenu) { + profile = "ShellPopupProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "278 118"; + extent = "100 36"; + minExtent = "49 36"; + visible = "1"; + helpTag = "0"; + text = "Select # Channels"; + maxLength = "255"; + maxPopupHeight = "200"; + buttonBitmap = "gui/shll_pulldown"; + rolloverBarBitmap = "gui/shll_pulldownbar_rol"; + selectedBarBitmap = "gui/shll_pulldownbar_act"; + noButtonStyle = "0"; + }; new GuiTextCtrl() { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "26 89"; + position = "26 177"; extent = "79 22"; minExtent = "8 8"; visible = "1"; @@ -953,7 +1081,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "36 104"; + position = "36 192"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -969,7 +1097,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "231 89"; + position = "231 177"; extent = "79 22"; minExtent = "8 8"; visible = "1"; @@ -981,7 +1109,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "241 104"; + position = "241 192"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -996,7 +1124,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "26 129"; + position = "26 217"; extent = "60 22"; minExtent = "8 8"; visible = "1"; @@ -1008,7 +1136,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "36 144"; + position = "36 232"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1024,7 +1152,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "231 129"; + position = "231 217"; extent = "97 22"; minExtent = "8 8"; visible = "1"; @@ -1036,7 +1164,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "241 144"; + position = "241 232"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1051,7 +1179,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "31 179"; + position = "31 267"; extent = "170 30"; minExtent = "26 27"; visible = "1"; @@ -1064,7 +1192,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "231 169"; + position = "231 257"; extent = "74 22"; minExtent = "8 8"; visible = "0"; @@ -1076,7 +1204,7 @@ new GuiControl(OptionsDlg) { profile = "DisabledTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "231 169"; + position = "231 257"; extent = "74 22"; minExtent = "8 8"; visible = "1"; @@ -1088,7 +1216,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "241 184"; + position = "241 272"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1100,15 +1228,26 @@ new GuiControl(OptionsDlg) { value = "0.8"; usePlusMinus = "1"; }; + }; + new ShellFieldCtrl(OP_VoicePane) { + profile = "ShellFieldProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "138 42"; + extent = "437 316"; + minExtent = "16 18"; + visible = "1"; + helpTag = "0"; + new ShellToggleButton(OP_MicrophoneEnabledTgl) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "31 231"; + position = "31 13"; extent = "170 30"; minExtent = "26 27"; visible = "1"; - variable = "$pref::Audio::microphoneEnabled"; + variable = "$pref::Audio::enableVoiceCapture"; helpTag = "0"; text = "MICROPHONE ENABLED"; maxLength = "255"; @@ -1117,7 +1256,7 @@ new GuiControl(OptionsDlg) { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "232 226"; + position = "232 8"; extent = "173 38"; minExtent = "32 38"; visible = "1"; @@ -1130,7 +1269,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "28 261"; + position = "28 43"; extent = "102 22"; minExtent = "8 8"; visible = "1"; @@ -1142,7 +1281,7 @@ new GuiControl(OptionsDlg) { profile = "DisabledTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "28 261"; + position = "28 43"; extent = "102 22"; minExtent = "8 8"; visible = "0"; @@ -1154,7 +1293,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "38 276"; + position = "38 58"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1169,7 +1308,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "231 261"; + position = "231 43"; extent = "123 22"; minExtent = "8 8"; visible = "1"; @@ -1181,7 +1320,7 @@ new GuiControl(OptionsDlg) { profile = "DisabledTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "231 261"; + position = "231 43"; extent = "123 22"; minExtent = "8 8"; visible = "0"; @@ -1193,7 +1332,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextCenterProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "271 279"; + position = "271 61"; extent = "110 22"; minExtent = "8 8"; visible = "1"; @@ -1205,7 +1344,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "241 276"; + position = "241 58"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1217,6 +1356,88 @@ new GuiControl(OptionsDlg) { value = "4.78947"; usePlusMinus = "1"; }; + new GuiTextCtrl(OP_VoiceListenLabel) { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "46 96"; + extent = "140 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Voice Listen Quality:"; + maxLength = "255"; + }; + new ShellPopupMenu(OP_VoiceListenMenu) { + profile = "ShellPopupProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "183 87"; + extent = "169 36"; + minExtent = "49 36"; + visible = "1"; + helpTag = "0"; + text = "Select Quality"; + maxLength = "255"; + maxPopupHeight = "200"; + buttonBitmap = "gui/shll_pulldown"; + rolloverBarBitmap = "gui/shll_pulldownbar_rol"; + selectedBarBitmap = "gui/shll_pulldownbar_act"; + noButtonStyle = "0"; + }; + new GuiTextCtrl(OP_VoiceSendLabel) { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "46 126"; + extent = "140 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Voice Send Quality:"; + maxLength = "255"; + }; + new ShellPopupMenu(OP_VoiceSendMenu) { + profile = "ShellPopupProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "183 117"; + extent = "169 36"; + minExtent = "49 36"; + visible = "1"; + helpTag = "0"; + text = "Select Quality"; + maxLength = "255"; + maxPopupHeight = "200"; + buttonBitmap = "gui/shll_pulldown"; + rolloverBarBitmap = "gui/shll_pulldownbar_rol"; + selectedBarBitmap = "gui/shll_pulldownbar_act"; + noButtonStyle = "0"; + }; + new GuiTextCtrl(OP_VoiceListenLabel_Disabled) { + profile = "DisabledTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "46 96"; + extent = "140 22"; + minExtent = "8 8"; + visible = "0"; + helpTag = "0"; + text = "Voice Listen Quality:"; + maxLength = "255"; + }; + new GuiTextCtrl(OP_VoiceSendLabel_Disabled) { + profile = "DisabledTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "46 126"; + extent = "140 22"; + minExtent = "8 8"; + visible = "0"; + helpTag = "0"; + text = "Voice Send Quality:"; + maxLength = "255"; + }; }; new ShellFieldCtrl(OP_ControlsPane) { profile = "ShellFieldProfile"; @@ -1232,8 +1453,8 @@ new GuiControl(OptionsDlg) { profile = "NewScrollCtrlProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "2 2"; - extent = "290 282"; + position = "2 31"; + extent = "290 253"; minExtent = "24 52"; visible = "1"; helpTag = "0"; @@ -1250,7 +1471,7 @@ new GuiControl(OptionsDlg) { horizSizing = "right"; vertSizing = "bottom"; position = "4 6"; - extent = "266 270"; + extent = "266 241"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -1290,7 +1511,7 @@ new GuiControl(OptionsDlg) { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "292 46"; + position = "292 38"; extent = "140 38"; minExtent = "32 38"; visible = "1"; @@ -1303,7 +1524,7 @@ new GuiControl(OptionsDlg) { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "292 84"; + position = "292 68"; extent = "140 38"; minExtent = "32 38"; visible = "1"; @@ -1312,11 +1533,24 @@ new GuiControl(OptionsDlg) { text = "SAVE AS"; simpleStyle = "0"; }; + new ShellToggleButton(OP_MouseTgl) { + profile = "ShellRadioProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "296 116"; + extent = "126 30"; + minExtent = "26 27"; + visible = "0"; + variable = "pref::Input::MouseEnabled"; + helpTag = "0"; + text = "DINPUT MOUSE"; + maxLength = "255"; + }; new ShellBitmapButton(OP_ConfigureMouseBtn) { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "292 155"; + position = "292 146"; extent = "140 38"; minExtent = "32 38"; visible = "1"; @@ -1325,32 +1559,31 @@ new GuiControl(OptionsDlg) { text = "CONFIGURE MOUSE"; simpleStyle = "0"; }; - new ShellBitmapButton(OP_ConfigureJoystickBtn) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "292 231"; - extent = "140 38"; - minExtent = "32 38"; - visible = "0"; - command = "Canvas.pushDialog(JoystickConfigDlg);"; - helpTag = "0"; - text = "CONFIGURE JOYSTICK"; - simpleStyle = "0"; - }; new ShellToggleButton(OP_JoystickTgl) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "296 197"; + position = "296 194"; extent = "126 30"; minExtent = "26 27"; - visible = "0"; - variable = "pref::Input::JoystickEnabled"; + visible = "1"; helpTag = "0"; text = "ENABLE JOYSTICK"; maxLength = "255"; }; + new ShellBitmapButton(OP_ConfigureJoystickBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "292 224"; + extent = "140 38"; + minExtent = "32 38"; + visible = "1"; + command = "Canvas.pushDialog(JoystickConfigDlg);"; + helpTag = "0"; + text = "CONFIGURE JOYSTICK"; + simpleStyle = "0"; + }; new GuiTextCtrl() { profile = "ShellTextRightProfile"; horizSizing = "right"; @@ -1386,6 +1619,35 @@ new GuiControl(OptionsDlg) { text = "grave"; }; }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "22 9"; + extent = "100 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Control Group:"; + maxLength = "255"; + }; + new ShellPopupMenu(OP_ControlGroupMenu) { + profile = "ShellPopupProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "118 0"; + extent = "180 36"; + minExtent = "49 36"; + visible = "1"; + helpTag = "0"; + text = "Select Control Group"; + maxLength = "255"; + maxPopupHeight = "200"; + buttonBitmap = "gui/shll_pulldown"; + rolloverBarBitmap = "gui/shll_pulldownbar_rol"; + selectedBarBitmap = "gui/shll_pulldownbar_act"; + noButtonStyle = "0"; + }; }; new ShellFieldCtrl(OP_NetworkPane) { profile = "ShellFieldProfile"; @@ -1397,11 +1659,62 @@ new GuiControl(OptionsDlg) { visible = "0"; helpTag = "0"; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "9 16"; + extent = "60 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Presets:"; + maxLength = "255"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "68 8"; + extent = "110 38"; + minExtent = "32 38"; + visible = "1"; + command = "OP_NetworkPane.applyPresets( \"modem1\" );"; + helpTag = "0"; + text = "28.8 MODEM"; + simpleStyle = "0"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "170 8"; + extent = "110 38"; + minExtent = "32 38"; + visible = "1"; + command = "OP_NetworkPane.applyPresets( \"modem2\" );"; + helpTag = "0"; + text = "56K MODEM"; + simpleStyle = "0"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "272 8"; + extent = "110 38"; + minExtent = "32 38"; + visible = "1"; + command = "OP_NetworkPane.applyPresets( \"lan\" );"; + helpTag = "0"; + text = "DSL/LAN"; + simpleStyle = "0"; + }; new GuiTextCtrl() { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "26 8"; + position = "26 52"; extent = "65 22"; minExtent = "8 8"; visible = "1"; @@ -1413,7 +1726,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "36 23"; + position = "36 67"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1428,7 +1741,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "231 8"; + position = "231 52"; extent = "62 22"; minExtent = "8 8"; visible = "1"; @@ -1440,7 +1753,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "241 23"; + position = "241 67"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1455,7 +1768,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "26 48"; + position = "26 92"; extent = "99 22"; minExtent = "8 8"; visible = "1"; @@ -1467,7 +1780,7 @@ new GuiControl(OptionsDlg) { profile = "ShellSliderProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "36 63"; + position = "36 107"; extent = "170 24"; minExtent = "12 24"; visible = "1"; @@ -1482,7 +1795,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "11 119"; + position = "11 153"; extent = "200 22"; minExtent = "8 8"; visible = "1"; @@ -1494,7 +1807,7 @@ new GuiControl(OptionsDlg) { profile = "ShellPopupProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "208 110"; + position = "208 144"; extent = "180 36"; minExtent = "49 36"; visible = "1"; @@ -1511,7 +1824,7 @@ new GuiControl(OptionsDlg) { profile = "ShellTextRightProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "67 157"; + position = "67 191"; extent = "144 22"; minExtent = "8 8"; visible = "1"; @@ -1523,7 +1836,7 @@ new GuiControl(OptionsDlg) { profile = "ShellPopupProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "208 148"; + position = "208 182"; extent = "180 36"; minExtent = "49 36"; visible = "1"; @@ -1540,7 +1853,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "123 208"; + position = "123 233"; extent = "190 30"; minExtent = "26 27"; visible = "1"; @@ -1553,7 +1866,7 @@ new GuiControl(OptionsDlg) { profile = "ShellRadioProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "123 236"; + position = "123 261"; extent = "190 30"; minExtent = "26 27"; visible = "1"; diff --git a/base/gui/TribeAndWarriorBrowserGui.gui b/base/gui/TribeAndWarriorBrowserGui.gui index 2c1748a..c042176 100644 --- a/base/gui/TribeAndWarriorBrowserGui.gui +++ b/base/gui/TribeAndWarriorBrowserGui.gui @@ -28,8 +28,8 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { profile = "ShellHorzTabFrameProfile"; horizSizing = "width"; vertSizing = "bottom"; - position = "28 63"; - extent = "564 270"; + position = "22 54"; + extent = "576 254"; minExtent = "26 254"; visible = "1"; helpTag = "0"; @@ -41,8 +41,8 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { profile = "TabGroupProfile"; horizSizing = "width"; vertSizing = "bottom"; - position = "38 34"; - extent = "546 29"; + position = "30 25"; + extent = "560 29"; minExtent = "38 29"; visible = "1"; helpTag = "0"; @@ -55,8 +55,8 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { profile = "ShellFieldProfile"; horizSizing = "width"; vertSizing = "height"; - position = "39 71"; - extent = "543 262"; + position = "33 63"; + extent = "554 270"; minExtent = "16 18"; visible = "1"; helpTag = "0"; @@ -66,7 +66,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "3 27"; - extent = "537 231"; + extent = "550 239"; minExtent = "16 18"; visible = "0"; helpTag = "0"; @@ -76,7 +76,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "237 20"; - extent = "297 209"; + extent = "310 217"; minExtent = "16 18"; visible = "1"; helpTag = "0"; @@ -86,7 +86,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "2 6"; - extent = "293 201"; + extent = "306 209"; minExtent = "24 52"; visible = "1"; helpTag = "0"; @@ -103,7 +103,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "bottom"; position = "9 9"; - extent = "275 183"; + extent = "288 191"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -113,7 +113,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "0 0"; - extent = "259 16"; + extent = "272 16"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -129,7 +129,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "right"; vertSizing = "height"; position = "3 3"; - extent = "234 226"; + extent = "234 234"; minExtent = "16 18"; visible = "1"; helpTag = "0"; @@ -148,11 +148,11 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { wrap = "0"; }; new ShellFancyArrayScrollCtrl(ML1) { - profile = "clockProfile"; + profile = "ShellServerBrowserProfile"; horizSizing = "width"; vertSizing = "height"; position = "-2 151"; - extent = "237 77"; + extent = "237 85"; minExtent = "24 52"; visible = "1"; helpTag = "0"; @@ -165,7 +165,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "right"; vertSizing = "bottom"; position = "0 16"; - extent = "237 61"; + extent = "237 69"; minExtent = "8 52"; visible = "1"; helpTag = "0"; @@ -181,7 +181,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "right"; vertSizing = "bottom"; position = "4 7"; - extent = "213 47"; + extent = "213 55"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -199,11 +199,11 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { }; }; new ShellFancyTextList(MemberList) { - profile = "clockProfile"; + profile = "ShellBrowserListProfile"; horizSizing = "width"; vertSizing = "height"; position = "0 0"; - extent = "217 73"; + extent = "217 81"; minExtent = "8 20"; visible = "1"; altCommand = "TribePane.RosterDblClick();"; @@ -223,6 +223,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { drawSeparators = "0"; headerSort = "1"; allowReposition = "1"; + noSelect = "0"; }; }; }; @@ -302,7 +303,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "3 27"; - extent = "537 231"; + extent = "550 239"; minExtent = "16 18"; visible = "1"; helpTag = "0"; @@ -312,7 +313,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "237 20"; - extent = "297 209"; + extent = "310 217"; minExtent = "16 18"; visible = "1"; helpTag = "0"; @@ -322,7 +323,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "2 2"; - extent = "293 205"; + extent = "306 213"; minExtent = "24 52"; visible = "1"; helpTag = "0"; @@ -339,7 +340,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "bottom"; position = "4 4"; - extent = "269 197"; + extent = "298 205"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -349,7 +350,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "bottom"; position = "0 0"; - extent = "273 204"; + extent = "286 16"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -365,7 +366,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "right"; vertSizing = "height"; position = "3 3"; - extent = "234 226"; + extent = "234 234"; minExtent = "16 18"; visible = "1"; helpTag = "0"; @@ -388,7 +389,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "height"; position = "-2 151"; - extent = "237 75"; + extent = "237 83"; minExtent = "24 52"; visible = "1"; helpTag = "0"; @@ -401,7 +402,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "right"; vertSizing = "bottom"; position = "0 16"; - extent = "237 59"; + extent = "237 67"; minExtent = "8 52"; visible = "1"; helpTag = "0"; @@ -417,7 +418,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "right"; vertSizing = "bottom"; position = "4 7"; - extent = "213 45"; + extent = "213 53"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -427,7 +428,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "right"; vertSizing = "bottom"; position = "0 0"; - extent = "8 47"; + extent = "8 8"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -435,11 +436,11 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { }; }; new ShellFancyTextList(W_MemberList) { - profile = "clockProfile"; + profile = "ShellBrowserListProfile"; horizSizing = "width"; vertSizing = "height"; position = "0 0"; - extent = "217 71"; + extent = "217 79"; minExtent = "8 20"; visible = "1"; altCommand = "PlayerPane.DblClick();"; @@ -458,6 +459,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { drawSeparators = "0"; headerSort = "1"; allowReposition = "0"; + noSelect = "0"; }; }; }; @@ -537,7 +539,7 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { horizSizing = "width"; vertSizing = "bottom"; position = "7 5"; - extent = "8 26"; + extent = "155 26"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -546,27 +548,27 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { name = "EAST"; OldText = "EAST"; }; - new ShellBitmapButton(TWBClosePaneBtn) { - profile = "ShellButtonProfile"; - horizSizing = "left"; - vertSizing = "bottom"; - position = "506 -3"; - extent = "43 38"; - minExtent = "32 38"; - visible = "0"; - command = "TWBTabView.closeCurrentPane();"; - accelerator = "escape"; - helpTag = "0"; - text = "X"; - simpleStyle = "0"; - }; + }; + new ShellBitmapButton(TWBClosePaneBtn) { + profile = "ShellButtonProfile"; + horizSizing = "left"; + vertSizing = "bottom"; + position = "552 60"; + extent = "43 38"; + minExtent = "32 38"; + visible = "1"; + command = "TWBTabView.closeCurrentPane();"; + accelerator = "escape"; + helpTag = "0"; + text = "X"; + simpleStyle = "0"; }; new ShellBitmapButton() { profile = "ShellButtonProfile"; horizSizing = "left"; vertSizing = "top"; - position = "303 330"; - extent = "104 38"; + position = "221 335"; + extent = "128 38"; minExtent = "32 38"; visible = "1"; command = "CreateTribe();"; @@ -578,8 +580,8 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { profile = "ShellButtonProfile"; horizSizing = "left"; vertSizing = "top"; - position = "390 330"; - extent = "102 38"; + position = "341 335"; + extent = "128 38"; minExtent = "32 38"; visible = "1"; command = "SearchTribes();"; @@ -591,8 +593,8 @@ new GuiChunkedBitmapCtrl(TribeAndWarriorBrowserGui) { profile = "ShellButtonProfile"; horizSizing = "left"; vertSizing = "top"; - position = "475 330"; - extent = "114 38"; + position = "461 335"; + extent = "128 38"; minExtent = "32 38"; visible = "1"; command = "SearchWarriors();"; diff --git a/base/gui/TribeAttribDlg.gui b/base/gui/TribeAttribDlg.gui deleted file mode 100644 index bdbdf2f..0000000 --- a/base/gui/TribeAttribDlg.gui +++ /dev/null @@ -1,151 +0,0 @@ -//--- OBJECT WRITE BEGIN --- -new GuiControl(TribeAttribDlg) { - profile = "DlgBackProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "0 0"; - extent = "640 480"; - minExtent = "8 8"; - visible = "1"; - variable = "$NewTagAppend"; - helpTag = "0"; - tribename = "DEV Team"; - - new ShellPaneCtrl() { - profile = "ShellDlgPaneProfile"; - horizSizing = "center"; - vertSizing = "center"; - position = "155 145"; - extent = "330 190"; - minExtent = "48 92"; - visible = "1"; - helpTag = "0"; - text = "CHANGE TRIBE TAG"; - noTitleBar = "0"; - - new GuiTextCtrl() { - profile = "ShellTextRightProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "65 41"; - extent = "80 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "Current:"; - }; - new ShellFieldCtrl() { - profile = "ShellFieldProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "151 39"; - extent = "130 22"; - minExtent = "16 18"; - visible = "1"; - helpTag = "0"; - - new GuiTextCtrl(TAD_CurrentTag) { - profile = "ShellAltTextCenterProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "1 3"; - extent = "124 20"; - minExtent = "8 8"; - visible = "1"; - variable = "$CurrentTribeTag"; - helpTag = "0"; - text = "TAG"; - }; - }; - new GuiTextCtrl() { - profile = "ShellTextRightProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "65 71"; - extent = "80 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "New:"; - }; - new ShellTextEditCtrl(TAD_NewTag) { - profile = "NewTextEditProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "141 63"; - extent = "148 38"; - minExtent = "32 38"; - visible = "1"; - variable = "$NewTribeTag"; - command = "updateNewTagPreview();"; - helpTag = "0"; - historySize = "0"; - maxLength = "8"; - password = "0"; - glowOffset = "9 9"; - }; - new GuiTextCtrl() { - profile = "ShellTextRightProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "29 101"; - extent = "65 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "Preview:"; - }; - new ShellFieldCtrl() { - profile = "ShellFieldProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "100 101"; - extent = "180 22"; - minExtent = "16 18"; - visible = "1"; - helpTag = "0"; - - new GuiTextCtrl(TAD_PreviewTag) { - profile = "ShellAltTextCenterProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "0 3"; - extent = "180 20"; - minExtent = "8 8"; - visible = "1"; - variable = "$NewTagPreview"; - helpTag = "0"; - text = "PREVIEW"; - }; - }; - new ShellBitmapButton(TAD_OKBtn) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "top"; - position = "187 135"; - extent = "100 38"; - minExtent = "32 38"; - visible = "1"; - command = "TribeAttribDlg.ChangeTribeTag();"; - accelerator = "Enter"; - helpTag = "0"; - text = "OK"; - simpleStyle = "0"; - }; - new ShellBitmapButton(TAD_CancelBtn) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "top"; - position = "43 135"; - extent = "100 38"; - minExtent = "32 38"; - visible = "1"; - command = "Canvas.popDialog(TribeAttribDlg);"; - accelerator = "escape"; - helpTag = "0"; - text = "CANCEL"; - simpleStyle = "0"; - }; - }; -}; -//--- OBJECT WRITE END --- diff --git a/base/gui/TribePropertiesDlg.gui b/base/gui/TribePropertiesDlg.gui index b3b7277..e6e369f 100644 --- a/base/gui/TribePropertiesDlg.gui +++ b/base/gui/TribePropertiesDlg.gui @@ -14,12 +14,13 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { profile = "ShellDlgProfile"; horizSizing = "center"; vertSizing = "center"; - position = "113 2"; + position = "116 63"; extent = "408 354"; minExtent = "8 8"; visible = "1"; helpTag = "0"; text = "TRIBE PROPERTIES"; + maxLength = "255"; new ShellFieldCtrl() { profile = "ShellFieldProfile"; @@ -135,6 +136,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "ACTIONS"; + maxLength = "255"; }; new ShellRadioButton() { profile = "ShellRadioProfile"; @@ -146,6 +148,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Admin 3 [4]"; + maxLength = "255"; groupNum = "7"; }; new GuiTextCtrl() { @@ -158,6 +161,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Required Access Level"; + maxLength = "255"; }; new ShellRadioButton() { profile = "ShellRadioProfile"; @@ -169,6 +173,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Admin 2 [3]"; + maxLength = "255"; groupNum = "7"; }; new ShellRadioButton() { @@ -181,6 +186,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Admin 1 [2]"; + maxLength = "255"; groupNum = "7"; }; new ShellRadioButton() { @@ -193,6 +199,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Member [1]"; + maxLength = "255"; groupNum = "7"; }; new ShellRadioButton() { @@ -205,6 +212,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Public [0] "; + maxLength = "255"; groupNum = "7"; }; new ShellBitmapButton(TP_UpdateSecurityBtn) { @@ -277,6 +285,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "DESCRIPTION"; + maxLength = "255"; }; new ShellBitmapButton(TP_EditDescBtn) { profile = "ShellButtonProfile"; @@ -336,12 +345,13 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { horizSizing = "left"; vertSizing = "relative"; position = "0 0"; - extent = "249 14"; + extent = "249 28"; minExtent = "8 8"; visible = "1"; helpTag = "0"; lineSpacing = "2"; allowColorChars = "1"; + maxChars = "-1"; }; }; }; @@ -376,6 +386,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "TRIBE TAG"; + maxLength = "255"; }; new ShellRadioButton(TP_PrePendFlagBtn) { profile = "ShellRadioProfile"; @@ -388,6 +399,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { command = "TribePropertiesDlg.ToggleAppending();"; helpTag = "0"; text = "PREPEND TAG"; + maxLength = "255"; groupNum = "8"; }; new ShellRadioButton(TP_AppendFlagBtn) { @@ -401,6 +413,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { command = "TribePropertiesDlg.ToggleAppending();"; helpTag = "0"; text = "APPEND TAG"; + maxLength = "255"; groupNum = "8"; }; }; @@ -414,8 +427,8 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; command = "TribePropertiesDlg.RefreshTag();"; helpTag = "0"; - historySize = "0"; maxLength = "9"; + historySize = "0"; password = "0"; glowOffset = "9 9"; }; @@ -429,6 +442,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "CURRENT:"; + maxLength = "255"; }; new GuiTextCtrl(TP_CurrentTag) { profile = "GuiDefaultProfile"; @@ -440,6 +454,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "TAG"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "ShellTextProfile"; @@ -451,6 +466,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "NEW TAG:"; + maxLength = "255"; }; new GuiTextCtrl(TP_PreviewTag) { profile = "GuiDefaultProfile"; @@ -462,6 +478,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "TAG"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "ShellTextProfile"; @@ -473,6 +490,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "PREVIEW:"; + maxLength = "255"; }; new ShellBitmapButton(TP_TribeTagBtn) { profile = "ShellButtonProfile"; @@ -498,6 +516,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "DISBAND TRIBE"; + maxLength = "255"; }; new GuiTextCtrl(TP_RecruitingLabel) { profile = "ShellTextProfile"; @@ -509,6 +528,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "RECRUITING"; + maxLength = "255"; }; new ShellRadioButton(TP_RecruitFlagBtn) { profile = "ShellRadioProfile"; @@ -521,6 +541,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { command = "TribePropertiesDlg.ChangeRecruiting();"; helpTag = "0"; text = "YES"; + maxLength = "255"; groupNum = "7"; }; new ShellRadioButton(TP_RecruitFlagNoBtn) { @@ -534,6 +555,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { command = "TribePropertiesDlg.ChangeRecruiting();"; helpTag = "0"; text = "NO"; + maxLength = "255"; groupNum = "7"; }; }; @@ -569,6 +591,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Current Tribe Graphic:"; + maxLength = "255"; }; new ShellBitmapButton(TP_SubmitGraphicBtn) { profile = "ShellButtonProfile"; @@ -592,11 +615,11 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { minExtent = "8 8"; visible = "1"; helpTag = "0"; - bitmap = "texticons/twb_Lineup.jpg"; + bitmap = "texticons/twb/twb_Laserrifle.jpg"; wrap = "0"; }; new ShellFancyArrayScrollCtrl(ML1) { - profile = "clockProfile"; + profile = "ShellServerBrowserProfile"; horizSizing = "width"; vertSizing = "height"; position = "233 21"; @@ -638,8 +661,8 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { profile = "GuiDefaultProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "0 -195"; - extent = "8 1307"; + position = "0 0"; + extent = "8 962"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -647,7 +670,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { }; }; new ShellFancyTextList(TribeGraphicsList) { - profile = "clockProfile"; + profile = "ShellBrowserListProfile"; horizSizing = "width"; vertSizing = "height"; position = "0 0"; @@ -671,7 +694,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { drawSeparators = "0"; headerSort = "1"; allowReposition = "1"; - CID = "0"; + noSelect = "0"; }; }; new GuiTextCtrl() { @@ -684,6 +707,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "-------------- Graphic Requirements --------------"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "GuiTextProfile"; @@ -695,6 +719,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Max Dimensions:"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "GuiTextProfile"; @@ -706,6 +731,7 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Max Size:"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "GuiTextProfile"; @@ -717,39 +743,43 @@ new GuiChunkedBitmapCtrl(TribePropertiesDlg) { visible = "1"; helpTag = "0"; text = "Format:"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "BrowserFilterTextProfile"; horizSizing = "right"; vertSizing = "bottom"; position = "131 203"; - extent = "26 22"; + extent = "20 22"; minExtent = "8 8"; visible = "1"; helpTag = "0"; text = "28k"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "BrowserFilterTextProfile"; horizSizing = "right"; vertSizing = "bottom"; position = "131 216"; - extent = "36 22"; + extent = "27 22"; minExtent = "8 8"; visible = "1"; helpTag = "0"; text = "JPEG"; + maxLength = "255"; }; new GuiTextCtrl() { profile = "BrowserFilterTextProfile"; horizSizing = "right"; vertSizing = "bottom"; position = "131 190"; - extent = "93 22"; + extent = "70 22"; minExtent = "8 8"; visible = "1"; helpTag = "0"; text = "228w x 150h"; + maxLength = "255"; }; }; }; diff --git a/base/gui/WarriorPropertiesDlg.gui b/base/gui/WarriorPropertiesDlg.gui index c6669d7..87968c5 100644 --- a/base/gui/WarriorPropertiesDlg.gui +++ b/base/gui/WarriorPropertiesDlg.gui @@ -14,14 +14,230 @@ new GuiChunkedBitmapCtrl(WarriorPropertiesDlg) { profile = "ShellDlgProfile"; horizSizing = "center"; vertSizing = "center"; - position = "116 50"; - extent = "408 380"; + position = "116 69"; + extent = "408 342"; minExtent = "8 8"; visible = "1"; helpTag = "0"; text = "WARRIOR PROPERTIES"; maxLength = "255"; + new ShellFieldCtrl(W_ProfilePane) { + profile = "ShellFieldProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "10 63"; + extent = "385 239"; + minExtent = "16 18"; + visible = "1"; + helpTag = "0"; + + new ShellBitmapButton(WP_EditDescriptionBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "0 103"; + extent = "95 38"; + minExtent = "32 38"; + visible = "1"; + command = "WarriorPropertiesDlg.editDescription();"; + helpTag = "0"; + text = "EDIT"; + simpleStyle = "0"; + }; + new ShellFieldCtrl() { + profile = "ShellFieldProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "180 4"; + extent = "201 77"; + minExtent = "16 18"; + visible = "1"; + helpTag = "0"; + + new GuiTextCtrl() { + profile = "ShellTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "7 14"; + extent = "25 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "URL:"; + maxLength = "255"; + }; + new ShellTextEditCtrl(UrlEdit) { + profile = "NewTextEditProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "27 6"; + extent = "178 38"; + minExtent = "32 38"; + visible = "1"; + helpTag = "0"; + text = "www.tribes2.com"; + maxLength = "255"; + historySize = "0"; + password = "0"; + glowOffset = "9 9"; + }; + new ShellBitmapButton(WP_ChangeUrl) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "-2 40"; + extent = "206 38"; + minExtent = "32 38"; + visible = "1"; + command = "WarriorPropertiesDlg.UpdateUrl();"; + helpTag = "0"; + text = "CHANGE HOME ADDRESS"; + simpleStyle = "0"; + }; + }; + new ShellBitmapButton(WP_ClearDescriptionBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "0 128"; + extent = "95 38"; + minExtent = "32 38"; + visible = "1"; + command = "WarriorPropertiesDlg.clearDescription();"; + helpTag = "0"; + text = "CLEAR"; + simpleStyle = "0"; + }; + new GuiTextCtrl() { + profile = "ShellTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "10 88"; + extent = "76 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "DESCRIPTION:"; + maxLength = "255"; + }; + new ShellFieldCtrl() { + profile = "ShellFieldProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "3 3"; + extent = "175 78"; + minExtent = "16 18"; + visible = "1"; + helpTag = "0"; + + new GuiTextCtrl() { + profile = "ShellTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "11 4"; + extent = "35 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "NAME:"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "ShellTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "18 24"; + extent = "27 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "NEW:"; + maxLength = "255"; + }; + new ShellBitmapButton(WP_ChangeNameBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "-2 42"; + extent = "179 38"; + minExtent = "32 38"; + visible = "1"; + command = "WarriorPropertiesDlg.ChangePlayerName();"; + helpTag = "0"; + text = "CHANGE NAME"; + simpleStyle = "0"; + }; + new ShellTextEditCtrl(NewNameEdit) { + profile = "NewTextEditProfile"; + horizSizing = "left"; + vertSizing = "bottom"; + position = "39 16"; + extent = "138 38"; + minExtent = "32 38"; + visible = "1"; + helpTag = "0"; + maxLength = "16"; + historySize = "0"; + password = "0"; + glowOffset = "9 9"; + }; + new GuiTextCtrl(wp_currentname) { + profile = "BrowserProgressProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "51 6"; + extent = "113 17"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "EAST"; + maxLength = "20"; + }; + }; + new ShellScrollCtrl() { + profile = "NewScrollCtrlProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "87 88"; + extent = "295 147"; + minExtent = "24 52"; + visible = "1"; + helpTag = "0"; + willFirstRespond = "1"; + hScrollBar = "alwaysOff"; + vScrollBar = "alwaysOn"; + constantThumbHeight = "0"; + defaultLineHeight = "15"; + childMargin = "10 5"; + fieldBase = "gui/shll_field"; + + new GuiScrollContentCtrl() { + profile = "GuiDefaultProfile"; + horizSizing = "right"; + vertSizing = "height"; + position = "14 9"; + extent = "251 129"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + + new GuiMLTextCtrl(WP_WarriorDescription) { + profile = "GuiDefaultProfile"; + horizSizing = "left"; + vertSizing = "relative"; + position = "0 0"; + extent = "249 28"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + lineSpacing = "2"; + allowColorChars = "1"; + maxChars = "-1"; + }; + }; + }; + }; new ShellFieldCtrl() { profile = "ShellFieldProfile"; horizSizing = "right"; @@ -40,16 +256,30 @@ new GuiChunkedBitmapCtrl(WarriorPropertiesDlg) { extent = "105 38"; minExtent = "32 38"; visible = "1"; + command = "W_GraphicsControl.setVisible(0);W_ProfilePane.setVisible(1);"; helpTag = "0"; text = "PROFILE"; simpleStyle = "0"; }; + new ShellBitmapButton(WP_GFXBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "82 -5"; + extent = "105 38"; + minExtent = "32 38"; + visible = "1"; + command = "W_ProfilePane.setVisible(0);W_GraphicsControl.setVisible(1);WarriorPropertiesDlg.LoadGfxPane();"; + helpTag = "0"; + text = "GFX"; + simpleStyle = "0"; + }; }; new ShellBitmapButton(W_OKBtn) { profile = "ShellButtonProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "312 337"; + position = "312 298"; extent = "91 38"; minExtent = "32 38"; visible = "1"; @@ -58,22 +288,155 @@ new GuiChunkedBitmapCtrl(WarriorPropertiesDlg) { text = "CLOSE"; simpleStyle = "0"; }; - new ShellFieldCtrl(W_ProfilePane) { + new ShellFieldCtrl(W_GraphicsControl) { profile = "ShellFieldProfile"; horizSizing = "right"; vertSizing = "bottom"; position = "10 63"; - extent = "385 277"; + extent = "385 239"; minExtent = "16 18"; - visible = "1"; + visible = "0"; helpTag = "0"; - new ShellFancyArrayScrollCtrl(WGL) { - profile = "clockProfile"; + new ShellBitmapButton(TP_SubmitGraphicBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "229 198"; + extent = "158 38"; + minExtent = "32 38"; + visible = "0"; + helpTag = "0"; + text = "FIND NEW GRAPHIC"; + simpleStyle = "0"; + }; + new GuiTextCtrl() { + profile = "BrowserProgressProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "9 8"; + extent = "125 17"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Current Graphic:"; + maxLength = "255"; + }; + new ShellBitmapButton(WP_SubmitGraphicBtn) { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "229 173"; + extent = "158 38"; + minExtent = "32 38"; + visible = "1"; + command = "WarriorPropertiesDlg.SetPlayerGraphic();"; + helpTag = "0"; + text = "USE SELECTED GRAPHIC"; + simpleStyle = "0"; + }; + new GuiBitmapCtrl(PlayerGraphic) { + profile = "GuiDefaultProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "6 24"; + extent = "228 150"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + bitmap = "texticons/twb/twb_Missilelauncher.jpg"; + wrap = "0"; + }; + new GuiTextCtrl() { + profile = "BrowserFilterTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "131 190"; + extent = "70 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "228w x 150h"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "BrowserProgressProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "4 177"; + extent = "230 19"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "-------------- Graphic Requirements --------------"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "GuiTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "21 190"; + extent = "102 20"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Max Dimensions:"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "GuiTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "65 203"; + extent = "58 20"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Max Size:"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "GuiTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "77 216"; + extent = "46 20"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Format:"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "BrowserFilterTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "131 203"; + extent = "20 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "28k"; + maxLength = "255"; + }; + new GuiTextCtrl() { + profile = "BrowserFilterTextProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "131 216"; + extent = "27 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "JPEG"; + maxLength = "255"; + }; + new ShellFancyArrayScrollCtrl(WL1) { + profile = "ShellServerBrowserProfile"; horizSizing = "width"; vertSizing = "height"; - position = "233 101"; - extent = "152 148"; + position = "233 21"; + extent = "149 156"; minExtent = "24 52"; visible = "1"; helpTag = "0"; @@ -86,7 +449,7 @@ new GuiChunkedBitmapCtrl(WarriorPropertiesDlg) { horizSizing = "right"; vertSizing = "bottom"; position = "0 16"; - extent = "152 132"; + extent = "149 140"; minExtent = "8 52"; visible = "1"; helpTag = "0"; @@ -97,22 +460,22 @@ new GuiChunkedBitmapCtrl(WarriorPropertiesDlg) { defaultLineHeight = "15"; childMargin = "0 3"; - new VirtualScrollContentCtrl(ML3) { + new VirtualScrollContentCtrl(WL3) { profile = "GuiDefaultProfile"; horizSizing = "right"; vertSizing = "bottom"; position = "4 7"; - extent = "128 118"; + extent = "125 126"; minExtent = "8 8"; visible = "1"; helpTag = "0"; - new GuiControl(ML4) { + new GuiControl(WL4) { profile = "GuiDefaultProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "0 0"; - extent = "8 8"; + position = "0 -212"; + extent = "8 962"; minExtent = "8 8"; visible = "1"; helpTag = "0"; @@ -120,11 +483,11 @@ new GuiChunkedBitmapCtrl(WarriorPropertiesDlg) { }; }; new ShellFancyTextList(WarriorGraphicsList) { - profile = "clockProfile"; + profile = "ShellBrowserListProfile"; horizSizing = "width"; vertSizing = "height"; position = "0 0"; - extent = "132 144"; + extent = "129 152"; minExtent = "8 20"; visible = "1"; command = "WarriorGraphicsList.onSelect();"; @@ -144,208 +507,9 @@ new GuiChunkedBitmapCtrl(WarriorPropertiesDlg) { drawSeparators = "0"; headerSort = "1"; allowReposition = "1"; + noSelect = "0"; }; }; - new ShellBitmapButton(WP_SubmitGraphicBtn) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "229 242"; - extent = "160 38"; - minExtent = "32 38"; - visible = "1"; - command = "WarriorPropertiesDlg.SetPlayerGraphic();"; - helpTag = "0"; - text = "USE SELECTED GRAPHIC"; - simpleStyle = "0"; - }; - new GuiTextCtrl() { - profile = "BrowserProgressProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "9 104"; - extent = "125 17"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "Current Graphic"; - maxLength = "255"; - }; - new GuiBitmapCtrl(PlayerGraphic) { - profile = "GuiDefaultProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "6 121"; - extent = "228 150"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - bitmap = "texticons/twb/twb_Laserrifle.jpg"; - wrap = "0"; - }; - new ShellFieldCtrl() { - profile = "ShellFieldProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "3 3"; - extent = "175 99"; - minExtent = "16 18"; - visible = "1"; - helpTag = "0"; - - new GuiTextCtrl() { - profile = "ShellTextProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "11 11"; - extent = "35 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "NAME:"; - maxLength = "255"; - }; - new GuiTextCtrl() { - profile = "ShellTextProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "18 38"; - extent = "27 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "NEW:"; - maxLength = "255"; - }; - new ShellBitmapButton(WP_ChangeNameBtn) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "-2 65"; - extent = "179 38"; - minExtent = "32 38"; - visible = "1"; - command = "WarriorPropertiesDlg.ChangePlayerName();"; - helpTag = "0"; - text = "CHANGE NAME"; - simpleStyle = "0"; - }; - new ShellTextEditCtrl(NewNameEdit) { - profile = "NewTextEditProfile"; - horizSizing = "left"; - vertSizing = "bottom"; - position = "39 30"; - extent = "138 38"; - minExtent = "32 38"; - visible = "1"; - helpTag = "0"; - maxLength = "16"; - historySize = "0"; - password = "0"; - glowOffset = "9 9"; - }; - new GuiTextCtrl(WP_CurrentName) { - profile = "BrowserProgressProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "51 13"; - extent = "113 17"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "EAST"; - maxLength = "20"; - }; - }; - new ShellFieldCtrl() { - profile = "ShellFieldProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "180 37"; - extent = "201 65"; - minExtent = "16 18"; - visible = "1"; - helpTag = "0"; - - new GuiTextCtrl() { - profile = "ShellTextProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "8 9"; - extent = "25 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "URL:"; - maxLength = "255"; - }; - new ShellTextEditCtrl(UrlEdit) { - profile = "NewTextEditProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "28 1"; - extent = "178 38"; - minExtent = "32 38"; - visible = "1"; - helpTag = "0"; - text = "www.tribes2.com"; - maxLength = "255"; - historySize = "0"; - password = "0"; - glowOffset = "9 9"; - }; - new ShellBitmapButton(WP_ChangeUrl) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "-2 30"; - extent = "206 38"; - minExtent = "32 38"; - visible = "1"; - command = "WarriorPropertiesDlg.UpdateUrl();"; - helpTag = "0"; - text = "CHANGE HOME ADDRESS"; - simpleStyle = "0"; - }; - }; - new ShellBitmapButton(WP_EditDescriptionBtn) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "317 0"; - extent = "73 38"; - minExtent = "32 38"; - visible = "1"; - command = "WarriorPropertiesDlg.editDescription();"; - helpTag = "0"; - text = "EDIT"; - simpleStyle = "0"; - }; - new ShellBitmapButton(WP_ClearDescriptionBtn) { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "260 0"; - extent = "72 38"; - minExtent = "32 38"; - visible = "1"; - command = "WarriorPropertiesDlg.clearDescription();"; - helpTag = "0"; - text = "CLEAR"; - simpleStyle = "0"; - }; - new GuiTextCtrl() { - profile = "ShellTextProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "186 8"; - extent = "76 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "DESCRIPTION:"; - maxLength = "255"; - }; }; }; }; diff --git a/base/gui/guiProfiles.cs b/base/gui/guiProfiles.cs index def5c12..268080d 100644 --- a/base/gui/guiProfiles.cs +++ b/base/gui/guiProfiles.cs @@ -90,13 +90,6 @@ new GuiControlProfile ("GuiContentProfile") fillColor = "255 255 255"; }; -new GuiControlProfile ("memberListProfile") -{ - fontType = "Univers Condensed"; - fontSize = 12; - fontColor = "255 222 0"; -}; - new GuiControlProfile ("clockProfile") { fontType = "Univers Condensed"; @@ -104,13 +97,6 @@ new GuiControlProfile ("clockProfile") fontColor = "0 255 0"; }; -new GuiControlProfile ("browserListProfile") -{ - fontType = "Univers Condensed"; - fontSize = 14; - fontColor = "0 255 0"; -}; - new GuiControlProfile ("GuiContentProfileNoClear") { opaque = false; @@ -490,6 +476,20 @@ new GuiControlProfile ("ShellServerBrowserProfile") canKeyFocus = true; }; +new GuiControlProfile ("ShellBrowserListProfile") +{ + fontType = $ShellFont; + fontSize = 12; + fontColor = "20 220 20"; + fontColorHL = "60 250 60"; + fontColorNA = "128 128 128"; + fontColorSEL = "0 60 0"; + soundButtonDown = sButtonDown; + soundButtonOver = sButtonOver; + tab = true; + canKeyFocus = true; +}; + new GuiControlProfile ("LobbyPlayerListProfile") { fontType = $ShellFont; diff --git a/base/input.log b/base/input.log new file mode 100644 index 0000000..646feb0 --- /dev/null +++ b/base/input.log @@ -0,0 +1,441 @@ +Input log opened at Wed Mar 28 14:15:31 2001 + +Operating System: + WinNT version 5.0 + Build number 2195 + Service Pack 1 + +Enabling DirectInput... +DirectX 3 detected. +Enumerating input devices... +Keyboard detected, created as keyboard0 (asynchronous). + 128 total objects detected. + 128 keys. + +Mouse detected, created as mouse0 (asynchronous). + 6 total objects detected. + 3 buttons. + 1 x-axis. + 1 y-axis. + 1 z-axis. + +--- Filling the ASCII table! --- +KC: 0X09 DK: 0X01 VK: 0X1B + LOWER- R: 1 A[0]: 0X001B A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X001B A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X0A DK: 0X39 VK: 0X20 + LOWER- R: 1 A[0]: 0X0020 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0020 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X0B DK: 0XD1 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X0C DK: 0XC9 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X0D DK: 0XCF VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X0E DK: 0XC7 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X0F DK: 0XCB VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X10 DK: 0XC8 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X11 DK: 0XCD VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X12 DK: 0XD0 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X13 DK: 0XB7 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X14 DK: 0XD2 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X15 DK: 0XD3 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X17 DK: 0X0B VK: 0X30 + LOWER- R: 1 A[0]: 0X0030 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0029 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X18 DK: 0X02 VK: 0X31 + LOWER- R: 1 A[0]: 0X0031 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0021 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X19 DK: 0X03 VK: 0X32 + LOWER- R: 1 A[0]: 0X0032 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0040 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X1A DK: 0X04 VK: 0X33 + LOWER- R: 1 A[0]: 0X0033 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0023 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X1B DK: 0X05 VK: 0X34 + LOWER- R: 1 A[0]: 0X0034 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0024 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X1C DK: 0X06 VK: 0X35 + LOWER- R: 1 A[0]: 0X0035 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0025 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X1D DK: 0X07 VK: 0X36 + LOWER- R: 1 A[0]: 0X0036 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X005E A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X1E DK: 0X08 VK: 0X37 + LOWER- R: 1 A[0]: 0X0037 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0026 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X1F DK: 0X09 VK: 0X38 + LOWER- R: 1 A[0]: 0X0038 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X002A A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X20 DK: 0X0A VK: 0X39 + LOWER- R: 1 A[0]: 0X0039 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0028 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X21 DK: 0X1E VK: 0X41 + LOWER- R: 1 A[0]: 0X0061 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0041 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X22 DK: 0X30 VK: 0X42 + LOWER- R: 1 A[0]: 0X0062 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0042 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X23 DK: 0X2E VK: 0X43 + LOWER- R: 1 A[0]: 0X0063 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0043 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X24 DK: 0X20 VK: 0X44 + LOWER- R: 1 A[0]: 0X0064 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0044 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X25 DK: 0X12 VK: 0X45 + LOWER- R: 1 A[0]: 0X0065 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0045 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X26 DK: 0X21 VK: 0X46 + LOWER- R: 1 A[0]: 0X0066 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0046 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X27 DK: 0X22 VK: 0X47 + LOWER- R: 1 A[0]: 0X0067 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0047 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X28 DK: 0X23 VK: 0X48 + LOWER- R: 1 A[0]: 0X0068 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0048 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X29 DK: 0X17 VK: 0X49 + LOWER- R: 1 A[0]: 0X0069 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0049 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X2A DK: 0X24 VK: 0X4A + LOWER- R: 1 A[0]: 0X006A A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X004A A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X2B DK: 0X25 VK: 0X4B + LOWER- R: 1 A[0]: 0X006B A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X004B A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X2C DK: 0X26 VK: 0X4C + LOWER- R: 1 A[0]: 0X006C A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X004C A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X2D DK: 0X32 VK: 0X4D + LOWER- R: 1 A[0]: 0X006D A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X004D A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X2E DK: 0X31 VK: 0X4E + LOWER- R: 1 A[0]: 0X006E A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X004E A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X2F DK: 0X18 VK: 0X4F + LOWER- R: 1 A[0]: 0X006F A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X004F A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X30 DK: 0X19 VK: 0X50 + LOWER- R: 1 A[0]: 0X0070 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0050 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X31 DK: 0X10 VK: 0X51 + LOWER- R: 1 A[0]: 0X0071 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0051 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X32 DK: 0X13 VK: 0X52 + LOWER- R: 1 A[0]: 0X0072 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0052 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X33 DK: 0X1F VK: 0X53 + LOWER- R: 1 A[0]: 0X0073 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0053 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X34 DK: 0X14 VK: 0X54 + LOWER- R: 1 A[0]: 0X0074 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0054 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X35 DK: 0X16 VK: 0X55 + LOWER- R: 1 A[0]: 0X0075 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0055 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X36 DK: 0X2F VK: 0X56 + LOWER- R: 1 A[0]: 0X0076 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0056 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X37 DK: 0X11 VK: 0X57 + LOWER- R: 1 A[0]: 0X0077 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0057 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X38 DK: 0X2D VK: 0X58 + LOWER- R: 1 A[0]: 0X0078 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0058 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X39 DK: 0X15 VK: 0X59 + LOWER- R: 1 A[0]: 0X0079 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0059 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X3A DK: 0X2C VK: 0X5A + LOWER- R: 1 A[0]: 0X007A A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X005A A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X3B DK: 0X29 VK: 0XC0 + LOWER- R: 1 A[0]: 0X0060 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X007E A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X3C DK: 0X0C VK: 0XBD + LOWER- R: 1 A[0]: 0X002D A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X005F A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X3D DK: 0X0D VK: 0XBB + LOWER- R: 1 A[0]: 0X003D A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X002B A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X3E DK: 0X1A VK: 0XDB + LOWER- R: 1 A[0]: 0X005B A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X007B A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X3F DK: 0X1B VK: 0XDD + LOWER- R: 1 A[0]: 0X005D A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X007D A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X40 DK: 0X2B VK: 0XDC + LOWER- R: 1 A[0]: 0X005C A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X007C A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X41 DK: 0X27 VK: 0XBA + LOWER- R: 1 A[0]: 0X003B A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X003A A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X42 DK: 0X28 VK: 0XDE + LOWER- R: 1 A[0]: 0X0027 A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X0022 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X43 DK: 0X33 VK: 0XBC + LOWER- R: 1 A[0]: 0X002C A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X003C A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X44 DK: 0X34 VK: 0XBE + LOWER- R: 1 A[0]: 0X002E A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X003E A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X45 DK: 0X35 VK: 0XBF + LOWER- R: 1 A[0]: 0X002F A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X003F A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X46 DK: 0X52 VK: 0X2D + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X47 DK: 0X4F VK: 0X23 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X48 DK: 0X50 VK: 0X28 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X49 DK: 0X51 VK: 0X22 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X4A DK: 0X4B VK: 0X25 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X4B DK: 0X4C VK: 0X0C + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X4C DK: 0X4D VK: 0X27 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X4D DK: 0X47 VK: 0X24 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X4E DK: 0X48 VK: 0X26 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X4F DK: 0X49 VK: 0X21 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X50 DK: 0X37 VK: 0X6A + LOWER- R: 1 A[0]: 0X002A A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X002A A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X51 DK: 0X4E VK: 0X6B + LOWER- R: 1 A[0]: 0X002B A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X002B A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X52 DK: 0XB3 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X53 DK: 0X4A VK: 0X6D + LOWER- R: 1 A[0]: 0X002D A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X002D A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X54 DK: 0X53 VK: 0X2E + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X55 DK: 0XB5 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X56 DK: 0X9C VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X57 DK: 0X3B VK: 0X70 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X58 DK: 0X3C VK: 0X71 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X59 DK: 0X3D VK: 0X72 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X5A DK: 0X3E VK: 0X73 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X5B DK: 0X3F VK: 0X74 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X5C DK: 0X40 VK: 0X75 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X5D DK: 0X41 VK: 0X76 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X5E DK: 0X42 VK: 0X77 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X5F DK: 0X43 VK: 0X78 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X60 DK: 0X44 VK: 0X79 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X61 DK: 0X57 VK: 0X7A + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X62 DK: 0X58 VK: 0X7B + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X63 DK: 0X64 VK: 0X7C + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X64 DK: 0X65 VK: 0X7D + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X65 DK: 0X66 VK: 0X7E + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X6F DK: 0X45 VK: 0X90 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X70 DK: 0X46 VK: 0X91 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X71 DK: 0X1D VK: 0X11 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X72 DK: 0X9D VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X73 DK: 0X38 VK: 0X12 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X74 DK: 0XB8 VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X75 DK: 0X2A VK: 0X10 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X76 DK: 0X36 VK: 0X10 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X77 DK: 0XDB VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X78 DK: 0XDC VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X79 DK: 0XDD VK: 0X00 + LOWER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + UPPER- R: 0 A[0]: 0X0000 A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +KC: 0X80 DK: 0X56 VK: 0XE2 + LOWER- R: 1 A[0]: 0X005C A[1]: 0X0000 + UPPER- R: 1 A[0]: 0X007C A[1]: 0X0000 + GOOFY- R: 0 A[0]: 0X0000 A[1]: 0X0000 +--- Finished filling the ASCII table! --- + +*** CLOSING LOG *** diff --git a/base/missions/Abominable.mis b/base/missions/Abominable.mis index 7bd06eb..c396aed 100644 --- a/base/missions/Abominable.mis +++ b/base/missions/Abominable.mis @@ -14,10 +14,10 @@ //--- OBJECT WRITE BEGIN --- new SimGroup(MissionGroup) { - powerCount = "0"; - musicTrack = "ice"; CnH_timeLimit = "25"; cdTrack = "5"; + musicTrack = "ice"; + powerCount = "0"; new MissionArea(MissionArea) { area = "-600 -808 992 1632"; @@ -29,10 +29,10 @@ new SimGroup(MissionGroup) { direction = "0.57735 0.57735 -0.57735"; color = "0.600000 0.600000 0.600000 1.000000"; ambient = "0.200000 0.200000 0.200000 1.000000"; - rotation = "1 0 0 0"; scale = "1 1 1"; locked = "true"; position = "-800 -1272 0"; + rotation = "1 0 0 0"; }; new TerrainBlock(Terrain) { rotation = "1 0 0 0"; @@ -41,24 +41,24 @@ new SimGroup(MissionGroup) { terrainFile = "Abominable.ter"; squareSize = "8"; emptySquares = "272205 337997 338253 338509 338765 379020 379276 379532 379788 380044"; - visibleDistance = "1200"; hazeDistance = "250"; locked = "true"; position = "-1024 -1024 0"; + visibleDistance = "1200"; }; new NavigationGraph(NavGraph) { conjoinAngleDev = "55"; cullDensity = "0.3"; customArea = "0 0 0 0"; - coverage = "0"; - rotation = "0 0 0 0"; - XDimOverSize = "0"; scale = "1 1 1"; YDimOverSize = "0"; locked = "true"; - conjoinBowlDev = "20"; GraphFile = "Abominable.nav"; + conjoinBowlDev = "20"; position = "0 0 0 1"; + coverage = "0"; + rotation = "0 0 0 0"; + XDimOverSize = "0"; }; new Sky(Sky) { position = "-7 5 0"; @@ -72,6 +72,7 @@ new SimGroup(MissionGroup) { cloudSpeed3 = "0.0003"; visibleDistance = "350"; useSkyTextures = "1"; + renderBottomTexture = "0"; SkySolidColor = "0.000000 0.000000 0.000000 0.000000"; fogDistance = "60"; fogColor = "0.300000 0.300000 0.300000 1.000000"; @@ -84,8 +85,8 @@ new SimGroup(MissionGroup) { fogVolumeColor1 = "128.000000 128.000000 128.000000 0.000000"; fogVolumeColor2 = "128.000000 128.000000 128.000000 0.000000"; fogVolumeColor3 = "128.000000 128.000000 128.000000 0.000000"; - cloudSpeed0 = "0.000000 0.000000"; locked = "true"; + cloudSpeed0 = "0.000000 0.000000"; }; new Precipitation(Precipitation) { position = "-7 5 0"; @@ -206,9 +207,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3289"; - team = "1"; + group = "3394"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIODefendLocation) { position = "-391.639 -689.494 211.654"; @@ -234,9 +235,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3289"; - team = "1"; + group = "3394"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIODeployEquipment) { position = "-389.162 -685.697 203.984"; @@ -262,12 +263,12 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3289"; - team = "1"; + group = "3394"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIODeployEquipment) { - position = "-393.239 -700.595 209.593"; + position = "-387.657 -700.997 209.393"; rotation = "0 0 -1 89.9544"; scale = "1 1 1"; dataBlock = "AIObjectiveMarker"; @@ -290,9 +291,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3289"; - team = "1"; + group = "3394"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIODeployEquipment) { position = "-390.81 -704.636 186.451"; @@ -318,9 +319,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3289"; - team = "1"; + group = "3394"; isInvalid = "0"; + team = "1"; }; }; new SimGroup(Tower3) { @@ -336,7 +337,7 @@ new SimGroup(MissionGroup) { description = "Defend the FlipFlop"; targetObject = "Team0flipflop3"; targetClientId = "-1"; - targetObjectId = "3344"; + targetObjectId = "3449"; location = "-161.64 -23.2113 296.991"; weightLevel1 = "4750"; weightLevel2 = "2750"; @@ -350,9 +351,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3295"; - team = "1"; + group = "3400"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIOTouchObject) { position = "-161.64 -23.2113 296.991"; @@ -365,7 +366,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop3"; targetClientId = "-1"; - targetObjectId = "3344"; + targetObjectId = "3449"; location = "-161.64 -23.2113 296.991"; weightLevel1 = "4800"; weightLevel2 = "2800"; @@ -379,9 +380,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3295"; - team = "1"; + group = "3400"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIODeployEquipment) { position = "-170.462 -13.963 295.049"; @@ -407,9 +408,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3295"; - team = "1"; + group = "3400"; isInvalid = "0"; + team = "1"; }; }; new AIObjective(AIORepairObject) { @@ -422,7 +423,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory5"; targetClientId = "-1"; - targetObjectId = "3384"; + targetObjectId = "3489"; location = "-400.782 -678.349 202.8"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -436,8 +437,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "-400.786 -743.235 177.141"; @@ -449,7 +450,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory4"; targetClientId = "-1"; - targetObjectId = "3382"; + targetObjectId = "3487"; location = "-400.786 -743.235 177.141"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -463,8 +464,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "-213.61 40.0348 274.617"; @@ -476,7 +477,7 @@ new SimGroup(MissionGroup) { description = "Repair the TurretBaseLarge"; targetObject = "Team0TurretBaseLarge1"; targetClientId = "-1"; - targetObjectId = "3348"; + targetObjectId = "3453"; location = "-213.61 40.0348 274.617"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -490,8 +491,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "-181.193 -45.5791 277.315"; @@ -503,7 +504,7 @@ new SimGroup(MissionGroup) { description = "Repair the TurretBaseLarge"; targetObject = "Team0TurretBaseLarge2"; targetClientId = "-1"; - targetObjectId = "3351"; + targetObjectId = "3456"; location = "-181.193 -45.5791 277.315"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -517,8 +518,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "-377.992 -689.852 207.84"; @@ -530,7 +531,7 @@ new SimGroup(MissionGroup) { description = "Repair the SentryTurret"; targetObject = "Team0SentryTurret3"; targetClientId = "-1"; - targetObjectId = "3380"; + targetObjectId = "3485"; location = "-377.992 -689.852 207.84"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -544,8 +545,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "-158.359 -20.7588 315.022"; @@ -557,7 +558,7 @@ new SimGroup(MissionGroup) { description = "Repair the SensorMediumPulse"; targetObject = "Team0SensorMediumPulse1"; targetClientId = "-1"; - targetObjectId = "3353"; + targetObjectId = "3458"; location = "-158.359 -20.7588 315.022"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -571,8 +572,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIOTouchObject) { position = "120.531 595.532 61.3005"; @@ -585,7 +586,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop1"; targetClientId = "-1"; - targetObjectId = "3357"; + targetObjectId = "3462"; location = "120.531 595.532 61.3005"; weightLevel1 = "4000"; weightLevel2 = "2000"; @@ -599,8 +600,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "107.036 595.662 57.4869"; @@ -612,7 +613,7 @@ new SimGroup(MissionGroup) { description = "Repair the SentryTurret"; targetObject = "Team0SentryTurret2"; targetClientId = "-1"; - targetObjectId = "3358"; + targetObjectId = "3463"; location = "107.036 595.662 57.4869"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -626,8 +627,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIOTouchObject) { position = "23.5983 -395.053 240.566"; @@ -640,7 +641,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop4"; targetClientId = "-1"; - targetObjectId = "3373"; + targetObjectId = "3478"; location = "23.5983 -395.053 240.566"; weightLevel1 = "4900"; weightLevel2 = "2900"; @@ -654,8 +655,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "130.099 589.492 36.2003"; @@ -667,7 +668,7 @@ new SimGroup(MissionGroup) { description = "Repair the GeneratorLarge"; targetObject = "Team0generatorLarge2"; targetClientId = "-1"; - targetObjectId = "3359"; + targetObjectId = "3464"; location = "130.099 589.492 36.2003"; weightLevel1 = "3200"; weightLevel2 = "1600"; @@ -681,8 +682,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "130.102 648.963 26.1874"; @@ -694,7 +695,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory2"; targetClientId = "-1"; - targetObjectId = "3360"; + targetObjectId = "3465"; location = "130.102 648.963 26.1874"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -708,8 +709,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIOTouchObject) { position = "-366.433 349.044 279.604"; @@ -722,7 +723,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop2"; targetClientId = "-1"; - targetObjectId = "3368"; + targetObjectId = "3473"; location = "-366.433 349.044 279.604"; weightLevel1 = "4500"; weightLevel2 = "2500"; @@ -736,8 +737,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; new AIObjective(AIORepairObject) { position = "129.399 584.373 52.4464"; @@ -749,7 +750,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory3"; targetClientId = "-1"; - targetObjectId = "3362"; + targetObjectId = "3467"; location = "129.399 584.373 52.4464"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -763,8 +764,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "1"; isInvalid = "0"; + team = "1"; }; }; }; @@ -804,7 +805,7 @@ new SimGroup(MissionGroup) { description = "Defend the FlipFlop"; targetObject = "Team0flipflop3"; targetClientId = "-1"; - targetObjectId = "3344"; + targetObjectId = "3449"; location = "-161.64 -23.2113 296.991"; weightLevel1 = "4750"; weightLevel2 = "2750"; @@ -818,9 +819,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3316"; - team = "2"; + group = "3421"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIOTouchObject) { position = "-161.64 -23.2113 296.991"; @@ -833,7 +834,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop3"; targetClientId = "-1"; - targetObjectId = "3344"; + targetObjectId = "3449"; location = "-161.64 -23.2113 296.991"; weightLevel1 = "4800"; weightLevel2 = "2800"; @@ -847,9 +848,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3316"; - team = "2"; + group = "3421"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIODeployEquipment) { position = "-154.08 -29.4053 295.085"; @@ -875,9 +876,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3316"; - team = "2"; + group = "3421"; isInvalid = "0"; + team = "2"; }; }; new AIObjective(AIOTouchObject) { @@ -905,8 +906,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "-400.786 -743.235 177.141"; @@ -918,7 +919,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory4"; targetClientId = "-1"; - targetObjectId = "3382"; + targetObjectId = "3487"; location = "-400.786 -743.235 177.141"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -932,8 +933,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "-213.61 40.0348 274.617"; @@ -945,7 +946,7 @@ new SimGroup(MissionGroup) { description = "Repair the TurretBaseLarge"; targetObject = "Team0TurretBaseLarge1"; targetClientId = "-1"; - targetObjectId = "3348"; + targetObjectId = "3453"; location = "-213.61 40.0348 274.617"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -959,8 +960,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new SimGroup(Tower1) { powerCount = "0"; @@ -975,7 +976,7 @@ new SimGroup(MissionGroup) { description = "Defend the FlipFlop"; targetObject = "Team0flipflop1"; targetClientId = "-1"; - targetObjectId = "3357"; + targetObjectId = "3462"; location = "120.531 595.532 61.3005"; weightLevel1 = "5000"; weightLevel2 = "3000"; @@ -989,9 +990,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3323"; - team = "2"; + group = "3428"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIOTouchObject) { position = "120.531 595.532 61.3005"; @@ -1004,7 +1005,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop1"; targetClientId = "-1"; - targetObjectId = "3357"; + targetObjectId = "3462"; location = "120.531 595.532 61.3005"; weightLevel1 = "4950"; weightLevel2 = "2950"; @@ -1018,9 +1019,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3323"; - team = "2"; + group = "3428"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIODeployEquipment) { position = "118.059 590.475 53.3606"; @@ -1046,9 +1047,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3323"; - team = "2"; + group = "3428"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIODeployEquipment) { position = "123.533 584.182 59.2442"; @@ -1074,9 +1075,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3323"; - team = "2"; + group = "3428"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIODeployEquipment) { position = "124.983 610.647 36.895"; @@ -1102,9 +1103,9 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - group = "3323"; - team = "2"; + group = "3428"; isInvalid = "0"; + team = "2"; }; }; new AIObjective(AIORepairObject) { @@ -1117,7 +1118,7 @@ new SimGroup(MissionGroup) { description = "Repair the SentryTurret"; targetObject = "Team0SentryTurret2"; targetClientId = "-1"; - targetObjectId = "3358"; + targetObjectId = "3463"; location = "107.036 595.662 57.4869"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -1131,8 +1132,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "130.099 589.492 36.2003"; @@ -1144,7 +1145,7 @@ new SimGroup(MissionGroup) { description = "Repair the GeneratorLarge"; targetObject = "Team0generatorLarge2"; targetClientId = "-1"; - targetObjectId = "3359"; + targetObjectId = "3464"; location = "130.099 589.492 36.2003"; weightLevel1 = "3200"; weightLevel2 = "1600"; @@ -1158,8 +1159,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIOTouchObject) { position = "23.5983 -395.053 240.566"; @@ -1172,7 +1173,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop4"; targetClientId = "-1"; - targetObjectId = "3373"; + targetObjectId = "3478"; location = "23.5983 -395.053 240.566"; weightLevel1 = "4500"; weightLevel2 = "2500"; @@ -1186,8 +1187,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "130.102 648.963 26.1874"; @@ -1199,7 +1200,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory2"; targetClientId = "-1"; - targetObjectId = "3360"; + targetObjectId = "3465"; location = "130.102 648.963 26.1874"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -1213,8 +1214,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIOTouchObject) { position = "-366.433 349.044 279.604"; @@ -1227,7 +1228,7 @@ new SimGroup(MissionGroup) { mode = "TouchFlipFlop"; targetObject = "Team0flipflop2"; targetClientId = "-1"; - targetObjectId = "3368"; + targetObjectId = "3473"; location = "-366.433 349.044 279.604"; weightLevel1 = "4900"; weightLevel2 = "2900"; @@ -1241,8 +1242,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "129.399 584.373 52.4464"; @@ -1254,7 +1255,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory3"; targetClientId = "-1"; - targetObjectId = "3362"; + targetObjectId = "3467"; location = "129.399 584.373 52.4464"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -1268,8 +1269,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "-181.193 -45.5791 277.315"; @@ -1281,7 +1282,7 @@ new SimGroup(MissionGroup) { description = "Repair the TurretBaseLarge"; targetObject = "Team0TurretBaseLarge2"; targetClientId = "-1"; - targetObjectId = "3351"; + targetObjectId = "3456"; location = "-181.193 -45.5791 277.315"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -1295,8 +1296,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "-401.019 -683.641 186.553"; @@ -1308,7 +1309,7 @@ new SimGroup(MissionGroup) { description = "Repair the GeneratorLarge"; targetObject = "Team0generatorLarge3"; targetClientId = "-1"; - targetObjectId = "3381"; + targetObjectId = "3486"; location = "-401.019 -683.641 186.553"; weightLevel1 = "3200"; weightLevel2 = "1600"; @@ -1322,8 +1323,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "-400.782 -678.349 202.8"; @@ -1335,7 +1336,7 @@ new SimGroup(MissionGroup) { description = "Repair the StationInventory"; targetObject = "Team0StationInventory5"; targetClientId = "-1"; - targetObjectId = "3384"; + targetObjectId = "3489"; location = "-400.782 -678.349 202.8"; weightLevel1 = "2900"; weightLevel2 = "1400"; @@ -1349,8 +1350,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "-377.992 -689.852 207.84"; @@ -1362,7 +1363,7 @@ new SimGroup(MissionGroup) { description = "Repair the SentryTurret"; targetObject = "Team0SentryTurret3"; targetClientId = "-1"; - targetObjectId = "3380"; + targetObjectId = "3485"; location = "-377.992 -689.852 207.84"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -1376,8 +1377,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; new AIObjective(AIORepairObject) { position = "-158.359 -20.7588 315.022"; @@ -1389,7 +1390,7 @@ new SimGroup(MissionGroup) { description = "Repair the SensorMediumPulse"; targetObject = "Team0SensorMediumPulse1"; targetClientId = "-1"; - targetObjectId = "3353"; + targetObjectId = "3458"; location = "-158.359 -20.7588 315.022"; weightLevel1 = "3100"; weightLevel2 = "1000"; @@ -1403,8 +1404,8 @@ new SimGroup(MissionGroup) { issuedByClientId = "-1"; forceClientId = "-1"; locked = "1"; - team = "2"; isInvalid = "0"; + team = "2"; }; }; }; @@ -1423,8 +1424,8 @@ new SimGroup(MissionGroup) { scale = "1 1 1"; interiorFile = "stowr6.dif"; showTerrainInside = "0"; - team = "0"; locked = "true"; + team = "0"; }; new StaticShape(Team0flipflop3) { position = "-161.64 -23.2113 294.724"; @@ -1433,11 +1434,11 @@ new SimGroup(MissionGroup) { dataBlock = "FlipFlop"; lockCount = "0"; homingCount = "0"; - Target = "33"; + locked = "true"; + Projector = "3454"; name = "Center Tower"; team = "0"; - locked = "true"; - Projector = "3349"; + Target = "33"; }; new StaticShape(Team0StationInventory1) { position = "-163.264 -21.4939 304.23"; @@ -1447,10 +1448,10 @@ new SimGroup(MissionGroup) { dataBlock = "StationInventory"; lockCount = "0"; homingCount = "0"; - Target = "34"; - team = "0"; + Trigger = "3451"; locked = "true"; - Trigger = "3346"; + team = "0"; + Target = "34"; }; new InteriorInstance() { position = "-208.975 36.6553 261.907"; @@ -1458,8 +1459,8 @@ new SimGroup(MissionGroup) { scale = "1 1 1"; interiorFile = "smisc1.dif"; showTerrainInside = "0"; - team = "0"; locked = "true"; + team = "0"; }; new Turret(Team0TurretBaseLarge1) { position = "-212.918 39.7529 272.913"; @@ -1470,10 +1471,10 @@ new SimGroup(MissionGroup) { lockCount = "0"; homingCount = "0"; initialBarrel = "PlasmaBarrelLarge"; - Target = "35"; + locked = "true"; lastProjectile = "3951"; team = "0"; - locked = "true"; + Target = "35"; }; new StaticShape() { position = "-164.566 -26.1453 312.696"; @@ -1482,10 +1483,10 @@ new SimGroup(MissionGroup) { dataBlock = "LogoProjector"; lockCount = "0"; homingCount = "0"; - Target = "-1"; - team = "0"; holo = "0"; locked = "true"; + team = "0"; + Target = "-1"; }; new InteriorInstance() { position = "-181.348 -45.1196 272.111"; @@ -1493,8 +1494,8 @@ new SimGroup(MissionGroup) { scale = "1 1 2.28969"; interiorFile = "smisc3.dif"; showTerrainInside = "0"; - team = "0"; locked = "true"; + team = "0"; }; new Turret(Team0TurretBaseLarge2) { position = "-181.202 -44.8315 275.611"; @@ -1505,11 +1506,11 @@ new SimGroup(MissionGroup) { lockCount = "0"; homingCount = "0"; initialBarrel = "PlasmaBarrelLarge"; - Target = "36"; + locked = "true"; lastProjectile = "3921"; team = "0"; damageTimeMS = "770705"; - locked = "true"; + Target = "36"; }; new StaticShape(Team0generatorLarge1) { position = "-169.883 -31.5901 -296.777"; @@ -1519,9 +1520,9 @@ new SimGroup(MissionGroup) { dataBlock = "GeneratorLarge"; lockCount = "0"; homingCount = "0"; - Target = "37"; - team = "0"; locked = "true"; + team = "0"; + Target = "37"; }; new StaticShape(Team0SensorMediumPulse1) { position = "-158.359 -20.7588 312.502"; @@ -1531,9 +1532,9 @@ new SimGroup(MissionGroup) { dataBlock = "SensorMediumPulse"; lockCount = "0"; homingCount = "0"; - Target = "38"; - team = "0"; locked = "true"; + team = "0"; + Target = "38"; }; new WayPoint() { position = "-161.6 -23.2 294.7"; @@ -1557,8 +1558,8 @@ new SimGroup(MissionGroup) { interiorFile = "sbunk9.dif"; showTerrainInside = "0"; AudioProfile = "Universal_Base_Pulse_2"; - team = "0"; locked = "true"; + team = "0"; }; new StaticShape(Team0flipflop1) { position = "120.531 595.532 58.8337"; @@ -1567,11 +1568,11 @@ new SimGroup(MissionGroup) { dataBlock = "FlipFlop"; lockCount = "0"; homingCount = "0"; - Target = "39"; + locked = "true"; + Projector = "3470"; name = "NE Holdfast"; team = "0"; - locked = "true"; - Projector = "3365"; + Target = "39"; }; new Turret(Team0SentryTurret2) { position = "107.066 595.662 57.9"; @@ -1582,9 +1583,9 @@ new SimGroup(MissionGroup) { lockCount = "0"; homingCount = "0"; initialBarrel = "SentryTurretBarrel"; - Target = "40"; - team = "0"; locked = "false"; + team = "0"; + Target = "40"; }; new StaticShape(Team0generatorLarge2) { position = "129.834 591.431 34.9"; @@ -1594,9 +1595,9 @@ new SimGroup(MissionGroup) { dataBlock = "GeneratorLarge"; lockCount = "0"; homingCount = "0"; - Target = "41"; - team = "0"; locked = "true"; + team = "0"; + Target = "41"; }; new StaticShape(Team0StationInventory2) { position = "130.462 649.096 25.825"; @@ -1606,10 +1607,10 @@ new SimGroup(MissionGroup) { dataBlock = "StationInventory"; lockCount = "0"; homingCount = "0"; - Target = "42"; - team = "0"; + Trigger = "3466"; locked = "false"; - Trigger = "3361"; + team = "0"; + Target = "42"; }; new StaticShape(Team0StationInventory3) { position = "129.399 584.373 50.8806"; @@ -1619,10 +1620,10 @@ new SimGroup(MissionGroup) { dataBlock = "StationInventory"; lockCount = "0"; homingCount = "0"; - Target = "43"; - team = "0"; + Trigger = "3468"; locked = "true"; - Trigger = "3363"; + team = "0"; + Target = "43"; }; new WayPoint() { position = "120.936 595.731 59.6705"; @@ -1642,10 +1643,10 @@ new SimGroup(MissionGroup) { dataBlock = "LogoProjector"; lockCount = "0"; homingCount = "0"; - Target = "-1"; - team = "0"; holo = "0"; locked = "true"; + team = "0"; + Target = "-1"; }; }; new SimGroup(NWTower) { @@ -1657,8 +1658,8 @@ new SimGroup(MissionGroup) { scale = "1 1 1"; interiorFile = "stowr1.dif"; showTerrainInside = "0"; - team = "0"; locked = "true"; + team = "0"; }; new StaticShape(Team0flipflop2) { position = "-366.433 349.044 277.2"; @@ -1667,11 +1668,11 @@ new SimGroup(MissionGroup) { dataBlock = "FlipFlop"; lockCount = "0"; homingCount = "0"; - Target = "44"; + locked = "true"; + Projector = "3476"; name = "NW Outpost"; team = "0"; - locked = "true"; - Projector = "3371"; + Target = "44"; }; new WayPoint() { position = "-366.485 348.997 277.3"; @@ -1694,9 +1695,9 @@ new SimGroup(MissionGroup) { collideable = "0"; static = "1"; rotate = "0"; - Target = "-1"; - team = "0"; locked = "true"; + team = "0"; + Target = "-1"; }; new StaticShape() { position = "-366.51 344.833 295.149"; @@ -1705,10 +1706,10 @@ new SimGroup(MissionGroup) { dataBlock = "LogoProjector"; lockCount = "0"; homingCount = "0"; - Target = "-1"; - team = "0"; holo = "0"; locked = "true"; + team = "0"; + Target = "-1"; }; }; new SimGroup(SETower) { @@ -1721,11 +1722,11 @@ new SimGroup(MissionGroup) { dataBlock = "FlipFlop"; lockCount = "0"; homingCount = "0"; - Target = "45"; + locked = "false"; + Projector = "3481"; name = "SE Outpost"; team = "0"; - locked = "false"; - Projector = "3376"; + Target = "45"; }; new WayPoint() { position = "23.0428 -395.374 238.543"; @@ -1748,9 +1749,9 @@ new SimGroup(MissionGroup) { collideable = "0"; static = "1"; rotate = "0"; - Target = "-1"; - team = "0"; locked = "true"; + team = "0"; + Target = "-1"; }; new StaticShape() { position = "23.6405 -390.683 256.234"; @@ -1759,10 +1760,10 @@ new SimGroup(MissionGroup) { dataBlock = "LogoProjector"; lockCount = "0"; homingCount = "0"; - Target = "-1"; - team = "0"; holo = "0"; locked = "true"; + team = "0"; + Target = "-1"; }; }; new SimGroup(SWTower) { @@ -1775,8 +1776,8 @@ new SimGroup(MissionGroup) { interiorFile = "sbunk9.dif"; showTerrainInside = "0"; AudioProfile = "Universal_Base_Pulse_2"; - team = "0"; locked = "true"; + team = "0"; }; new StaticShape() { position = "-387.637 -689.558 218.178"; @@ -1785,10 +1786,10 @@ new SimGroup(MissionGroup) { dataBlock = "LogoProjector"; lockCount = "0"; homingCount = "0"; - Target = "-1"; - team = "0"; holo = "0"; locked = "true"; + team = "0"; + Target = "-1"; }; new Turret(Team0SentryTurret3) { position = "-378.082 -689.873 208.25"; @@ -1798,10 +1799,10 @@ new SimGroup(MissionGroup) { lockCount = "0"; homingCount = "0"; initialBarrel = "SentryTurretBarrel"; - Target = "46"; + locked = "true"; name = "SW Sentry"; team = "0"; - locked = "true"; + Target = "46"; }; new StaticShape(Team0generatorLarge3) { position = "-400.723 -685.512 185.17"; @@ -1811,9 +1812,9 @@ new SimGroup(MissionGroup) { dataBlock = "GeneratorLarge"; lockCount = "0"; homingCount = "0"; - Target = "47"; - team = "0"; locked = "false"; + team = "0"; + Target = "47"; }; new StaticShape(Team0StationInventory4) { position = "-401.372 -743.023 176.18"; @@ -1823,10 +1824,10 @@ new SimGroup(MissionGroup) { dataBlock = "StationInventory"; lockCount = "0"; homingCount = "0"; - Target = "48"; - team = "0"; + Trigger = "3488"; locked = "false"; - Trigger = "3383"; + team = "0"; + Target = "48"; }; new StaticShape(Team0StationInventory5) { position = "-400.782 -678.349 201.234"; @@ -1836,10 +1837,10 @@ new SimGroup(MissionGroup) { dataBlock = "StationInventory"; lockCount = "0"; homingCount = "0"; - Target = "49"; - team = "0"; + Trigger = "3490"; locked = "true"; - Trigger = "3385"; + team = "0"; + Target = "49"; }; new WayPoint() { position = "-391.892 -689.898 210.023"; @@ -1858,21 +1859,21 @@ new SimGroup(MissionGroup) { scale = "1 1 1"; interiorFile = "stowr1.dif"; showTerrainInside = "0"; - team = "0"; locked = "true"; + team = "0"; }; - new StaticShape() { + new StaticShape(Team0flipflop5) { position = "-391.658 -689.443 209.2"; rotation = "1 0 0 0"; scale = "1 1 1"; dataBlock = "FlipFlop"; lockCount = "0"; homingCount = "0"; - Target = "50"; + locked = "true"; + Projector = "3484"; name = "SW Holdfast"; team = "0"; - locked = "true"; - Projector = "3379"; + Target = "50"; }; }; }; @@ -1964,7 +1965,7 @@ new SimGroup(MissionGroup) { locked = "true"; }; new TSStatic() { - position = "127.939 584.318 58.83"; + position = "127.939 584.718 58.83"; rotation = "1 0 0 0"; scale = "1 1 1"; shapeName = "stackable3m.dts"; diff --git a/base/missions/AgentsOfFortune.mis b/base/missions/AgentsOfFortune.mis index fd45b42..0a2e817 100644 --- a/base/missions/AgentsOfFortune.mis +++ b/base/missions/AgentsOfFortune.mis @@ -2,26 +2,26 @@ // MissionTypes = DM Hunters TeamHunters //--- MISSION QUOTE BEGIN --- -//Don't fear the Reaper. Fear me. -// -- Gir Draxon, Leader of the Hordes, 3941 CE +//I am of the Chainless. I am Strong. I show no mercy. +//--BioDerm battle chant //--- MISSION QUOTE END --- //--- MISSION STRING BEGIN --- //[Hunters TeamHunters]Nexus located atop central tower //Three satellite towers around central tower //Inventory stations in all towers -//Ideal for combined indoor/outdoor combat tactics +//Ideal for combined indoor/outdoor tactics //--- MISSION STRING END --- //--- OBJECT WRITE BEGIN --- new SimGroup(MissionGroup) { - powerCount = "0"; DM_timeLimit = "25"; - Hunters_timeLimit = "25"; - Team_Hunters_timeLimit = "25"; - musicTrack = "badlands"; DM_scoreLimit = "25"; + musicTrack = "badlands"; + powerCount = "0"; + Hunters_timeLimit = "25"; cdTrack = "4"; + Team_Hunters_timeLimit = "25"; new MissionArea(MissionArea) { area = "-160 -88 512 512"; @@ -54,17 +54,17 @@ new SimGroup(MissionGroup) { fogVolumeColor1 = "128.000000 128.000000 128.000000 nan"; fogVolumeColor2 = "128.000000 128.000000 128.000000 148120713330651839000000000000000000000.000000"; fogVolumeColor3 = "128.000000 128.000000 128.000000 nan"; - locked = "true"; cloudSpeed0 = "0.000000 0.000000"; + locked = "true"; }; new Sun() { direction = "0.57735 0.57735 -0.57735"; color = "0.600000 0.600000 0.600000 1.000000"; ambient = "0.600000 0.600000 0.600000 1.000000"; position = "0 0 0"; - locked = "true"; rotation = "1 0 0 0"; scale = "1 1 1"; + locked = "true"; }; new TerrainBlock(Terrain) { rotation = "1 0 0 0"; @@ -81,17 +81,16 @@ new SimGroup(MissionGroup) { cullDensity = "0.3"; customArea = "0 0 0 0"; position = "0 0 0 1"; - XDimOverSize = "0"; - locked = "true"; - rotation = "0 0 0 0"; conjoinBowlDev = "20"; - scale = "1 1 1"; - coverage = "0"; - YDimOverSize = "0"; GraphFile = "AgentsOfFortune.nav"; + rotation = "0 0 0 0"; + coverage = "0"; + scale = "1 1 1"; + locked = "true"; + YDimOverSize = "0"; + XDimOverSize = "0"; }; new SimGroup(ObserverDropPoints) { - powerCount = "0"; new Camera() { position = "170.145 354.633 306.299"; @@ -122,13 +121,10 @@ new SimGroup(MissionGroup) { }; }; new SimGroup(Teams) { - powerCount = "0"; new SimGroup(Team1) { - powerCount = "0"; new SimGroup(spawnspheres) { - powerCount = "0"; new SpawnSphere() { position = "120.543 125.555 178.74"; @@ -141,12 +137,11 @@ new SimGroup(MissionGroup) { sphereWeight = "100"; indoorWeight = "0"; outdoorWeight = "100"; - locked = "true"; missionTypesList = "Hunters TeamHunters DM"; + locked = "true"; }; }; new SimGroup(AIObjectives) { - powerCount = "0"; new AIObjective(AIORepairObject) { position = "206.155 290.506 238.077"; @@ -173,9 +168,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "199.076 306.979 274.076"; @@ -202,9 +196,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "-54.5328 142.977 234.564"; @@ -231,9 +224,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "-61.6912 133.365 198.742"; @@ -260,9 +252,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "132.621 170.206 141.512"; @@ -289,9 +280,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "242.229 -55.9849 184.697"; @@ -318,9 +308,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "132.35 81.4307 123.601"; @@ -347,9 +336,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "249.2 -47.0356 220.655"; @@ -376,9 +364,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "132.247 133.472 42.4322"; @@ -405,9 +392,8 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; new AIObjective(AIORepairObject) { position = "132.537 114.232 42.4282"; @@ -434,17 +420,14 @@ new SimGroup(MissionGroup) { forceClientId = "-1"; locked = "1"; issuingClientId = "-1"; - gameType = "all"; isInvalid = "0"; - team = "1"; + gameType = "all"; }; }; }; new SimGroup(Team2) { - powerCount = "0"; new SimGroup(spawnspheres) { - powerCount = "0"; new SpawnSphere() { position = "120.543 125.555 178.74"; @@ -457,16 +440,14 @@ new SimGroup(MissionGroup) { sphereWeight = "100"; indoorWeight = "0"; outdoorWeight = "100"; - locked = "true"; missionTypesList = "TeamHunters"; + locked = "true"; }; }; }; new SimGroup(team0) { - powerCount = "0"; new SimGroup(base) { - powerCount = "1"; providesPower = "1"; new InteriorInstance() { @@ -477,7 +458,6 @@ new SimGroup(MissionGroup) { showTerrainInside = "0"; AudioProfile = "Universal_Base_Pulse_1"; locked = "true"; - team = "0"; }; new InteriorInstance() { position = "-61.9873 145.333 208.013"; @@ -487,7 +467,6 @@ new SimGroup(MissionGroup) { showTerrainInside = "0"; AudioProfile = "Universal_Base_Pulse_1"; locked = "true"; - team = "0"; }; new InteriorInstance() { position = "203.206 303.487 247.408"; @@ -497,7 +476,6 @@ new SimGroup(MissionGroup) { showTerrainInside = "0"; AudioProfile = "Universal_Base_Pulse_1"; locked = "true"; - team = "0"; }; new StaticShape(Team1StationInventory1) { position = "203.105 290.287 236.41"; @@ -509,8 +487,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "33"; - Trigger = "3361"; - team = "0"; }; new StaticShape(Team1StationInventory2) { position = "196.076 306.979 272.41"; @@ -522,8 +498,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "34"; - Trigger = "3363"; - team = "0"; }; new StaticShape(Team1StationInventory3) { position = "-54.7328 141.777 233.01"; @@ -535,8 +509,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "35"; - Trigger = "3365"; - team = "0"; }; new StaticShape(Team1StationInventory4) { position = "-61.8912 132.165 197.01"; @@ -548,8 +520,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "36"; - Trigger = "3367"; - team = "0"; }; new StaticShape(Team1StationInventory5) { position = "131.421 170.206 139.83"; @@ -561,8 +531,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "37"; - Trigger = "3369"; - team = "0"; }; new StaticShape(Team1StationInventory6) { position = "242.042 -53.8823 182.9"; @@ -574,8 +542,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "38"; - Trigger = "3371"; - team = "0"; }; new StaticShape(Team1StationInventory7) { position = "131.15 81.4307 121.83"; @@ -587,8 +553,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "39"; - Trigger = "3373"; - team = "0"; }; new StaticShape(Team1StationInventory8) { position = "249.4 -44.2356 218.9"; @@ -600,8 +564,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "40"; - Trigger = "3375"; - team = "0"; }; new StaticShape(Team1StationInventory9) { position = "131.047 133.472 40.825"; @@ -613,8 +575,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "41"; - Trigger = "3377"; - team = "0"; }; new StaticShape(Team1StationInventory10) { position = "131.293 114.234 40.825"; @@ -626,8 +586,6 @@ new SimGroup(MissionGroup) { homingCount = "0"; locked = "true"; Target = "42"; - Trigger = "3379"; - team = "0"; }; new InteriorInstance() { position = "242.199 -41.2332 193.901"; @@ -637,86 +595,83 @@ new SimGroup(MissionGroup) { showTerrainInside = "0"; AudioProfile = "Universal_Base_Pulse_1"; locked = "true"; - team = "0"; + }; + new Item(Nexus) { + position = "130.989 125.937 160.988"; + rotation = "1 0 0 0"; + scale = "1 1 1"; + dataBlock = "Nexus"; + lockCount = "0"; + homingCount = "0"; + collideable = "0"; + static = "1"; + rotate = "0"; + missionTypesList = "Hunters TeamHunters"; + flashThreadDir = "1"; + locked = "true"; + Target = "43"; + }; + new StaticShape() { + position = "130.989 125.937 168.77"; + rotation = "1 0 0 0"; + scale = "0.7 0.7 1"; + dataBlock = "NexusCap"; + lockCount = "0"; + homingCount = "0"; + missionTypesList = "Hunters TeamHunters"; + locked = "true"; + Target = "-1"; + }; + new StaticShape() { + position = "130.989 125.937 162.77"; + rotation = "1 0 0 0"; + scale = "0.7 0.7 1"; + dataBlock = "NexusBase"; + lockCount = "0"; + homingCount = "0"; + missionTypesList = "Hunters TeamHunters"; + locked = "true"; + Target = "-1"; + }; + new WayPoint() { + position = "130.623 125.532 162.74"; + rotation = "1 0 0 0"; + scale = "1 1 1"; + dataBlock = "WayPointMarker"; + lockCount = "0"; + homingCount = "0"; + name = "Nexus"; + team = "0"; + missionTypesList = "Hunters TeamHunters"; + locked = "true"; + }; + new WayPoint() { + position = "130.623 125.532 163.74"; + rotation = "1 0 0 0"; + scale = "1 1 1"; + dataBlock = "WayPointMarker"; + lockCount = "0"; + homingCount = "0"; + name = "Tower"; + team = "0"; + missionTypesList = "DM"; + locked = "true"; }; }; }; - }; - new Item(Nexus) { - position = "130.989 125.937 160.988"; - rotation = "1 0 0 0"; - scale = "1 1 1"; - dataBlock = "Nexus"; - lockCount = "0"; - homingCount = "0"; - collideable = "0"; - static = "1"; - rotate = "0"; - locked = "true"; - missionTypesList = "Hunters TeamHunters"; - Target = "43"; - flashThreadDir = "1"; - }; - new StaticShape() { - position = "130.989 125.937 168.77"; - rotation = "1 0 0 0"; - scale = "0.7 0.7 1"; - dataBlock = "NexusCap"; - lockCount = "0"; - homingCount = "0"; - locked = "true"; - missionTypesList = "Hunters TeamHunters"; - Target = "-1"; - }; - new StaticShape() { - position = "130.989 125.937 162.77"; - rotation = "1 0 0 0"; - scale = "0.7 0.7 1"; - dataBlock = "NexusBase"; - lockCount = "0"; - homingCount = "0"; - locked = "true"; - missionTypesList = "Hunters TeamHunters"; - Target = "-1"; - }; - new WayPoint() { - position = "130.623 125.532 162.74"; - rotation = "1 0 0 0"; - scale = "1 1 1"; - dataBlock = "WayPointMarker"; - lockCount = "0"; - homingCount = "0"; - name = "Nexus"; - team = "0"; - locked = "true"; - missionTypesList = "Hunters TeamHunters"; - }; - new WayPoint() { - position = "130.623 125.532 163.74"; - rotation = "1 0 0 0"; - scale = "1 1 1"; - dataBlock = "WayPointMarker"; - lockCount = "0"; - homingCount = "0"; - name = "Tower"; - team = "0"; - locked = "true"; - missionTypesList = "DM"; - }; - new Trigger(NexusTrigger) { - position = "116.023 141.332 149.54"; - rotation = "1 0 0 0"; - scale = "30 30 27.2131"; - dataBlock = "gameTrigger"; - polyhedron = "0.0000000 0.0000000 0.0000000 1.0000000 0.0000000 0.0000000 -0.0000000 -0.0000000 1.0000000 -0.0000000 -1.0000000 -0.0000000"; - locked = "true"; - missionTypesList = "Hunters TeamHunters"; + new Trigger(NexusTrigger) { + position = "109.972 143.602 158.388"; + rotation = "1 0 0 0"; + scale = "41.3963 35.6001 19.8193"; + dataBlock = "gameTrigger"; + polyhedron = "0.0000000 0.0000000 0.0000000 1.0000000 0.0000000 0.0000000 -0.0000000 -1.0000000 -0.0000000 -0.0000000 -0.0000000 1.0000000"; + missionTypesList = "Hunters TeamHunters"; + locked = "true"; + }; }; new SimGroup(RandomOrganics) { - powerCount = "0"; new SimGroup(Addition5BiodermPlant5) { - powerCount = "0"; new TSStatic() { position = "269.5 -33.5 187.748"; @@ -777,7 +732,6 @@ new SimGroup(MissionGroup) { }; }; new SimGroup(ambient) { - powerCount = "0"; new TSStatic() { position = "210.085 300.266 272.4"; @@ -833,7 +787,7 @@ new SimGroup(MissionGroup) { rotation = "0 -1 0 26.929"; scale = "1 1 1"; shapeName = "stackable1l.dts"; - locked = "false"; + locked = "true"; }; new TSStatic() { position = "126.808 126.436 39.78"; @@ -972,18 +926,20 @@ new SimGroup(MissionGroup) { shapeName = "stackable3m.dts"; locked = "true"; }; - }; - new TSStatic() { - position = "85.2228 126.233 56.31"; - rotation = "1 0 0 0"; - scale = "1 1 1"; - shapeName = "stackable3s.dts"; - }; - new TSStatic() { - position = "176.956 125.898 56.3"; - rotation = "0 0 1 16.0428"; - scale = "1 1 1"; - shapeName = "stackable2l.dts"; + new TSStatic() { + position = "85.2228 126.233 56.31"; + rotation = "1 0 0 0"; + scale = "1 1 1"; + shapeName = "stackable3s.dts"; + locked = "true"; + }; + new TSStatic() { + position = "176.956 125.898 56.3"; + rotation = "0 0 1 16.0428"; + scale = "1 1 1"; + shapeName = "stackable2l.dts"; + locked = "true"; + }; }; }; //--- OBJECT WRITE END --- diff --git a/base/missions/AshesToAshes.mis b/base/missions/AshesToAshes.mis index fb6cdf9..df3b39c 100644 --- a/base/missions/AshesToAshes.mis +++ b/base/missions/AshesToAshes.mis @@ -22,7 +22,7 @@ new SimGroup(MissionGroup) { new MissionArea(MissionArea) { area = "-472 -840 1152 1152"; - flightCeiling = "2000"; + flightCeiling = "350"; flightCeilingRange = "50"; locked = "true"; }; diff --git a/base/missions/DeathBirdsFly.mis b/base/missions/DeathBirdsFly.mis index ec9c559..8aaff22 100644 --- a/base/missions/DeathBirdsFly.mis +++ b/base/missions/DeathBirdsFly.mis @@ -2,8 +2,7 @@ // MissionTypes = CTF //--- MISSION QUOTE BEGIN --- -//We will not glorify ourselves, Lord Phoenix. -//Your wrath will clothe us in righteousness as we chastise the tribes with fire. +//A darkness infects the wilderzone, one that only fire can cleanse. Our fire. // -- Anton Malderi, anointed Phoenix Prime, 3941 CE //--- MISSION QUOTE END --- diff --git a/base/missions/Respite.mis b/base/missions/Respite.mis index 632da38..a572e34 100644 --- a/base/missions/Respite.mis +++ b/base/missions/Respite.mis @@ -2,7 +2,7 @@ // DisplayName = Respite //--- MISSION QUOTE BEGIN --- -//Let all the Tribes of Man hear me: none shall escape the Bright Lord's mercy. +//Let all the Tribes of Man bear witness: the Phoenix rises at last to claim its own. // -- Anton Malderi yl-Harabec, first anointed Phoenix Prime of the Harbingers, 3941 CE //--- MISSION QUOTE END --- diff --git a/base/missions/Rimehold.mis b/base/missions/Rimehold.mis index fc8df36..0d34f6a 100644 --- a/base/missions/Rimehold.mis +++ b/base/missions/Rimehold.mis @@ -1,7 +1,7 @@ // MissionTypes = Hunters TeamHunters //--- MISSION QUOTE BEGIN --- -//Howl, O Wolves, howl for our dead kin scattered on the frozen seas of Ymir. Then take up your weapons. We shall hunt the Hordes until the stars grow cold. +//Forget the Blood Eagle! The Hordes killed a half million of us at Ymir. That's a lot of kin to avenge, so lock and load. This is going to take awhile. // -- Jarek Redmoon, Ur-Shaman of the Starwolf, 3941 CE //--- MISSION QUOTE END --- diff --git a/base/missions/Sanctuary.mis b/base/missions/Sanctuary.mis index 31b3526..dd02e01 100644 --- a/base/missions/Sanctuary.mis +++ b/base/missions/Sanctuary.mis @@ -19,8 +19,8 @@ new SimGroup(MissionGroup) { new MissionArea(MissionArea) { area = "-976 -928 1360 1424"; - flightCeiling = "2000"; - flightCeilingRange = "50"; + flightCeiling = "400"; + flightCeilingRange = "20"; }; new Sun() { direction = "0.57735 0.57735 -0.57735"; diff --git a/base/missions/Training4.mis b/base/missions/Training4.mis index 72ef134..8a12cb0 100644 --- a/base/missions/Training4.mis +++ b/base/missions/Training4.mis @@ -1,5 +1,5 @@ // MissionTypes = SinglePlayer -// DisplayName = Seargent +// DisplayName = Sergeant //--- MISSION BRIEFING BEGIN --- //Welcome, Sergeant. We have another tricky assignment for you. Captain Kenzie requested you lead the field operation, and I'm sure you're the right man for the mission. diff --git a/base/missions/Underhill.mis b/base/missions/Underhill.mis index ff7308c..5f0daca 100644 --- a/base/missions/Underhill.mis +++ b/base/missions/Underhill.mis @@ -1,7 +1,7 @@ // MissionTypes = Hunters Bounty DM //--- MISSION QUOTE BEGIN --- -//Fah! Humans are weak! Find me a human who can fight, and I will bring you the sun in these two hands! +//Humans are always treacherous. Their lies make them weak. The weak are our prey. // -- Rog Gedharhk Blood-Drinker, Horde Maul reaver //--- MISSION QUOTE END --- diff --git a/base/prefs/WASDConfig.cs b/base/prefs/WASDConfig.cs index b731ed0..94acfaa 100644 --- a/base/prefs/WASDConfig.cs +++ b/base/prefs/WASDConfig.cs @@ -98,4 +98,10 @@ moveMap.bind(mouse0, "yaxis", pitch); moveMap.bind(mouse0, "button0", mouseFire); moveMap.bind(mouse0, "button1", mouseJet); moveMap.bind(mouse0, "zaxis", cycleWeaponAxis); -GlobalActionMap.bind(keyboard, "grave", toggleConsole); \ No newline at end of file +observerMap.delete(); +new ActionMap(observerMap); +observerMap.bind(keyboard, "space", jump); +observerMap.bind(keyboard, "e", moveup); +observerMap.bind(keyboard, "c", movedown); +observerMap.bind(mouse0, "button1", mouseJet); +GlobalActionMap.bind(keyboard, "grave", toggleConsole); diff --git a/base/scripts/BountyGame.cs b/base/scripts/BountyGame.cs index fbfeedd..c98e0f8 100644 --- a/base/scripts/BountyGame.cs +++ b/base/scripts/BountyGame.cs @@ -352,22 +352,18 @@ function BountyGame::buildListValidTargets(%game, %cl) for (%cIndex = 0; %cIndex < %numClients; %cIndex++) { %opponent = ClientGroup.getObject(%cIndex); - //echo ("Predator = " @ %cl @ " PossPrey = " @ %opponent); - if (!%opponent.isNotInGame) //hasn't dropped - { - if (%opponent != %cl) //don't add client himself to list + //make sure the target isn't yourself, or an observer + if (%opponent != %cl && %opponent.team > 0 && !%opponent.isNotInGame) + { + //make sure candidate for list has not already been killed by client + if (!%cl.eliminated[%opponent]) { - if (%opponent.player) //make sure candidate for list has a player - { - if (!%cl.eliminated[%opponent]) //make sure candidate for list has not already been killed by client - { - %cl.validList[%availTargets] = %opponent; - %availTargets++; - } - } + %cl.validList[%availTargets] = %opponent; + %availTargets++; } } } + //returns length of list (number of players eligible as targets to this client) %game.hudUpdateObjRem(%cl, %availTargets); if ((%availTargets <= %game.WARN_AT_NUM_OBJREM) && (%cl.hasHadTarget)) @@ -412,6 +408,7 @@ function BountyGame::gameOver(%game) %client = ClientGroup.getObject(%i); %game.resetScore(%client); cancel(%client.waypointSchedule); + cancel(%client.forceRespawnThread); } } @@ -436,6 +433,18 @@ function BountyGame::AIHasJoined(%game, %client) //messageAllExcept(%client, -1, 'MsgClientJoinTeam', '%1 has joined the fray.', %client.name, "", %client, 1); } +function BountyGame::forceRespawn(%game, %client) +{ + //make sure the player hasn't already respawned + if (isObject(%client.player)) + return; + + commandToClient(%client, 'setHudMode', 'Standard'); + Game.spawnPlayer( %client, true ); + %client.camera.setFlyMode(); + %client.setControlObject(%client.player); +} + function BountyGame::onClientKilled(%game, %clVictim, %clKiller, %damageType, %implement, %damageLoc) { DefaultGame::onClientKilled(%game, %clVictim, %clKiller, %damageType, %implement, %damageLoc); @@ -446,6 +455,10 @@ function BountyGame::onClientKilled(%game, %clVictim, %clKiller, %damageType, %i // any time a person dies, the kill streak is reset %clVictim.killStreak = 0; + + //force the player to respawn + if (!%clVictim.isAIControlled()) + %clVictim.forceRespawnThread = %game.schedule(5000, forceRespawn, %clVictim); } function BountyGame::onClientLeaveGame(%game, %clientId) @@ -476,7 +489,10 @@ function BountyGame::onClientLeaveGame(%game, %clientId) function BountyGame::onClientEnterObserverMode(%game, %clientId) { - // is this fair? go to observer mode and no one has you as a target any more + //cancel the respawn schedule + cancel(%clientId.forceRespawnThread); + + //notify everyone else, and choose a new objective if required... %numClients = ClientGroup.getCount(); for (%index = 0; %index < %numClients; %index++) { @@ -815,7 +831,7 @@ function BountyGame::updateScoreHud(%game, %client, %tag) for (%cIndex = 0; %cIndex < ClientGroup.getCount(); %cIndex++) { %opponent = ClientGroup.getObject(%cIndex); - if (!%opponent.isNotInGame && %opponent != %cl && isObject(%opponent.player) && !%cl.eliminated[%opponent]) + if (!%opponent.isNotInGame && %opponent.team > 0 && %opponent != %cl && !%cl.eliminated[%opponent]) %clTargets++; } @@ -840,6 +856,36 @@ function BountyGame::updateScoreHud(%game, %client, %tag) } } + // Tack on the list of observers: + %observerCount = 0; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.team == 0) + %observerCount++; + } + + if (%observerCount > 0) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient(%client, 'SetLineHud', "", %tag, %index, '\tOBSERVERS (%1)TIME', %observerCount); + %index++; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + //if this is an observer + if (%cl.team == 0) + { + %obsTime = getSimTime() - %cl.observerStartTime; + %obsTimeStr = %game.formatTime(%obsTime, false); + messageClient( %client, 'SetLineHud', "", %tag, %index, '\t%1%2', + %cl.name, %obsTimeStr ); + %index++; + } + } + } + //clear the rest of Hud so we don't get old lines hanging around... messageClient(%client, 'ClearHud', "", %tag, %index); } diff --git a/base/scripts/ChatGui.cs b/base/scripts/ChatGui.cs index 41ad2cf..f530c86 100644 --- a/base/scripts/ChatGui.cs +++ b/base/scripts/ChatGui.cs @@ -10,8 +10,11 @@ $ESCAPE_SEQ = "_-_"; $IRCClient::serverList = GetIRCServerList(0); $IRCClient::serverCount = getRecordCount($IRCClient::serverList); $IRCClient::retries = -1; -$IRCClient::serverIndex = -1; -$IRCClient::serverport = 6667; +if ($IRCClient::serverCount > 1) + $IRCClient::serverIndex = getRandom($IRCClient::serverCount-1)-1; +else + $IRCClient::serverIndex = -1; +$IRCClient::serverAttempt = 0; $AWAY_TIMEOUT = 5 * 60 * 1000; $VERSION_FLOOD_TIMEOUT = 5.0; @@ -35,6 +38,12 @@ $CHANNEL_TOPIC_LIMITED = 128; $CHANNEL_HAS_KEY = 256; $CHANNEL_NEW = 512; +// Default messages (if gui is left blank) +$DefaultChatAwayMessage = "Don't be alarmed. I'm going to step away from my computer."; +$DefaultChatKickMessage = "Alright, you\'re outta here!"; +$DefaultChatBanMessage = "You, and three generations of your offspring, are banned from this channel."; + + //------------------------------------------------------------------------------ function JoinChatDlg::onWake(%this) { @@ -53,9 +62,17 @@ function JoinChatList::onSelect(%this,%id,%text) //------------------------------------------------------------------------------ function JoinChatDlg::join(%this) { - IRCClient::join(IRCClient::channelName(JoinChatName.getValue())); - Canvas.popDialog(JoinChatDlg); - LaunchTabView.viewTab("CHAT",ChatGui,0); + if(trim(JoinChatName.getValue()) $= "") + { + messageBoxOK("ERROR", "Invalid Channel Name"); + return; + } + else + { + IRCClient::join(IRCClient::channelName(trim( JoinChatName.getValue()) )); + Canvas.popDialog(JoinChatDlg); + LaunchTabView.viewTab("CHAT", ChatGui, 0); + } } //------------------------------------------------------------------------------ @@ -95,6 +112,7 @@ function ChatGui::onWake(%this) ChatGui.awake = true; ChatTabView.setSelected($IRCClient::currentChannel); ChatGuiScroll.scrollToBottom(); + ChatMessageEntry.schedule(1, makeFirstResponder, true); } //------------------------------------------------------------------------------ @@ -105,7 +123,8 @@ function ChatGui::setKey(%this,%ignore) //------------------------------------------------------------------------------ function ChatTabView::onAdd(%this) { - %this.addTab($IRCClient::channels.getObject(0),"STATUS"); + if ($LaunchMode $= "Normal") + %this.addTab($IRCClient::channels.getObject(0),"STATUS"); } //------------------------------------------------------------------------------ @@ -114,6 +133,11 @@ function ChatTabView::onSelect(%this,%obj,%name) ChatTabFrame.setAltColor(%obj.private); %i = %obj.findMember($IRCClient::people.getObject(0)); ChatEditChannelBtn.setVisible(%obj.getFlags(%i) & $PERSON_OPERATOR); + + //is this the status window? do we need the options button + %vis = (%name $= "STATUS" ? true : false); + ChatEditOptionsBtn.setVisible(%vis); + ChatChannelTopic.setValue(%obj.topic); if (ChatGui.awake) { @@ -282,13 +306,7 @@ function ChatRoomMemberList::onRightMouseDown(%this,%column,%row,%mousePos) // Open the action menu: ChatMemberPopup.member = %this.getRowId(%row); ChatMemberPopup.position = %mousePos; - Canvas.pushDialog(ChatMemberActionDlg); - ChatMemberPopup.forceOnAction(); -} - -//------------------------------------------------------------------------------ -function ChatMemberActionDlg::onWake(%this) -{ + ChatMemberPopup.clear(); %nick = IRCClient::displayNick(ChatMemberPopup.member); %is = $IRCClient::currentChannel.findMember(ChatMemberPopup.member); @@ -310,7 +328,7 @@ function ChatMemberActionDlg::onWake(%this) } else { - if (strcmp(ChatMemberPopup.member.getName(),$IRCClient::currentChannel.getName())) + if (strcmp(ChatMemberPopup.member.displayName,$IRCClient::currentChannel.getName())) ChatMemberPopup.add("Chat",2); if ($IRCClient::currentChannel.getFlags(%im) & $PERSON_OPERATOR) @@ -338,6 +356,9 @@ function ChatMemberActionDlg::onWake(%this) ChatMemberPopup.add("Invite to" SPC IRCClient::displayChannel(%c.getName()),%c); } } + + Canvas.pushDialog(ChatMemberActionDlg); + ChatMemberPopup.forceOnAction(); } //------------------------------------------------------------------------------ @@ -360,7 +381,7 @@ function ChatMemberPopup::onSelect(%this,%id,%text) case 1: // Set Away IRCClient::away($pref::IRCClient::awaymsg); case 2: // Chat - %c = IRCClient::findChannel(ChatMemberPopup.member.getName(),true); + %c = IRCClient::findChannel(ChatMemberPopup.member.displayName,true); ChatTabView.setSelected(%c); case 3: // Admin IRCClient::setOperator(ChatMemberPopup.member); @@ -543,6 +564,75 @@ function AcceptChannelOptions() IRCClient::setKey(%c,false,""); } +//======================================================================== +// chat options menu + +//------------------------------------------------------------------------------ +function EditChatOptions() +{ + $tempHighlightOn = $pref::IRCClient::HightlightOn; + ButtonChatHighlight.setValue($tempHighlightOn); + + $tempHideLinks = $pref::IRCClient::hideLinks; + ButtonChatNameLinkToggle.setValue($tempHideLinks); + + //for now + ButtonChatShowJoin.setVisible(false); + ButtonChatChannelHighlight.setVisible(false); + + EditChatAwayMessage.setValue($pref::IRCClient::awaymsg); + EditChatKickMessage.setValue($pref::IRCClient::kickmsg); + EditChatBanMessage.setValue($pref::IRCClient::banmsg); + + Canvas.pushDialog(ChatOptionsDlg); +} + +//------------------------------------------------------------------------------ +function acceptChatOptions() +{ + //error("Accepting Chat Options...."); + $pref::IRCClient::HighlightOn = $tempHighlightOn; + + $pref::IRCClient::hideLinks = $tempHideLinks; + + if($tempAwayMsg !$= "") + $pref::IRCClient::awaymsg = $tempAwayMsg; + else + $pref::IRCClient::awaymsg = $DefaultChatAwayMessage; + + if($tempkickmsg !$= "") + $pref::IRCClient::kickmsg = $tempkickmsg; + else + $pref::IRCClient::kickmsg = $DefaultChatKickMessage; + + if($tempbanmsg !$= "") + $pref::IRCClient::banmsg = $tempbanmsg; + else + $pref::IRCClient::banmsg = $DefaultChatBanMessage; + + canvas.popDialog(ChatOptionsDlg); +} + +//------------------------------------------------------------------------------ +function CancelChatOptions() +{ + canvas.popDialog(ChatOptionsDlg); +} + +//------------------------------------------------------------------------------ +function ToggleChatHiglight() +{ + $tempHighlightOn = !$tempHighlightOn; + ButtonChatHighlight.setValue($tempHighlightOn); +} + +//------------------------------------------------------------------------------ +function ToggleChatLinkedNicks() +{ + $tempHideLinks = !$tempHideLinks; + ButtonChatNameLinkToggle.setValue($tempHideLinks); +} + //------------------------------------------------------------------------------ function IRCClient::init() { @@ -553,8 +643,9 @@ function IRCClient::init() $IRCClient::connectwait = 0; $IRCClient::room = ""; $IRCClient::numCensorWords = 0; + $IRCClient::previousChannelCount = 0; - $IRCClient::people.add(new SimObject("IRCMe") + $IRCClient::people.add(new SimObject() { real = ""; identity = ""; @@ -589,9 +680,6 @@ function IRCClient::notify(%event) MessageBoxOK("No Response","Connection failed. The IRC server did not respond.",""); case IDIRC_ERR_DROPPED: MessageBoxOK("Connection Dropped","You have been disconnected from IRC server " @ $IRCClient::server @ ".",""); - case IDIRC_RECONNECT: - case IDIRC_ERR_RECONNECT: - MessageBoxOK("No Reconnect","Unable to reconnect to IRC server " @ $IRCClient::server @ ".",""); case IDIRC_ERR_BADCHALLENGE: case IDIRC_ERR_BADCHALRESP_REPLY: case IDIRC_CHANNEL_LIST: @@ -710,7 +798,7 @@ function IRCClient::findPerson(%nick) for (%i = 0; %i < $IRCClient::people.getCount(); %i++) { %person = $IRCClient::people.getObject(%i); - if (%person.getName() $= %nick) + if (%person.displayName $= %nick) return %person; } } @@ -745,7 +833,7 @@ function IRCClient::findPerson2(%prefix,%create) if (%create) { - %p = new SimObject(%nick) + %p = new SimObject() { real = ""; identity = ""; @@ -753,9 +841,9 @@ function IRCClient::findPerson2(%prefix,%create) flags = 0; ping = 0; ref = 0; + displayName = %nick; }; - if (strlen(%ident)) - IRCClient::setIdentity(%p,%ident); + IRCClient::setIdentity(%p,%ident); $IRCClient::people.add(%p); %c = IRCClient::findChannel(%nick); @@ -769,9 +857,9 @@ function IRCClient::findPerson2(%prefix,%create) } // initiate WHO do determine username - if (!strlen(%ident) && %p != $IRCClient::people.getObject(1) && - getSubStr(%nick,strlen(%nick)-1,1) $= "^") - IRCClient::whois(%p); + //if (!strlen(%ident) && %p != $IRCClient::people.getObject(1) && + //getSubStr(%nick,strlen(%nick)-1,1) $= "^") + //IRCClient::whois(%p); return %p; } @@ -817,42 +905,35 @@ function IRCClient::undoEscapes(%string) function IRCClient::setIdentity(%p,%ident) { %p.identity = %ident; - - if (getSubStr(%p.getName(),strlen(%p.getName())-1,1) $= "^") - { - // identity is set and user is WON-authenticated - %i = strpos(%ident,"@"); - while ((%j = strpos(%ident,"@",%i+1)) >= 0) - %i = %j; - %user = IRCToByte(getSubStr(%ident,0,%i)); - - %delimeter = $ESCAPE_SEQ @ "00"; - %delimlen = strlen(%delimeter); - %i = strpos(%user,%delimeter); - %name = getSubStr(%user,0,%i); - %user = getSubStr(%user,%i+%delimlen, - strlen(%user)-(%i+%delimlen)); - %i = strpos(%user,%delimeter); - %tag = getSubStr(%user,0,%i); - %append = getSubStr(%user,%i+%delimlen,1); - - if (strlen(%tag)) - if (%append) - { - %p.nick = %name @ %tag; - %p.tagged = "" @ %name @ "" @ %tag @ ""; - } - else - { - %p.nick = %tag @ %name; - %p.tagged = "" @ %tag @ "" @ %name @ ""; - } - else - { + %nick = %p.displayName; + if (strpos(%nick, "^") != -1) + { + %triple = IRCGetTriple(%nick); + %name = getField(%triple, 0); + %tag = getField(%triple, 1); + %append = getField(%triple, 2); + %p.untagged = %name; + if (%tag $= "") + { %p.nick = %name; %p.tagged = "" @ %name @ ""; - } - } + } + else + if(%append) + { + %p.nick = %name @ %tag; + %p.tagged = "" @ %name @ "" @ %tag @ ""; + } + else + { + %p.nick = %tag @ %name; + %p.tagged = "" @ %tag @ "" @ %name @ ""; + } + } + else + { + %p.tagged = %nick; + } } //------------------------------------------------------------------------------ @@ -862,17 +943,22 @@ function IRCClient::displayNick(%person) if (strlen(%person.nick)) return %person.nick; else - return %person.getName(); + return %person.displayName; } +//------------------------------------------------------------------------------ //------------------------------------------------------------------------------ function IRCClient::taggedNick(%person) { + //error("IRCClient::taggedNick( "@%person@" )"); // identity is set and user is WON-authenticated if (strlen(%person.nick)) - return %person.tagged; + if($pref::IRCClient::hideLinks) + return %person.nick; + else + return %person.tagged; else - return %person.getName(); + return %person.displayName; } //------------------------------------------------------------------------------ @@ -881,7 +967,7 @@ function IRCClient::correctNick(%p) for (%i = 1; %i < $IRCClient::channels.getCount(); %i++) { %c = $IRCClient::channels.getObject(%i); - if (%c.getName() $= %p.getName()) + if (%c.getName() $= %p.displayName) { ChatTabView.setTabText(%c,IRCClient::displayNick(%p)); %c.topic = "Private chat with" SPC IRCClient::displayNick(%p); @@ -906,7 +992,8 @@ function IRCClient::correctNick(%p) //------------------------------------------------------------------------------ function IRCClient::findChannel(%name,%create) { - if (%name $= "") + //error("IRCClient::findChannel( "@%name@", "@%create@" )"); + if(%name $= "") return $IRCClient::currentChannel; for (%i = 0; %i < $IRCClient::channels.getCount(); %i++) @@ -941,7 +1028,7 @@ function IRCClient::findChannel(%name,%create) %c = new ChannelVector(%name) { topic = %topic; - key = ""; + key = $IRCClient::key; flags = $CHANNEL_NEW; personLimit = 0; private = %private; @@ -959,6 +1046,17 @@ function IRCClient::findChannel(%name,%create) $IRCClient::nextChannel = %c; IRCClient::notify(IDIRC_ADDCHANNEL); } + else + { + %messages = %name @ "_messages"; + if (isobject(%messages)) + { + for (%i = 0; %i < %messages.getNumLines(); %i++) + %c.pushBackLine(%messages.getLineText(%i)); + + %messages.delete(); + } + } return %c; } @@ -1017,14 +1115,25 @@ function IRCClient::connect() if($IRCClient::retries == -1 || $IRCClient::retries > 5) { $IRCClient::serverIndex++; - $IRCClient::retries = 0; - if($IRCClient::serverIndex >= $IRCClient::serverCount) + if ($IRCClient::serverIndex >= $IRCClient::serverCount) + $IRCClient::serverIndex = 0; + $IRCClient::serverAttempt++; + if ($IRCClient::serverCount == 0 || $IRCClient::serverAttempt > $IRCClient::serverCount) { IRCClient::newMessage("","Unable to connect to IRC servers."); - IRCClient::notify(IDIRC_ERR_RECONNECT); + IRCClient::notify(IDIRC_ERR_TIMEOUT); $IRCClient::state = IDIRC_DISCONNECTED; + $IRCClient::retries = -1; + if($IRCClient::serverCount > 1) + $IRCClient::serverIndex = getRandom($IRCClient::serverCount-1)-1; + else + $IRCClient::serverIndex = -1; + $IRCClient::serverAttempt = 0; + return; } + else + $IRCClient::retries = 0; $IRCClient::server = getField(getRecord($IRCClient::serverList, $IRCClient::serverIndex), 0); } IRCClient::newMessage("","Connecting to " @ $IRCClient::server); @@ -1075,8 +1184,9 @@ function IRCTCP::onConnectFailed(%this) else { IRCClient::newMessage("","Connection failed. The server did not respond."); - IRCClient::disconnect(); - IRCClient::notify(IDIRC_ERR_TIMEOUT); + + $IRCClient::retries++; + IRCClient::connect(); } } @@ -1085,11 +1195,60 @@ function IRCClient::reconnect() { if (!$pref::IRCClient::autoreconnect) return (false); + + %i = 0; + while ($IRCClient::channels.getCount() > 1) + { + %c = $IRCClient::channels.getObject(1); + + if (%c.private) + { + %c.delete(); + $IRCClient::deletedChannel = %c; + if ($IRCClient::currentChannel == %c) + $IRCClient::nextChannel = $IRCClient::channels.getObject(0); + IRCClient::notify(IDIRC_DELCHANNEL); + + continue; + } + + $IRCClient::previousChannel[%i] = %c.getName(); + $IRCClient::previousKey[%i] = %c.key; + + %messages = $IRCClient::previousChannel[%i] @ "_messages"; + if (isobject(%messages)) + %messages.delete(); + %m = new MessageVector(%messages); + + for (%j = 0; %j < %c.getNumLines(); %j++) + %m.pushBackLine(%c.getLineText(%j)); + + $IRCClient::channels.remove(%c); + for (%j = 0; %j < %c.numMembers(); %j++) + { + %m = %c.getMemberId(%j); + %m.ref--; + if (%m.ref == 0) + { + $IRCClient::people.remove(%m); + %m.delete(); + } + } + %c.delete(); + $IRCClient::deletedChannel = %c; + if ($IRCClient::currentChannel == %c) + $IRCClient::nextChannel = $IRCClient::channels.getObject(0); + IRCClient::notify(IDIRC_DELCHANNEL); + + %i++; + } + $IRCClient::previousChannelCount = %i; + + IRCClient::newMessage("","Attempting to reconnect."); $IRCClient::retries++; - IRCClient::newMessage("","Try " @ $IRCClient::retries @ ". Attempting to reconnect to " @ $IRCClient::server @ "."); - IRCClient::notify(IDIRC_RECONNECT); IRCClient::connect(); + return true; } @@ -1112,6 +1271,13 @@ function IRCClient::disconnect() IRCClient::reset(); } +//------------------------------------------------------------------------------ +function IRCClient::relogin() +{ + IRCClient::newMessage("","IRCClient: Reauthentication starting"); + IRCClient::send("CERT " @ WONLoginIRC()); +} + //------------------------------------------------------------------------------ function IRCClient::send(%message) { @@ -1163,8 +1329,8 @@ function IRCClient::processLine(%line) if (!IRCClient::dispatch(%prefix,%command,%params)) { - echo("IRCClient: " @ %command @ " not handled by dispatch!"); - echo("(cmd:) " @ %prefix @ " " @ %command @ " " @ %params); + //echo("IRCClient: " @ %command @ " not handled by dispatch!"); + //echo("(cmd:) " @ %prefix @ " " @ %command @ " " @ %params); } } } @@ -1368,10 +1534,14 @@ function IRCClient::onPrivMsg(%prefix,%params) if (getSubStr(%msg,0,1) $= ":") %msg = getSubStr(%msg,1,strlen(%msg)-1); + // should we highlight this message + if($pref::IRCClient::highlightOn) + %msg = IRCClient::nickHighLight(%msg); + %nick = %ch; if (getSubStr(%ch,0,1) $= "@" || getSubStr(%ch,0,1) $= "+") %nick = getSubStr(%nick,1,strlen(%nick)-1); - if ( %nick $= %p.getName()) + if ( %nick $= %p.displayName) nextToken(%prefix,ch," !"); if (strcmp(getSubStr(%msg,0,1),"\x01")) @@ -1401,19 +1571,14 @@ function IRCClient::onNick(%prefix,%params) if (%person) { - if (!(%person.flags & $PERSON_IGNORE)) - IRCClient::newMessage($IRCClient::currentChannel,%person.getName() @ " is now known as " @ %params @ "."); + %old = IRCClient::taggedNick(%person); - %channel = IRCClient::findChannel(%person.getName()); - - if (%channel) - %channel.setName(%params); + %person.displayName = %params; + IRCClient::setIdentity(%person,%person.ident); + IRCClient::correctNick(%person); - %person.setName(%params); - - // If this is me, re-set the console variable - if (%person == $IRCClient::people.getObject(0)) - $IRCClient::NickName = %person.getName(); + if (!(%person.flags & $PERSON_IGNORE)) + IRCClient::newMessage($IRCClient::currentChannel,%old @ " is now known as " @ IRCClient::taggedNick(%person) @ "."); } } @@ -1465,7 +1630,7 @@ function IRCClient::onMOTDEnd(%prefix, %params) // EXAMPLE :StLouis.MO.US.UnderNet.org 372 homer128 :- ==> Disclaimer/ Rules: if ($IRCClient::state $= IDIRC_CONNECTING_WAITING) { - IRCClient::newMessage("","Successfully connected to " @ $IRCClient::server @ ":" @ $IRCClient::serverport); + IRCClient::newMessage("","Successfully connected to " @ $IRCClient::server); $IRCClient::state = IDIRC_CONNECTED; IRCClient::notify(IDIRC_CONNECTED); @@ -1759,7 +1924,7 @@ function IRCClient::onMode(%prefix,%params) IRCClient::notify(IDIRC_SORT); // only display the message if my privilages are modified. - if (strcmp(%arg,$IRCClient::people.getObject(0).getName())) + if (strcmp(%arg,$IRCClient::people.getObject(0).displayName)) break; nextToken(%prefix,arg,"!"); @@ -1782,7 +1947,7 @@ function IRCClient::onMode(%prefix,%params) IRCClient::notify(IDIRC_SORT); // only display the message if my privilages are modified. - if (strcmp(%arg,$IRCClient::people.getObject(0).getName())) + if (strcmp(%arg,$IRCClient::people.getObject(0).displayName)) break; nextToken(%prefix,arg,"!"); @@ -2015,7 +2180,7 @@ function IRCClient::onBanListEnd(%prefix,%params) //------------------------------------------------------------------------------ function IRCClient::onBadNick(%prefix,%params) { - IRCClient::newMessage("","NOTICE: Nickname (" @ $IRCClient::people.getObject(0).getName() @ ") is already in use."); + IRCClient::newMessage("","NOTICE: Nickname (" @ $IRCClient::people.getObject(0).displayName @ ") is already in use."); IRCClient::notify(IDIRC_ERR_NICK_IN_USE); } @@ -2056,11 +2221,14 @@ function IRCClient::onAway(%prefix,%params) //------------------------------------------------------------------------------ function IRCClient::onAction(%prefix,%params) -{ +{ %msg = nextToken(%params,ch," :"); %c = IRCClient::findChannel(%ch,true); + + %person = IRCClient::findPerson2(%prefix,true); + %name = IRCClient::taggedNick(%person); - IRCClient::newMessage(%c,%prefix @ " " @ %msg); + IRCClient::newMessage(%c, %name @ " " @ %msg); } //------------------------------------------------------------------------------ @@ -2254,20 +2422,35 @@ function IRCClient::onChalRespReply(%prefix,%params) %params = nextToken(%params,ident," "); %params = nextToken(%params,reply," "); %me = $IRCClient::people.getObject(0); - %me.setName(%nick); + %me.displayName = %nick; IRCClient::setIdentity(%me,%ident @ "@localhost"); if (WONLoginIRC(%reply) $= "OK") { - IRCClient::newMessage("","Successfully connected to " @ $IRCClient::server @ ":" @ $IRCClient::serverport); - $IRCClient::state = IDIRC_CONNECTED; - IRCClient::notify(IDIRC_CONNECTED); + if ($IRCClient::state !$= IDIRC_CONNECTED) + { + IRCClient::newMessage("","Successfully connected to " @ $IRCClient::server); + $IRCClient::state = IDIRC_CONNECTED; + IRCClient::notify(IDIRC_CONNECTED); - if ($IRCClient::awaytimeout) - cancel($IRCClient::awaytimeout); - $IRCClient::awaytimeout = schedule($AWAY_TIMEOUT,0,"ChatAway_Timeout"); - // auto join a room if requested - if (strlen($IRCClient::room)) - IRCClient::send("JOIN " @ $IRCClient::room); + if ($IRCClient::awaytimeout) + cancel($IRCClient::awaytimeout); + $IRCClient::awaytimeout = schedule($AWAY_TIMEOUT,0,"ChatAway_Timeout"); + // auto join a room if requested + if (strlen($IRCClient::room)) + IRCClient::send("JOIN " @ $IRCClient::room); + + if ($IRCClient::previousChannelCount > 0) + { + for (%i = 0; %i < $IRCClient::previousChannelCount; %i++) + IRCClient::join($IRCClient::previousChannel[%i] @ " " @ $IRCClient::previousKey[%i]); + $IRCClient::previousChannelCount = 0; + } + } + else + { + IRCClient::newMessage("","Successfully reauthenticated with " @ $IRCClient::server); + IRCClient::correctNick($IRCClient::people.getObject(0)); + } } else { @@ -2345,7 +2528,7 @@ function IRCClient::sendAction(%message) { IRCClient::send("PRIVMSG " @ $IRCClient::currentChannel.getName() @ " :\x01ACTION " @ %message @ "\x01"); %me = $IRCClient::people.getObject(0); - IRCClient::newMessage($IRCClient::currentChannel,%me.getName() @ " " @ %message); + IRCClient::newMessage($IRCClient::currentChannel,IRCClient::taggedNick(%me) @ " " @ %message); } } @@ -2368,6 +2551,8 @@ function IRCClient::join(%params) } else { + $IRCClient::key = %key; + IRCClient::send("JOIN " @ %channel @ " " @ %key); IRCClient::connecting(); } @@ -2387,14 +2572,11 @@ function IRCClient::nick(%nick) if (($IRCClient::state $= IDIRC_CONNECTED || $IRCClient::state $= IDIRC_CONNECTING_IRC) && strlen(nick)) { - if (stricmp(%nick, $IRCClient::people.getObject(0).getName())) + if (stricmp(%nick, $IRCClient::people.getObject(0).displayName)) IRCClient::send("NICK " @ %nick); } else - { - $IRCClient::people.getObject(0).setName(%nick); - $IRCClient::NickName = %nick; - } + $IRCClient::people.getObject(0).displayName = %nick; } //------------------------------------------------------------------------------ @@ -2403,6 +2585,27 @@ function IRCClient::name(%name) $IRCClient::people.getObject(0).real = %name; } +//---------------------------------------------------------------------- +function IRCClient::nickHighLight(%message) +{ + //error("IRCClient::nickHighLight( "@%message@" )"); + %nick = $IRCClient::people.getObject(0).untagged; + + //%nickLen = strLen(%nick); + // swap in for multiple nick options here + + %wordCount = getWordCount(%message); + for(%i = 0; %i < %wordCount; %i++) + { + %word = getWord(%message, %i); + if(%word $= %nick) + { + %message = "\c2" @ %message; + } + } + return %message; +} + //------------------------------------------------------------------------------ function IRCClient::part(%params) { @@ -2442,8 +2645,8 @@ function IRCClient::part(%params) IRCClient::notify(IDIRC_DELCHANNEL); } - break; - } + break; + } } //------------------------------------------------------------------------------ @@ -2500,7 +2703,7 @@ function IRCClient::ping(%params) //------------------------------------------------------------------------------ function IRCClient::setOperator(%p) { - IRCClient::send("MODE " @ $IRCClient::currentChannel.getName() @ " +o " @ %p.getName()); + IRCClient::send("MODE " @ $IRCClient::currentChannel.getName() @ " +o " @ %p.displayName); } //------------------------------------------------------------------------------ @@ -2540,16 +2743,16 @@ function IRCClient::setSpectator(%nick) //------------------------------------------------------------------------------ function IRCClient::kick(%p,%msg) { - IRCClient::send("KICK" SPC $IRCClient::currentChannel.getName() SPC %p.getName() @ " :" @ %msg); + IRCClient::send("KICK" SPC $IRCClient::currentChannel.getName() SPC %p.displayName @ " :" @ %msg); } //------------------------------------------------------------------------------ function IRCClient::ban(%p,%add) { if (%add) - IRCClient::send("MODE " @ $IRCClient::currentChannel.getName() @ " +b " @ %p.getName()); + IRCClient::send("MODE " @ $IRCClient::currentChannel.getName() @ " +b " @ %p.displayName); else - IRCClient::send("MODE " @ $IRCClient::currentChannel.getName() @ " -b " @ %p.getName()); + IRCClient::send("MODE " @ $IRCClient::currentChannel.getName() @ " -b " @ %p.displayName); } //------------------------------------------------------------------------------ @@ -2581,21 +2784,21 @@ function IRCClient::ignore(%p,%tf) //------------------------------------------------------------------------------ function IRCClient::invite(%p,%c) { - IRCClient::send("INVITE" SPC %p.getName() SPC %c.getName()); + IRCClient::send("INVITE" SPC %p.displayName SPC %c.getName()); } //------------------------------------------------------------------------------ function IRCClient::who(%p) { IRCClient::connecting(); - IRCClient::send("WHO" SPC %p.getName()); + IRCClient::send("WHO" SPC %p.displayName); } //------------------------------------------------------------------------------ function IRCClient::whois(%p) { IRCClient::connecting(); - IRCClient::send("WHOIS" SPC %p.getName()); + IRCClient::send("WHOIS" SPC %p.displayName); } //------------------------------------------------------------------------------ @@ -2680,7 +2883,10 @@ function IRCClient::onJoinServer(%mission,%server,%address,%mayprequire,%prequir //------------------------------------------------------------------------------ function IRCClient::onJoinGame(%address,%desc) { - %msg = "launched into " @ %desc @ "."; + if (%address $= "") + %msg = $pref::IRCClient::hostMsg; + else + %msg = "launched into " @ %desc @ "."; IRCClient::away(%msg); for (%i = 1; %i < $IRCClient::channels.getCount(); %i++) { @@ -2690,5 +2896,14 @@ function IRCClient::onJoinGame(%address,%desc) } } -IRCClient::init(); -IRCClient::connect(); \ No newline at end of file +//------------------------------------------------------------------------------ +function IRCClient::onLeaveGame() +{ + IRCClient::away(""); +} + +if ($LaunchMode $= "Normal") +{ + IRCClient::init(); + IRCClient::connect(); +} \ No newline at end of file diff --git a/base/scripts/ChooseFilterDlg.cs b/base/scripts/ChooseFilterDlg.cs index f89f7be..b837b8b 100644 --- a/base/scripts/ChooseFilterDlg.cs +++ b/base/scripts/ChooseFilterDlg.cs @@ -264,7 +264,7 @@ function clearMissionTypes() // Add all the mission types found on this machine: for ( %i = 0; %i < $HostTypeCount; %i++ ) - FilterEditMissionType.add( $HostTypeName[%i], %i ); + FilterEditMissionType.add( $HostTypeDisplayName[%i], %i ); } //------------------------------------------------------------------------------ diff --git a/base/scripts/CnHGame.cs b/base/scripts/CnHGame.cs index 363c1b8..c3c3e4b 100644 --- a/base/scripts/CnHGame.cs +++ b/base/scripts/CnHGame.cs @@ -24,8 +24,9 @@ function FlipFlop::playerTouch(%data, %flipflop, %player) function Flipflop::objectiveInit(%data, %flipflop) { - %flipflop.teamBonusThread = ""; - %flipflop.playerBonusThread = ""; + %flipflop.tCapThread = ""; + %flipflop.tHoldThread = ""; + %flipflop.pCapThread = ""; Parent::objectiveInit(%data, %flipflop); } @@ -46,9 +47,7 @@ function CnHGame::initGameVars(%game) %game.SCORE_PER_TURRET_KILL = 1; %game.SCORE_PER_FLIPFLOP_DEFEND = 1; - %game.SCORE_LIMIT_PER_TOWER = 1200; //default of 1500 points per tower required to win @ 1 pt per %game.TIME_REQ_TEAM_HOLD_BONUS milliseconds - // default of 1500 per switch if not defined in mission file specifically. 2 pts per sec per switch = 10 minute min & 20 minute max mission length - // not counting time spent waiting for first point(s). Should be 15-30ish minute missions depending on turnovers + %game.SCORE_LIMIT_PER_TOWER = 1200; //default of 1200 points per tower required to win @ 1 pt per %game.TIME_REQ_TEAM_HOLD_BONUS milliseconds %game.TIME_REQ_PLYR_CAP_BONUS = 12 * 1000; //player must hold a switch 12 seconds to get a point for it. %game.TIME_REQ_TEAM_CAP_BONUS = 12 * 1000; //time after touching it takes for team to get a point @@ -131,11 +130,14 @@ function CnHGame::gameOver(%game) messageAll('MsgClearObjHud', ""); for(%i = 0; %i < ClientGroup.getCount(); %i ++) { - %client = %group.getObject(%i); + %client = ClientGroup.getObject(%i); %game.resetScore(%client); } for ( %team = 1; %team <= %game.numTeams; %team++ ) + { $TeamScore[%team] = 0; + messageAll('MsgCnHTeamCap', "", -1, -1, -1, %team, $TeamScore[%team], %game.getScoreLimit()); + } } function CnHGame::stopScoreTimers(%game) @@ -148,9 +150,9 @@ function CnHGame::stopScoreTimers(%game) for(%i = 0; %i < %ffGroup.getCount(); %i++) { %curFF = %ffGroup.getObject(%i); + cancel(%curFF.tHoldThread); cancel(%curFF.pCapThread); cancel(%curFF.tCapThread); - cancel(%curFF.tHoldThread); } } @@ -309,7 +311,7 @@ function CnHGame::testPlayerFFDefend(%game, %victimID, %killerID) while(%objID != 0) { %objType = %objID.getDataBlock().getName(); - echo("tFD found " @ %objType @ " belonging to team " @ %objID.team); + //echo("tFD found " @ %objType @ " belonging to team " @ %objID.team); if ((%objType $= "FlipFlop") && (%objID.team == %killerID.team)) return true; //found a killer's team flipflop near the point of victim's death else @@ -323,31 +325,42 @@ function CnHGame::awardScorePlayerFFDefend(%game, %cl, %this) %cl.flipFlopDefends++; //if (%game.SCORE_PER_FLIPFLOP_DEFEND != 0) //messageClient(%cl, $scoreFliDefMsg, 'You receive a %1 point bonus for defending the %2.', %game.SCORE_PER_FLIPFLOP_DEFEND, %game.cleanWord(%this.name)); - %game.recalcScore(%cl); + %game.recalcScore(%cl); } function CnHGame::awardScorePlayerFFCap(%game, %cl, %this) { + if(!($missionRunning)) + return; + %cl.flipFlopsCapped++; - %game.recalcScore(%cl); + %game.recalcScore(%cl); } function CnHGame::awardScoreTeamFFCap(%game, %team, %this) { cancel(%this.tCapThread); + + if(!($missionRunning)) + return; + $TeamScore[%team] +=%game.SCORE_PER_TEAM_FLIPFLOP_CAP; %sLimit = %game.getScoreLimit(); if (%game.SCORE_PER_TEAM_FLIPFLOP_CAP) messageAll('MsgCnHTeamCap', "", -1, -1, -1, %team, $teamScore[%team], %sLimit); if (%game.SCORE_PER_TEAM_FLIPFLOP_HOLD != 0) - %this.tHoldThread = %game.schedule(%game.TIME_REQ_TEAM_HOLD_BONUS, "awardScoreTeamFFHold", %team, %this, true); + %this.tHoldThread = %game.schedule(%game.TIME_REQ_TEAM_HOLD_BONUS, "awardScoreTeamFFHold", %team, %this); %game.checkScoreLimit(%team); } -function CnHGame::awardScoreTeamFFHold(%game, %team, %this, %msg) +function CnHGame::awardScoreTeamFFHold(%game, %team, %this) { cancel(%this.tHoldThread); + + if(!($missionRunning)) + return; + $TeamScore[%team] +=%game.SCORE_PER_TEAM_FLIPFLOP_HOLD; %sLimit = %game.getScoreLimit(); if (%game.SCORE_PER_TEAM_FLIPFLOP_HOLD) @@ -360,7 +373,7 @@ function CnHGame::awardScoreTeamFFHold(%game, %team, %this, %msg) %game.checkScoreLimit(%team); - %this.tHoldThread = %game.schedule(%game.TIME_REQ_TEAM_HOLD_BONUS, "awardScoreTeamFFHold", %team, %this, false); + %this.tHoldThread = %game.schedule(%game.TIME_REQ_TEAM_HOLD_BONUS, "awardScoreTeamFFHold", %team, %this); } function CnHGame::testValidRepair(%game, %obj) diff --git a/base/scripts/DMGame.cs b/base/scripts/DMGame.cs index 1c27461..a4e69af 100644 --- a/base/scripts/DMGame.cs +++ b/base/scripts/DMGame.cs @@ -349,6 +349,36 @@ function DMGame::updateScoreHud(%game, %client, %tag) } } + // Tack on the list of observers: + %observerCount = 0; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.team == 0) + %observerCount++; + } + + if (%observerCount > 0) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient(%client, 'SetLineHud', "", %tag, %index, '\tOBSERVERS (%1)TIME', %observerCount); + %index++; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + //if this is an observer + if (%cl.team == 0) + { + %obsTime = getSimTime() - %cl.observerStartTime; + %obsTimeStr = %game.formatTime(%obsTime, false); + messageClient( %client, 'SetLineHud', "", %tag, %index, '\t%1%2', + %cl.name, %obsTimeStr ); + %index++; + } + } + } + //clear the rest of Hud so we don't get old lines hanging around... messageClient( %client, 'ClearHud', "", %tag, %index ); } diff --git a/base/scripts/DebriefGui.cs b/base/scripts/DebriefGui.cs index 373edcc..5f677aa 100644 --- a/base/scripts/DebriefGui.cs +++ b/base/scripts/DebriefGui.cs @@ -10,7 +10,11 @@ function DebriefGui::onWake( %this ) moveMap.pop(); if ( isObject( passengerKeys ) ) passengerKeys.pop(); - flyingCameraMove.pop(); + if ( isObject( observerBlockMap ) ) + observerBlockMap.pop(); + if ( isObject( observerMap ) ) + observerMap.pop(); + //flyingCameraMove.pop(); if ( isObject( debriefMap ) ) { diff --git a/base/scripts/GameGui.cs b/base/scripts/GameGui.cs index 24f7a26..f479cb4 100644 --- a/base/scripts/GameGui.cs +++ b/base/scripts/GameGui.cs @@ -47,6 +47,13 @@ function GameGui::onSleep( %this ) %ctrl = "GM_" @ %this.pane @ "Pane"; if ( isObject( %ctrl ) ) %ctrl.onDeactivate(); + +// if( isObject( $dummySeq ) ) +// { +// $dummySeq.delete(); +// } + + Canvas.popDialog(LaunchToolbarDlg); } //------------------------------------------------------------------------------ @@ -156,7 +163,7 @@ $BrowserColumnCount++; $BrowserColumnName[6] = "Rules Set"; $BrowserColumnRange[6] = "25 300"; $BrowserColumnCount++; -$BrowserColumnName[7] = "# Players"; +$BrowserColumnName[7] = "# Players (Bots)"; $BrowserColumnRange[7] = "25 150"; $BrowserColumnCount++; $BrowserColumnName[8] = "CPU"; @@ -533,7 +540,8 @@ function JoinSelectedGame() %info = GMJ_Browser.getServerInfoString(); %desc = "a" SPC getField(%info,4) @ "(" @ getField(%info,3) @ ") game on the \"" @ getField(%info,0) @ "\" server. Click here to follow"; - IRCClient::onJoinGame($JoinGameAddress,%desc); + + IRCClient::onJoinGame($JoinGameAddress,%desc); JoinGame($JoinGameAddress); } @@ -550,7 +558,6 @@ function JoinGame(%address) %playerVoice = getField( %playerPref, 3 ); %playerVoicePitch = getField( %playerPref, 4 ); connect( %address, $JoinGamePassword, %playerName, %playerRaceGender, %playerSkin, %playerVoice, %playerVoicePitch ); - ServerConnection.setSimulatedNetParams(0.1, 10); } //------------------------------------------------------------------------------ @@ -574,19 +581,28 @@ function GM_HostPane::onActivate( %this ) // Select the saved-off prefs: if ( $Host::MissionType !$= "" ) { - %selId = GMH_MissionType.findText( $Host::MissionType ); - if ( %selId != -1 ) + // Find the last selected type: + for ( %type = 0; %type < $HostTypeCount; %type++ ) { - GMH_MissionType.setSelected( %selId ); - GMH_MissionType.onSelect( %selId, "" ); + if ( $HostTypeName[%type] $= $Host::MissionType ) + break; + } + + if ( %type != $HostTypeCount ) + { + GMH_MissionType.setSelected( %type ); + GMH_MissionType.onSelect( %type, "" ); if ( $Host::Map !$= "" ) { - %index = GMH_MissionList.findTextIndex( $Host::Map ); - if ( %index != -1 ) + // Find the last selected mission: + for ( %index = 0; %index < $HostMissionCount[%type]; %index++ ) { - %selId = GMH_MissionList.getRowId( %index ); - GMH_MissionList.setSelectedById( %selId ); + if ( $HostMissionFile[$HostMission[%type, %index]] $= $Host::Map ) + break; } + + if ( %index != $HostMissionCount[%type] ) + GMH_MissionList.setSelectedById( $HostMission[%type, %index] ); } } } @@ -609,7 +625,31 @@ function buildMissionTypePopup( %popup ) { %popup.clear(); for( %type = 0; %type < $HostTypeCount; %type++ ) - %popup.add( $HostTypeName[%type], %type ); + %popup.add( $HostTypeDisplayName[%type], %type ); +} + +//------------------------------------------------------------------------------ +function getMissionTypeDisplayNames() +{ + %file = new FileObject(); + for ( %type = 0; %type < $HostTypeCount; %type++ ) + { + $HostTypeDisplayName[%type] = $HostTypeName[%type]; + if ( %file.openForRead( "scripts/" @ $HostTypeName[%type] @ "Game.cs" ) ) + { + while ( !%file.isEOF() ) + { + %line = %file.readLine(); + if ( getSubStr( %line, 0, 17 ) $= "// DisplayName = " ) + { + $HostTypeDisplayName[%type] = getSubStr( %line, 17, 1000 ); + break; + } + } + } + } + + %file.delete(); } //------------------------------------------------------------------------------ @@ -679,6 +719,8 @@ function buildMissionList() $HostMissionCount[%i]++; } } + + getMissionTypeDisplayNames(); %fobject.delete(); } @@ -705,6 +747,8 @@ function validateMissionAndType(%misName, %misType) return true; } +//------------------------------------------------------------------------------ +// This function returns the index of the next mission in the mission list. //------------------------------------------------------------------------------ function getNextMission( %misName, %misType ) { @@ -749,7 +793,7 @@ function getNextMission( %misName, %misType ) } } - return $HostMissionFile[$HostMission[%type, %i]]; + return $HostMission[%type, %i]; } //------------------------------------------------------------------------------ @@ -823,6 +867,8 @@ function StartHostedGame() return; } + IRCClient::onJoinGame("", ""); + MessagePopup( "STARTING SERVER", "Initializing..." ); Canvas.repaint(); @@ -1173,8 +1219,19 @@ function GMW_PlayerModel::update( %this ) } %skin = getField( $pref::Player[$pref::Player::Current], 2 ); - - %this.setModel( %shape @ ".dts", %skin ); + +// if( isObject( $dummySeq ) ) +// { +// $dummySeq.delete(); +// } +// +// $dummySeq = new TSShapeConstructor() +// { +// baseShape = %shape @ ".dts"; +// sequence0 = %shape @ "_forward.dsq dummyRun"; +// }; + + %this.setModel( %shape, %skin ); } //------------------------------------------------------------------------------ @@ -1344,7 +1401,7 @@ function GMW_SkinPopup::onSelect( %this, %id, %text ) $pref::Player[$pref::Player::Current] = setField( $pref::Player[$pref::Player::Current], 2, %text ); // Update the player model: - GMW_PlayerModel.update(); + GMW_PlayerModel.update(); } //------------------------------------------------------------------------------ @@ -1487,9 +1544,9 @@ function NW_NameEdit::checkValidPlayerName( %this ) %name = %this.getValue(); %test = strToPlayerName( %name ); if ( %name !$= %test ) - %this.setValue( %name ); + %this.setValue( %test ); - NW_DoneBtn.setActive( strlen( stripTrailingSpaces( %name ) ) > 2 ); + NW_DoneBtn.setActive( strlen( stripTrailingSpaces( %test ) ) > 2 ); } //------------------------------------------------------------------------------ diff --git a/base/scripts/HuntersGame.cs b/base/scripts/HuntersGame.cs index d5d48e3..b0c49c6 100644 --- a/base/scripts/HuntersGame.cs +++ b/base/scripts/HuntersGame.cs @@ -145,7 +145,6 @@ function HuntersGame::missionLoadDone(%game) %client = ClientGroup.getObject(%i); %game.resetScore(%client); %client.flagCount = 1; - %client.trackClient = 0; %client.trackWaypoint = ""; %client.playerTrackLine = -1; } @@ -555,41 +554,6 @@ function HuntersGame::updateFlagHoarder(%game) } } -function HuntersGame::updateTrackers(%game, %client) -{ - //update anyone who is tracking this player - %count = ClientGroup.getCount(); - for (%i = 0; %i < %count; %i++) - { - %cl = ClientGroup.getObject(%i); - if (%cl.trackClient == %client) - { - //see if the tracker has a waypoint already - if (!isObject(%cl.trackWaypoint)) - { - //create a waypoint at player's location... - %cl.trackWaypoint = new WayPoint() - { - position = %player.position; - rotation = "1 0 0 0"; - scale = "1 1 1"; - name = "Tracking" SPC getTaggedString(%client.name); - dataBlock = "WayPointMarker"; - lockCount = "0"; - homingCount = "0"; - team = %client.team; - }; - - //add the waypoint to the cleanup group - MissionCleanup.add(%cl.trackWaypoint); - } - - //set the position - %cl.trackWaypoint.setTransform(%player.getWorldBoxCenter() SPC "0 0 1 0"); - } - } -} - function HuntersGame::sendFlagCountMessage(%game, %client) { //send the messages @@ -1584,8 +1548,6 @@ function HuntersGame::updateScoreHud(%game, %client, %tag) %col1Style = ""; else if ( %col1Client == %client ) %col1Style = ""; - else if ( %col1Client == %client.trackClient ) - %col1Style = ""; //see if we have two columns if (%numColumns == 2) @@ -1608,8 +1570,6 @@ function HuntersGame::updateScoreHud(%game, %client, %tag) %col2Style = ""; else if ( %col2Client == %client ) %col2Style = ""; - else if ( %col2Client == %client.trackClient ) - %col2Style = ""; } } @@ -1628,16 +1588,67 @@ function HuntersGame::updateScoreHud(%game, %client, %tag) else { if ( %numColumns == 2 ) - messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3%8%4%5%6', - %col1Client.name, %col1ClientScore, %col1ClientFlags, - %col2Client.name, %col2ClientScore, %col2ClientFlags, - %col1Style, %col2Style, %col1Client, %col2Client); + { + + //this is lame, but we can only have up to %9 args + if ( %col2Client == %maxFlagsClient ) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3%4%5%6', + %col1Client.name, %col1ClientScore, %col1ClientFlags, + %col2Client.name, %col2ClientScore, %col2ClientFlags, + %col1Style, %col1Client, %col2Client); + } + else if ( %col2Client == %client ) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3%4%5%6', + %col1Client.name, %col1ClientScore, %col1ClientFlags, + %col2Client.name, %col2ClientScore, %col2ClientFlags, + %col1Style, %col1Client, %col2Client); + } + else + { + messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3%4%5%6', + %col1Client.name, %col1ClientScore, %col1ClientFlags, + %col2Client.name, %col2ClientScore, %col2ClientFlags, + %col1Style, %col1Client, %col2Client); + } + } else messageClient( %client, 'SetLineHud', "", %tag, %index, '%4\t%1%2%3', %col1Client.name, %col1ClientScore, %col1ClientFlags, %col1Style, %col1Client ); } } + // Tack on the list of observers: + %observerCount = 0; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.team == 0) + %observerCount++; + } + + if (%observerCount > 0) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient(%client, 'SetLineHud', "", %tag, %index, '\tOBSERVERS (%1)TIME', %observerCount); + %index++; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + //if this is an observer + if (%cl.team == 0) + { + %obsTime = getSimTime() - %cl.observerStartTime; + %obsTimeStr = %game.formatTime(%obsTime, false); + messageClient( %client, 'SetLineHud', "", %tag, %index, '\t%1%2', + %cl.name, %obsTimeStr ); + %index++; + } + } + } + //clear the rest of Hud so we don't get old lines hanging around... messageClient( %client, 'ClearHud', "", %tag, %index ); } diff --git a/base/scripts/LaunchLanGui.cs b/base/scripts/LaunchLanGui.cs index e0b17b0..b8d4bf9 100644 --- a/base/scripts/LaunchLanGui.cs +++ b/base/scripts/LaunchLanGui.cs @@ -269,7 +269,7 @@ function LaunchGui::onWake(%this) if ( !Canvas.isCursorOn() ) CursorOn(); $enableDirectInput = "0"; - disableDirectInput(); + deactivateDirectInput(); Canvas.pushDialog(LaunchToolbarDlg); if ( !$FirstLaunch ) LaunchTabView.viewLastTab(); diff --git a/base/scripts/LobbyGui.cs b/base/scripts/LobbyGui.cs index 401eedb..87a5323 100644 --- a/base/scripts/LobbyGui.cs +++ b/base/scripts/LobbyGui.cs @@ -53,10 +53,14 @@ function LobbyGui::onWake( %this ) moveMap.pop(); if ( isObject( passengerkeys ) ) passengerKeys.pop(); - flyingCameraMove.pop(); + if ( isObject( observerBlockMap ) ) + observerBlockMap.pop(); + if ( isObject( observerMap ) ) + observerMap.pop(); + //flyingCameraMove.pop(); $enableDirectInput = "0"; - disableDirectInput(); + deactivateDirectInput(); LobbyMessageVector.attach(HudMessageVector); LobbyMessageScroll.scrollToBottom(); @@ -382,7 +386,8 @@ function fillLobbyMissionMenu( %type, %typeName ) LobbyVoteMenu.key++; LobbyVoteMenu.clear(); LobbyVoteMenu.mode = "mission"; - LobbyVoteMenu.missionType = %typeName; + LobbyVoteMenu.missionType = %type; + LobbyVoteMenu.typeName = %typeName; commandToServer( 'GetMissionList', LobbyVoteMenu.key, %type ); } @@ -547,18 +552,18 @@ function lobbyVote() startNewVote( "VoteChangeMission", "change the mission to", %text, // Mission display name - LobbyVoteMenu.missionType, // Mission type display name - $clVoteCmd[%id], // Mission file name - LobbyVoteMenu.missionType ); // Mission type + LobbyVoteMenu.typeName, // Mission type display name + $clVoteCmd[%id], // Mission id + LobbyVoteMenu.missionType ); // Mission type id } else { startNewVote( "VoteTournamentMode", "change the server to", %text, // Mission display name - LobbyVoteMenu.missionType, // Mission type display name - $clVoteCmd[%id], // Mission file name - LobbyVoteMenu.missionType ); // Mission type + LobbyVoteMenu.typeName, // Mission type display name + $clVoteCmd[%id], // Mission id + LobbyVoteMenu.missionType ); // Mission type id LobbyVoteMenu.tourneyChoose = 0; } LobbyVoteMenu.reset(); diff --git a/base/scripts/OptionsDlg.cs b/base/scripts/OptionsDlg.cs index 98b7dcc..7bb4874 100644 --- a/base/scripts/OptionsDlg.cs +++ b/base/scripts/OptionsDlg.cs @@ -17,12 +17,13 @@ function OptionsDlg::onWake( %this ) CursorOn(); $enableDirectInput = "1"; - enableDirectInput(); + activateDirectInput(); OP_VideoPane.setVisible( false ); OP_GraphicsPane.setVisible( false ); OP_TexturesPane.setVisible( false ); OP_SoundPane.setVisible( false ); + OP_VoicePane.setVisible( false ); OP_ControlsPane.setVisible( false ); OP_NetworkPane.setVisible( false ); OP_GamePane.setVisible( false ); @@ -31,6 +32,7 @@ function OptionsDlg::onWake( %this ) OP_GraphicsTab.setValue( false ); OP_TexturesTab.setValue( false ); OP_SoundTab.setValue( false ); + OP_VoiceTab.setValue( false ); OP_ControlsTab.setValue( false ); OP_NetworkTab.setValue( false ); OP_GameTab.setValue( false ); @@ -61,6 +63,8 @@ function OptionsDlg::onWake( %this ) OP_TerrainSlider.setValue( $max_screenerror - $pref::Terrain::screenError ); OP_ShapeSlider.setValue( ( $max_TSScreenError - $pref::TS::screenError ) / ( $max_TSScreenError - $min_TSScreenError ) ); OP_ShadowSlider.setValue( $pref::Shadows ); + OP_InteriorDetailSlider.setValue( $pref::Interior::detailAdjust ); + OP_VisibleDistanceSlider.setValue( $pref::VisibleDistanceMod ); OP_SkyDetailMenu.init(); if ( !$pref::SkyOn ) %selId = 5; @@ -70,17 +74,22 @@ function OptionsDlg::onWake( %this ) %selId = 1; OP_SkyDetailMenu.setSelected( %selId ); OP_SkyDetailMenu.setText( OP_SkyDetailMenu.getTextById( %selId ) ); - OP_VertexLightTgl.setValue( $pref::Interior::VertexLighting ); OP_PlayerRenderMenu.init(); %selId = $pref::Player::renderMyPlayer | ( $pref::Player::renderMyItems << 1 ); OP_PlayerRenderMenu.setSelected( %selId ); - OP_VisibleDistanceSlider.setValue( $pref::VisibleDistanceMod ); + OP_VertexLightTgl.setValue( $pref::Interior::VertexLighting ); // Initialize the Textures Options controls: - OP_ShapeTexSlider.setValue( 5 - $pref::OpenGL::mipReduction ); - OP_TerrainTexSlider.setValue( 6 - $pref::Terrain::texDetail ); - OP_BuildingTexSlider.setValue( 5 - $pref::OpenGL::interiorMipReduction ); - OP_SkyTexSlider.setValue( 5 - $pref::OpenGL::skyMipReduction ); + OP_TerrainTexSlider.setValue( 6 - $pref::Terrain::texDetail ); + + // We're using the noDrawArraysAlpha variable here because we've already + // gone gold (hard to add a new profiling variable). But the Voodoo2/3/3500 + // cards that have the 256x256 texture limitation (in OpenGL) also have the + // noDrawArraysAlpha hack on...so that works out nice + %mipRange = $pref::OpenGL::noDrawArraysAlpha ? 4.0 : 5.0; + OP_ShapeTexSlider.setValue( (5 - $pref::OpenGL::mipReduction) / %mipRange ); + OP_BuildingTexSlider.setValue( (5 - $pref::OpenGL::interiorMipReduction) / %mipRange ); + OP_SkyTexSlider.setValue( (5 - $pref::OpenGL::skyMipReduction) / %mipRange ); // Initialize the Sound Options controls: // provider menu @@ -102,32 +111,40 @@ function OptionsDlg::onWake( %this ) OP_AudioSpeakerMenu.setSelected(%selId); OP_AudioSpeakerMenu.onSelect(%selId, ""); + OP_AudioFrequencyMenu.init(); + OP_AudioBitRateMenu.init(); + OP_AudioChannelsMenu.init(); + OP_MasterVolumeSlider.setValue( $pref::Audio::masterVolume ); OP_EffectsVolumeSlider.setValue( $pref::Audio::effectsVolume ); OP_VoiceBindVolumeSlider.setValue( $pref::Audio::radioVolume ); OP_GuiVolumeSlider.setValue( $pref::Audio::guiVolume ); OP_MusicTgl.onAction(); OP_MusicVolumeSlider.setValue( $pref::Audio::musicVolume ); + + // Initialize the Voice Settings controls: OP_MicrophoneEnabledTgl.onAction(); OP_MicrophoneVolumeSlider.setValue( $pref::Audio::voiceVolume ); OP_InputBoostSlider.setValue( $pref::Audio::captureGainScale ); + OP_VoiceListenMenu.init(); + OP_VoiceSendMenu.init(); updateInputBoost(); // Initialize the Control Options controls: - OP_RemapList.fillList(); + OP_ControlGroupMenu.init(); + // JOYSTICK SUPPORT WILL BE RE-ENABLED IN THE PATCH - //if ( isJoystickDetected() ) - if ( false ) + if ( isJoystickDetected() ) { + OP_JoystickTgl.setValue( $pref::Input::JoystickEnabled ); OP_JoystickTgl.setActive( true ); OP_ConfigureJoystickBtn.setActive( $pref::Input::JoystickEnabled ); } else { - OP_JoystickTgl.setVisible( false ); // PATCH + OP_JoystickTgl.setValue( false ); OP_JoystickTgl.setActive( false ); $pref::Input::JoystickEnabled = false; - OP_ConfigureJoystickBtn.setVisible( false ); // PATCH OP_ConfigureJoystickBtn.setActive( false ); } @@ -228,6 +245,9 @@ function OptionsDlg::deviceDependent( %this ) OP_AnisotropyLabel_Disabled.setVisible( true ); OP_AnisotropyLabel.setVisible( false ); } + + OP_EnvMapTgl.setValue($pref::environmentMaps); + OP_EnvMapTgl.setActive($pref::OpenGL::allowTexGen); } //------------------------------------------------------------------------------ @@ -238,7 +258,7 @@ function OptionsDlg::onSleep( %this ) CursorOff(); $enableDirectInput = "0"; - disableDirectInput(); + deactivateDirectInput(); OP_VideoDriverMenu.clear(); OP_ResMenu.clear(); @@ -246,6 +266,14 @@ function OptionsDlg::onSleep( %this ) OP_AudioProviderMenu.clear(); OP_AudioSpeakerMenu.clear(); + if ( %this.resetAudio ) + { + echo( "Resetting the audio driver..." ); + audioSetDriver( "none" ); + audioSetDriver( $pref::Audio::activeDriver ); + %this.resetAudio = ""; + } + if ( isObject( ServerConnection ) && isTextureFlushRequired() ) MessageBoxYesNo( "WARNING", "You have made changes that require Tribes 2 to flush the texture cache. " @ "Doing this while the game is running can take a long time. " @@ -261,13 +289,18 @@ function isTextureFlushRequired() if ( $pref::Interior::VertexLighting != OP_VertexLightTgl.getValue() ) return( true ); - if ( $pref::OpenGL::mipReduction != 5 - mFloor( OP_ShapeTexSlider.getValue() ) ) + // We're using the noDrawArraysAlpha variable here because we've already + // gone gold (hard to add a new profiling variable). But the Voodoo2/3/3500 + // cards that have the 256x256 texture limitation (in OpenGL) also have the + // noDrawArraysAlpha hack on...so that works out nice + %mipRange = $pref::OpenGL::noDrawArraysAlpha ? 4 : 5; + if ( $pref::OpenGL::mipReduction != 5 - mFloor( OP_ShapeTexSlider.getValue() * %mipRange ) ) return( true ); - if ( $pref::OpenGL::interiorMipReduction != 5 - mFloor( OP_BuildingTexSlider.getValue() ) ) + if ( $pref::OpenGL::interiorMipReduction != 5 - mFloor( OP_BuildingTexSlider.getValue() * %mipRange ) ) return( true ); - if ( $pref::OpenGL::skyMipReduction != 5 - mFloor( OP_SkyTexSlider.getValue() ) ) + if ( $pref::OpenGL::skyMipReduction != 5 - mFloor( OP_SkyTexSlider.getValue() * %mipRange ) ) return( true ); if ( $AnisotropySupported && $pref::OpenGL::anisotropy != OP_AnisotropySlider.getValue() ) @@ -382,28 +415,34 @@ function OptionsDlg::saveSettings( %this ) $pref::Terrain::texDetail = 6 - mFloor( OP_TerrainTexSlider.getValue() ); - %temp = 5 - mFloor( OP_ShapeTexSlider.getValue() ); + // We're using the noDrawArraysAlpha variable here because we've already + // gone gold (hard to add a new profiling variable). But the Voodoo2/3/3500 + // cards that have the 256x256 texture limitation (in OpenGL) also have the + // noDrawArraysAlpha hack on...so that works out nice + %mipRange = $pref::OpenGL::noDrawArraysAlpha ? 4 : 5; + + %temp = 5 - mFloor( OP_ShapeTexSlider.getValue() * %mipRange ); if ( $pref::OpenGL::mipReduction != %temp ) { - $pref::OpenGL::mipReduction = %temp; - setOpenGLMipReduction( $pref::OpenGL::mipReduction ); - %flushTextures = true; + $pref::OpenGL::mipReduction = %temp; + setOpenGLMipReduction( $pref::OpenGL::mipReduction ); + %flushTextures = true; } - %temp = 5 - mFloor( OP_BuildingTexSlider.getValue() ); + %temp = 5 - mFloor( OP_BuildingTexSlider.getValue() * %mipRange ); if ( $pref::OpenGL::interiorMipReduction != %temp ) { - $pref::OpenGL::interiorMipReduction = %temp; - setOpenGLInteriorMipReduction( $pref::OpenGL::interiorMipReduction ); - %flushTextures = true; + $pref::OpenGL::interiorMipReduction = %temp; + setOpenGLInteriorMipReduction( $pref::OpenGL::interiorMipReduction ); + %flushTextures = true; } - %temp = 5 - mFloor( OP_SkyTexSlider.getValue() ); + %temp = 5 - mFloor( OP_SkyTexSlider.getValue() * %mipRange ); if ( $pref::OpenGL::skyMipReduction != %temp ) { - $pref::OpenGL::skyMipReduction = %temp; - setOpenGLSkyMipReduction( $pref::OpenGL::skyMipReduction ); - %flushTextures = true; + $pref::OpenGL::skyMipReduction = %temp; + setOpenGLSkyMipReduction( $pref::OpenGL::skyMipReduction ); + %flushTextures = true; } if ( $TextureCompressionSupported && !$pref::OpenGL::disableARBTextureCompression ) @@ -463,6 +502,7 @@ function OptionsDlg::saveSettings( %this ) $pref::TS::detailAdjust = $min_TSDetailAdjust + OP_ShapeSlider.getValue() * ( $max_TSDetailAdjust - $min_TSDetailAdjust ); $pref::Shadows = OP_ShadowSlider.getValue(); setShadowDetailLevel( $pref::Shadows ); + $pref::Interior::detailAdjust = OP_InteriorDetailSlider.getValue(); $pref::VisibleDistanceMod = OP_VisibleDistanceSlider.getValue(); $pref::Audio::musicVolume = OP_MusicVolumeSlider.getValue(); @@ -479,6 +519,34 @@ function OptionsDlg::saveSettings( %this ) if ( !$missionRunning ) MusicPlayer.stop(); + if ( $pref::Audio::enableVoiceCapture ) + { + %reinit = false; + %selId = OP_VoiceListenMenu.getSelected(); + if ( $pref::Audio::decodingMask != %selId ) + { + $pref::Audio::decodingMask = %selId; + %reinit = true; + } + + %selId = OP_VoiceSendMenu.getSelected(); + if ( $pref::Audio::encodingLevel != %selId ) + { + $pref::Audio::encodingLevel = %selId; + %reinit = true; + } + + if ( %reinit ) + { + alxCaptureDestroy(); + alxCaptureInit(); + + // If in a game, let the server know about the altered settings: + if ( isObject( ServerConnection ) ) + commandToServer( 'SetVoiceInfo', $pref::Audio::voiceChannels, $pref::Audio::decodingMask, $pref::Audio::encodingLevel ); + } + } + $pref::Net::PacketRateToClient = mFloor( OP_PacketRateSlider.getValue() ); $pref::Net::PacketSize = mFloor( OP_PacketSizeSlider.getValue() ); $pref::Net::PacketRateToServer = mFloor( OP_UpdateRateSlider.getValue() ); @@ -739,7 +807,7 @@ function OP_ApplyBtn::updateState( %this ) //------------------------------------------------------------------------------ //------------------------------------------------------------------------------ -// Graphics: +// Graphics Settings: // function updateGammaCorrection() { @@ -778,7 +846,7 @@ function OP_PlayerRenderMenu::init( %this ) //------------------------------------------------------------------------------ //------------------------------------------------------------------------------ -// Textures: +// Texture Settings: // function OP_CompressMenu::init( %this ) { @@ -818,7 +886,7 @@ function OP_TexQualityMenu::onSelect( %this, %id, %text ) //------------------------------------------------------------------------------ //------------------------------------------------------------------------------ -// Audio: +// Audio Settings: // function setAudioProvider(%idx) { @@ -859,7 +927,6 @@ function OP_AudioResetProvider::onAction(%this) setAudioProvider($Audio::originalProvider); %this.setActive(false); } - //------------------------------------------------------------------------------ function OP_AudioSpeakerMenu::onSelect(%this, %id, %text) { @@ -867,6 +934,87 @@ function OP_AudioSpeakerMenu::onSelect(%this, %id, %text) $pref::Audio::speakerType = alxGetContextstr(ALC_SPEAKER_NAME, %id); } +//------------------------------------------------------------------------------ +function OP_AudioFrequencyMenu::init( %this ) +{ + %this.clear(); + %this.add( "11 KHz", 0 ); + %this.add( "22 KHz", 1 ); + %this.add( "44 KHz", 2 ); + + switch ( $pref::Audio::frequency ) + { + case 11025: %this.setSelected( 0 ); + case 22050: %this.setSelected( 1 ); + default: %this.setSelected( 2 ); + } +} + +//------------------------------------------------------------------------------ +function OP_AudioFrequencyMenu::onSelect( %this, %id, %text ) +{ + switch ( %id ) + { + case 0: %newVal = 11025; + case 1: %newVal = 22050; + default: %newVal = 44100; + } + + if ( $pref::Audio::frequency != %newVal ) + { + $pref::Audio::frequency = %newVal; + OptionsDlg.resetAudio = true; + } +} + +//------------------------------------------------------------------------------ +function OP_AudioBitRateMenu::init( %this ) +{ + %this.clear(); + %this.add( "8 bit", 0 ); + %this.add( "16 bit", 1 ); + + if ( $pref::Audio::sampleBits == 8 ) + %this.setSelected( 0 ); + else + %this.setSelected( 1 ); +} + +//------------------------------------------------------------------------------ +function OP_AudioBitRateMenu::onSelect( %this, %id, %text ) +{ + %newVal = %id == 0 ? 8 : 16; + if ( $pref::Audio::sampleBits != %newVal ) + { + $pref::Audio::sampleBits = %newVal; + OptionsDlg.resetAudio = true; + } +} + +//------------------------------------------------------------------------------ +function OP_AudioChannelsMenu::init( %this ) +{ + %this.clear(); + %this.add( "One", 0 ); + %this.add( "Two", 1 ); + + if ( $pref::Audio::channels == 1 ) + %this.setSelected( 0 ); + else + %this.setSelected( 1 ); +} + +//------------------------------------------------------------------------------ +function OP_AudioChannelsMenu::onSelect( %this, %id, %text ) +{ + %newVal = %id == 0 ? 1 : 2; + if ( $pref::Audio::channels != %newVal ) + { + $pref::Audio::channels = %newVal; + OptionsDlg.resetAudio = true; + } +} + //------------------------------------------------------------------------------ function OP_MusicTgl::onAction( %this ) { @@ -903,7 +1051,11 @@ function updateMasterVolume() alxListenerf( AL_GAIN_LINEAR, %volume ); } + //------------------------------------------------------------------------------ +//------------------------------------------------------------------------------ +// Voice Settings: +// function OP_MicrophoneEnabledTgl::onAction( %this ) { %on = %this.getValue(); @@ -915,6 +1067,20 @@ function OP_MicrophoneEnabledTgl::onAction( %this ) OP_InputBoostLabel_Disabled.setVisible( !%on ); OP_InputBoostSlider.setActive( %on ); OP_InputBoostPercentTxt.setVisible( %on ); + OP_VoiceListenLabel.setVisible( %on ); + OP_VoiceListenLabel_Disabled.setVisible( !%on ); + OP_VoiceListenMenu.setActive( %on ); + OP_VoiceSendLabel.setVisible( %on ); + OP_VoiceSendLabel_Disabled.setVisible( !%on ); + OP_VoiceSendMenu.setActive( %on ); + + if(%on != alxIsEnabled("capture")) + { + if(%on) + alxCaptureInit(); + else + alxCaptureDestroy(); + } } //------------------------------------------------------------------------------ @@ -957,6 +1123,40 @@ function localCaptureStop( %method ) } } +//------------------------------------------------------------------------------ +function OP_VoiceListenMenu::init( %this ) +{ + %this.clear(); + %this.add( "Low", 1 ); + %this.add( "Medium", 3 ); + %this.add( "High", 7 ); + + switch ( $pref::Audio::decodingMask ) + { + case 3 or 7: + %this.setSelected( $pref::Audio::decodingMask ); + default: + %this.setSelected( 1 ); + } +} + +//------------------------------------------------------------------------------ +function OP_VoiceSendMenu::init( %this ) +{ + %this.clear(); + %this.add( "Low", 0 ); + %this.add( "Medium", 1 ); + %this.add( "High", 2 ); + + switch ( $pref::Audio::encodingLevel ) + { + case 1 or 2: + %this.setSelected( $pref::Audio::encodingLevel ); + default: + %this.setSelected( 0 ); + } +} + //------------------------------------------------------------------------------ //------------------------------------------------------------------------------ // Driver Info dialog: @@ -1310,6 +1510,20 @@ $RemapName[$RemapCount] = "Chat Page Down"; $RemapCmd[$RemapCount] = "pageMessageHudDown"; $RemapCount++; +$ObsRemapCount = 0; +$ObsRemapName[$ObsRemapCount] = "Move Up"; +$ObsRemapCmd[$ObsRemapCount] = "moveup"; +$ObsRemapCount++; +$ObsRemapName[$ObsRemapCount] = "Move Down"; +$ObsRemapCmd[$ObsRemapCount] = "movedown"; +$ObsRemapCount++; +$ObsRemapName[$ObsRemapCount] = "Toggle Observer Mode"; +$ObsRemapCmd[$ObsRemapCount] = "jump"; +$ObsRemapCount++; +$ObsRemapName[$ObsRemapCount] = "Cycle Camera"; +$ObsRemapCmd[$ObsRemapCount] = "mouseJet"; +$ObsRemapCount++; + //------------------------------------------------------------------------------ function restoreDefaultMappings() { @@ -1388,6 +1602,8 @@ function saveMapFile( %filename ) } moveMap.save( %mapFile ); + // Append the observer action map: + observerMap.save( %mapFile, true ); // Write out the console toggle key: %fObject = new FileObject(); @@ -1423,32 +1639,39 @@ function getMapDisplayName( %device, %action ) } else if ( strstr( %device, "joystick" ) != -1 ) { - // TODO - add POV support here... - // Substitute "joy" for "button" in the action string: + // Substitute "joystick" for "button" in the action string: %pos = strstr( %action, "button" ); if ( %pos != -1 ) { %mods = getSubStr( %action, 0, %pos ); %object = getSubStr( %action, %pos, 1000 ); %instance = getSubStr( %object, strlen( "button" ), 1000 ); - return( %mods @ "joy" @ ( %instance + 1 ) ); + return( %mods @ "joystick" @ ( %instance + 1 ) ); } else { %pos = strstr( %action, "pov" ); if ( %pos != -1 ) { - %mods = getSubStr( %action, 0, %pos ); - %object = getSubStr( %action, %pos, 1000 ); - MessageBoxOK( "WARNING", "Sorry, Joystick POVs are not yet supported." ); - return( "" ); + %wordCount = getWordCount( %action ); + %mods = %wordCount > 1 ? getWords( %action, 0, %wordCount - 2 ) @ " " : ""; + %object = getWord( %action, %wordCount - 1 ); + switch$ ( %object ) + { + case "upov": %object = "POV1 up"; + case "dpov": %object = "POV1 down"; + case "lpov": %object = "POV1 left"; + case "rpov": %object = "POV1 right"; + case "upov2": %object = "POV2 up"; + case "dpov2": %object = "POV2 down"; + case "lpov2": %object = "POV2 left"; + case "rpov2": %object = "POV2 right"; + default: %object = "??"; + } + return( %mods @ %object ); } else - { error( "Unsupported Joystick input object passed to getDisplayMapName!" ); - MessageBoxOK( "ERROR", "That type of input object is not supported." ); - return( "" ); - } } } @@ -1458,7 +1681,20 @@ function getMapDisplayName( %device, %action ) //------------------------------------------------------------------------------ function buildFullMapString( %index ) { - %temp = moveMap.getBinding( $RemapCmd[%index] ); + switch$ ( OP_ControlsPane.group ) + { + case "Observer": + %actionMap = observerMap; + %name = $ObsRemapName[%index]; + %cmd = $ObsRemapCmd[%index]; + + default: + %actionMap = moveMap; + %name = $RemapName[%index]; + %cmd = $RemapCmd[%index]; + } + + %temp = %actionMap.getBinding( %cmd ); %device = getField( %temp, 0 ); %object = getField( %temp, 1 ); if ( %device !$= "" && %object !$= "" ) @@ -1466,15 +1702,39 @@ function buildFullMapString( %index ) else %mapString = ""; - return( $RemapName[%index] @ "\t" @ %mapString ); + return( %name TAB %mapString ); +} + +//------------------------------------------------------------------------------ +function OP_ControlGroupMenu::init( %this ) +{ + %selId = %this.getSelected(); + %this.clear(); + %this.add( "Main", 0 ); + %this.add( "Observer", 1 ); + %this.setSelected( %selId ); + %this.onSelect( %selId, %this.getTextById( %selId ) ); +} + +//------------------------------------------------------------------------------ +function OP_ControlGroupMenu::onSelect( %this, %id, %text ) +{ + OP_ControlsPane.group = %text; + OP_RemapList.fillList(); } //------------------------------------------------------------------------------ function OP_RemapList::fillList( %this ) { + switch$ ( OP_ControlsPane.group ) + { + case "Observer": %count = $ObsRemapCount; + default: %count = $RemapCount; + } + %this.clear(); - for ( %i = 0; %i < $RemapCount; %i++ ) - %this.addRow( %i, buildFullMapString( %i ) ); + for ( %i = 0; %i < %count; %i++ ) + %this.addRow( %i, buildFullMapString( %i ) ); // Set the console key: %bind = GlobalActionMap.getBinding( "toggleConsole" ); @@ -1484,7 +1744,16 @@ function OP_RemapList::fillList( %this ) //------------------------------------------------------------------------------ function OP_RemapList::onDeleteKey( %this, %rowId ) { - clearMapping( %rowId ); + switch$ ( OP_ControlsPane.group ) + { + case "Observer": + %actionMap = observerMap; + %cmd = $ObsRemapCmd[%rowId]; + default: + %actionMap = moveMap; + %cmd = $RemapCmd[%rowId]; + } + clearMapping( %actionMap, %cmd ); %this.setRowById( %rowId, buildFullMapString( %rowId ) ); } @@ -1492,7 +1761,13 @@ function OP_RemapList::onDeleteKey( %this, %rowId ) function OP_RemapList::doRemap( %this ) { %selId = %this.getSelectedId(); - RemapFrame.setTitle( "REMAP \"" @ $RemapName[%selId] @ "\"" ); + switch$ ( OP_ControlsPane.group ) + { + case "Observer": %name = $ObsRemapName[%selId]; + default: %name = $RemapName[%selId]; + } + + RemapFrame.setTitle( "REMAP \"" @ %name @ "\"" ); RemapInputCtrl.mode = "move"; RemapInputCtrl.index = %selId; Canvas.pushDialog( RemapDlg ); @@ -1526,31 +1801,42 @@ function RemapDlg::onSleep( %this ) //------------------------------------------------------------------------------ function findRemapCmdIndex( %command ) { - for ( %i = 0; %i < $RemapCount; %i++ ) - { - if ( %command $= $RemapCmd[%i] ) - return( %i ); - } + switch$ ( OP_ControlsPane.group ) + { + case "Observer": + for ( %i = 0; %i < $ObsRemapCount; %i++ ) + { + if ( %command $= $ObsRemapCmd[%i] ) + return( %i ); + } + default: + for ( %i = 0; %i < $RemapCount; %i++ ) + { + if ( %command $= $RemapCmd[%i] ) + return( %i ); + } + } return( -1 ); } //------------------------------------------------------------------------------ -function clearMapping( %index ) +function clearMapping( %actionMap, %cmd ) { - %fullMapString = moveMap.getBinding( $RemapCmd[%index] ); + %fullMapString = %actionMap.getBinding( %cmd ); %mapCount = getRecordCount( %fullMapString ); for ( %i = 0; %i < %mapCount; %i++ ) { %temp = getRecord( %fullMapString, %i ); - moveMap.unbind( getField( %temp, 0 ), getField( %temp, 1 ) ); + %actionMap.unbind( getField( %temp, 0 ), getField( %temp, 1 ) ); } } //------------------------------------------------------------------------------ -function redoMapping( %device, %action, %oldIndex, %newIndex ) +function redoMapping( %actionMap, %device, %action, %cmd, %oldIndex, %newIndex ) { - moveMap.bind( %device, %action, $RemapCmd[%newIndex] ); + //%actionMap.bind( %device, %action, $RemapCmd[%newIndex] ); + %actionMap.bind( %device, %action, %cmd ); OP_RemapList.setRowById( %oldIndex, buildFullMapString( %oldIndex ) ); OP_RemapList.setRowById( %newIndex, buildFullMapString( %newIndex ) ); } @@ -1570,7 +1856,7 @@ function RemapInputCtrl::onInputEvent( %this, %device, %action ) //error( "** onInputEvent called - device = " @ %device @ ", action = " @ %action @ " **" ); Canvas.popDialog( RemapDlg ); - // Tested for the reserved keystrokes: + // Test for the reserved keystrokes: if ( %device $= "keyboard" ) { // Cancel... @@ -1581,33 +1867,7 @@ function RemapInputCtrl::onInputEvent( %this, %device, %action ) } } - if ( %this.mode $= "move" ) - { - // First check to see if the given action is already mapped: - %prevMap = moveMap.getCommand( %device, %action ); - if ( %prevMap !$= $RemapCmd[%this.index] ) - { - if ( %prevMap $= "" ) - { - moveMap.bind( %device, %action, $RemapCmd[%this.index] ); - OP_RemapList.setRowById( %this.index, buildFullMapString( %this.index ) ); - } - else - { - %mapName = getMapDisplayName( %device, %action ); - %prevMapIndex = findRemapCmdIndex( %prevMap ); - if ( %prevMapIndex == -1 ) - MessageBoxOK( "REMAP FAILED", "\"" @ %mapName @ "\" is already bound to a non-remappable command!" ); - else - MessageBoxYesNo( "WARNING", - "\"" @ %mapName @ "\" is already bound to \"" - @ $RemapName[%prevMapIndex] @ "\"!\nDo you want to undo this mapping?", - "redoMapping(" @ %device @ ", \"" @ %action @ "\", " @ %prevMapIndex @ ", " @ %this.index @ ");", "" ); - return; - } - } - } - else if ( %this.mode $= "consoleKey" ) + if ( %this.mode $= "consoleKey" ) { if ( %device !$= "keyboard" ) { @@ -1643,33 +1903,67 @@ function RemapInputCtrl::onInputEvent( %this, %device, %action ) } } else - error( "The sky is falling, the sky is falling!" ); + { + switch$ ( OP_ControlsPane.group ) + { + case "Observer": + %actionMap = observerMap; + %cmd = $ObsRemapCmd[%this.index]; + %name = $ObsRemapName[%this.index]; + + default: + %actionMap = moveMap; + %cmd = $RemapCmd[%this.index]; + %name = $RemapName[%this.index]; + } + + // First check to see if the given action is already mapped: + %prevMap = %actionMap.getCommand( %device, %action ); + if ( %prevMap !$= %cmd ) + { + if ( %prevMap $= "" ) + { + %actionMap.bind( %device, %action, %cmd ); + OP_RemapList.setRowById( %this.index, buildFullMapString( %this.index ) ); + } + else + { + %mapName = getMapDisplayName( %device, %action ); + %prevMapIndex = findRemapCmdIndex( %prevMap ); + if ( %prevMapIndex == -1 ) + MessageBoxOK( "REMAP FAILED", "\"" @ %mapName @ "\" is already bound to a non-remappable command!" ); + else + { + switch$ ( OP_ControlsPane.group ) + { + case "Observer": + %prevCmdName = $ObsRemapName[%prevMapIndex]; + default: + %prevCmdName = $RemapName[%prevMapIndex]; + } + + MessageBoxYesNo( "WARNING", + "\"" @ %mapName @ "\" is already bound to \"" + @ %prevCmdName @ "\"!\nDo you want to undo this mapping?", + "redoMapping(" @ %actionMap @ ", " @ %device @ ", \"" @ %action @ "\", \"" @ %cmd @ "\", " @ %prevMapIndex @ ", " @ %this.index @ ");", "" ); + } + return; + } + } + } } //------------------------------------------------------------------------------ function OP_JoystickTgl::onAction( %this ) { - OP_ConfigureJoystickBtn.setActive( %this.getValue() ); -} + %on = %this.getValue(); + if ( %on ) + enableJoystick(); + else + disableJoystick(); -//------------------------------------------------------------------------------ -//------------------------------------------------------------------------------ -$RemapAxisCount = 0; -$RemapAxisName[$RemapAxisCount] = "Look Up/Down"; -$RemapAxisCmd[$RemapAxisCount] = "pitch"; -$RemapAxisCount++; -$RemapAxisName[$RemapAxisCount] = "Turn Left/Right"; -$RemapAxisCmd[$RemapAxisCount] = "yaw"; -$RemapAxisCount++; -$RemapAxisName[$RemapAxisCount] = "Cycle Weapon"; -$RemapAxisCmd[$RemapAxisCount] = "cycleWeaponAxis"; -$RemapAxisCount++; -$RemapAxisName[$RemapAxisCount] = "Move Forward/Backward"; -$RemapAxisCmd[$RemapAxisCount] = "joystickMoveY"; -$RemapAxisCount++; -$RemapAxisName[$RemapAxisCount] = "Move Left/Right"; -$RemapAxisCmd[$RemapAxisCount] = "joystickMoveX"; -$RemapAxisCount++; + OP_ConfigureJoystickBtn.setActive( %on ); +} //------------------------------------------------------------------------------ function MouseConfigDlg::onWake( %this ) @@ -1682,6 +1976,7 @@ function MouseConfigDlg::onWake( %this ) MouseZActionMenu.add( "Nothing", 1 ); MouseZActionMenu.add( "Cycle Weapon", 2 ); MouseZActionMenu.add( "Next Weapon Only", 3 ); +// MouseZActionMenu.add( "Cycle Zoom Level", 4 ); %bind = moveMap.getCommand( "mouse", "zaxis" ); %selId = 1; @@ -1742,46 +2037,73 @@ function MouseYSlider::sync( %this ) } //------------------------------------------------------------------------------ +// Joystick Config dialog: +//------------------------------------------------------------------------------ +$JoyRemapCount = 0; +$JoyRemapName[$JoyRemapCount] = "Look Up/Down"; +$JoyRemapCmd[$JoyRemapCount] = "joyPitch"; +$JoyRemapCount++; +$JoyRemapName[$JoyRemapCount] = "Turn Left/Right"; +$JoyRemapCmd[$JoyRemapCount] = "joyYaw"; +$JoyRemapCount++; +$JoyRemapName[$JoyRemapCount] = "Move Forward/Backward"; +$JoyRemapCmd[$JoyRemapCount] = "joystickMoveY"; +$JoyRemapCount++; +$JoyRemapName[$JoyRemapCount] = "Strafe Left/Right"; +$JoyRemapCmd[$JoyRemapCount] = "joystickMoveX"; +$JoyRemapCount++; +$JoyRemapName[$JoyRemapCount] = "Cycle Weapon"; +$JoyRemapCmd[$JoyRemapCount] = "cycleWeaponAxis"; +$JoyRemapCount++; + //------------------------------------------------------------------------------ function JoystickConfigDlg::onWake( %this ) { // Add all of the axis tabs: %temp = getJoystickAxes( 0 ); - $joyAxisCount = getField( %temp , 0 ); + %tryCount = getField( %temp, 0 ); + $JoyAxisCount = 0; - for ( %i = 0; %i < $joyAxisCount; %i++ ) + for ( %i = 0; %i < %tryCount; %i++ ) { %type = getField( %temp, %i + 1 ); - $JoyAxisTab[%i] = new ShellTabButton() { - profile = "ShellTabProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "29" SPC ( 52 + ( %i * 30 ) ); - extent = "100 38"; - minExtent = "48 38"; - visible = "1"; - command = "JoystickConfigDlg.setPane(" @ %i @ ");"; - helpTag = "0"; - text = %type SPC "Axis"; - }; - switch$ ( %type ) { - case "X": $JoyAxisTab[%i].type = "xaxis"; - case "Y": $JoyAxisTab[%i].type = "yaxis"; - case "Z": $JoyAxisTab[%i].type = "zaxis"; - case "R": $JoyAxisTab[%i].type = "rxaxis"; - case "U": $JoyAxisTab[%i].type = "ryaxis"; - case "V": $JoyAxisTab[%i].type = "rzaxis"; + case "X": %tabName = "X Axis"; %tabType = "xaxis"; + case "Y": %tabName = "Y Axis"; %tabType = "yaxis"; + case "Z": %tabName = "Z Axis"; %tabType = "zaxis"; + case "R": %tabName = "R Axis"; %tabType = "rxaxis"; + case "U": %tabName = "U Axis"; %tabType = "ryaxis"; + case "V": %tabName = "V Axis"; %tabType = "rzaxis"; + case "S": %tabName = "Slider"; %tabType = "slider"; + default: %tabName = ""; } - JoystickConfigFrame.add( $JoyAxisTab[%i] ); + if ( %tabName !$= "" ) + { + $JoyAxisTab[$JoyAxisCount] = new ShellTabButton() { + profile = "ShellTabProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "29" SPC ( 52 + ( %i * 30 ) ); + extent = "100 38"; + minExtent = "48 38"; + visible = "1"; + command = "JoystickConfigDlg.setPane(" @ %i @ ");"; + helpTag = "0"; + text = %tabName; + type = %tabType; + }; + + $JoyAxisCount++; + JoystickConfigFrame.add( $JoyAxisTab[%i] ); + } } // Fill the action menu: JoyAxisActionMenu.clear(); - for ( %i = 0; %i < $RemapAxisCount; %i++ ) - JoyAxisActionMenu.add( $RemapAxisName[%i], %i ); + for ( %i = 0; %i < $JoyRemapCount; %i++ ) + JoyAxisActionMenu.add( $JoyRemapName[%i], %i ); JoyAxisActionMenu.add( "Nothing", 255 ); // Select the first axis: @@ -1793,7 +2115,7 @@ function JoystickConfigDlg::onSleep( %this ) { // Save the current pane's settings: bindJoystickAxis( %this.pane, JoyAxisActionMenu.getSelected() ); - for ( %i = 0; %i < $joyAxisCount; %i++ ) + for ( %i = 0; %i < $JoyAxisCount; %i++ ) { JoystickConfigFrame.remove( $JoyAxisTab[%i] ); $JoyAxisTab[%i].delete(); @@ -1818,18 +2140,18 @@ function JoystickConfigDlg::setPane( %this, %pane ) %bind = moveMap.getCommand( "joystick", %axisType ); if ( %bind !$= "" ) { - for ( %i = 0; %i < $RemapAxisCount; %i++ ) + for ( %i = 0; %i < $JoyRemapCount; %i++ ) { - if ( $RemapAxisCmd[%i] $= %bind ) + if ( $JoyRemapCmd[%i] $= %bind ) { JoyAxisActionMenu.setSelected( %i ); - JoyAxisActionMenu.setText( $RemapAxisName[%i] ); + JoyAxisActionMenu.setText( $JoyRemapName[%i] ); JoyAxisActionMenu.onSelect( %i, "" ); break; } } - if ( %i == $RemapAxisCount ) + if ( %i == $JoyRemapCount ) { JoyAxisActionMenu.setSelected( 255 ); // 255 is the code for "Nothing" JoyAxisActionMenu.onSelect( 255, "" ); @@ -1857,28 +2179,22 @@ function JoystickConfigDlg::setPane( %this, %pane ) //------------------------------------------------------------------------------ function JoyAxisActionMenu::onSelect( %this, %id, %text ) { - if ( %id >= $RemapAxisCount ) - { - JoyAxisSlider.setActive( false ); - DeadZoneSlider.setActive( false ); - InvertJoyAxisTgl.setActive( false ); - } - else - { - JoyAxisSlider.setActive( true ); - DeadZoneSlider.setActive( true ); - InvertJoyAxisTgl.setActive( true ); - } + %on = ( %id < $JoyRemapCount ); + JoyAxisSlider.setActive( %on ); + JoySensText.setVisible( %on ); + DeadZoneSlider.setActive( %on ); + DeadZoneText.setVisible( %on ); + InvertJoyAxisTgl.setActive( %on ); } //------------------------------------------------------------------------------ -function JoySensText::update() +function JoySensText::update( %this ) { %this.setValue( "(" @ getSubStr( JoyAxisSlider.getValue(), 0, 4 ) @ ")" ); } //------------------------------------------------------------------------------ -function DeadZoneText::update() +function DeadZoneText::update( %this ) { %val = DeadZoneSlider.getValue(); %percent = %val * 100; @@ -1893,7 +2209,7 @@ function DeadZoneText::update() function bindJoystickAxis( %axisIndex, %cmdIndex ) { %axis = $JoyAxisTab[%axisIndex].type; - if ( %cmdIndex > $RemapAxisCount ) + if ( %cmdIndex > $JoyRemapCount ) { // Make sure the axis is unbound: moveMap.unbind( "joystick", %axis ); @@ -1906,16 +2222,16 @@ function bindJoystickAxis( %axisIndex, %cmdIndex ) { %deadZone = "-" @ %delta SPC %delta; if ( InvertJoyAxisTgl.getValue() ) - moveMap.bind( "joystick", %axis, "SDI", %deadZone, %sens, $RemapAxisCmd[%cmdIndex] ); + moveMap.bind( "joystick", %axis, "SDI", %deadZone, %sens, $JoyRemapCmd[%cmdIndex] ); else - moveMap.bind( "joystick", %axis, "SD", %deadZone, %sens, $RemapAxisCmd[%cmdIndex] ); + moveMap.bind( "joystick", %axis, "SD", %deadZone, %sens, $JoyRemapCmd[%cmdIndex] ); } else { if ( InvertJoyAxisTgl.getValue() ) - moveMap.bind( "joystick", %axis, "SI", %sens, $RemapAxisCmd[%cmdIndex] ); + moveMap.bind( "joystick", %axis, "SI", %sens, $JoyRemapCmd[%cmdIndex] ); else - moveMap.bind( "joystick", %axis, "S", %sens, $RemapAxisCmd[%cmdIndex] ); + moveMap.bind( "joystick", %axis, "S", %sens, $JoyRemapCmd[%cmdIndex] ); } } @@ -1923,6 +2239,31 @@ function bindJoystickAxis( %axisIndex, %cmdIndex ) //------------------------------------------------------------------------------ // Network Settings: // +function OP_NetworkPane::applyPresets( %this, %which ) +{ + switch$ ( %which ) + { + case "modem1": + OP_PacketRateSlider.setValue( 10 ); + OP_UpdateRateSlider.setValue( 32 ); + OP_PacketSizeSlider.setValue( 200 ); + + case "modem2": + OP_PacketRateSlider.setValue( 12 ); + OP_UpdateRateSlider.setValue( 32 ); + OP_PacketSizeSlider.setValue( 240 ); + + case "lan": + OP_PacketRateSlider.setValue( 20 ); + OP_UpdateRateSlider.setValue( 32 ); + OP_PacketSizeSlider.setValue( 350 ); + + default: + error( "Invalid parameter passed to OP_NetworkPane::applyPresets!" ); + } +} + +//------------------------------------------------------------------------------ function OP_MasterServerMenu::init( %this ) { %this.clear(); @@ -1965,6 +2306,9 @@ function OP_RegionMenu::onSelect( %this, %id, %text ) } //------------------------------------------------------------------------------ +//------------------------------------------------------------------------------ +// Game Settings: +// function OP_LaunchScreenMenu::init( %this ) { %this.clear(); @@ -1979,9 +2323,6 @@ function OP_LaunchScreenMenu::init( %this ) //------------------------------------------------------------------------------ function toggleImmersion() { - if( isImmersionEnabled() ) - enableImmersion( $Pref::useImmersion = false ); - else - enableImmersion( $Pref::useImmersion = true ); + MessageBoxOK( "Force Feedback", "This will take effect next time you start Tribes 2." ); } diff --git a/base/scripts/RabbitGame.cs b/base/scripts/RabbitGame.cs index 8170ba7..255d0db 100644 --- a/base/scripts/RabbitGame.cs +++ b/base/scripts/RabbitGame.cs @@ -386,8 +386,13 @@ function RabbitGame::MissionAreaDamage(%game, %player) { if(%player.getState() !$= "Dead") { %player.setDamageFlash(0.1); + %damageRate = 0.05; + %pack = %player.getMountedImage($BackpackSlot); + if(%pack.getName() $= "RepairPackImage") + if(%player.getMountedImage($WeaponSlot).getName() $= "RepairGunImage") + %damageRate = 0.15; %prevHurt = %player.getDamageLevel(); - %player.setDamageLevel(%prevHurt + 0.05); + %player.setDamageLevel(%prevHurt + %damageRate); // a little redundancy to see if the lastest damage killed the player if(%player.getState() $= "Dead") %game.onClientKilled(%player.client, 0, $DamageType::OutOfBounds); @@ -555,6 +560,36 @@ function RabbitGame::updateScoreHud(%game, %client, %tag) } } + // Tack on the list of observers: + %observerCount = 0; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.team == 0) + %observerCount++; + } + + if (%observerCount > 0) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient(%client, 'SetLineHud', "", %tag, %index, '\tOBSERVERS (%1)TIME', %observerCount); + %index++; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + //if this is an observer + if (%cl.team == 0) + { + %obsTime = getSimTime() - %cl.observerStartTime; + %obsTimeStr = %game.formatTime(%obsTime, false); + messageClient( %client, 'SetLineHud', "", %tag, %index, '\t%1%2', + %cl.name, %obsTimeStr ); + %index++; + } + } + } + //clear the rest of Hud so we don't get old lines hanging around... messageClient( %client, 'ClearHud', "", %tag, %index ); } diff --git a/base/scripts/SiegeGame.cs b/base/scripts/SiegeGame.cs index 4e2cd77..9ff12e2 100644 --- a/base/scripts/SiegeGame.cs +++ b/base/scripts/SiegeGame.cs @@ -775,42 +775,6 @@ function SiegeGame::sendDebriefing( %game, %client ) } } -function SiegeGame::formatTime(%game, %tStr, %includeHundredths) -{ - %timeInSeconds = %tStr / 1000; - %mins = mFloor(%timeInSeconds / 60); - if(%mins < 1) - %timeString = "00:"; - else if(%mins < 10) - %timeString = "0" @ %mins @ ":"; - else - %timeString = %mins @ ":"; - - %timeInSeconds -= (%mins * 60); - %secs = mFloor(%timeInSeconds); - if(%secs < 1) - %timeString = %timeString @ "00"; - else if(%secs < 10) - %timeString = %timeString @ "0" @ %secs; - else - %timeString = %timeString @ %secs; - - if (%includeHundredths) - { - %timeString = %timeString @ "."; - %timeInSeconds -= %secs; - %hSecs = mFloor(%timeInSeconds * 100); // will be between 0 and 999 - if(%hSecs < 1) - %timeString = %timeString @ "00"; - else if(%hSecs < 10) - %timeString = %timeString @ "0" @ %hSecs; - else - %timeString = %timeString @ %hSecs; - } - - return %timeString; -} - function SiegeGame::clientMissionDropReady(%game, %client) { messageClient(%client, 'MsgClientReady', "", %game.class); @@ -1042,6 +1006,36 @@ function SiegeGame::updateScoreHud(%game, %client, %tag) %index++; } + // Tack on the list of observers: + %observerCount = 0; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.team == 0) + %observerCount++; + } + + if (%observerCount > 0) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient(%client, 'SetLineHud', "", %tag, %index, '\tOBSERVERS (%1)TIME', %observerCount); + %index++; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + //if this is an observer + if (%cl.team == 0) + { + %obsTime = getSimTime() - %cl.observerStartTime; + %obsTimeStr = %game.formatTime(%obsTime, false); + messageClient( %client, 'SetLineHud', "", %tag, %index, '\t%1%2', + %cl.name, %obsTimeStr ); + %index++; + } + } + } + //clear the rest of Hud so we don't get old lines hanging around... messageClient( %client, 'ClearHud', "", %tag, %index ); } diff --git a/base/scripts/SinglePlayerGame.cs b/base/scripts/SinglePlayerGame.cs index 9604a00..ce6072a 100644 --- a/base/scripts/SinglePlayerGame.cs +++ b/base/scripts/SinglePlayerGame.cs @@ -337,8 +337,8 @@ function SinglePlayerGame::onClientKilled(%game, %clVictim, %clKiller, %damageTy if(%num == 1) %textNum = "one life"; else %textNum = %num SPC "lives"; - messageBoxOk("Restart", "You have" SPC %textNum SPC "remaining.", "canvas.cursorOff(); spawnSinglePlayer();"); - canvas.cursorOn(); + messageBoxOk("Restart", "You have" SPC %textNum SPC "remaining.", "CursorOff(); spawnSinglePlayer();"); + //canvas.cursorOn(); } else schedule(3000, $player.player, singlePlayerDead); } @@ -371,6 +371,11 @@ function singlePlayerGame::AIHasJoined() // lets get rid of this mundane console spam } +function SinglePlayerGame::updateKillScores() +{ + // Do nothing other than get rid of the console warning... +} + function singlePlayerGame::biodermAssume(%game, %client) { //error(%client SPC "might talk."); @@ -413,7 +418,7 @@ function trainingBiodermSpeaks(%client) function singlePlayerDead() { missionFailed($player.miscMsg[trainingDeathLoss]); - canvas.cursorOn(); + CursorOn(); AIMissionEnd(); $objectiveQ[$enemyTeam].clear(); cancel($player.distanceCheckSchedule); @@ -468,6 +473,11 @@ function SinglePlayerGame::clientMissionDropReady(%game, %client) AISystemEnabled(true); $player.setControlObject( $player.player ); + $player.camera = new Camera() + { + dataBlock = Observer; + }; + startCurrentMission(%game); } @@ -555,7 +565,7 @@ function singlePlayerGame::gameOver(%game) deactivatepackage(Training6); deactivatePackage(singlePlayerMissionAreaEnforce); - if($player.currentWaypoint) + if(isObject( $player.currentWaypoint )) $player.currentWaypoint.delete(); if($player.OOB) @@ -821,7 +831,7 @@ function missionComplete(%text) $player.endMission = schedule(15000, game, forceFinish); messageBoxOk("Victory", %text, "forceFinish();"); - canvas.cursorOn(); + //canvas.cursorOn(); //AI stop clearQueue(); @@ -840,9 +850,6 @@ function forceFinish() //immediately disconnect - bringing us back to the main menu... Disconnect(); - - //we need to get the singlePlayer dialog after leaving - canvas.schedule(1000, "pushDialog", singlePlayerDlg); } function missionFailed(%text) @@ -862,6 +869,7 @@ function reloadMission() { cancel($player.endMission); Game.gameOver(); + CursorOn(); loadMission($currentMission, singlePlayer); debriefContinue(); } @@ -890,7 +898,7 @@ function firstPersonQuickPan() toggleFirstPerson($player); schedule(4000, $player.player, toggleFirstPerson, $player); } - + } @@ -967,8 +975,8 @@ function singleplayerGame::pickTeamSpawn(%game, %client, %respawn) function SinglePlayerGame::createCustomKeymap(%game) { - new ActionMap(TrainingMap); - TrainingMap.bindCmd( keyboard, "escape", escapeFromGame ); +// new ActionMap(TrainingMap); +// TrainingMap.bindCmd( keyboard, "escape", "escapeFromGame();", "" ); } //======================================================================================= @@ -983,9 +991,9 @@ function SinglePlayerEscapeDlg::onWake( %this ) $timeScale = 0; if( OptionsDlg.isAwake()) - { + { Canvas.popDialog( OptionsDlg ); - } + } } function SinglePlayerEscapeDlg::onSleep( %this ) @@ -1000,14 +1008,14 @@ function SinglePlayerEscapeDlg::leaveGame( %this ) Canvas.popDialog( SinglePlayerEscapeDlg ); if ( !%this.wasCursorOn ) CursorOff(); - MessageBoxYesNo( "LEAVE GAME", $player.miscMsg[LeaveGame], "forceFinish();", "$timeScale = 1;" ); + MessageBoxYesNo( "LEAVE GAME", $player.miscMsg[LeaveGame], "forceFinish();", "CursorOff(); $timeScale = 1;" ); } function SinglePlayerEscapeDlg::gotoSettings( %this ) { Canvas.popDialog( SinglePlayerEscapeDlg ); - if ( !%this.wasCursorOn ) - CursorOff(); + //if ( !%this.wasCursorOn ) + // CursorOff(); Canvas.pushDialog( OptionsDlg ); } @@ -1018,10 +1026,8 @@ function SinglePlayerEscapeDlg::returnToGame( %this ) Canvas.popDialog( SinglePlayerEscapeDlg ); CursorOff(); - - //moveMap.bindCmd( keyboard, "escape", "", "escapeFromGame();" ); movemap.push(); - trainingmap.push(); + //trainingmap.push(); } diff --git a/base/scripts/TeamHuntersGame.cs b/base/scripts/TeamHuntersGame.cs index 3a060ac..b20cdd4 100644 --- a/base/scripts/TeamHuntersGame.cs +++ b/base/scripts/TeamHuntersGame.cs @@ -126,6 +126,12 @@ function TeamHuntersGame::initGameVars(%game) %game.flagMsgDelayMS = 3000; %game.oobThrowFlagsDelayMS = 3000; + + // targets for each of the flag types (except for base which is properly skinned already) + HuntersFlag1.target = -1; // red + HuntersFlag2.target = allocTarget("", 'Blue', "", "", 0, "", ""); + HuntersFlag4.target = allocTarget("", 'Yellow', "", "", 0, "", ""); + HuntersFlag8.target = allocTarget("", 'Green', "", "", 0, "", ""); } function TeamHuntersGame::allowsProtectedStatics(%game) @@ -485,6 +491,7 @@ function TeamHuntersGame::CampingDamage(%game, %client, %firstWarning) function TeamHuntersGame::updateScoreHud(%game, %client, %tag) { + messageClient( %client, 'ClearHud', "", %tag, 0 ); // Send header: messageClient( %client, 'SetScoreHudHeader', "", '\t%1%2\t%3%4', $teamName[1], $teamScore[1], $teamName[2], $teamScore[2] ); @@ -574,13 +581,57 @@ function TeamHuntersGame::updateScoreHud(%game, %client, %tag) //else for observers, create an anchor around the player name so they can be observed else { - messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3\t%8%4%5%6', - %team1Client.name, %team1ClientScore, %team1ClientFlags, %team2Client.name, %team2ClientScore, %team2ClientFlags, %col1Style, %col2Style, %team1Client, %team2Client ); + //this is lame, but we can only have up to %9 args + if (%team2Client == %team2ClientMostFlags) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3\t%4%5%6', + %team1Client.name, %team1ClientScore, %team1ClientFlags, %team2Client.name, %team2ClientScore, %team2ClientFlags, %col1Style, %team1Client, %team2Client ); + } + else if (%team2Client == %client) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3\t%4%5%6', + %team1Client.name, %team1ClientScore, %team1ClientFlags, %team2Client.name, %team2ClientScore, %team2ClientFlags, %col1Style, %team1Client, %team2Client ); + } + else + { + messageClient( %client, 'SetLineHud', "", %tag, %index, '%7\t%1%2%3\t%4%5%6', + %team1Client.name, %team1ClientScore, %team1ClientFlags, %team2Client.name, %team2ClientScore, %team2ClientFlags, %col1Style, %team1Client, %team2Client ); + } } %index++; } + // Tack on the list of observers: + %observerCount = 0; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.team == 0) + %observerCount++; + } + + if (%observerCount > 0) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient(%client, 'SetLineHud', "", %tag, %index, '\tOBSERVERS (%1)TIME', %observerCount); + %index++; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + //if this is an observer + if (%cl.team == 0) + { + %obsTime = getSimTime() - %cl.observerStartTime; + %obsTimeStr = %game.formatTime(%obsTime, false); + messageClient( %client, 'SetLineHud', "", %tag, %index, '\t%1%2', + %cl.name, %obsTimeStr ); + %index++; + } + } + } + //clear the rest of Hud so we don't get old lines hanging around... messageClient( %client, 'ClearHud', "", %tag, %index ); } diff --git a/base/scripts/Training1.cs b/base/scripts/Training1.cs index d2650c0..5e7da21 100644 --- a/base/scripts/Training1.cs +++ b/base/scripts/Training1.cs @@ -121,10 +121,6 @@ function startCurrentMission() $teammate1.player.invincible = true; resetWildcat(); - $player.camera = new Camera() - { - dataBlock = Observer; - }; } //------------------------------------------------------------------------------ @@ -1002,7 +998,7 @@ function trainingIntroFlightEnd() function ClientCmdSetHudMode(%mode, %type, %node) { parent::ClientCmdSetHudMode(%mode, %type, %node); - TrainingMap.push(); + //TrainingMap.push(); getTrainingPacifistMap(); if(game.trainingIntro) trainingPacifistMap.push(); @@ -1315,6 +1311,13 @@ function serverCmdBuildClientTask(%client, %task, %team) // player shouldnt be able to use the voice commands to do anything } +function SinglePlayerEscapeDlg::returnToGame( %this ) +{ + parent::returnToGame( %this ); + if(game.trainingIntro) + trainingPacifistMap.push(); +} + //END TRAINING1 PACKAGE======================================================================= }; diff --git a/base/scripts/Training2.cs b/base/scripts/Training2.cs index acf9b1d..82489d6 100644 --- a/base/scripts/Training2.cs +++ b/base/scripts/Training2.cs @@ -125,8 +125,7 @@ function ClientCmdSetHudMode(%mode, %type, %node) parent::ClientCmdSetHudMode(%mode, %type, %node); movemap.push(); // hopefully this works - TrainingMap.push(); - + //TrainingMap.push(); } function AIEngageTask::assume(%task, %client) diff --git a/base/scripts/Training3.cs b/base/scripts/Training3.cs index 77d6980..c55289d 100644 --- a/base/scripts/Training3.cs +++ b/base/scripts/Training3.cs @@ -123,7 +123,7 @@ function FlipFlop::objectiveInit(%data, %flipflop) function ClientCmdSetHudMode(%mode, %type, %node) { parent::ClientCmdSetHudMode(%mode, %type, %node); - TrainingMap.push(); + //TrainingMap.push(); } @@ -299,8 +299,10 @@ function FlipFlop::playerTouch(%data, %flipFlop, %player ) function scoutFlyer::onRemove(%this, %obj) { - //error("scoutFlyer::onRemove("@ %obj@") called"); - if(%obj == $Shrike) { + error("scoutFlyer::onRemove("@ %obj@") called"); + if ( ! isObject( ServerConnection ) ) + return; + if(%obj == $Shrike ) { // we dont want the player to die hitting the ground cancel(game.pilotingTips); $player.player.invincible = true; diff --git a/base/scripts/Training4.cs b/base/scripts/Training4.cs index a73617a..154fbbe 100644 --- a/base/scripts/Training4.cs +++ b/base/scripts/Training4.cs @@ -65,7 +65,7 @@ function MP3Audio::play(%this) function ClientCmdSetHudMode(%mode, %type, %node) { parent::ClientCmdSetHudMode(%mode, %type, %node); - TrainingMap.push(); + //TrainingMap.push(); } // get the ball rolling diff --git a/base/scripts/Training5.cs b/base/scripts/Training5.cs index 086d502..c1daf97 100644 --- a/base/scripts/Training5.cs +++ b/base/scripts/Training5.cs @@ -68,7 +68,7 @@ function toggleScoreScreen(%val) function ClientCmdSetHudMode(%mode, %type, %node) { parent::ClientCmdSetHudMode(%mode, %type, %node); - TrainingMap.push(); + //TrainingMap.push(); } // get the ball rolling @@ -187,43 +187,72 @@ function objectiveDistanceChecks() schedule(5000, game, objectiveDistanceChecks); } -// cant blow up the gens except with the satchel charge +//====================================================================================== +// Objective Generators +//====================================================================================== function GeneratorLarge::damageObject(%data, %targetObject, %sourceObject, %position, %amount, %damageType) { - //error("Generator::damageObject called. DamageType = "@%damageType); - if( %targetObject == game.targetObject1 || %targetObject == game.targetObject2 && !game.detonationSequenceStarted){ - if(%damageType && %damageType != $DamageType::SatchelCharge && %damageType != $DamageType::Explosion) { - if(!game.tooSoonMsg) { - game.tooSoonMsg = true; - schedule(15000, game, eval, "game.tooSoonMsg = false;"); - messageClient($player, 0, $player.miscMsg[genAttackNoSatchel]); - // and a little bonus for easy players - if($pref::trainingDifficulty == 1 && - $player.player.getMountedImage($backPackSlot).getName() !$= "SatchelChargeImage" && !game.satchelWaypointSet) { + if(%targetObject == game.targetObject1 || %targetObject == game.targetObject2) + %message = training5ObjectiveGenDamaged(%targetObject, %damageType); + else + Parent::damageObject(%data, %targetObject, %sourceObject, %position, %amount, %damageType); - %waypoint = new WayPoint() { - position = nameToId(SatchelChargePack).position; - rotation = "1 0 0 0"; - scale = "1 1 1"; - dataBlock = "WayPointMarker"; - lockCount = "0"; - homingCount = "0"; - name = "Satchel Charge"; - team = 1; - locked = "true"; - }; - $player.satchelWaypoint = %waypoint; - game.satchelWaypointSet = true; - } - } - error("undestroyed gen failed damage type = "@ %damageType); - return; - } - else %targetObject.applyDamage(%targetObject.getDataBlock().maxDamage); - } - Parent::damageObject(%data, %targetObject, %sourceObject, %position, %amount, %damageType); + if(%message) + training5messageDamageFailed(); } +function training5ObjectiveGenDamaged(%targetObject, %damageType) +{ +//error("training5ObjectiveGenDamaged("@%targetObject@", "@%damageType@")"); + + if(game.genDestroyed[%targetObject]) + return false; + + if(%damageType != $DamageType::SatchelCharge) + { + return true; + } + + game.objectiveDestroyed = true; + %targetObject.applyDamage(%targetObject.getDataBlock().maxDamage); + return false; +} + +function training5messageDamageFailed() +{ + if(!game.tooSoonMsg && !game.objectiveDestroyed) { + game.tooSoonMsg = true; + schedule(15000, game, eval, "game.tooSoonMsg = false;"); + messageClient($player, 0, $player.miscMsg[genAttackNoSatchel]); + + training5easySatchelWaypoint(); + } +} + +function training5easySatchelWaypoint() +{ + if($pref::trainingDifficulty == 1 && + $player.player.getMountedImage($backPackSlot).getName() !$= "SatchelChargeImage" && !game.satchelWaypointSet) { + + %waypoint = new WayPoint() { + position = nameToId(SatchelChargePack).position; + rotation = "1 0 0 0"; + scale = "1 1 1"; + dataBlock = "WayPointMarker"; + lockCount = "0"; + homingCount = "0"; + name = "Satchel Charge"; + team = 1; + locked = "true"; + }; + $player.satchelWaypoint = %waypoint; + game.satchelWaypointSet = true; + } +} + +//====================================================================================== + + function AIEngageTask::assume(%task, %client) { Parent::assume(%task, %client); @@ -272,6 +301,14 @@ function singlePlayerGame::onAIKilled(%game, %clVictim, %clAttacker, %damageType } +function singleplayerGame::pickTeamSpawn(%game, %client, %respawn) +{ + if(%client.useSpawnSphere) + DefaultGame::pickTeamSpawn(%game, %client.team); + else + parent::pickTeamSpawn(%game, %client, %respawn); +} + function SinglePlayerGame::equip(%game, %player, %set) { if(!isObject(%player)) diff --git a/base/scripts/TrainingGui.cs b/base/scripts/TrainingGui.cs index c00c396..5b1ada6 100644 --- a/base/scripts/TrainingGui.cs +++ b/base/scripts/TrainingGui.cs @@ -77,6 +77,8 @@ function TrainingGui::onWake( %this ) function TrainingGui::onSleep( %this ) { %this.stopBriefing(); + + Canvas.popDialog(LaunchToolbarDlg); } //------------------------------------------------------------------------------ diff --git a/base/scripts/ai.cs b/base/scripts/ai.cs index c74ab88..22b542f 100644 --- a/base/scripts/ai.cs +++ b/base/scripts/ai.cs @@ -264,25 +264,24 @@ function AIMissionEnd() %client = ClientGroup.getObject(%i); if (%client.isAIControlled()) { - //cancel the respawn thread - if (%client.respawnThread > 0) - { - cancel(%client.respawnThread); - %client.respawnThread = ""; - } + //cancel the respawn thread and the objective thread... + cancel(%client.respawnThread); + cancel(%client.objectiveThread); - //cancel the objective reassessment thread - if (%client.objectiveThread > 0) - { - cancel(%client.objectiveThread); - %client.objectiveThread = ""; - } - - AIUnassignClient(%client); + //reset the clients tasks, variables, etc... + AIUnassignClient(%client); + %client.stop(); %client.clearTasks(); - %client.clearStep(); - %client.defaultTasksAdded = false; - %client.missionCycleCleanup(); + %client.clearStep(); + %client.lastDamageClient = -1; + %client.lastDamageTurret = -1; + %client.setEngageTarget(-1); + %client.setTargetObject(-1); + %client.pilotVehicle = false; + %client.defaultTasksAdded = false; + + //do the nav graph cleanup + %client.missionCycleCleanup(); } } @@ -398,6 +397,15 @@ function AIVehicleMounted(%vehicle) $AIVehicleSet.add(%vehicle); } +function AICorpseAdded(%corpse) +{ + if (isObject(%corpse)) + { + %corpse.isCorpse = true; + $AIItemSet.add(%corpse); + } +} + //OTHER UTILITY FUNCTIONS function AIConnection::onAIDrop(%client) @@ -439,6 +447,7 @@ function AIConnection::startMission(%client) //sends a message so everyone know the bot is in the game... Game.AIHasJoined(%client); + %client.matchStartReady = true; //spawn the bot... onAIRespawn(%client); @@ -522,7 +531,7 @@ function AIReassessObjective(%client) { ProfilePatch1(patchForTimeTest, %client); // Game.AIChooseGameObjective(%client); - schedule(5000, %client, "AIReassessObjective", %client); + %client.objectiveThread = schedule(5000, %client, "AIReassessObjective", %client); } function onAIRespawn(%client) @@ -552,7 +561,7 @@ function onAIRespawn(%client) %client.respawnThread = ""; //timeslice the objective reassessment for the bots - if (%client.objectiveThread <= 0) + if (!isEventPending(%client.objectiveThread)) { %curTime = getSimTime(); %remainder = %curTime % 5000; diff --git a/base/scripts/aiBountyGame.cs b/base/scripts/aiBountyGame.cs index cb611fd..266e708 100644 --- a/base/scripts/aiBountyGame.cs +++ b/base/scripts/aiBountyGame.cs @@ -14,6 +14,9 @@ function BountyGame::onAIRespawn(%game, %client) %client.addTask(AIBountyPatrolTask); %client.bountyTask = %client.addTask(AIBountyEngageTask); } + + //set the inv flag + %client.spawnUseInv = true; } function BountyGame::AIInit(%game) @@ -59,12 +62,14 @@ function AIBountyEngageTask::weight(%task, %client) } //see if anyone has fired on us recently... + %mustEngage = false; %losTimeout = 5000 + ($AIClientLOSTimeout * %client.getSkillLevel()); if (AIClientIsAlive(%client.lastDamageClient, %losTimeout) && getSimTime() - %client.lastDamageTime < %losTimeout) { //see if the attacker is either our target or, we are their target if (%client.lastDamageClient == %client.objectiveTarget || %client.lastDamageClient.objectiveTarget == %client) { + %mustEngage = true; %currentTarget = %client.getEngageTarget(); //see if this is a new attacker @@ -105,7 +110,40 @@ function AIBountyEngageTask::weight(%task, %client) //now set the weight if (%client.shouldEngage > 0) - %task.setWeight($AIWeightReturnFire); + { + //if we've been fired upon... + if (%mustEngage) + %task.setWeight($AIWeightReturnFire); + + //see if we can allow the bot to use an inv station... + else if (%client.spawnUseInv) + { + //see if there's an available inv station + %result = AIFindClosestInventory(%client, false); + %closestInv = getWord(%result, 0); + %closestDist = getWord(%result, 1); + if (isObject(%closestInv)) + { + if (isObject(%client.shouldEngage.player)) + { + %dist = %client.getPathDistance(%client.shouldEngage.player.position); + if (%dist < 70 || %closestDist > 200) + %task.setWeight($AIWeightReturnFire); + else + %task.setWeight($AIBountyWeightShouldEngage); + } + else + %task.setWeight($AIBountyWeightShouldEngage); + } + else + { + %client.spawnUseInv = false; + %task.setWeight($AIWeightReturnFire); + } + } + else + %task.setWeight($AIWeightReturnFire); + } else %task.setWeight(0); } diff --git a/base/scripts/aiDeathMatch.cs b/base/scripts/aiDeathMatch.cs index 1016f04..1bd9a96 100644 --- a/base/scripts/aiDeathMatch.cs +++ b/base/scripts/aiDeathMatch.cs @@ -18,5 +18,8 @@ function DMGame::onAIRespawn(%game, %client) %client.addtask(AIDetectMineTask); %client.addTask(AIPatrolTask); } + + //set the inv flag + %client.spawnUseInv = true; } diff --git a/base/scripts/aiDebug.cs b/base/scripts/aiDebug.cs index 54bc4ce..f4bf9b1 100644 --- a/base/scripts/aiDebug.cs +++ b/base/scripts/aiDebug.cs @@ -68,6 +68,16 @@ function aiCome(%from, %to) %from.player.setTransform(%to.player.getTransform()); } +function findBotWithInv(%item) +{ + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (isObject(%cl.player) && %cl.player.getInventory(%item)) + echo(%cl @ ":" SPC getTaggedString(%cl.name) SPC "has item" SPC %item); + } +} + function listInv(%client) { %player = %client.player; @@ -152,6 +162,21 @@ function listInv(%client) %count = %player.getInventory(ShockLance); if (%count > 0) echo("ShockLance: " @ %count); + %count = %player.getInventory(RepairPack); + if (%count > 0) + echo("RepairPack: " @ %count); + %count = %player.getInventory(EnergyPack); + if (%count > 0) + echo("EnergyPack: " @ %count); + %count = %player.getInventory(ShieldPack); + if (%count > 0) + echo("ShieldPack: " @ %count); + %count = %player.getInventory(CloakingPack); + if (%count > 0) + echo("CloakingPack: " @ %count); + %count = %player.getInventory(SensorJammerPack); + if (%count > 0) + echo("SensorJammerPack: " @ %count); } function createAIDebugDlg() diff --git a/base/scripts/aiDefaultTasks.cs b/base/scripts/aiDefaultTasks.cs index 4035ec1..1310686 100644 --- a/base/scripts/aiDefaultTasks.cs +++ b/base/scripts/aiDefaultTasks.cs @@ -27,6 +27,9 @@ $AIHuntersWeightPickupFlag = 4425; $AIRabbitWeightDefault = 4625; $AIRabbitWeightNeedInv = 4325; +//Bounty weights... +$AIBountyWeightShouldEngage = 4325; + //----------------------------------------------------------------------------- //AIEngageTask is responsible for anything to do with engaging an enemy @@ -292,7 +295,9 @@ function AIPickupItemTask::weight(%task, %client) if (!%item.isHidden()) { %dist = %client.getPathDistance(%item.getWorldBoxCenter()); - if ((%item.getDataBlock().getName() $= "RepairKit" || %item.getDataBlock().getName() $= "RepairPatch") && %damage > 0.3) + if (((%item.getDataBlock().getName() $= "RepairKit" || %item.getDataBlock().getName() $= "RepairPatch") || + (%item.isCorpse && %item.getInventory("RepairKit") > 0)) && + %player.getInventory("RepairKit") <= 0 && %damage > 0.3) { if (%dist > 0 && %dist < %closestHealthDist) { @@ -335,7 +340,7 @@ function AIPickupItemTask::weight(%task, %client) if (%closestItem > 0 && %closetItemDist < %closestHealthDist - 25 && (%damage < 0.6 || %currentTarget <= 0) && %closestItemLOS) { %task.pickupItem = %closestItem; - if (AIEngageOutOfAmmo(%client)) + if (AIEngageWeaponRating(%client) < 20) %task.setWeight($AIWeightNeedItemBadly); else if (%closestItemDist < 10 && %closestItemLOS) %task.setWeight($AIWeightNeedItem); @@ -363,7 +368,7 @@ function AIPickupItemTask::weight(%task, %client) else if (%closestItem > 0) { %task.pickupItem = %closestItem; - if (AIEngageOutOfAmmo(%client)) + if (AIEngageWeaponRating(%client) < 20) %task.setWeight($AIWeightNeedItemBadly); else if (%closestItemDist < 10 && %closestItemLOS) %task.setWeight($AIWeightNeedItem); @@ -420,6 +425,31 @@ function AIUseInventoryTask::weight(%task, %client) %damage = %player.getDamagePercent(); %weaponry = AIEngageWeaponRating(%client); + //if there's an inv station, and we haven't used an inv station since we + //spawned, the bot should use an inv once regardless + if (%client.spawnUseInv) + { + //see if we're already heading there + if (%client.buyInvTime != %task.buyInvTime) + { + //see if there's an inventory we can use + %result = AIFindClosestInventory(%client, false); + %closestInv = getWord(%result, 0); + if (isObject(%closestInv)) + { + %task.setWeight($AIWeightNeedItem); + return; + } + else + %client.spawnUseInv = false; + } + else + { + %task.setWeight($AIWeightNeedItem); + return; + } + } + //first, see if we need equipment or health if (%damage < 0.3 && %weaponry >= 40) { @@ -456,15 +486,12 @@ function AIUseInventoryTask::weight(%task, %client) %task.setWeight(0); return; } - //If they don't have LOS to the inv station, they should only use it if they need something badly - %mask = $TypeMasks::TerrainObjectType | $TypeMasks::InteriorObjectType; - %hasLOS = !containerRayCast(%client.player.getWorldBoxCenter(), %closestInv.getWorldBoxCenter(), %mask, 0); //set the weight... %task.closestInv = %closestInv; if (%damage > 0.8 || AIEngageOutOfAmmo(%client)) %task.setWeight($AIWeightNeedItemBadly); - else if (%closestDist < 20 && %hasLOS && (AIEngageWeaponRating(%client) <= 30 || %damage > 0.4)) + else if (%closestDist < 20 && (AIEngageWeaponRating(%client) <= 30 || %damage > 0.4)) %task.setWeight($AIWeightNeedItem); else if (%hasLOS) %task.setWeight($AIWeightFoundItem); @@ -481,7 +508,7 @@ function AIUseInventoryTask::monitor(%task, %client) %damage = %player.getDamagePercent(); %weaponry = AIEngageWeaponRating(%client); - if (%damage < 0.3 && %weaponry >= 40) + if (%damage < 0.3 && %weaponry >= 40 && !%client.spawnUseInv) { %task.buyInvTime = getSimTime(); return; @@ -491,13 +518,21 @@ function AIUseInventoryTask::monitor(%task, %client) %randNum = getRandom(); if (%randNum < 0.4) %buySet = "LightEnergyDefault MediumEnergySet HeavyEnergySet"; - else if (%randNum < 0.7) + else if (%randNum < 0.6) %buySet = "LightShieldSet MediumShieldSet HeavyShieldSet"; - else + else if (%randNum < 0.8) %buySet = "LightEnergyELF MediumRepairSet HeavyAmmoSet"; + else + %buySet = "LightEnergySniper MediumEnergySet HeavyEnergySet"; - //reset the simTime if we're not still in progress + //process the inv buying state machine %result = AIBuyInventory(%client, "", %buySet, %task.buyInvTime); + + //if we succeeded, reset the spawn flag + if (%result $= "Finished") + %client.spawnUseInv = false; + + //if we succeeded or failed, reset the state machine... if (%result !$= "InProgress") %task.buyInvTime = getSimTime(); diff --git a/base/scripts/aiHunters.cs b/base/scripts/aiHunters.cs index 6176fb6..aafe542 100644 --- a/base/scripts/aiHunters.cs +++ b/base/scripts/aiHunters.cs @@ -25,6 +25,9 @@ function HuntersGame::onAIRespawn(%game, %client) %client.addTask(AIPatrolTask); %client.huntersTask = %client.addTask(AIHuntersTask); } + + //set the inv flag + %client.spawnUseInv = true; } //--------------------------------------------------------------------------- diff --git a/base/scripts/aiInventory.cs b/base/scripts/aiInventory.cs index 0c1d4d7..2daf551 100644 --- a/base/scripts/aiInventory.cs +++ b/base/scripts/aiInventory.cs @@ -342,29 +342,47 @@ function AICouldUseItem(%client, %item) return false; } - //check ammo - %quantity = mFloor(%playerDataBlock.max[%type] * 0.7); - if (%player.getInventory(%type) < %quantity) - { - if (%type $= "ChainGunAmmo" && %player.getInventory("ChainGun") > 0) - return true; - if (%type $= "PlasmaAmmo" && %player.getInventory("Plasma") > 0) - return true; - if (%type $= "DiscAmmo" && %player.getInventory("Disc") > 0) - return true; - if (%type $= "GrenadeLauncher" && %player.getInventory("GrenadeLauncherAmmo") > 0) - return true; - if (%type $= "MortarAmmo" && %player.getInventory("Mortar") > 0) - return true; + //if the item is acutally, a corpse, check the corpse inventory... + if (%item.isCorpse) + { + %corpse = %item; + if (%corpse.getInventory("ChainGunAmmo") > 0 && %player.getInventory(%type) < %playerDataBlock.max[ChainGunAmmo]) + return true; + if (%corpse.getInventory("PlasmaAmmo") > 0 && %player.getInventory(%type) < %playerDataBlock.max[PlasmaAmmo]) + return true; + if (%corpse.getInventory("DiscAmmo") > 0 && %player.getInventory(%type) < %playerDataBlock.max[DiscAmmo]) + return true; + if (%corpse.getInventory("GrenadeLauncher") > 0 && %player.getInventory(%type) < %playerDataBlock.max[GrenadeLauncher]) + return true; + if (%corpse.getInventory("MortarAmmo") > 0 && %player.getInventory(%type) < %playerDataBlock.max[MortarAmmo] && %player.getInventory("Mortar") > 0) + return true; + } + else + { + //check ammo + %quantity = mFloor(%playerDataBlock.max[%type]); + if (%player.getInventory(%type) < %quantity) + { + if (%type $= "ChainGunAmmo") + return true; + if (%type $= "PlasmaAmmo") + return true; + if (%type $= "DiscAmmo") + return true; + if (%type $= "GrenadeLauncher") + return true; + if (%type $= "MortarAmmo" && %player.getInventory("Mortar") > 0) + return true; - //check mines and grenades as well - if (%type $= "Grenade" || %type $= "FlashGrenade" || %type $= "ConcussionGrenade") - return true; - } + //check mines and grenades as well + if (%type $= "Grenade" || %type $= "FlashGrenade" || %type $= "ConcussionGrenade") + return true; + } - //see if we can carry another weapon... - if (AICanPickupWeapon(%client, %type)) - return true; + //see if we can carry another weapon... + if (AICanPickupWeapon(%client, %type)) + return true; + } //guess we didn't find anything useful... (should still check for mines and grenades) return false; @@ -391,8 +409,9 @@ function AIEngageOutofAmmo(%client) %hasELF = (%player.getInventory("ELFGun") > 0); %hasMortar = (%player.getInventory("Mortar") > 0); %hasMissile = (%player.getInventory("MissileLauncher") > 0); + %hasLance = (%player.getInventory("ShockLance") > 0); - if(%hasBlaster || %hasSniper || %hasElf) + if (%hasBlaster || %hasSniper || %hasElf || %hasLance) return false; else { @@ -422,7 +441,7 @@ function AICanPickupWeapon(%client, %weapon) //make sure the %weapon given is a weapon they can use for engagement if (%weapon !$= "Blaster" && %weapon !$= "Plasma" && %weapon !$= "Chaingun" && %weapon !$= "Disc" && - %weapon !$= "GrenadeLauncher" && %weapon !$= "SniperRifle" && %weapon !$= "ELFGun") + %weapon !$= "GrenadeLauncher" && %weapon !$= "SniperRifle" && %weapon !$= "ELFGun" && %weapon !$= "ShockLance") { return false; } diff --git a/base/scripts/aiRabbit.cs b/base/scripts/aiRabbit.cs index d1306c0..c0b7455 100644 --- a/base/scripts/aiRabbit.cs +++ b/base/scripts/aiRabbit.cs @@ -15,6 +15,9 @@ function RabbitGame::onAIRespawn(%game, %client) %client.addTask(AITauntCorpseTask); %client.rabbitTask = %client.addTask(AIRabbitTask); } + + //set the inv flag + %client.spawnUseInv = true; } //--------------------------------------------------------------------------- @@ -68,6 +71,33 @@ function AIRabbitTask::weight(%task, %client) %task.setWeight($AIRabbitWeightDefault); else %task.setWeight($AIRabbitWeightNeedInv); + + //see if the spawnUseInv flag should be reset + if (%client.spawnUseInv) + { + if (!isObject($AIRabbitFlag.carrier)) + { + //see if there are any bots closer to a dropped flag + %found = false; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl != %client && %cl.isAIControlled() && isObject(%cl.player)) + { + %dist = VectorDist(%cl.player.position, $AIRabbitFlag.position); + if (%dist < %distToFlag) + { + %found = true; + break; + } + } + } + + //reset the spawnUseInv flag if we're the closest + if (!%found) + %client.spawnUsInv = false; + } + } } } diff --git a/base/scripts/client.cs b/base/scripts/client.cs index 00c0955..bdb4b9a 100644 --- a/base/scripts/client.cs +++ b/base/scripts/client.cs @@ -212,7 +212,7 @@ function PlayGui::onWake(%this) } $enableDirectInput = "1"; - enableDirectInput(); + activateDirectInput(); // chat hud dialog Canvas.pushDialog( MainChatHud ); @@ -246,7 +246,11 @@ function PlayGui::onSleep(%this) moveMap.pop(); if ( isObject( passengerKeys ) ) passengerKeys.pop(); - flyingCameraMove.pop(); + if ( isObject( observerBlockMap ) ) + observerBlockMap.pop(); + if ( isObject( observerMap ) ) + observerMap.pop(); + //flyingCameraMove.pop(); CursorOn(); } @@ -350,16 +354,6 @@ function ClientCmdVoteSubmitted(%type) } // End client voting functions. -function clientCmdSetVoiceCodec(%codec) -{ - if (%codec $= ".v12" || %codec $= ".v24" || %codec $= ".v29") - $Audio::voiceCodec = %codec; - else - $Audio::voiceCodec = ""; - echo("Got setVoiceCodec: " @ %codec); - alxCaptureInit(); -} - function clientCmdEndBomberSight() { PlayGui.remove($bombSightHud); @@ -1769,11 +1763,17 @@ function sceneLightingComplete() } clientCmdResetHud(); - %numChannels = $pref::Audio::microphoneEnabled ? $pref::audio::voiceChannels : 0; - commandToServer('SetVoiceChannels', %numChannels); + commandToServer('SetVoiceInfo', $pref::Audio::voiceChannels, $pref::Audio::decodingMask, $pref::Audio::encodingLevel); commandToServer('MissionStartPhase3Done', $MSeq); } +function clientCmdSetVoiceInfo(%channels, %decodingMask, %encodingLevel) +{ + $Audio::serverChannels = %channels; + $Audio::serverDecodingMask = %decodingMask; + $Audio::serverEncodingLevel = %encodingLevel; +} + function ClientReceivedDataBlock(%index, %total) { %pct = %index / %total; diff --git a/base/scripts/clientAudio.cs b/base/scripts/clientAudio.cs index 5b36aee..e87077f 100644 --- a/base/scripts/clientAudio.cs +++ b/base/scripts/clientAudio.cs @@ -22,7 +22,6 @@ $AudioProviders[3, isHardware] = false; $AudioProviders[3, enableEvironment] = false; // defaults -$Audio::voiceCodec = ".v12"; $Audio::defaultDriver = "miles"; $Audio::innerFalloffScale = "1.0"; $Audio::dynamicMemorySize = (1 << 20); diff --git a/base/scripts/clientDefaults.cs b/base/scripts/clientDefaults.cs index 61160ba..c87b06b 100644 --- a/base/scripts/clientDefaults.cs +++ b/base/scripts/clientDefaults.cs @@ -1,11 +1,15 @@ $JoinGamePort = 28000; -$pref::Audio::drivers = "Miles"; -$pref::Audio::enableVoiceCapture = 1; -$pref::Audio::forceMaxDistanceUpdate = 0; -$pref::Audio::voiceChannels = 2; $pref::Audio::activeDriver = "default"; +$pref::Audio::drivers = "Miles"; +$pref::Audio::frequency = 22100; +$pref::Audio::sampleBits = 16; +$pref::Audio::channels = 2; +$pref::Audio::enableVoiceCapture = 1; +$pref::Audio::voiceChannels = 2; +$pref::Audio::encodingLevel = 0; +$pref::Audio::decodingMask = 1; +$pref::Audio::forceMaxDistanceUpdate = 0; $pref::Audio::environmentEnabled = 0; -$pref::Audio::microphoneEnabled = 1; $pref::Audio::musicEnabled = 1; $pref::Audio::musicVolume = 0.8; $pref::Audio::masterVolume = 0.8; @@ -69,17 +73,14 @@ $pref::Forum::CacheSize = 100; $pref::HudMessageLogSize = 40; $pref::Input::ActiveConfig = "MyConfig"; $pref::Input::LinkMouseSensitivity = 1; -$pref::Input::MouseEnabled = 0; -$pref::Input::JoystickEnabled = 0; $pref::Input::KeyboardTurnSpeed = 0.1; $pref::Interior::TexturedFog = 0; -$pref::IRCClient::server = "198.74.38.141"; -$pref::IRCClient::serverport = 6668; $pref::IRCClient::autoreconnect = 1; $pref::IRCClient::showjoinleave = 1; $pref::IRCClient::awaymsg = "Don't be alarmed. I'm going to step away from my computer."; $pref::IRCClient::banmsg = "You, and three generations of your offspring, are banned from this channel."; $pref::IRCClient::kickmsg = "Alright, you're outta here!"; +$pref::IRCClient::hostmsg = "left to host a game."; $pref::Lobby::Column1 = 120; $pref::Lobby::Column2 = 120; $pref::Lobby::Column3 = 50; @@ -143,3 +144,4 @@ $pref::VisibleDistanceMod = 1.0; $pref::OpenGL::force16BitTexture = "0"; $pref::OpenGL::forcePalettedTexture = "1"; $pref::OpenGL::maxHardwareLights = 3; +$pref::OpenGL::allowTexGen = "1"; diff --git a/base/scripts/controlDefaults.cs b/base/scripts/controlDefaults.cs index edea3a5..0f3d579 100644 --- a/base/scripts/controlDefaults.cs +++ b/base/scripts/controlDefaults.cs @@ -180,23 +180,6 @@ moveMap.bind( keyboard, "pageUp", pageMessageHudUp ); moveMap.bind( keyboard, "pageDown", pageMessageHudDown ); //------------------------------------------------------------------------------ -// VOICE CAPTURE FUNCTIONS: -function voiceCapStart() -{ - vcRecordingHud.setVisible(true); - voiceCommHud.setVisible(true); - resizeVoiceCommWindow(); - alxCaptureStart(); -} - -function voiceCapStop() -{ - vcRecordingHud.setVisible(false); - if($numTalking < 1) - voiceCommHud.setVisible(false); - alxCaptureStop(); -} - function voiceCapture( %val ) { if ( %val ) @@ -1031,7 +1014,18 @@ moveMap.bind( keyboard, insert, voteYes ); moveMap.bind( keyboard, delete, voteNo ); /////////////////////// -//Vehicle Keys +// Observer Keys +/////////////////////// +if ( isObject( observerMap ) ) + observerMap.delete(); +new ActionMap( observerMap ); +observerMap.bind( keyboard, t, moveup ); +observerMap.bind( keyboard, b, movedown ); +observerMap.bind( keyboard, space, jump ); +observerMap.bind( mouse, button1, mouseJet ); + +/////////////////////// +// Vehicle Keys /////////////////////// function clientCmdSetWeaponryVehicleKeys() { @@ -1104,6 +1098,12 @@ function clientCmdSetDefaultVehicleKeys(%inVehicle) passengerKeys.copyBind( moveMap, setZoomFOV ); passengerKeys.copyBind( moveMap, toggleZoom ); + // Copy the joystick binds as well: + passengerKeys.copyBind( moveMap, joyPitch ); + passengerKeys.copyBind( moveMap, joyYaw ); + passengerKeys.copyBind( moveMap, joystickMoveX ); + passengerKeys.copyBind( moveMap, joystickMoveY ); + // Bind the chat keys as well: passengerKeys.copyBind( moveMap, ToggleMessageHud ); passengerKeys.copyBind( moveMap, TeamMessageHud ); @@ -1229,9 +1229,7 @@ function serverCmdSetVehicleWeapon(%client, %num) %turret.setImageTrigger(2, false); %turret.setImageTrigger(4, false); } - } - } function nextVehicleWeapon(%val) diff --git a/base/scripts/creditsText.cs b/base/scripts/creditsText.cs index e928aaa..6bc02c1 100644 --- a/base/scripts/creditsText.cs +++ b/base/scripts/creditsText.cs @@ -349,7 +349,7 @@ addCreditsLine("Daniel \"Emp\" Arnold"); addCreditsLine("Daniel \"Snaggs\" Soderstrom"); addCreditsLine("Daniel \"Trebz\" Nolan"); addCreditsLine("Daniel \"Wizard_TPG\" Neilsen"); -addCreditsLine("Daniel \"Zero\" Nichols"); +addCreditsLine("Daniel \"Shadow Mage\" Nichols"); addCreditsLine("Daniel \"Spooger\" Patton"); addCreditsLine("Danny \"OmegaRed\" Cotton"); addCreditsLine("Darion \"Shadower\" Lowenstein"); @@ -383,7 +383,7 @@ addCreditsLine("Jeremy \"Xevious\" Burke"); addCreditsLine("Jerry \"Tycho Brahe\" Holkins"); addCreditsLine("Joe \"Quadrature\" Downs"); addCreditsLine("Joe Bell Grant"); -addCreditsLine("Joern \"[TD] Pangur\" Schnautz"); +addCreditsLine("Joern \"Pangur\" Schnautz"); addCreditsLine("John \"Dr.Jones\" Burnett"); addCreditsLine("Jon \"Ratorasniki\" Naiman"); addCreditsLine("Jonathan \"Chaser\" Bale"); @@ -420,7 +420,7 @@ addCreditsLine("Nathan \"[HvC]NaTeDoGG\" Sweet"); addCreditsLine("Nick \"Enhanced Panda\" Orlich"); addCreditsLine("Nick \"Leb\" Petska"); addCreditsLine("Nick S. \"Enlightened One\" Pasto"); -addCreditsLine("Nickita \"FSB-SPY\" Bogolyubov"); +addCreditsLine("Nikita \"FSB-SPY\" Bogolyubov"); addCreditsLine("Olivier \"[cf] OroX\" Roulx"); addCreditsLine("Omar Yehia"); addCreditsLine("Pamela A. \"Diva\" Holmberg"); @@ -1166,7 +1166,7 @@ addCreditsLine("Michael van Huystee"); addCreditsLine("Michael Voigt"); addCreditsLine("Michael Waldvogle"); addCreditsLine("Michael Wichter"); -addCreditsLine("micheal thornton"); +addCreditsLine("Michael Thornton"); addCreditsLine("Mickey Borchardt"); addCreditsLine("Miguel Schneeberger"); addCreditsLine("Mika Hyvonen"); @@ -1289,7 +1289,7 @@ addCreditsLine("Phill Curiale"); addCreditsLine("Phillip Ervin"); addCreditsLine("Phillip Kono"); addCreditsLine("Phillip Ploesser"); -addCreditsLine("phillip stewart"); +addCreditsLine("Phillip Stewart"); addCreditsLine("Pöchhacker Lee"); addCreditsLine("Prasad Galpoththawela"); addCreditsLine("Radu Lucian"); diff --git a/base/scripts/damageTypes.cs b/base/scripts/damageTypes.cs index 93e65e5..77bb40d 100644 --- a/base/scripts/damageTypes.cs +++ b/base/scripts/damageTypes.cs @@ -15,8 +15,8 @@ $DamageType::Missile = 9; $DamageType::ShockLance = 10; $DamageType::Mine = 11; $DamageType::Explosion = 12; -$DamageType::Impact = 13; -$DamageType::Ground = 14; +$DamageType::Impact = 13; // Object to object collisions +$DamageType::Ground = 14; // Object to ground collisions $DamageType::Turret = 15; $DamageType::PlasmaTurret = 16; @@ -96,7 +96,73 @@ $DamageTypeText[99] = "suicide"; //---------------------------------------------------------------------------- // VEHICLE DAMAGE PROFILES //---------------------------------------------------------------------------- -datablock SimDataBlock(AirVehicleDamageProfile) + +//**** SHRIKE SCOUT FIGHTER **** +datablock SimDataBlock(ShrikeDamageProfile) +{ + shieldDamageScale[$DamageType::Blaster] = 1.0; + shieldDamageScale[$DamageType::Bullet] = 1.75; + shieldDamageScale[$DamageType::ELF] = 1.0; + shieldDamageScale[$DamageType::ShockLance] = 0.5; + shieldDamageScale[$DamageType::Laser] = 1.0; + shieldDamageScale[$DamageType::ShrikeBlaster] = 4.0; + shieldDamageScale[$DamageType::BellyTurret] = 2.0; + shieldDamageScale[$DamageType::AATurret] = 3.0; + shieldDamageScale[$DamageType::IndoorDepTurret] = 2.25; + shieldDamageScale[$DamageType::OutdoorDepTurret] = 2.25; + shieldDamageScale[$DamageType::SentryTurret] = 2.25; + shieldDamageScale[$DamageType::Disc] = 1.0; + shieldDamageScale[$DamageType::Grenade] = 1.0; + shieldDamageScale[$DamageType::Mine] = 3.0; + shieldDamageScale[$DamageType::Missile] = 3.0; + shieldDamageScale[$DamageType::Mortar] = 2.0; + shieldDamageScale[$DamageType::Plasma] = 1.0; + shieldDamageScale[$DamageType::BomberBombs] = 3.0; + shieldDamageScale[$DamageType::TankChaingun] = 3.0; + shieldDamageScale[$DamageType::TankMortar] = 2.0; + shieldDamageScale[$DamageType::MissileTurret] = 3.0; + shieldDamageScale[$DamageType::MortarTurret] = 2.0; + shieldDamageScale[$DamageType::PlasmaTurret] = 2.0; + shieldDamageScale[$DamageType::SatchelCharge] = 3.5; + shieldDamageScale[$DamageType::Default] = 1.0; + shieldDamageScale[$DamageType::Impact] = 1.1; + shieldDamageScale[$DamageType::Ground] = 1.0; + shieldDamageScale[$DamageType::Explosion] = 3.0; + shieldDamageScale[$DamageType::Lightning] = 10.0; + + damageScale[$DamageType::Blaster] = 1.0; + damageScale[$DamageType::Bullet] = 1.0; + damageScale[$DamageType::ELF] = 0.0; + damageScale[$DamageType::ShockLance] = 0.50; + damageScale[$DamageType::Laser] = 1.0; + damageScale[$DamageType::ShrikeBlaster] = 3.5; + damageScale[$DamageType::BellyTurret] = 1.2; + damageScale[$DamageType::AATurret] = 1.5; + damageScale[$DamageType::IndoorDepTurret] = 1.25; + damageScale[$DamageType::OutdoorDepTurret] = 1.25; + damageScale[$DamageType::SentryTurret] = 1.25; + damageScale[$DamageType::Disc] = 1.0; + damageScale[$DamageType::Grenade] = 0.75; + damageScale[$DamageType::Mine] = 4.0; + damageScale[$DamageType::Missile] = 1.5; + damageScale[$DamageType::Mortar] = 2.0; + damageScale[$DamageType::Plasma] = 0.5; + damageScale[$DamageType::BomberBombs] = 2.0; + damageScale[$DamageType::TankChaingun] = 2.0; + damageScale[$DamageType::TankMortar] = 2.0; + damageScale[$DamageType::MissileTurret] = 1.5; + damageScale[$DamageType::MortarTurret] = 2.0; + damageScale[$DamageType::PlasmaTurret] = 2.0; + damageScale[$DamageType::SatchelCharge] = 3.5; + damageScale[$DamageType::Default] = 1.0; + damageScale[$DamageType::Impact] = 1.1; + damageScale[$DamageType::Ground] = 1.0; + damageScale[$DamageType::Explosion] = 2.0; + damageScale[$DamageType::Lightning] = 10.0; +}; + +//**** THUNDERSWORD BOMBER **** +datablock SimDataBlock(BomberDamageProfile) { shieldDamageScale[$DamageType::Blaster] = 1.0; shieldDamageScale[$DamageType::Bullet] = 1.0; @@ -123,7 +189,7 @@ datablock SimDataBlock(AirVehicleDamageProfile) shieldDamageScale[$DamageType::PlasmaTurret] = 2.0; shieldDamageScale[$DamageType::SatchelCharge] = 3.5; shieldDamageScale[$DamageType::Default] = 1.0; - shieldDamageScale[$DamageType::Impact] = 1.0; + shieldDamageScale[$DamageType::Impact] = 0.8; shieldDamageScale[$DamageType::Ground] = 1.0; shieldDamageScale[$DamageType::Explosion] = 3.0; shieldDamageScale[$DamageType::Lightning] = 10.0; @@ -153,13 +219,78 @@ datablock SimDataBlock(AirVehicleDamageProfile) damageScale[$DamageType::PlasmaTurret] = 2.0; damageScale[$DamageType::SatchelCharge] = 3.5; damageScale[$DamageType::Default] = 1.0; - damageScale[$DamageType::Impact] = 1.0; + damageScale[$DamageType::Impact] = 0.8; damageScale[$DamageType::Ground] = 1.0; damageScale[$DamageType::Explosion] = 2.0; damageScale[$DamageType::Lightning] = 10.0; }; -datablock SimDataBlock(GravCycleDamageProfile) +//**** HAVOC TRANSPORT **** +datablock SimDataBlock(HavocDamageProfile) +{ + shieldDamageScale[$DamageType::Blaster] = 1.0; + shieldDamageScale[$DamageType::Bullet] = 1.0; + shieldDamageScale[$DamageType::ELF] = 1.0; + shieldDamageScale[$DamageType::ShockLance] = 0.5; + shieldDamageScale[$DamageType::Laser] = 1.0; + shieldDamageScale[$DamageType::ShrikeBlaster] = 3.5; + shieldDamageScale[$DamageType::BellyTurret] = 2.0; + shieldDamageScale[$DamageType::AATurret] = 3.0; + shieldDamageScale[$DamageType::IndoorDepTurret] = 2.25; + shieldDamageScale[$DamageType::OutdoorDepTurret] = 2.25; + shieldDamageScale[$DamageType::SentryTurret] = 2.25; + shieldDamageScale[$DamageType::Disc] = 1.0; + shieldDamageScale[$DamageType::Grenade] = 1.0; + shieldDamageScale[$DamageType::Mine] = 3.0; + shieldDamageScale[$DamageType::Missile] = 3.0; + shieldDamageScale[$DamageType::Mortar] = 2.0; + shieldDamageScale[$DamageType::Plasma] = 1.0; + shieldDamageScale[$DamageType::BomberBombs] = 3.0; + shieldDamageScale[$DamageType::TankChaingun] = 3.0; + shieldDamageScale[$DamageType::TankMortar] = 2.0; + shieldDamageScale[$DamageType::MissileTurret] = 3.0; + shieldDamageScale[$DamageType::MortarTurret] = 2.0; + shieldDamageScale[$DamageType::PlasmaTurret] = 2.0; + shieldDamageScale[$DamageType::SatchelCharge] = 3.5; + shieldDamageScale[$DamageType::Default] = 1.0; + shieldDamageScale[$DamageType::Impact] = 0.5; + shieldDamageScale[$DamageType::Ground] = 1.0; + shieldDamageScale[$DamageType::Explosion] = 3.0; + shieldDamageScale[$DamageType::Lightning] = 10.0; + + damageScale[$DamageType::Blaster] = 0.75; + damageScale[$DamageType::Bullet] = 0.75; + damageScale[$DamageType::ELF] = 0.0; + damageScale[$DamageType::ShockLance] = 0.50; + damageScale[$DamageType::Laser] = 1.0; + damageScale[$DamageType::ShrikeBlaster] = 2.5; + damageScale[$DamageType::BellyTurret] = 1.2; + damageScale[$DamageType::AATurret] = 1.5; + damageScale[$DamageType::IndoorDepTurret] = 1.25; + damageScale[$DamageType::OutdoorDepTurret] = 1.25; + damageScale[$DamageType::SentryTurret] = 1.25; + damageScale[$DamageType::Disc] = 1.0; + damageScale[$DamageType::Grenade] = 0.75; + damageScale[$DamageType::Mine] = 4.0; + damageScale[$DamageType::Missile] = 1.5; + damageScale[$DamageType::Mortar] = 2.0; + damageScale[$DamageType::Plasma] = 0.5; + damageScale[$DamageType::BomberBombs] = 2.0; + damageScale[$DamageType::TankChaingun] = 2.0; + damageScale[$DamageType::TankMortar] = 2.0; + damageScale[$DamageType::MissileTurret] = 1.5; + damageScale[$DamageType::MortarTurret] = 2.0; + damageScale[$DamageType::PlasmaTurret] = 2.0; + damageScale[$DamageType::SatchelCharge] = 3.5; + damageScale[$DamageType::Default] = 1.0; + damageScale[$DamageType::Impact] = 0.5; + damageScale[$DamageType::Ground] = 1.0; + damageScale[$DamageType::Explosion] = 2.0; + damageScale[$DamageType::Lightning] = 10.0; +}; + +//**** WILDCAT GRAV CYCLE **** +datablock SimDataBlock(WildcatDamageProfile) { shieldDamageScale[$DamageType::Blaster] = 2.0; shieldDamageScale[$DamageType::Bullet] = 2.5; @@ -185,7 +316,7 @@ datablock SimDataBlock(GravCycleDamageProfile) shieldDamageScale[$DamageType::PlasmaTurret] = 2.0; shieldDamageScale[$DamageType::SatchelCharge] = 3.0; shieldDamageScale[$DamageType::Default] = 1.0; - shieldDamageScale[$DamageType::Impact] = 1.0; + shieldDamageScale[$DamageType::Impact] = 1.25; shieldDamageScale[$DamageType::Ground] = 1.0; shieldDamageScale[$DamageType::Explosion] = 2.0; shieldDamageScale[$DamageType::Lightning] = 5.0; @@ -214,13 +345,14 @@ datablock SimDataBlock(GravCycleDamageProfile) damageScale[$DamageType::PlasmaTurret] = 1.0; damageScale[$DamageType::SatchelCharge] = 2.2; damageScale[$DamageType::Default] = 1.0; - damageScale[$DamageType::Impact] = 1.0; + damageScale[$DamageType::Impact] = 1.25; damageScale[$DamageType::Ground] = 1.0; damageScale[$DamageType::Explosion] = 1.0; damageScale[$DamageType::Lightning] = 5.0; }; -datablock SimDataBlock(GroundVehicleDamageProfile) +//**** BEOWULF TANK **** +datablock SimDataBlock(TankDamageProfile) { shieldDamageScale[$DamageType::Blaster] = 0.6; shieldDamageScale[$DamageType::Bullet] = 0.75; @@ -246,7 +378,7 @@ datablock SimDataBlock(GroundVehicleDamageProfile) shieldDamageScale[$DamageType::PlasmaTurret] = 1.25; shieldDamageScale[$DamageType::SatchelCharge] = 2.0; shieldDamageScale[$DamageType::Default] = 1.0; - shieldDamageScale[$DamageType::Impact] = 1.0; + shieldDamageScale[$DamageType::Impact] = 0.75; shieldDamageScale[$DamageType::Ground] = 1.0; shieldDamageScale[$DamageType::Explosion] = 2.0; shieldDamageScale[$DamageType::Lightning] = 10.0; @@ -275,7 +407,69 @@ datablock SimDataBlock(GroundVehicleDamageProfile) damageScale[$DamageType::PlasmaTurret] = 1.0; damageScale[$DamageType::SatchelCharge] = 2.0; damageScale[$DamageType::Default] = 1.0; - damageScale[$DamageType::Impact] = 1.0; + damageScale[$DamageType::Impact] = 0.75; + damageScale[$DamageType::Ground] = 1.0; + damageScale[$DamageType::Explosion] = 1.0; + damageScale[$DamageType::Lightning] = 10.0; +}; + +//**** JERICHO MPB **** +datablock SimDataBlock(MPBDamageProfile) +{ + shieldDamageScale[$DamageType::Blaster] = 0.6; + shieldDamageScale[$DamageType::Bullet] = 0.75; + shieldDamageScale[$DamageType::ELF] = 1.0; + shieldDamageScale[$DamageType::ShockLance] = 0.5; + shieldDamageScale[$DamageType::Laser] = 1.0; + shieldDamageScale[$DamageType::ShrikeBlaster] = 1.75; + shieldDamageScale[$DamageType::BellyTurret] = 1.25; + shieldDamageScale[$DamageType::AATurret] = 0.8; + shieldDamageScale[$DamageType::IndoorDepTurret] = 1.0; + shieldDamageScale[$DamageType::OutdoorDepTurret] = 1.0; + shieldDamageScale[$DamageType::Disc] = 0.8; + shieldDamageScale[$DamageType::Grenade] = 0.8; + shieldDamageScale[$DamageType::Mine] = 3.25; + shieldDamageScale[$DamageType::Missile] = 2.0; + shieldDamageScale[$DamageType::Mortar] = 0.8; + shieldDamageScale[$DamageType::Plasma] = 1.0; + shieldDamageScale[$DamageType::BomberBombs] = 1.5; + shieldDamageScale[$DamageType::TankChaingun] = 1.5; + shieldDamageScale[$DamageType::TankMortar] = 1.4; + shieldDamageScale[$DamageType::MissileTurret] = 1.25; + shieldDamageScale[$DamageType::MortarTurret] = 1.0; + shieldDamageScale[$DamageType::PlasmaTurret] = 1.25; + shieldDamageScale[$DamageType::SatchelCharge] = 2.0; + shieldDamageScale[$DamageType::Default] = 1.0; + shieldDamageScale[$DamageType::Impact] = 0.5; + shieldDamageScale[$DamageType::Ground] = 1.0; + shieldDamageScale[$DamageType::Explosion] = 2.0; + shieldDamageScale[$DamageType::Lightning] = 10.0; + + damageScale[$DamageType::Blaster] = 0.75; + damageScale[$DamageType::Bullet] = 0.75; + damageScale[$DamageType::ELF] = 0.0; + damageScale[$DamageType::ShockLance] = 0.50; + damageScale[$DamageType::Laser] = 1.0; + damageScale[$DamageType::ShrikeBlaster] = 2.0; + damageScale[$DamageType::BellyTurret] = 1.0; + damageScale[$DamageType::AATurret] = 1.0; + damageScale[$DamageType::IndoorDepTurret] = 1.0; + damageScale[$DamageType::OutdoorDepTurret] = 1.0; + damageScale[$DamageType::Disc] = 1.0; + damageScale[$DamageType::Grenade] = 1.0; + damageScale[$DamageType::Mine] = 2.25; + damageScale[$DamageType::Missile] = 1.25; + damageScale[$DamageType::Mortar] = 1.0; + damageScale[$DamageType::Plasma] = 0.5; + damageScale[$DamageType::BomberBombs] = 1.0; + damageScale[$DamageType::TankChaingun] = 0.75; + damageScale[$DamageType::TankMortar] = 1.0; + damageScale[$DamageType::MissileTurret] = 1.25; + damageScale[$DamageType::MortarTurret] = 1.0; + damageScale[$DamageType::PlasmaTurret] = 1.0; + damageScale[$DamageType::SatchelCharge] = 2.0; + damageScale[$DamageType::Default] = 1.0; + damageScale[$DamageType::Impact] = 0.5; damageScale[$DamageType::Ground] = 1.0; damageScale[$DamageType::Explosion] = 1.0; damageScale[$DamageType::Lightning] = 10.0; @@ -380,7 +574,7 @@ datablock SimDataBlock(StaticShapeDamageProfile) shieldDamageScale[$DamageType::PlasmaTurret] = 2.0; shieldDamageScale[$DamageType::SatchelCharge] = 6.0; shieldDamageScale[$DamageType::Default] = 1.0; - shieldDamageScale[$DamageType::Impact] = 1.0; + shieldDamageScale[$DamageType::Impact] = 1.25; shieldDamageScale[$DamageType::Ground] = 1.0; shieldDamageScale[$DamageType::Explosion] = 2.0; shieldDamageScale[$DamageType::Lightning] = 5.0; @@ -410,7 +604,7 @@ datablock SimDataBlock(StaticShapeDamageProfile) damageScale[$DamageType::PlasmaTurret] = 2.0; damageScale[$DamageType::SatchelCharge] = 4.0; damageScale[$DamageType::Default] = 1.0; - damageScale[$DamageType::Impact] = 1.0; + damageScale[$DamageType::Impact] = 1.25; damageScale[$DamageType::Ground] = 1.0; damageScale[$DamageType::Explosion] = 1.0; damageScale[$DamageType::Lightning] = 5.0; @@ -447,7 +641,7 @@ datablock SimDataBlock(LightPlayerDamageProfile) damageScale[$DamageType::PlasmaTurret] = 1.0; damageScale[$DamageType::SatchelCharge] = 3.0; damageScale[$DamageType::Default] = 1.0; - damageScale[$DamageType::Impact] = 1.0; + damageScale[$DamageType::Impact] = 1.2; damageScale[$DamageType::Ground] = 1.0; damageScale[$DamageType::Explosion] = 1.2; damageScale[$DamageType::Lightning] = 1.0; @@ -513,7 +707,7 @@ datablock SimDataBlock(HeavyPlayerDamageProfile) damageScale[$DamageType::PlasmaTurret] = 1.0; damageScale[$DamageType::SatchelCharge] = 3.0; damageScale[$DamageType::Default] = 1.0; - damageScale[$DamageType::Impact] = 1.0; + damageScale[$DamageType::Impact] = 0.8; damageScale[$DamageType::Ground] = 1.0; damageScale[$DamageType::Explosion] = 0.6; damageScale[$DamageType::Lightning] = 1.4; diff --git a/base/scripts/defaultGame.cs b/base/scripts/defaultGame.cs index c3a8323..5fc0885 100644 --- a/base/scripts/defaultGame.cs +++ b/base/scripts/defaultGame.cs @@ -927,6 +927,9 @@ function DefaultGame::onClientKilled(%game, %clVictim, %clKiller, %damageType, % else aiReleaseHumanControl(%clVictim, %clVictim.controlAI); + //used to track corpses so the AI can get ammo, etc... + AICorpseAdded(%plVictim); + //if the death was a suicide, prevent respawning for 5 seconds... %clVictim.lastDeathSuicide = false; if (%damageType == $DamageType::Suicide) @@ -2305,6 +2308,9 @@ function DefaultGame::sendGamePlayerPopupMenu( %game, %client, %targetClient, %k %outrankTarget = !%targetClient.isSuperAdmin; else if ( %client.isAdmin ) %outrankTarget = !%targetClient.isAdmin; + + if( ! %targetClient.matchStartReady ) + return; //mute options if ( !%isTargetSelf ) @@ -2509,14 +2515,28 @@ function DefaultGame::sendTimeLimitList( %game, %client, %key ) //------------------------------------------------------------------------------ // all global votes here -function DefaultGame::voteChangeMission(%game, %admin, %missionDisplayName, %typeDisplayName, %mission, %missionType) +function DefaultGame::voteChangeMission(%game, %admin, %missionDisplayName, %typeDisplayName, %missionId, %missionTypeId) { + %mission = $HostMissionFile[%missionId]; + if ( %mission $= "" ) + { + error( "Invalid mission index passed to DefaultGame::voteChangeMission!" ); + return; + } + + %missionType = $HostTypeName[%missionTypeId]; + if ( %missionType $= "" ) + { + error( "Invalid mission type id passed to DefaultGame::voteChangeMission!" ); + return; + } + if(%admin) { messageAll('MsgAdminChangeMission', '\c2The Admin has changed the mission to %1 (%2).', %missionDisplayName, %typeDisplayName ); logEcho("mission changed to "@%missionDisplayName@"/"@%typeDisplayName@" (admin)"); %game.gameOver(); - loadMission(%mission, %missionType, false); + loadMission( %mission, %missionType, false ); } else { @@ -2526,7 +2546,7 @@ function DefaultGame::voteChangeMission(%game, %admin, %missionDisplayName, %typ messageAll('MsgVotePassed', '\c2The mission was changed to %1 (%2) by vote.', %missionDisplayName, %typeDisplayName ); logEcho("mission changed to "@%missionDisplayName@"/"@%typeDisplayName@" (vote)"); %game.gameOver(); - loadMission(%mission, %missionType, false); + loadMission( %mission, %missionType, false ); } else messageAll('MsgVoteFailed', '\c2Change mission vote did not pass: %1 percent.', mFloor(%game.totalVotesFor/(ClientGroup.getCount() - $HostGameBotCount) * 100)); @@ -2586,8 +2606,22 @@ function DefaultGame::voteTeamDamage(%game, %admin) } //------------------------------------------------------------------------------ -function DefaultGame::voteTournamentMode( %game, %admin, %missionDisplayName, %typeDisplayName, %mission, %missionType ) +function DefaultGame::voteTournamentMode( %game, %admin, %missionDisplayName, %typeDisplayName, %missionId, %missionTypeId ) { + %mission = $HostMissionFile[%missionId]; + if ( %mission $= "" ) + { + error( "Invalid mission index passed to DefaultGame::voteTournamentMode!" ); + return; + } + + %missionType = $HostTypeName[%missionTypeId]; + if ( %missionType $= "" ) + { + error( "Invalid mission type id passed to DefaultGame::voteTournamentMode!" ); + return; + } + %cause = ""; if (%admin) { @@ -2904,9 +2938,6 @@ function DefaultGame::updateScoreHud(%game, %client, %tag) %index++; } - - //clear the rest of Hud so we don't get old lines hanging around... - messageClient( %client, 'ClearHud', "", %tag, %index ); } else { @@ -2980,9 +3011,40 @@ function DefaultGame::updateScoreHud(%game, %client, %tag) } } - //clear the rest of Hud so we don't get old lines hanging around... - messageClient( %client, 'ClearHud', "", %tag, %index ); } + + // Tack on the list of observers: + %observerCount = 0; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.team == 0) + %observerCount++; + } + + if (%observerCount > 0) + { + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient(%client, 'SetLineHud', "", %tag, %index, '\tOBSERVERS (%1)TIME', %observerCount); + %index++; + for (%i = 0; %i < ClientGroup.getCount(); %i++) + { + %cl = ClientGroup.getObject(%i); + //if this is an observer + if (%cl.team == 0) + { + %obsTime = getSimTime() - %cl.observerStartTime; + %obsTimeStr = %game.formatTime(%obsTime, false); + messageClient( %client, 'SetLineHud', "", %tag, %index, '\t%1%2', + %cl.name, %obsTimeStr ); + %index++; + } + } + } + + //clear the rest of Hud so we don't get old lines hanging around... + messageClient( %client, 'ClearHud', "", %tag, %index ); } //------------------------------------------------------------------------------ @@ -3016,6 +3078,42 @@ function notifyMatchEnd(%time) UpdateClientTimes(%time); } +function DefaultGame::formatTime(%game, %tStr, %includeHundredths) +{ + %timeInSeconds = %tStr / 1000; + %mins = mFloor(%timeInSeconds / 60); + if(%mins < 1) + %timeString = "00:"; + else if(%mins < 10) + %timeString = "0" @ %mins @ ":"; + else + %timeString = %mins @ ":"; + + %timeInSeconds -= (%mins * 60); + %secs = mFloor(%timeInSeconds); + if(%secs < 1) + %timeString = %timeString @ "00"; + else if(%secs < 10) + %timeString = %timeString @ "0" @ %secs; + else + %timeString = %timeString @ %secs; + + if (%includeHundredths) + { + %timeString = %timeString @ "."; + %timeInSeconds -= %secs; + %hSecs = mFloor(%timeInSeconds * 100); // will be between 0 and 999 + if(%hSecs < 1) + %timeString = %timeString @ "00"; + else if(%hSecs < 10) + %timeString = %timeString @ "0" @ %hSecs; + else + %timeString = %timeString @ %hSecs; + } + + return %timeString; +} + //------------------------------------------------------------------------------ //AI FUNCTIONS function DefaultGame::AIChooseGameObjective(%game, %client) diff --git a/base/scripts/deployables.cs b/base/scripts/deployables.cs index 4eb4341..f2f7452 100644 --- a/base/scripts/deployables.cs +++ b/base/scripts/deployables.cs @@ -118,6 +118,8 @@ datablock StaticShapeData(DeployedStationInventory) : StaticShapeDamageProfile renderWhenDestroyed = false; doesRepair = true; + deployedObject = true; + cmdCategory = "DSupport"; cmdIcon = CMDStationIcon; cmdMiniIconName = "commander/MiniIcons/com_inventory_grey"; @@ -126,6 +128,7 @@ datablock StaticShapeData(DeployedStationInventory) : StaticShapeDamageProfile debrisShapeName = "debris_generic_small.dts"; debris = DeployableDebris; + heatSignature = 0; }; datablock ShapeBaseImageData(InventoryDeployableImage) @@ -138,6 +141,7 @@ datablock ShapeBaseImageData(InventoryDeployableImage) mountPoint = 1; offset = "0 0 0"; deployed = DeployedStationInventory; + heatSignature = 0; stateName[0] = "Idle"; stateTransitionOnTriggerDown[0] = "Activate"; @@ -163,6 +167,7 @@ datablock ItemData(InventoryDeployable) rotate = false; image = "InventoryDeployableImage"; pickUpName = "an inventory pack"; + heatSignature = 0; computeCRC = true; emap = true; @@ -194,6 +199,8 @@ datablock StaticShapeData(DeployedMotionSensor) : StaticShapeDamageProfile explosion = DeployablesExplosion; dynamicType = $TypeMasks::SensorObjectType; + deployedObject = true; + cmdCategory = "DSupport"; cmdIcon = CMDSensorIcon; cmdMiniIconName = "commander/MiniIcons/com_deploymotionsensor"; @@ -206,6 +213,7 @@ datablock StaticShapeData(DeployedMotionSensor) : StaticShapeDamageProfile debrisShapeName = "debris_generic_small.dts"; debris = DeployableDebris; + heatSignature = 0; }; datablock ShapeBaseImageData(MotionSensorDeployableImage) @@ -226,6 +234,7 @@ datablock ShapeBaseImageData(MotionSensorDeployableImage) maxDepSlope = 360; deploySound = MotionSensorDeploySound; emap = true; + heatSignature = 1; }; datablock ItemData(MotionSensorDeployable) @@ -243,6 +252,7 @@ datablock ItemData(MotionSensorDeployable) computeCRC = true; emap = true; + heatSignature = 0; //maxSensors = 3; maxSensors = 2; @@ -271,6 +281,8 @@ datablock StaticShapeData(DeployedPulseSensor) : StaticShapeDamageProfile explosion = DeployablesExplosion; dynamicType = $TypeMasks::SensorObjectType; + deployedObject = true; + cmdCategory = "DSupport"; cmdIcon = CMDSensorIcon; cmdMiniIconName = "commander/MiniIcons/com_deploypulsesensor"; @@ -283,6 +295,7 @@ datablock StaticShapeData(DeployedPulseSensor) : StaticShapeDamageProfile debrisShapeName = "debris_generic_small.dts"; debris = DeployableDebris; + heatSignature = 0; }; datablock ShapeBaseImageData(PulseSensorDeployableImage) @@ -303,6 +316,7 @@ datablock ShapeBaseImageData(PulseSensorDeployableImage) maxDepSlope = 40; emap = true; + heatSignature = 0; }; datablock ItemData(PulseSensorDeployable) @@ -366,7 +380,7 @@ datablock ItemData(TurretOutdoorDeployable) pickupRadius = 1; rotate = false; image = "TurretOutdoorDeployableImage"; - pickUpName = "an outdoor turret pack"; + pickUpName = "a landspike turret pack"; computeCRC = true; emap = true; @@ -410,7 +424,7 @@ datablock ItemData(TurretIndoorDeployable) pickupRadius = 1; rotate = false; image = "TurretIndoorDeployableImage"; - pickUpName = "an indoor turret pack"; + pickUpName = "a spider clamp turret pack"; computeCRC = true; emap = true; @@ -889,6 +903,10 @@ function ShapeBaseImageData::onDeploy(%item, %plyr, %slot) %deplObj.setDeployRotation(%item.surfacePt, %item.surfaceNrm); else %deplObj.setTransform(%item.surfacePt SPC %rot); + + // set the recharge rate right away + if(%deplObj.getDatablock().rechargeRate) + %deplObj.setRechargeRate(%deplObj.getDatablock().rechargeRate); // set team, owner, and handle %deplObj.team = %plyr.client.Team; diff --git a/base/scripts/hud.cs b/base/scripts/hud.cs index c45225b..5834358 100644 --- a/base/scripts/hud.cs +++ b/base/scripts/hud.cs @@ -1,83 +1,83 @@ -function createObserverMoveMap() -{ - if ( isObject( flyingCameraMove ) ) - flyingCameraMove.delete(); - - new ActionMap( flyingCameraMove ); - flyingCameraMove.bind( keyboard, s, moveleft ); - flyingCameraMove.bind( keyboard, f, moveright ); - flyingCameraMove.bind( keyboard, e, moveforward ); - flyingCameraMove.bind( keyboard, d, movebackward ); - flyingCameraMove.bind( keyboard, t, moveup ); - flyingCameraMove.bind( keyboard, b, movedown ); - - // allow hud activation - flyingCameraMove.copyBind( moveMap, toggleScoreScreen ); - flyingCameraMove.copyBind( moveMap, toggleCommanderMap ); - flyingCameraMove.copyBind( moveMap, TeamMessageHud ); - flyingCameraMove.copyBind( moveMap, toggleMessageHud ); - flyingCameraMove.copyBind( moveMap, toggleInventoryHud ); - flyingCameraMove.copyBind( moveMap, voteYes ); - flyingCameraMove.copyBind( moveMap, voteNo ); - flyingCameraMove.copyBind( moveMap, activateChatMenuHud ); - - // Bind the command assignment/response keys as well: - flyingCameraMove.copyBind( moveMap, toggleTaskListDlg ); - flyingCameraMove.copyBind( moveMap, fnAcceptTask ); - flyingCameraMove.copyBind( moveMap, fnDeclineTask ); - flyingCameraMove.copyBind( moveMap, fnTaskCompleted ); - flyingCameraMove.copyBind( moveMap, fnResetTaskList ); - - // misc - flyingCameraMove.copyBind( moveMap, voiceCapture ); - - // inventory binds - flyingCameraMove.copyBind( moveMap, toggleInventoryHud ); - flyingCameraMove.copyBind( moveMap, selectFavorite1 ); - flyingCameraMove.copyBind( moveMap, selectFavorite2 ); - flyingCameraMove.copyBind( moveMap, selectFavorite3 ); - flyingCameraMove.copyBind( moveMap, selectFavorite4 ); - flyingCameraMove.copyBind( moveMap, selectFavorite5 ); - flyingCameraMove.copyBind( moveMap, selectFavorite6 ); - flyingCameraMove.copyBind( moveMap, selectFavorite7 ); - flyingCameraMove.copyBind( moveMap, selectFavorite8 ); - flyingCameraMove.copyBind( moveMap, selectFavorite9 ); - flyingCameraMove.copyBind( moveMap, selectFavorite10 ); - - flyingCameraMove.copyBind( moveMap, selectFavorite11 ); - flyingCameraMove.copyBind( moveMap, selectFavorite12 ); - flyingCameraMove.copyBind( moveMap, selectFavorite13 ); - flyingCameraMove.copyBind( moveMap, selectFavorite14 ); - flyingCameraMove.copyBind( moveMap, selectFavorite15 ); - flyingCameraMove.copyBind( moveMap, selectFavorite16 ); - flyingCameraMove.copyBind( moveMap, selectFavorite17 ); - flyingCameraMove.copyBind( moveMap, selectFavorite18 ); - flyingCameraMove.copyBind( moveMap, selectFavorite19 ); - flyingCameraMove.copyBind( moveMap, selectFavorite20 ); - - flyingCameraMove.copyBind( moveMap, quickPackEnergyPack ); - flyingCameraMove.copyBind( moveMap, quickPackRepairPack ); - flyingCameraMove.copyBind( moveMap, quickPackShieldPack ); - flyingCameraMove.copyBind( moveMap, quickPackCloakPack ); - flyingCameraMove.copyBind( moveMap, quickPackJammerPack ); - flyingCameraMove.copyBind( moveMap, quickPackAmmoPack ); - flyingCameraMove.copyBind( moveMap, quickPackSatchelCharge ); - flyingCameraMove.copyBind( moveMap, quickPackDeployableStation ); - flyingCameraMove.copyBind( moveMap, quickPackIndoorTurret ); - flyingCameraMove.copyBind( moveMap, quickPackOutdoorTurret ); - flyingCameraMove.copyBind( moveMap, quickPackMotionSensor ); - flyingCameraMove.copyBind( moveMap, quickPackPulse ); - - //preserve the fire, jump, and jet buttons - flyingCameraMove.copyBind( moveMap, mouseFire ); - flyingCameraMove.copyBind( moveMap, mouseJet ); - flyingCameraMove.copyBind( moveMap, jump ); - flyingCameraMove.copyBind( moveMap, yaw ); - flyingCameraMove.copyBind( moveMap, pitch ); - - flyingCameraMove.bindCmd( keyboard, escape, "", "escapeFromGame();" ); -} -createObserverMoveMap(); +// function createObserverMoveMap() +// { +// if ( isObject( flyingCameraMove ) ) +// flyingCameraMove.delete(); +// +// new ActionMap( flyingCameraMove ); +// flyingCameraMove.bind( keyboard, s, moveleft ); +// flyingCameraMove.bind( keyboard, f, moveright ); +// flyingCameraMove.bind( keyboard, e, moveforward ); +// flyingCameraMove.bind( keyboard, d, movebackward ); +// flyingCameraMove.bind( keyboard, t, moveup ); +// flyingCameraMove.bind( keyboard, b, movedown ); +// +// // allow hud activation +// flyingCameraMove.copyBind( moveMap, toggleScoreScreen ); +// flyingCameraMove.copyBind( moveMap, toggleCommanderMap ); +// flyingCameraMove.copyBind( moveMap, TeamMessageHud ); +// flyingCameraMove.copyBind( moveMap, toggleMessageHud ); +// flyingCameraMove.copyBind( moveMap, toggleInventoryHud ); +// flyingCameraMove.copyBind( moveMap, voteYes ); +// flyingCameraMove.copyBind( moveMap, voteNo ); +// flyingCameraMove.copyBind( moveMap, activateChatMenuHud ); +// +// // Bind the command assignment/response keys as well: +// flyingCameraMove.copyBind( moveMap, toggleTaskListDlg ); +// flyingCameraMove.copyBind( moveMap, fnAcceptTask ); +// flyingCameraMove.copyBind( moveMap, fnDeclineTask ); +// flyingCameraMove.copyBind( moveMap, fnTaskCompleted ); +// flyingCameraMove.copyBind( moveMap, fnResetTaskList ); +// +// // misc +// flyingCameraMove.copyBind( moveMap, voiceCapture ); +// +// // inventory binds +// flyingCameraMove.copyBind( moveMap, toggleInventoryHud ); +// flyingCameraMove.copyBind( moveMap, selectFavorite1 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite2 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite3 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite4 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite5 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite6 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite7 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite8 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite9 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite10 ); +// +// flyingCameraMove.copyBind( moveMap, selectFavorite11 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite12 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite13 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite14 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite15 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite16 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite17 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite18 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite19 ); +// flyingCameraMove.copyBind( moveMap, selectFavorite20 ); +// +// flyingCameraMove.copyBind( moveMap, quickPackEnergyPack ); +// flyingCameraMove.copyBind( moveMap, quickPackRepairPack ); +// flyingCameraMove.copyBind( moveMap, quickPackShieldPack ); +// flyingCameraMove.copyBind( moveMap, quickPackCloakPack ); +// flyingCameraMove.copyBind( moveMap, quickPackJammerPack ); +// flyingCameraMove.copyBind( moveMap, quickPackAmmoPack ); +// flyingCameraMove.copyBind( moveMap, quickPackSatchelCharge ); +// flyingCameraMove.copyBind( moveMap, quickPackDeployableStation ); +// flyingCameraMove.copyBind( moveMap, quickPackIndoorTurret ); +// flyingCameraMove.copyBind( moveMap, quickPackOutdoorTurret ); +// flyingCameraMove.copyBind( moveMap, quickPackMotionSensor ); +// flyingCameraMove.copyBind( moveMap, quickPackPulse ); +// +// //preserve the fire, jump, and jet buttons +// flyingCameraMove.copyBind( moveMap, mouseFire ); +// flyingCameraMove.copyBind( moveMap, mouseJet ); +// flyingCameraMove.copyBind( moveMap, jump ); +// flyingCameraMove.copyBind( moveMap, yaw ); +// flyingCameraMove.copyBind( moveMap, pitch ); +// +// flyingCameraMove.bindCmd( keyboard, escape, "", "escapeFromGame();" ); +// } +// createObserverMoveMap(); //-------------------------------------------------------------------------- function GameConnection::sensorPing(%this, %ping) @@ -652,6 +652,7 @@ function MessageHud::open(%this) MessageHud_Edit.extent = setWord(MessageHud_Edit.extent, 0, %ctrlExtent - %textExtent - (2 * %offset)); %this.setVisible(true); + deactivateKeyboard(); MessageHud_Edit.makeFirstResponder(true); } @@ -677,6 +678,8 @@ function MessageHud::close(%this) Canvas.popDialog(%this); %this.setVisible(false); + if ( $enableDirectInput ) + activateKeyboard(); MessageHud_Edit.setValue(""); } @@ -716,7 +719,7 @@ function MainChatHud::onWake( %this ) { // set the chat hud to the users pref %this.setChatHudLength( $Pref::ChatHudLength ); -} +} // chat hud sizes $outerChatLenY[1] = 72; @@ -934,8 +937,12 @@ function updateActionMaps() moveMap.pop(); if (isObject(passengerKeys)) passengerKeys.pop(); - if (isObject(flyingCameraMove)) - flyingCameraMove.pop(); + if ( isObject( observerBlockMap ) ) + observerBlockMap.pop(); + if ( isObject( observerMap ) ) + observerMap.pop(); + //if (isObject(flyingCameraMove)) + // flyingCameraMove.pop(); if (isObject(ControlActionMap)) ControlActionMap.pop(); @@ -953,7 +960,18 @@ function updateActionMaps() ControlActionMap.push(); case "Observer": - flyingCameraMove.push(); + moveMap.push(); + if ( isObject( observerBlockMap ) ) + observerBlockMap.delete(); + // Create an action map just to block unwanted parts of the move map: + new ActionMap( observerBlockMap ); + observerBlockMap.blockBind( moveMap, jump ); + observerBlockMap.blockBind( moveMap, mouseJet ); + observerBlockMap.blockBind( moveMap, toggleZoom ); + observerBlockMap.blockBind( moveMap, setZoomFOV ); + observerBlockMap.push(); + observerMap.push(); + //flyingCameraMove.push(); case "PickTeam": // no mapping @@ -1237,19 +1255,33 @@ function clearHud(%msgType, %msgString, %tag, %a0) { for(%i = 0; %i < $Hud[%tag].numCol; %i++) { - $Hud[%tag].childGui.remove($Hud[%tag].data[%startingLine, %i]); - $Hud[%tag].data[%startingLine, %i] = ""; - } - - //don't forget to resize - if (%tag $= 'scoreScreen') - { - %prevExtent = $Hud[%tag].childGui.extent; - $Hud[%tag].childGui.extent = firstWord(%prevExtent) SPC (getWord(%prevExtent, 1) - 24); + //remove and delete the hud line + %obj = $Hud[%tag].data[%startingLine, %i]; + $Hud[%tag].childGui.remove(%obj); + $Hud[%tag].data[%startingLine, %i] = ""; + %obj.delete(); } %startingLine++; } + + //don't forget to adjust the size accordingly... + if (%tag $= 'scoreScreen') + { + %height = 0; + %guiCtrl = $Hud[%tag].childGui; + + //set the new extent to be the position + extent of the last element... + %height = 0; + if (%guiCtrl.getCount() > 0) + { + %lastCtrl = %guiCtrl.getObject(%guiCtrl.getCount() - 1); + %height = getWord(%lastCtrl.position, 1) + getWord(%lastCtrl.extent, 1); + } + + //now reset the extent + %guiCtrl.resize(getWord(%guiCtrl.position, 0), getWord(%guiCtrl.position, 1), getWord(%guiCtrl.extent, 0), %height); + } } //------------------------------------------------------------------------------ @@ -1264,11 +1296,22 @@ function removeLineHud(%msgType, %msgString, %hudName, %lineNumber, %a0, %a1, %a $Hud[%tag].data[%lineNum, %i] = ""; } - //don't forget to resize + //don't forget to adjust the size accordingly... if (%tag $= 'scoreScreen') { - %prevExtent = $Hud[%tag].childGui.extent; - $Hud[%tag].childGui.extent = firstWord(%prevExtent) SPC (getWord(%prevExtent, 1) - 24); + %height = 0; + %guiCtrl = $Hud[%tag].childGui; + + //set the new extent to be the position + extent of the last element... + %height = 0; + if (%guiCtrl.getCount() > 0) + { + %lastCtrl = %guiCtrl.getObject(%guiCtrl.getCount() - 1); + %height = getWord(%lastCtrl.position, 1) + getWord(%lastCtrl.extent, 1); + } + + //now reset the extent + %guiCtrl.resize(getWord(%guiCtrl.position, 0), getWord(%guiCtrl.position, 1), getWord(%guiCtrl.extent, 0), %height); } } @@ -1287,6 +1330,24 @@ function setLineHud(%msgType, %msgString, %hudName, %lineNumber, %a0, %a1, %a2, for(%i = 0; %i < $Hud[%tag].numCol; %i++) $Hud[%tag].data[%lineNum, %i].hudSetValue(detag(%a[%i]),detag(%a4)); + + //don't forget to adjust the size accordingly... + if (%tag $= 'scoreScreen') + { + %height = 0; + %guiCtrl = $Hud[%tag].childGui; + + //set the new extent to be the position + extent of the last element... + %height = 0; + if (%guiCtrl.getCount() > 0) + { + %lastCtrl = %guiCtrl.getObject(%guiCtrl.getCount() - 1); + %height = getWord(%lastCtrl.position, 1) + getWord(%lastCtrl.extent, 1); + } + + //now reset the extent + %guiCtrl.resize(getWord(%guiCtrl.position, 0), getWord(%guiCtrl.position, 1), getWord(%guiCtrl.extent, 0), %height); + } } //------------------------------------------------------------------------------ diff --git a/base/scripts/item.cs b/base/scripts/item.cs index 9106378..93eefae 100644 --- a/base/scripts/item.cs +++ b/base/scripts/item.cs @@ -333,6 +333,14 @@ function Flag::onAdd(%this, %obj) // make sure flags play "flapping" ambient thread Parent::onAdd(%this, %obj); %obj.playThread($AmbientThread, "ambient"); + + %blocker = new VehicleBlocker() + { + position = %obj.position; + rotation = %obj.rotation; + dimensions = "2 2 4"; + }; + MissionCleanup.add(%blocker); } function Flag::onCollision(%data,%obj,%col) diff --git a/base/scripts/joystickBind.cs b/base/scripts/joystickBind.cs index 1769d0b..59631bb 100644 --- a/base/scripts/joystickBind.cs +++ b/base/scripts/joystickBind.cs @@ -17,13 +17,12 @@ function joystickMoveY(%val) $mvBackwardAction = ( %val > 0.0 ); } -function joystickYaw(%val) +function joyYaw(%val) { - // Let the mapping system do all the scaling/inversion... - $mvYaw += %val; + $mvYaw += getMouseAdjustAmount( %val ); } -function joystickPitch(%val) +function joyPitch(%val) { - $mvPitch += %val; -} + $mvPitch += getMouseAdjustAmount( %val ); +} \ No newline at end of file diff --git a/base/scripts/loadingGui.cs b/base/scripts/loadingGui.cs index 35fb63e..e1ab1cc 100644 --- a/base/scripts/loadingGui.cs +++ b/base/scripts/loadingGui.cs @@ -19,6 +19,8 @@ function LoadingGui::onWake(%this) $HudHandle['shellScreen'] = ""; } $HudHandle['loadingScreen'] = alxPlay(LoadingScreenSound, 0, 0, 0); + + CloseMessagePopup(); } //------------------------------------------------------------------------------ diff --git a/base/scripts/objectiveHud.cs b/base/scripts/objectiveHud.cs index ddf430a..b7cef9d 100644 --- a/base/scripts/objectiveHud.cs +++ b/base/scripts/objectiveHud.cs @@ -103,7 +103,7 @@ function setupObjHud(%gameType) profile = "GuiTextObjGreenCenterProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "100 3"; + position = "105 3"; extent = "50 16"; visible = "1"; }; @@ -111,7 +111,7 @@ function setupObjHud(%gameType) profile = "GuiTextObjHudCenterProfile"; horizSizing = "right"; vertSizing = "bottom"; - position = "100 19"; + position = "105 19"; extent = "50 16"; visible = "1"; }; @@ -783,17 +783,6 @@ function cnhAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) objectiveHud.numHeld[%teamNum].setValue(%held); } -//addMessageCallback('MsgFlipFlopInit', hudFlipFlopInit); - -//function hudFlipFlopInit(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) -//{ -// %flipNum = detag(%a1); -// %flipName = Game.cleanWord(detag(%a2)); -// %status = detag(%a3); -// if(%flipName $= "") -// %flipname = "FlipFlop " @ %flipNum; -//} - addMessageCallback('MsgFlipFlopsHeld', hudFlipFlopsHeld); function hudFlipFlopsHeld(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) diff --git a/base/scripts/packs/repairpack.cs b/base/scripts/packs/repairpack.cs index 5415df2..a9c65c7 100644 --- a/base/scripts/packs/repairpack.cs +++ b/base/scripts/packs/repairpack.cs @@ -83,6 +83,12 @@ datablock ItemData(RepairPack) image = "RepairPackImage"; pickUpName = "a repair pack"; + lightOnlyStatic = true; + lightType = "PulsingLight"; + lightColor = "1 0 0 1"; + lightTime = 1200; + lightRadius = 4; + computeCRC = true; emap = true; }; diff --git a/base/scripts/packs/satchelCharge.cs b/base/scripts/packs/satchelCharge.cs index 03338fb..9c102d4 100644 --- a/base/scripts/packs/satchelCharge.cs +++ b/base/scripts/packs/satchelCharge.cs @@ -413,16 +413,18 @@ function SatchelChargeThrown::onDestroyed(%this, %object, %lastState) %dmgRadius = 10; %dmgMod = 0.3; %expImpulse = 1000; + %dmgType = $DamageType::Explosion; } else { - messageClient(%object.sourceObject.client, 'msgSatchelChargeDetonate', "\c2Satchel Charge Detonated!"); + messageClient(%object.sourceObject.client, 'msgSatchelChargeDetonate', "\c2Satchel charge detonated!"); %dmgRadius = 20; %dmgMod = 1.0; %expImpulse = 2500; + %dmgType = $DamageType::SatchelCharge; } - RadiusExplosion(%object, %object.getPosition(), %dmgRadius, %dmgMod, %expImpulse, %object.sourceObject, $DamageType::SatchelCharge); + RadiusExplosion(%object, %object.getPosition(), %dmgRadius, %dmgMod, %expImpulse, %object.sourceObject, %dmgType); %object.schedule(500, "delete"); } diff --git a/base/scripts/pathedObject.cs b/base/scripts/pathedObject.cs deleted file mode 100644 index b656eb0..0000000 --- a/base/scripts/pathedObject.cs +++ /dev/null @@ -1,78 +0,0 @@ -//-------------------------------------------------------------------------- -// Pathed objects: -// -// accept the following commands: -// goForward() -// goBackward() -// goToWaypoint(waypoint) -// doCollideReverse() -// -// respond to the following queries -// getNumWaypoints() -// -// generate the following events -// onTriggerTick -// onStop -// onCollide (For non-displacing objects only) -// -//-------------------------------------------------------------------------- - -datablock PathedObjectData(defaultPathFollow) -{ - displaceObjects = "false"; - reversalPauseMS = 1000; -}; - -datablock PathedObjectData(displaceOnCollision) -{ - displaceObjects = "true"; - reversalPauseMS = 1000; -}; - -function PathedObject::onTrigger(%this, %triggerId, %on) -{ - // Default behavior for a door: - // if triggered: go to open state (last waypoint) - // if untriggered: go to closed state (first waypoint) - - if (%on $= "true") { - %this.triggerCount++; - } else { - if (%this.triggerCount > 0) - %this.triggerCount--; - } - - if (%this.triggerCount > 0) - %this.goForward(); - else - %this.goBackward(); -} - -// Commented out functions are implemented in code for efficiency, placed here for -// parameter description... -// -//function PathedObject::onTriggerTick(%this, %triggerId) -//{ -// // Do nothing -//} -// -//function PathedObject::onStop(%this, %position) -//{ -// // Do nothing by default. -// // Possible values for %position: -// // Start -// // End -// // # (Waypoint number) -//} -// -//function PathedObject::onCollide(%this, %position) -//{ -// %myBlock = %this.getDataBlock(); -// -// if (%myBlock.displaceObjects) { -// error(%this @ ": displacing pathed objects should never call onCollide"); -// return; -// } -// -// %this.doCollideReverse(); -//}\ diff --git a/base/scripts/player.cs b/base/scripts/player.cs index 713cdbc..c336e23 100644 --- a/base/scripts/player.cs +++ b/base/scripts/player.cs @@ -1,4 +1,4 @@ -//---------------------------------------------------------------------------- + //---------------------------------------------------------------------------- //---------------------------------------------------------------------------- $InvincibleTime = 6; @@ -949,11 +949,11 @@ datablock SplashData(PlayerSplash) datablock ParticleData(HumanArmorJetParticle) { - dragCoefficient = 1.5; + dragCoefficient = 0.0; gravityCoefficient = 0; inheritedVelFactor = 0.2; constantAcceleration = 0.0; - lifetimeMS = 150; + lifetimeMS = 50; lifetimeVarianceMS = 0; textureName = "particleTest"; colors[0] = "0.32 0.47 0.47 1.0"; @@ -1160,7 +1160,10 @@ datablock PlayerData(LightMaleHumanArmor) : LightPlayerDamageProfile rechargeRate = 0.256; jetForce = 26.2 * 90; + underwaterJetForce = 26.2 * 90 * 2.0; + underwaterVertJetFactor = 1.5; jetEnergyDrain = 0.8; + underwaterJetEnergyDrain = 0.5; minJetEnergy = 1; maxJetHorizontalPercentage = 0.8; @@ -1171,6 +1174,11 @@ datablock PlayerData(LightMaleHumanArmor) : LightPlayerDamageProfile maxBackwardSpeed = 13; maxSideSpeed = 13; + maxUnderwaterForwardSpeed = 8.4; + maxUnderwaterBackwardSpeed = 7.8; + maxUnderwaterSideSpeed = 7.8; + + jumpForce = 8.3 * 90; jumpEnergyDrain = 0; minJumpEnergy = 0; @@ -1217,9 +1225,9 @@ datablock PlayerData(LightMaleHumanArmor) : LightPlayerDamageProfile splashEmitter[0] = PlayerFoamDropletsEmitter; splashEmitter[1] = PlayerFoamEmitter; splashEmitter[2] = PlayerBubbleEmitter; - mediumSplashSoundVelocity = 25.0; - hardSplashSoundVelocity = 35.0; - exitSplashSoundVelocity = 12.0; + mediumSplashSoundVelocity = 10.0; + hardSplashSoundVelocity = 20.0; + exitSplashSoundVelocity = 5.0; // Controls over slope of runnable/jumpable surfaces runSurfaceAngle = 70; @@ -1238,8 +1246,8 @@ datablock PlayerData(LightMaleHumanArmor) : LightPlayerDamageProfile upResistFactor = 0.3; // heat inc'ers and dec'ers - heatDecayPerSec = 1.0 / 6.0; // takes 6 seconds to clear heat sig. - heatIncreasePerSec = 1.0 / 3.0; // takes 3 seconds of constant jet to get full heat sig. + heatDecayPerSec = 1.0 / 3.0; // takes 3 seconds to clear heat sig. + heatIncreasePerSec = 1.0 / 3.0; // takes 3.0 seconds of constant jet to get full heat sig. footstepSplashHeight = 0.35; //Footstep Sounds @@ -1406,7 +1414,10 @@ datablock PlayerData(MediumMaleHumanArmor) : MediumPlayerDamageProfile rechargeRate = 0.256; jetForce = 24.6 * 130; + underwaterJetForce = 24.6 * 130 * 2.0; + underwaterVertJetFactor = 1.5; jetEnergyDrain = 1.0; + underwaterJetEnergyDrain = 0.5; minJetEnergy = 1; maxJetHorizontalPercentage = 0.8; @@ -1417,12 +1428,16 @@ datablock PlayerData(MediumMaleHumanArmor) : MediumPlayerDamageProfile maxBackwardSpeed = 10; maxSideSpeed = 10; + maxUnderwaterForwardSpeed = 6.6; + maxUnderwaterBackwardSpeed = 6; + maxUnderwaterSideSpeed = 6; + recoverDelay = 9; recoverRunForceScale = 1.2; // heat inc'ers and dec'ers - heatDecayPerSec = 1.0 / 6.0; // takes 6 seconds to clear heat sig. - heatIncreasePerSec = 1.0 / 3.0; // takes 3 seconds of constant jet to get full heat sig. + heatDecayPerSec = 1.0 / 3.0; // takes 3 seconds to clear heat sig. + heatIncreasePerSec = 1.0 / 3.0; // takes 3.0 seconds of constant jet to get full heat sig. jumpForce = 8.4 * 130; jumpEnergyDrain = 0; @@ -1484,9 +1499,9 @@ datablock PlayerData(MediumMaleHumanArmor) : MediumPlayerDamageProfile splashEmitter[0] = PlayerFoamDropletsEmitter; splashEmitter[1] = PlayerFoamEmitter; splashEmitter[2] = PlayerBubbleEmitter; - mediumSplashSoundVelocity = 25.0; - hardSplashSoundVelocity = 35.0; - exitSplashSoundVelocity = 12.0; + mediumSplashSoundVelocity = 10.0; + hardSplashSoundVelocity = 20.0; + exitSplashSoundVelocity = 5.0; footstepSplashHeight = 0.35; //Footstep Sounds @@ -1652,7 +1667,10 @@ datablock PlayerData(HeavyMaleHumanArmor) : HeavyPlayerDamageProfile rechargeRate = 0.256; jetForce = 21.4 * 180; + underwaterJetForce = 21.4 * 180 * 2.0; + underwaterVertJetFactor = 1.5; jetEnergyDrain = 1.1; + underwaterJetEnergyDrain = 0.55; minJetEnergy = 1; maxJetHorizontalPercentage = 0.8; @@ -1663,6 +1681,10 @@ datablock PlayerData(HeavyMaleHumanArmor) : HeavyPlayerDamageProfile maxBackwardSpeed = 5; maxSideSpeed = 5; + maxUnderwaterForwardSpeed = 3.9; + maxUnderwaterBackwardSpeed = 3; + maxUnderwaterSideSpeed = 3; + recoverDelay = 9; recoverRunForceScale = 1.2; @@ -1672,8 +1694,8 @@ datablock PlayerData(HeavyMaleHumanArmor) : HeavyPlayerDamageProfile jumpDelay = 0; // heat inc'ers and dec'ers - heatDecayPerSec = 1.0 / 6.0; // takes 6 seconds to clear heat sig. - heatIncreasePerSec = 1.0 / 3.0; // takes 3 seconds of constant jet to get full heat sig. + heatDecayPerSec = 1.0 / 3.0; // takes 3 seconds to clear heat sig. + heatIncreasePerSec = 1.0 / 3.0; // takes 3.0 seconds of constant jet to get full heat sig. // Controls over slope of runnable/jumpable surfaces runSurfaceAngle = 70; @@ -1728,9 +1750,9 @@ datablock PlayerData(HeavyMaleHumanArmor) : HeavyPlayerDamageProfile splashEmitter[0] = PlayerFoamDropletsEmitter; splashEmitter[1] = PlayerFoamEmitter; splashEmitter[2] = PlayerBubbleEmitter; - mediumSplashSoundVelocity = 25.0; - hardSplashSoundVelocity = 35.0; - exitSplashSoundVelocity = 12.0; + mediumSplashSoundVelocity = 10.0; + hardSplashSoundVelocity = 20.0; + exitSplashSoundVelocity = 5.0; footstepSplashHeight = 0.35; //Footstep Sounds @@ -2107,7 +2129,7 @@ function Armor::onCollision(%this,%obj,%col) return; } } - if(%col.getDataBlock().noEnemyControl && %obj.team != %col.team) + if(%col.noEnemyControl && %obj.team != %col.team) return; commandToClient(%obj.client,'SetDefaultVehicleKeys', true); @@ -2455,7 +2477,17 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am else if(isObject(%sourceObject) && %sourceObject.getClassName() $= "Turret") %sourceTeam = getTargetSensorGroup(%sourceObject.getTarget()); else - %sourceTeam = %sourceObject ? getTargetSensorGroup(%sourceObject.getTarget()) : -1; + { + if (%sourceObject && %sourceObject.getTarget() >= 0 ) + { + %sourceTeam = getTargetSensorGroup(%sourceObject.getTarget()); + } + else + { + %sourceTeam = -1; + } + } + // if teamdamage is off, and both parties are on the same team // (but are not the same person), apply no damage if(!$teamDamage && (%targetClient != %sourceClient) && (%targetTeam == %sourceTeam)) diff --git a/base/scripts/power.cs b/base/scripts/power.cs index d335bea..5b379f8 100644 --- a/base/scripts/power.cs +++ b/base/scripts/power.cs @@ -6,6 +6,8 @@ $DeployThread = 3; $HumSound = 0; $ActivateSound = 1; $DeploySound = 2; +$PlaySound = 3; + //****************************************************************************** //* Power -Audio- Data Blocks * //****************************************************************************** @@ -157,6 +159,8 @@ function GameBase::setSelfPowered(%this) if(!%this.isPowered()) { %this.selfPower = true; + if(%this.getDatablock().deployedObject) + %this.initDeploy = true; %this.getDataBlock().gainPower(%this); } else diff --git a/base/scripts/projectiles.cs b/base/scripts/projectiles.cs index 1bdcded..90799cb 100644 --- a/base/scripts/projectiles.cs +++ b/base/scripts/projectiles.cs @@ -303,7 +303,6 @@ function ShockLanceImage::onFire(%this, %obj, %slot) $TypeMasks::ForceFieldObjectType | $TypeMasks::StaticObjectType | $TypeMasks::MoveableObjectType | - $TypeMasks::PathedObjectType | $TypeMasks::DamagableItemObjectType; // did I miss anything? players, vehicles, stations, gens, sensors, turrets @@ -339,18 +338,17 @@ function ShockLanceImage::onFire(%this, %obj, %slot) if(%hitObj.getDataBlock().getClassName() $= "PlayerData") { // Now we see if we hit from behind... - %eyeVector = %hitobj.getEyeVector(); + %forwardVec = %hitobj.getForwardVector(); + %objDir2D = getWord(%forwardVec, 0) @ " " @ getWord(%forwardVec,1) @ " " @ "0.0"; + %objPos = %hitObj.getPosition(); + %dif = VectorSub(%objPos, %muzzlePos); + %dif = getWord(%dif, 0) @ " " @ getWord(%dif, 1) @ " 0"; + %dif = VectorNormalize(%dif); + %dot = VectorDot(%dif, %objDir2D); - %eyeXForm = %hitobj.getEyeTransform(); - %eyePos = getWord(%eyeXForm, 0) @ " " @ getWord(%eyeXForm, 1) @ " " @ getWord(%eyeXForm, 2); - %dif = VectorSub(%eyePos, %muzzlePos); - %dif = getWord(%dif, 0) @ " " @ getWord(%dif, 1) @ " 0"; - %dif = VectorNormalize(%dif); - %eyeVector = getWord(%eyeVector, 0) @ " " @ getWord(%eyeVector, 1) @ " 0"; - %dot = VectorDot(%dif, %eyeVector); - // 120 Deg angle test... - if (%dot > mCos(1.05)) { + // 1.05 == 60 degrees in radians + if (%dot >= mCos(1.05)) { // Rear hit %damageMultiplier = 3.0; } @@ -405,15 +403,31 @@ function ELFProjectileData::unzapTarget(%data, %projectile, %target, %targeter) } } +function ELFProjectileData::targetDestroyedCancel(%data, %projectile, %target, %targeter) +{ + cancel(%projectile.ELFrecur); + %target.stopAudio($ELFZapSound); + %targeter.stopAudio($ELFFireSound); + %target.zapSound = false; + %targeter.zappingSound = false; + %projectile.delete(); +} + function ELFProjectile::checkELFStatus(%this, %data, %target, %targeter) { if(isObject(%target)) { + if(%target.getDamageState() $= "Destroyed") + { + %data.targetDestroyedCancel(%this, %target, %targeter); + return; + } + %enLevel = %target.getEnergyLevel(); if(%enLevel < 1.0) { %dataBlock = %target.getDataBlock(); - %dataBlock.damageObject(%target, %this.sourceObject, %target.getPosition(), %data.drainHealth, %data.directDamageType); + %dataBlock.damageObject(%target, %this.sourceObject, %target.getPosition(), %data.drainHealth, %data.directDamageType); } else diff --git a/base/scripts/server.cs b/base/scripts/server.cs index 6b48cc3..d4a595a 100644 --- a/base/scripts/server.cs +++ b/base/scripts/server.cs @@ -49,7 +49,6 @@ function CreateServer(%mission, %missionType) exec("scripts/station.cs"); exec("scripts/simGroup.cs"); exec("scripts/trigger.cs"); - exec("scripts/pathedObject.cs"); exec("scripts/forceField.cs"); exec("scripts/lightning.cs"); exec("scripts/weather.cs"); @@ -78,7 +77,7 @@ function CreateServer(%mission, %missionType) $HostGamePlayerCount = 0; if ( $HostGameType !$= "SinglePlayer" ) allowConnections(true); - new SimGroup (ServerGroup); + $ServerGroup = new SimGroup (ServerGroup); if(%mission $= "") { %mission = $HostMissionFile[$HostMission[0,0]]; @@ -117,13 +116,48 @@ function CreateServer(%mission, %missionType) loadMission(%mission, %missionType, true); } +function findNextCycleMission() +{ + %numPlayers = ClientGroup.getCount(); + %tempMission = $CurrentMission; + %failsafe = 0; + while (1) + { + %nextMissionIndex = getNextMission(%tempMission, $CurrentMissionType); + %nextPotentialMission = $HostMissionFile[%nextMissionIndex]; + + //just cycle to the next if we've gone all the way around... + if (%nextPotentialMission $= $CurrentMission || %failsafe >= 1000) + { + %nextMissionIndex = getNextMission($CurrentMission, $CurrentMissionType); + return $HostMissionName[%nextMissionIndex]; + } + + //get the player count limits for this mission + %limits = $Host::MapPlayerLimits[%nextPotentialMission, $CurrentMissionType]; + if (%limits $= "") + return %nextPotentialMission; + else + { + %minPlayers = getWord(%limits, 0); + %maxPlayers = getWord(%limits, 1); + + if ((%minPlayers < 0 || %numPlayers >= %minPlayers) && (%maxPlayers < 0 || %numPlayers <= %maxPlayers)) + return %nextPotentialMission; + } + + //since we didn't return the mission, we must not have an acceptable number of players - check the next + %tempMission = %nextPotentialMission; + %failsafe++; + } +} + function CycleMissions() { echo( "cycling mission. " @ ClientGroup.getCount() @ " clients in game." ); - %nextMission = getNextMission($CurrentMission, $CurrentMissionType); - messageAll( 'MsgClient', 'Loading %1 (%2)...', %nextMission, $CurrentMissionType ); - - loadMission(%nextMission, $CurrentMissionType); + %nextMission = findNextCycleMission(); + messageAll( 'MsgClient', 'Loading %1 (%2)...', %nextMission, $MissionTypeDisplayName ); + loadMission( %nextMission, $CurrentMissionType ); } function DestroyServer() @@ -131,8 +165,8 @@ function DestroyServer() $missionRunning = false; allowConnections(false); stopHeartbeat(); - if(isObject(ServerGroup)) - ServerGroup.delete(); + if(isObject($ServerGroup)) + $ServerGroup.delete(); // delete all the connections: while(ClientGroup.getCount()) @@ -194,6 +228,8 @@ function DisconnectedCleanup() MusicPlayer.stop(); clearTextureHolds(); purgeResources(); + + IRCClient::onLeaveGame(); } function kick(%client, %admin) @@ -310,7 +346,7 @@ function GameConnection::onConnect( %client, %name, %raceGender, %skin, %voice, // Override the connect name if this server does not allow smurfs: %realName = getField( %authInfo, 0 ); - if ( $Host::NoSmurfs ) + if ( $PlayingOnline && $Host::NoSmurfs ) %name = %realName; if ( strcmp( %name, %realName ) == 0 ) @@ -439,7 +475,6 @@ function GameConnection::onConnect( %client, %name, %raceGender, %skin, %voice, // commandToClient(%client, 'getManagerID', %client); - commandToClient(%client, 'setVoiceCodec', $Audio::voiceCodec); commandToClient(%client, 'setBeaconNames', "Target Beacon", "Marker Beacon", "Bomb Target"); if ( $CurrentMissionType !$= "SinglePlayer" ) @@ -571,6 +606,8 @@ function loadMissionStage1(%missionName, %missionType, %firstMission) MissionCleanup.delete(); Game.deactivatePackages(); Game.delete(); + $ServerGroup.delete(); + $ServerGroup = new SimGroup(ServerGroup); } $CurrentMission = %missionName; @@ -1109,9 +1146,33 @@ function serverCmdClientTeamChange( %client ) } } +function serverCanAddBot() +{ + //find out how many bots are already playing + %botCount = 0; + %numClients = ClientGroup.getCount(); + for (%i = 0; %i < %numClients; %i++) + { + %cl = ClientGroup.getObject(%i); + if (%cl.isAIcontrolled()) + %botCount++; + } + + //add only if we have less bots than the bot count, and if there would still be room for a + if ($HostGameBotCount > 0 && %botCount < $Host::botCount && %numClients < $Host::maxPlayers - 1) + return true; + else + return false; +} + function serverCmdAddBot( %client ) { - aiConnectMultiple( 1, $Host::MinBotDifficulty, $Host::MaxBotDifficulty, -1 ); + //only admins can add bots... + if (%client.isAdmin) + { + if (serverCanAddBot()) + aiConnectMultiple( 1, $Host::MinBotDifficulty, $Host::MaxBotDifficulty, -1 ); + } } function serverCmdClientJoinTeam( %client, %team ) @@ -1257,7 +1318,7 @@ function serverCmdGetTeamList( %client, %key ) function serverCmdGetMissionTypes( %client, %key ) { for ( %type = 0; %type < $HostTypeCount; %type++ ) - messageClient( %client, 'MsgVoteItem', "", %key, %type, "", $HostTypeName[%type], true ); + messageClient( %client, 'MsgVoteItem', "", %key, %type, "", $HostTypeDisplayName[%type], true ); } function serverCmdGetMissionList( %client, %key, %type ) @@ -1267,16 +1328,17 @@ function serverCmdGetMissionList( %client, %key, %type ) for ( %i = $HostMissionCount[%type] - 1; %i >= 0; %i-- ) { + %idx = $HostMission[%type, %i]; + // If we have bots, don't change to a mission that doesn't support bots: if ( $HostGameBotCount > 0 ) { - if( !$BotEnabled[$HostMission[%type,%i]] ) + if( !$BotEnabled[%idx] ) continue; } - %idx = $HostMission[%type, %i]; messageClient( %client, 'MsgVoteItem', "", %key, - $HostMissionFile[%idx], // actual filename, will be stored in $clVoteCmd + %idx, // mission index, will be stored in $clVoteCmd "", $HostMissionName[%idx], true ); diff --git a/base/scripts/serverDefaults.cs b/base/scripts/serverDefaults.cs index 4c0d115..f0c3629 100644 --- a/base/scripts/serverDefaults.cs +++ b/base/scripts/serverDefaults.cs @@ -24,8 +24,7 @@ $holoName[6] = "Harbinger"; $Host::AdminList = ""; // all players that will be automatically an admin upon joining server $Host::SuperAdminList = ""; // all players that will be automatically a super admin upon joining server -$Host::BindAddress = ""; // set to an ip address if the server wants to specify which NIC/IP to use -$Host::RulesSet = "Base"; +$Host::BindAddress = ""; // set to an ip address if the server wants to specify which NIC/IP to use $Host::Port = 28000; $Host::GameName = "Tribes 2 Server"; $Host::Password = ""; @@ -54,4 +53,64 @@ $Host::MaxMessageLen = 120; $MasterServerAddress = "IP:198.74.40.152:28000"; -$Audio::voiceCodec = ".v12"; // .v12 (1.2 kbits/sec), .v24 (2.4 kbits/sec), .v29 (2.9kbits/sec) +// 0: .v12 (1.2 kbits/sec), 1: .v24 (2.4 kbits/sec), 2: .v29 (2.9kbits/sec) +$Audio::maxEncodingLevel = 2; +$Audio::maxVoiceChannels = 2; + +$Host::MapPlayerLimits["Abominable", "CnH"] = "-1 32"; +$Host::MapPlayerLimits["AgentsOfFortune", "TeamHunters"] = "-1 32"; +$Host::MapPlayerLimits["Archipelago", "CTF"] = "16 -1"; +$Host::MapPlayerLimits["AshesToAshes", "CnH"] = "16 -1"; +$Host::MapPlayerLimits["BeggarsRun", "CTF"] = "-1 16"; +$Host::MapPlayerLimits["CasernCavite", "Hunters"] = "-1 32"; +$Host::MapPlayerLimits["CasernCavite", "DM"] = "-1 32"; +$Host::MapPlayerLimits["CasernCavite", "Bounty"] = "-1 24"; +$Host::MapPlayerLimits["Damnation", "CTF"] = "-1 32"; +$Host::MapPlayerLimits["DeathBirdsFly", "CTF"] = "32 -1"; +$Host::MapPlayerLimits["Desiccator", "CTF"] = "16 -1"; +$Host::MapPlayerLimits["DustToDust", "CTF"] = "-1 24"; +$Host::MapPlayerLimits["DustToDust", "Hunters"] = "-1 32"; +$Host::MapPlayerLimits["DustToDust", "TeamHunters"] = "-1 32"; +$Host::MapPlayerLimits["Equinox", "CnH"] = "-1 32"; +$Host::MapPlayerLimits["Equinox", "DM"] = "-1 32"; +$Host::MapPlayerLimits["Escalade", "Hunters"] = "16 -1"; +$Host::MapPlayerLimits["Escalade", "TeamHunters"] = "16 -1"; +$Host::MapPlayerLimits["Escalade", "DM"] = "16 -1"; +$Host::MapPlayerLimits["Escalade", "Bounty"] = "16 32"; +$Host::MapPlayerLimits["Escalade", "Rabbit"] = "16 -1"; +$Host::MapPlayerLimits["Firestorm", "CTF"] = "-1 24"; +$Host::MapPlayerLimits["Firestorm", "CnH"] = "-1 24"; +$Host::MapPlayerLimits["Flashpoint", "CnH"] = "16 -1"; +$Host::MapPlayerLimits["Gehenna", "Hunters"] = "16 -1"; +$Host::MapPlayerLimits["Gehenna", "TeamHunters"] = "16 -1"; +$Host::MapPlayerLimits["Insalubria", "CnH"] = "-1 32"; +$Host::MapPlayerLimits["JacobsLadder", "CnH"] = "-1 32"; +$Host::MapPlayerLimits["Katabatic", "CTF"] = "-1 24"; +$Host::MapPlayerLimits["Masada", "Siege"] = "-1 16"; +$Host::MapPlayerLimits["Minotaur", "CTF"] = "-1 24"; +$Host::MapPlayerLimits["Myrkwood", "Hunters"] = "-1 16"; +$Host::MapPlayerLimits["Myrkwood", "DM"] = "-1 16"; +$Host::MapPlayerLimits["Myrkwood", "Rabbit"] = "-1 24"; +$Host::MapPlayerLimits["Oasis", "DM"] = "-1 16"; +$Host::MapPlayerLimits["Overreach", "CnH"] = "16 -1"; +$Host::MapPlayerLimits["Quagmire", "CTF"] = "16 -1"; +$Host::MapPlayerLimits["Rasp", "TeamHunters"] = "-1 32"; +$Host::MapPlayerLimits["Rasp", "Bounty"] = "-1 24"; +$Host::MapPlayerLimits["Recalescence", "CTF"] = "16 -1"; +$Host::MapPlayerLimits["Reversion", "CTF"] = "-1 32"; +$Host::MapPlayerLimits["Rimehold", "Hunters"] = "16 -1"; +$Host::MapPlayerLimits["Rimehold", "Hunters"] = "16 -1"; +$Host::MapPlayerLimits["Riverdance", "CTF"] = "8 32"; +$Host::MapPlayerLimits["Sanctuary", "CTF"] = "-1 32"; +$Host::MapPlayerLimits["Sirocco", "CnH"] = "16 -1"; +$Host::MapPlayerLimits["Slapdash", "CTF"] = "16 -1"; +$Host::MapPlayerLimits["SunDried", "DM"] = "16 -1"; +$Host::MapPlayerLimits["SunDried", "Bounty"] = "16 -1"; +$Host::MapPlayerLimits["Talus", "Bounty"] = "-1 24"; +$Host::MapPlayerLimits["ThinIce", "CTF"] = "-1 32"; +$Host::MapPlayerLimits["Tombstone", "CTF"] = "8 32"; +$Host::MapPlayerLimits["UltimaThule", "CTF"] = "-1 -1"; +$Host::MapPlayerLimits["Underhill", "DM"] = "16 -1"; +$Host::MapPlayerLimits["Underhill", "Bounty"] = "-1 24"; +$Host::MapPlayerLimits["Whiteout", "DM"] = "16 -1"; +$Host::MapPlayerLimits["Whiteout", "Bounty"] = "16 -1"; diff --git a/base/scripts/staticShape.cs b/base/scripts/staticShape.cs index 48b2a4f..6510120 100644 --- a/base/scripts/staticShape.cs +++ b/base/scripts/staticShape.cs @@ -11,7 +11,18 @@ function StaticShapeData::onGainPowerEnabled(%data, %obj) %obj.schedule(750, "playThread", $PowerThread, "Power"); else %obj.playThread($PowerThread,"Power"); - %obj.setRechargeRate(%data.rechargeRate); + // deployable objects get their recharge rate set right away -- don't set it again unless + // the object has just been re-enabled + if(%obj.initDeploy) + %obj.initDeploy = false; + else + { + if(%obj.getRechargeRate() <= 0) + { + %oldERate = %obj.getRechargeRate(); + %obj.setRechargeRate(%oldERate + %data.rechargeRate); + } + } if(%data.humSound !$= "") %obj.playAudio($HumSound, %data.humSound); %obj.setPoweredState(true); diff --git a/base/scripts/station.cs b/base/scripts/station.cs index 7e4440e..fcbc1e9 100644 --- a/base/scripts/station.cs +++ b/base/scripts/station.cs @@ -332,7 +332,7 @@ function StationInventory::getSound(%data, %forward) function StationInventory::setPlayersPosition(%data, %obj, %trigger, %colObj) { %vel = getWords(%colObj.getVelocity(), 0, 1) @ " 0"; - if((VectorLen(%vel) < 17) && (%obj.triggeredBy != %colObj)) + if((VectorLen(%vel) < 22) && (%obj.triggeredBy != %colObj)) { %pos = %trigger.position; %colObj.setvelocity("0 0 0"); @@ -428,7 +428,7 @@ function StationVehicle::getSound(%data, %forward) function StationVehicle::setPlayersPosition(%data, %obj, %trigger, %colObj) { %vel = getWords(%colObj.getVelocity(), 0, 1) @ " 0"; - if((VectorLen(%vel) < 17) && (%obj.triggeredBy != %colObj)) + if((VectorLen(%vel) < 22) && (%obj.triggeredBy != %colObj)) { %posXY = getWords(%trigger.getTransform(),0 ,1); %posZ = getWord(%trigger.getTransform(), 2); @@ -473,30 +473,21 @@ function StationVehiclePad::onAdd(%this, %obj) %sv.trigger.disableObj = %sv; //Remove unwanted vehicles - if(%obj.scoutVehicle $= "Removed") - { } - else - %sv.vehicle[scoutvehicle] = true; - if(%obj.assaultVehicle $= "Removed") - { } - else - %sv.vehicle[assaultVehicle] = true; - if(%obj.mobileBaseVehicle $= "Removed") - { } - else - %sv.vehicle[mobileBasevehicle] = true; - if(%obj.scoutFlyer $= "Removed") - { } - else - %sv.vehicle[scoutFlyer] = true; - if(%obj.bomberFlyer $= "Removed") - { } - else - %sv.vehicle[bomberFlyer] = true; - if(%obj.hapcFlyer $= "Removed") - { } - else - %sv.vehicle[hapcFlyer] = true; + if(%obj.scoutVehicle !$= "Removed") + %sv.vehicle[scoutvehicle] = true; + if(%obj.assaultVehicle !$= "Removed") + %sv.vehicle[assaultVehicle] = true; + if(%obj.mobileBaseVehicle !$= "Removed") + { + %sv.vehicle[mobileBasevehicle] = true; +// createTeleporter(%sv.getDataBlock(), %sv); + } + if(%obj.scoutFlyer !$= "Removed") + %sv.vehicle[scoutFlyer] = true; + if(%obj.bomberFlyer !$= "Removed") + %sv.vehicle[bomberFlyer] = true; + if(%obj.hapcFlyer !$= "Removed") + %sv.vehicle[hapcFlyer] = true; } function StationVehiclePad::onEndSequence(%data, %obj, %thread) @@ -606,7 +597,7 @@ function MobileInvStation::getSound(%data, %forward) function MobileInvStation::setPlayersPosition(%data, %obj, %trigger, %colObj) { %vel = getWords(%colObj.getVelocity(), 0, 1) @ " 0"; - if((VectorLen(%vel) < 17) && (%obj.triggeredBy != %colObj)) + if((VectorLen(%vel) < 22) && (%obj.triggeredBy != %colObj)) { %pos = %trigger.position; %colObj.setvelocity("0 0 0"); @@ -708,8 +699,10 @@ function stationTrigger::onLeaveTrigger(%data, %obj, %colObj) %obj.station.getDataBlock().endRepairing(%obj.station); %obj.station.triggeredBy = ""; %obj.station.getDataBlock().stationTriggered(%obj.station, 0); - %colObj.station = ""; - if(%colObj.getMountedImage($WeaponSlot) == 0) + + if(!%colObj.teleporting) + %colObj.station = ""; + if(%colObj.getMountedImage($WeaponSlot) == 0 && !%colObj.teleporting) { if(%colObj.inv[%colObj.lastWeapon]) %colObj.use(%colObj.lastWeapon); @@ -732,30 +725,35 @@ function stationTrigger::onLeaveTrigger(%data, %obj, %colObj) //////////////////////////////////////////////////////////////////////////////// function Station::stationTriggered(%data, %obj, %isTriggered) { - if(%isTriggered) - { - %obj.setThreadDir($ActivateThread, TRUE); - %obj.playThread($ActivateThread,"activate"); - %obj.playAudio($ActivateSound, %data.getSound(true)); - %obj.inUse = "Up"; - } - else - { - if(%obj.getDataBlock().getName() !$= StationVehicle) + if(%data.teleporter $= "") + { + if(%isTriggered) { - %obj.stopThread($ActivateThread); - if(%obj.getObjectMount()) - %obj.getObjectMount().stopThread($ActivateThread); - %obj.inUse = "Down"; + %obj.setThreadDir($ActivateThread, TRUE); + %obj.playThread($ActivateThread,"activate"); + %obj.playAudio($ActivateSound, %data.getSound(true)); + %obj.inUse = "Up"; } else { - %obj.setThreadDir($ActivateThread, FALSE); - %obj.playThread($ActivateThread,"activate"); - %obj.playAudio($ActivateSound, %data.getSound(false)); - %obj.inUse = "Down"; - } + if(%obj.getDataBlock().getName() !$= StationVehicle) + { + %obj.stopThread($ActivateThread); + if(%obj.getObjectMount()) + %obj.getObjectMount().stopThread($ActivateThread); + %obj.inUse = "Down"; + } + else + { + %obj.setThreadDir($ActivateThread, FALSE); + %obj.playThread($ActivateThread,"activate"); + %obj.playAudio($ActivateSound, %data.getSound(false)); + %obj.inUse = "Down"; + } + } } + else + %data.tryTeleport(%obj); } ////-Station-/////////////////////////////////////////////////////////////////// @@ -899,7 +897,7 @@ function DeployedStationInventory::stationFinished(%data, %obj) function DeployedStationInventory::setPlayersPosition(%data, %obj, %trigger, %colObj) { %vel = getWords(%colObj.getVelocity(), 0, 1) @ " 0"; - if((VectorLen(%vel) < 17) && (%obj.triggeredBy != %colObj)) + if((VectorLen(%vel) < 22) && (%obj.triggeredBy != %colObj)) { // build offset for player position %yrot = getWords(VectorOrthoBasis( getWords( %obj.getTransform(), 3, 6 ) ) ,3 ,5); @@ -943,3 +941,333 @@ function DeployedStationInventory::getSound(%data, %forward) else return false; } + + +//////////////////////////////////////////////////////////////////////////////// +/// -Mobile Base Teleporter DATA- ////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// + +datablock AudioProfile(StationTeleportAcitvateSound) +{ + filename = "fx/powered/vehicle_screen_on2.wav"; + description = AudioClosest3d; + preload = true; + effect = StationVehicleAcitvateEffect; +}; + +datablock AudioProfile(StationTeleportHumSound) +{ + filename = "fx/powered/station_hum.wav"; + description = CloseLooping3d; + preload = true; +}; + +datablock AudioProfile(StationTeleportDeactivateSound) +{ + filename = "fx/powered/vehicle_screen_off.wav"; + description = AudioClose3d; + preload = true; + effect = StationVehicleDeactivateEffect; +}; + +datablock AudioProfile(TeleportSound) +{ + filename = "fx/powered/vehicle_screen_on2.wav"; + description = AudioClosest3d; + preload = true; + effect = StationVehicleAcitvateEffect; +}; + +datablock AudioProfile(UnTeleportSound) +{ + filename = "fx/powered/vehicle_screen_off.wav"; + description = AudioClose3d; + preload = true; + effect = StationVehicleDeactivateEffect; +}; + +datablock StaticShapeData(MPBTeleporter) : StaticShapeDamageProfile +{ + className = Station; + catagory = "Stations"; + shapeFile = "station_teleport.dts"; + maxDamage = 1.20; + destroyedLevel = 1.20; + disabledLevel = 0.84; + explosion = ShapeExplosion; + expDmgRadius = 10.0; + expDamage = 0.4; + expImpulse = 1500.0; + dynamicType = $TypeMasks::StationObjectType; + isShielded = true; + energyPerDamagePoint = 33; + maxEnergy = 250; + rechargeRate = 0.31; + humSound = StationTeleportHumSound; + // don't let these be damaged in Siege missions + noDamageInSiege = true; + + cmdCategory = "Support"; + cmdIcon = CMDVehicleStationIcon; + cmdMiniIconName = "commander/MiniIcons/com_vehicle_pad_inventory"; + targetTypeTag = 'Teleport Station'; + teleporter = 1; +}; + +//////////////////////////////////////////////////////////////////////////////// +/// -Mobile Base Teleport- ///////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// + +/// -Mobile Base- ////////////////////////////////////////////////////////////// +//Function -- onAdd (%this, %obj) +// %this = Object data block +// %obj = Object being added +//Decription -- Called when the object is added to the mission +//////////////////////////////////////////////////////////////////////////////// +function MPBTeleporter::onAdd(%this, %obj) +{ + Parent::onAdd(%this, %obj); +} + +function MPBTeleporter::createTrigger(%this, %obj) +{ +// createTarget(%obj, 'Inventory Station', "", "", 'Station', 0, 0); + + %obj.setRechargeRate(%obj.getDatablock().rechargeRate); + %trigger = new Trigger() + { + dataBlock = stationTrigger; + polyhedron = "-0.75 0.75 0.1 1.5 0.0 0.0 0.0 -1.5 0.0 0.0 0.0 2.3"; + }; + MissionCleanup.add(%trigger); + %trigger.setTransform(%obj.getTransform()); + + %trigger.station = %obj; + %trigger.mainObj = %obj.vStation; + %trigger.disableObj = %obj; + + %obj.trigger = %trigger; +} + +/// -Mobile Base- ////////////////////////////////////////////////////////////// +//Function -- stationReady(%data, %obj) +// %data = Station Data Block +// %obj = Station Object +//Decription -- Called when station has been triggered and animation is +// completed +//////////////////////////////////////////////////////////////////////////////// +function MPBTeleporter::stationReady(%data, %obj) +{ + //Display the Inventory Station GUI here + %obj.notReady = 1; + %obj.inUse = "Down"; + %obj.schedule(200,"playThread",$ActivateThread,"activate1"); + %obj.getObjectMount().playThread($ActivateThread,"Activate"); + %player = %obj.triggeredBy; + %energy = %player.getEnergyLevel(); + %player.setCloaked(true); + %player.schedule(900, "setCloaked", false); + if (!%player.client.isAIControlled()) + buyFavorites(%player.client); + + %player.setEnergyLevel(%energy); +} + +/// -Mobile Base- ////////////////////////////////////////////////////////////// +//Function -- stationFinished(%data, %obj) +// %data = Station Data Block +// %obj = Station Object +//Decription -- Called when player has left the station +//////////////////////////////////////////////////////////////////////////////// +function MPBTeleporter::stationFinished(%data, %obj) +{ + //Hide the Inventory Station GUI +} + +/// -Mobile Base- ////////////////////////////////////////////////////////////// +//Function -- getSound(%data, %forward) +// %data = Station Data Block +// %forward = direction the animation is playing +//Decription -- This sound will be played at the same time as the activate +// animation. +//////////////////////////////////////////////////////////////////////////////// +function MPBTeleporter::getSound(%data, %forward) +{ + if(%forward) + return "MobileBaseInventoryActivateSound"; + else + return false; +} + +/// -Mobile Base- ////////////////////////////////////////////////////////////// +//Function -- setPlayerPosition(%data, %obj, %trigger, %colObj) +// %data = Station Data Block +// %obj = Station Object +// %trigger = Stations trigger +// %colObj = Object that is at the station +//Decription -- Called when player enters the trigger. Used to set the player +// in the center of the station. +//////////////////////////////////////////////////////////////////////////////// +function MPBTeleporter::setPlayersPosition(%data, %obj, %trigger, %colObj) +{ + %vel = getWords(%colObj.getVelocity(), 0, 1) @ " 0"; + if((VectorLen(%vel) < 22) && (%obj.triggeredBy != %colObj)) + { + %pos = %trigger.position; + %colObj.setvelocity("0 0 0"); + %rot = getWords(%colObj.getTransform(),3, 6); + %colObj.setTransform(getWord(%pos,0) @ " " @ getWord(%pos,1) @ " " @ getWord(%pos,2)+0.8 @ " " @ %rot);//center player on object + %colObj.setvelocity("0 0 0"); + return true; + } + return false; +} + +function MPBTeleporter::tryTeleport(%data, %obj) +{ + if(isObject(%obj.MPB) && %obj.MPB.fullyDeployed && %obj.triggeredBy !$= "") + { + %trans = %obj.MPB.getTransform(); + %vX = getWord(%trans, 0); + %vY = getWord(%trans, 1); + %vZ = getWord(%trans, 2); + %rot= getWords(%trans, 3,6); + + %obj.triggeredBy.teleporting = 1; + %obj.triggeredBy.startFade( 1000, 0, true ); + %obj.triggeredBy.playAudio($PlaySound, TeleportSound); + %obj.triggeredBy.setMoveState(true); + %data.schedule(4500,"teleportingDone", %obj.triggeredBy); + + %data.schedule(2000, "teleportout", %obj, %obj.triggeredBy, %vX @ " " @ %vY @ " " @ %vZ + 3 @ " " @ %rot); + + } + else if(%obj.triggeredBy !$= "") + MessageClient(%obj.triggeredBy.client, "", 'MPB is not deployed.'); +} + + +function MPBTeleporter::onEndSequence(%data, %obj, %thread) +{ +} + +function MPBTeleporter::teleportOut(%data, %obj, %player, %trans) +{ + if(isObject(%obj.MPB)) + { + %index = -1; + for(%x=0; %x < %obj.MPB.spawnPosCount; %x++) + { + %index = mFloor(getRandom() * %obj.MPB.spawnPosCount); + + InitContainerRadiusSearch(%MPB.spawnPos[%index], 2, $TypeMasks::MoveableObjectType); + if(ContainerSearchNext() == 0) + break; + else + %index = -1; + } + + if(%index >= 0) + %player.setTransform(%obj.MPB.spawnPos[%index] @ " " @ getWords(%obj.MPB.getTransform(), 3, 6)); + else + { + messageClient(%player.client, "", 'No Valid teleporting positions.'); + %player.teleporting = 0; + } + } + else + { + messageClient(%player.client, "", 'No Valid teleporting positions because MPB was destroyed'); + %player.teleporting = 0; + } + %data.schedule(1000, "teleportIn", %player); +} + +function MPBTeleporter::teleportIn(%data, %player, %trans) +{ + %player.startFade(1000, 0, false ); + %player.playAudio($PlaySound, UnTeleportSound); +} + +function MPBTeleporter::teleportingDone(%data, %player) +{ + %player.setMoveState(false); + %player.teleporting = 0; + %player.station = ""; + if(%player.getMountedImage($WeaponSlot) == 0) + { + if(%player.inv[%player.lastWeapon]) + %player.use(%player.lastWeapon); + + if(%player.getMountedImage($WeaponSlot) == 0) + %player.selectWeaponSlot( 0 ); + } +} + +for(%y = -1; %y < 1; %y += 0.25) +{ + %xCount=0; + for(%x = -1; %x < 1; %x += 0.25) + { + $MPBSpawnPos[(%yCount * 8) + %xCount] = %x @ " " @ %y; + %xCount++; + } + %yCount++; +} + +function checkSpawnPos(%MPB, %radius) +{ + %count = -1; + for(%x = 0; %x < 64; %x++) + { + %pPos = getWords(%MPB.getTransform(), 0, 2); + %pPosX = getWord(%pPos, 0); + %pPosY = getWord(%pPos, 1); + %pPosZ = getWord(%pPos, 2); + + %posX = %pPosX + ( getWord($MPBSpawnPos[%x],0) * %radius); + %posY = %pPosY + (getWord($MPBSpawnPos[%x],1) * %radius); + + %terrHeight = getTerrainHeight(%posX @ " " @ %posY); + + if(abs(%terrHeight - %pPosZ) < %radius ) + { + %mask = $TypeMasks::VehicleObjectType | $TypeMasks::MoveableObjectType | + $TypeMasks::StaticShapeObjectType | $TypeMasks::StaticTSObjectType | + $TypeMasks::ForceFieldObjectType | $TypeMasks::ItemObjectType | + $TypeMasks::PlayerObjectType | $TypeMasks::TurretObjectType | + $TypeMasks::InteriorObjectType; + + InitContainerRadiusSearch(%posX @ " " @ %posY @ " " @ %terrHeight, 2, %mask); + if(ContainerSearchNext() == 0) + %MPB.spawnPos[%count++] = %posX @ " " @ %posY @ " " @ %terrHeight; + } + } + %MPB.spawnPosCount = %count; +} + +function createTeleporter(%data, %obj) +{ + %Teleporter = new StaticShape() { + scale = "1 1 1"; + dataBlock = "MPBTeleporter"; + lockCount = "0"; + homingCount = "0"; + team = %obj.team; + }; + %obj.teleporter = %Teleporter; + %Teleporter.vStation = %obj.pad; + MissionCleanup.add(%Teleporter); + + %trans = %obj.getTransform(); + %vSPos = getWords(%trans,0,2); + %vRot = getWords(%trans,3,5); + %vAngle = getWord(%trans,6); + %matrix = VectorOrthoBasis(%vRot @ " " @ %vAngle + 0.36); + %yRot = getWords(%matrix, 3, 5); + %pos = vectorAdd(%vSPos, vectorScale(%yRot, -31.5)); + + %Teleporter.setTransform(%pos @ " " @ %vRot @ " " @ %vAngle); + %Teleporter.getDataBlock().createTrigger(%Teleporter); +} + diff --git a/base/scripts/turrets/aaBarrelLarge.cs b/base/scripts/turrets/aaBarrelLarge.cs index 31db32c..444819b 100644 --- a/base/scripts/turrets/aaBarrelLarge.cs +++ b/base/scripts/turrets/aaBarrelLarge.cs @@ -164,7 +164,7 @@ datablock TurretImageData(AABarrelLarge) seekRadius = 200; maxSeekAngle = 6; seekTime = 1.0; - minSeekHeat = 0.5; + minSeekHeat = 0.7; useTargetAudio = false; // Turret parameters diff --git a/base/scripts/turrets/indoorDeployableBarrel.cs b/base/scripts/turrets/indoorDeployableBarrel.cs index 1ed5a57..0c11760 100644 --- a/base/scripts/turrets/indoorDeployableBarrel.cs +++ b/base/scripts/turrets/indoorDeployableBarrel.cs @@ -65,6 +65,8 @@ datablock TurretData(TurretDeployedFloorIndoor) : TurretDamageProfile heatSignature = 0.0; explosion = SmallTurretExplosion; + deployedObject = true; + thetaMin = 5; thetaMax = 145; thetaNull = 90; diff --git a/base/scripts/turrets/missileBarrelLarge.cs b/base/scripts/turrets/missileBarrelLarge.cs index b198d83..cd1a381 100644 --- a/base/scripts/turrets/missileBarrelLarge.cs +++ b/base/scripts/turrets/missileBarrelLarge.cs @@ -60,15 +60,15 @@ datablock SeekerProjectileData(TurretMissile) puffEmitter = MissilePuffEmitter; lifetimeMS = 20000; - muzzleVelocity = 65.0; - turningSpeed = 40.0; + muzzleVelocity = 80.0; + turningSpeed = 90.0; proximityRadius = 4; - terrainAvoidanceSpeed = 140; - terrainScanAhead = 30; - terrainHeightFail = 18; - terrainAvoidanceRadius = 60; + terrainAvoidanceSpeed = 180; + terrainScanAhead = 25; + terrainHeightFail = 12; + terrainAvoidanceRadius = 100; useFlechette = true; flechetteDelayMs = 550; @@ -93,14 +93,14 @@ datablock TurretImageData(MissileBarrelLarge) isSeeker = true; seekRadius = 300; maxSeekAngle = 30; - seekTime = 1.5; + seekTime = 1.0; minSeekHeat = 0.7; emap = true; minTargetingDistance = 40; // Turret parameters - activationMS = 3000; - deactivateDelayMS = 2500; + activationMS = 500; + deactivateDelayMS = 1000; thinkTimeMS = 200; degPerSecTheta = 580; degPerSecPhi = 1080; diff --git a/base/scripts/turrets/outdoorDeployableBarrel.cs b/base/scripts/turrets/outdoorDeployableBarrel.cs index 68f4a3f..890d762 100644 --- a/base/scripts/turrets/outdoorDeployableBarrel.cs +++ b/base/scripts/turrets/outdoorDeployableBarrel.cs @@ -112,7 +112,7 @@ datablock TurretData(TurretDeployedOutdoor) : TurretDamageProfile className = DeployedTurret; shapeFile = "turret_outdoor_deploy.dts"; - rechargeRate = 0.05; + rechargeRate = 0.15; mass = 5.0; maxDamage = 0.80; @@ -120,6 +120,8 @@ datablock TurretData(TurretDeployedOutdoor) : TurretDamageProfile disabledLevel = 0.35; repairRate = 0; explosion = HandGrenadeExplosion; + + deployedObject = true; thetaMin = 0; thetaMax = 145; @@ -130,7 +132,6 @@ datablock TurretData(TurretDeployedOutdoor) : TurretDamageProfile maxEnergy = 60; renderWhenDestroyed = false; barrel = DeployableOutdoorBarrel; - rechargeRate = 0.25; heatSignature = 0; canControl = true; diff --git a/base/scripts/vehicles/serverVehicleHud.cs b/base/scripts/vehicles/serverVehicleHud.cs index 634f34e..949a64c 100644 --- a/base/scripts/vehicles/serverVehicleHud.cs +++ b/base/scripts/vehicles/serverVehicleHud.cs @@ -121,6 +121,12 @@ function createVehicle(%client, %station, %blockName, %team , %pos, %rot, %angle %obj = %blockName.create(%team); if(%obj) { + if ( %blockName $= "MobileBaseVehicle" ) + { + %station.station.teleporter.MPB = %obj; + %obj.teleporter = %station.station.teleporter; + } + %station.ready = false; %obj.team = %team; %obj.useCreateHeight(true); diff --git a/base/scripts/vehicles/vehicle.cs b/base/scripts/vehicles/vehicle.cs index 499e3e5..1a699a8 100644 --- a/base/scripts/vehicles/vehicle.cs +++ b/base/scripts/vehicles/vehicle.cs @@ -200,6 +200,7 @@ function VehicleData::onLeaveLiquid(%data, %obj, %type) function VehicleData::onDestroyed(%data, %obj, %prevState) { + radiusVehicleExplosion(%data, %obj); if(%obj.turretObject) if(%obj.turretObject.getControllingClient()) %obj.turretObject.getDataBlock().playerDismount(%obj.turretObject); @@ -219,6 +220,79 @@ function VehicleData::onDestroyed(%data, %obj, %prevState) %obj.schedule(300, "delete"); } +function radiusVehicleExplosion(%data, %vehicle) +{ + // this is a modified version of RadiusExplosion() from projectiles.cs + %position = %vehicle.getPosition(); + InitContainerRadiusSearch(%position, %data.explosionRadius, $TypeMasks::PlayerObjectType | + $TypeMasks::VehicleObjectType | + $TypeMasks::MoveableObjectType | + $TypeMasks::StaticShapeObjectType | + $TypeMasks::ForceFieldObjectType | + $TypeMasks::TurretObjectType | + $TypeMasks::ItemObjectType); + + %numTargets = 0; + while ((%targetObject = containerSearchNext()) != 0) + { + if(%targetObject == %vehicle) + continue; + + %dist = containerSearchCurrRadDamageDist(); + + if (%dist > %data.explosionRadius) + continue; + + if (%targetObject.isMounted()) + { + %mount = %targetObject.getObjectMount(); + if(%mount == %vehicle) + continue; + + %found = -1; + for (%i = 0; %i < %mount.getDataBlock().numMountPoints; %i++) + { + if (%mount.getMountNodeObject(%i) == %targetObject) + { + %found = %i; + break; + } + } + + if (%found != -1) + { + if (%mount.getDataBlock().isProtectedMountPoint[%found] && (%mount != %vehicle)) + continue; + } + } + + %targets[%numTargets] = %targetObject; + %targetDists[%numTargets] = %dist; + %numTargets++; + } + + for (%i = 0; %i < %numTargets; %i++) + { + %targetObject = %targets[%i]; + %dist = %targetDists[%i]; + + %coverage = calcExplosionCoverage(%position, %targetObject, + ($TypeMasks::InteriorObjectType | + $TypeMasks::TerrainObjectType | + $TypeMasks::ForceFieldObjectType)); + if (%coverage == 0) + continue; + + %amount = (1.0 - (%dist / %data.explosionRadius)) * %coverage * %data.explosionDamage; + %targetData = %targetObject.getDataBlock(); + + %momVec = "0 0 1"; + + if(%amount > 0) + %targetData.damageObject(%targetObject, %sourceObject, %position, %amount, $DamageType::Explosion, %momVec); + } +} + function VehicleData::deleteAllMounted() { @@ -396,6 +470,10 @@ function MobileBaseVehicle::deleteAllMounted(%data, %obj) } if(isObject(%obj.shield)) %obj.shield.delete(); + + %obj.teleporter.setThreadDir($ActivateThread, FALSE); + %obj.teleporter.playThread($ActivateThread,"activate"); + %obj.teleporter.playAudio($ActivateSound, StationTeleportDeacitvateSound); } //************************************************************** @@ -576,6 +654,13 @@ function MobileBaseVehicle::playerMounted(%data, %obj, %player, %node) %obj.shield.open(); %obj.shield.schedule(1000,"delete"); %obj.deploySchedule = ""; + + %obj.teleporter.setThreadDir($ActivateThread, FALSE); + %obj.teleporter.playThread($ActivateThread,"activate"); + %obj.teleporter.playAudio($ActivateSound, StationTeleportDeacitvateSound); + %obj.fullyDeployed = 0; + + %obj.noEnemyControl = 0; } %obj.deployed = 0; } @@ -634,7 +719,7 @@ function MobileBaseVehicle::vehicleDeploy(%data, %obj, %player) %obj.station.setSelfPowered(); %obj.station.playThread($PowerThread,"Power"); %obj.station.playAudio($HumSound,StationHumSound); - + %obj.station.vehicle = %obj; %obj.turret = new turret() { scale = "1 1 1"; dataBlock = "MobileTurretBase"; @@ -642,10 +727,13 @@ function MobileBaseVehicle::vehicleDeploy(%data, %obj, %player) homingCount = "0"; team = %obj.team; }; + %obj.turret.setDamageLevel(%obj.getDamageLevel()); %obj.mountObject(%obj.turret, 1); %obj.turret.setSelfPowered(); %obj.turret.playThread($PowerThread,"Power"); %obj.turret.mountImage(MissileBarrelLarge, 0 ,false); + + checkSpawnPos(%obj, 20); } } else @@ -725,6 +813,8 @@ function MobileBaseVehicle::onEndSequence(%data, %obj, %thread) %obj.station.goingOut = true; %obj.shield.setTransform(%obj.getSlotTransform(3)); %obj.shield.close(); + %obj.isDeployed = true; + %obj.noEnemyControl = 1; } Parent::onEndSequence(%data, %obj, %thread); @@ -735,7 +825,13 @@ function MobileInvStation::onEndSequence(%data, %obj, %thread) if(!%obj.goingOut) %obj.startFade(0,0,true); else + { %obj.notDeployed = 0; + %obj.vehicle.fullyDeployed = 1; + %obj.vehicle.teleporter.setThreadDir($ActivateThread, TRUE); + %obj.vehicle.teleporter.playThread($ActivateThread,"activate"); + %obj.vehicle.teleporter.playAudio($ActivateSound, StationTeleportAcitvateSound); + } Parent::onEndSequence(%data, %obj, %thread); } @@ -800,10 +896,21 @@ function MobileBaseVehicle::checkDeploy(%data, %obj) function MobileBaseVehicle::checkTurretDistance(%data, %obj) { %pos = getWords(%obj.getTransform(), 0, 2); - InitContainerRadiusSearch(%pos, 150, $TypeMasks::TurretObjectType); + InitContainerRadiusSearch(%pos, 100, $TypeMasks::TurretObjectType | $TypeMasks::InteriorObjectType); while ((%objFound = ContainerSearchNext()) != 0) - if(%objFound.getDataBlock().ClassName $= "TurretBase") - return "Turret Base in area. Unable to deploy."; + { + if(%objFound.getType() & $TypeMasks::TurretObjectType) + { + if(%objFound.getDataBlock().ClassName $= "TurretBase") + return "Turret Base is in the area. Unable to deploy."; + } + else + { + %subStr = getSubStr(%objFound.interiorFile, 1, 4); + if(%subStr !$= "rock" && %subStr !$= "spir" && %subStr !$= "misc") + return "Building is in the area. Unable to deploy."; + } + } return ""; } @@ -979,7 +1086,7 @@ function VehicleData::damageObject(%data, %targetObject, %sourceObject, %positio function VehicleData::onImpact(%data, %vehicleObject, %collidedObject, %vec, %vecLen) { if(%vecLen > %data.minImpactSpeed) - %data.damageObject(%vehicleObject, 0, VectorAdd(%vec, %vehicleObject.getPosition), + %data.damageObject(%vehicleObject, 0, VectorAdd(%vec, %vehicleObject.getPosition()), %vecLen * %data.speedDamageScale, $DamageType::Ground); // associated "crash" sounds diff --git a/base/scripts/vehicles/vehicle_bomber.cs b/base/scripts/vehicles/vehicle_bomber.cs index bd5ce95..5bf8f76 100644 --- a/base/scripts/vehicles/vehicle_bomber.cs +++ b/base/scripts/vehicles/vehicle_bomber.cs @@ -101,7 +101,7 @@ datablock AudioProfile(BomberBombIdleSound) // VEHICLE CHARACTERISTICS //************************************************************** -datablock FlyingVehicleData(BomberFlyer) : AirVehicleDamageProfile +datablock FlyingVehicleData(BomberFlyer) : BomberDamageProfile { spawnOffset = "0 0 2"; @@ -129,6 +129,8 @@ datablock FlyingVehicleData(BomberFlyer) : AirVehicleDamageProfile cameraOffset = 5; cameraLag = 1.0; explosion = LargeAirVehicleExplosion; + explosionDamage = 0.5; + explosionRadius = 5.0; maxDamage = 2.80; // Total health destroyedLevel = 2.80; // Damage textures show up at this health level @@ -140,12 +142,6 @@ datablock FlyingVehicleData(BomberFlyer) : AirVehicleDamageProfile rotationalDrag = 1800; // Angular Drag (dampens the drift after you stop moving the mouse...also tumble drag) rechargeRate = 0.8; - // Turbo Jet - jetForce = 5000; // Afterburner thrust (this is in addition to normal thrust) - minJetEnergy = 40.0; // Afterburner can't be used if below this threshhold. - jetEnergyDrain = 2.0; // Energy use of the afterburners (low number is less drain...can be fractional) - vertThrustMultiple = 2.0; - // Auto stabilize speed maxAutoSpeed = 15; // Autostabilizer kicks in when less than this speed. (meters/second) autoAngularForce = 1500; // Angular stabilizer force (this force levels you out when autostabilizer kicks in) @@ -163,6 +159,12 @@ datablock FlyingVehicleData(BomberFlyer) : AirVehicleDamageProfile hoverHeight = 5; // Height off the ground at rest createHoverHeight = 3; // Height off the ground when created + // Turbo Jet + jetForce = 3000; // Afterburner thrust (this is in addition to normal thrust) + minJetEnergy = 40.0; // Afterburner can't be used if below this threshhold. + jetEnergyDrain = 3.0; // Energy use of the afterburners (low number is less drain...can be fractional) + vertThrustMultiple = 2.0; + dustEmitter = LargeVehicleLiftoffDustEmitter; triggerDustHeight = 4.0; dustHeight = 2.0; @@ -181,13 +183,16 @@ datablock FlyingVehicleData(BomberFlyer) : AirVehicleDamageProfile bodyFriction = 0; // Don't mess with this. bodyRestitution = 0.5; // When you hit the ground, how much you rebound. (between 0 and 1) minRollSpeed = 0; // Don't mess with this. - minImpactSpeed = 8; // If hit ground at speed above this then it's an impact. Meters/second - softImpactSpeed = 10; // Sound hooks. This is the soft hit. + softImpactSpeed = 20; // Sound hooks. This is the soft hit. hardImpactSpeed = 25; // Sound hooks. This is the hard hit. - speedDamageScale = 0.035; - collDamageThresholdVel = 20.0; - collDamageMultiplier = 0.025; + // Ground Impact Damage (uses DamageType::Ground) + minImpactSpeed = 20; // If hit ground at speed above this then it's an impact. Meters/second + speedDamageScale = 0.150; + + // Object Impact Damage (uses DamageType::Impact) + collDamageThresholdVel = 25; + collDamageMultiplier = 0.030; // minTrailSpeed = 15; // The speed your contrail shows up at. @@ -204,9 +209,9 @@ datablock FlyingVehicleData(BomberFlyer) : AirVehicleDamageProfile // softSplashSoundVelocity = 15.0; - mediumSplashSoundVelocity = 30.0; - hardSplashSoundVelocity = 60.0; - exitSplashSoundVelocity = 20.0; + mediumSplashSoundVelocity = 20.0; + hardSplashSoundVelocity = 30.0; + exitSplashSoundVelocity = 10.0; exitingWater = VehicleExitWaterHardSound; impactWaterEasy = VehicleImpactWaterSoftSound; diff --git a/base/scripts/vehicles/vehicle_havoc.cs b/base/scripts/vehicles/vehicle_havoc.cs index 2b6dbb3..1571801 100644 --- a/base/scripts/vehicles/vehicle_havoc.cs +++ b/base/scripts/vehicles/vehicle_havoc.cs @@ -21,7 +21,7 @@ datablock AudioProfile(HAPCFlyerThrustSound) // VEHICLE CHARACTERISTICS //************************************************************** -datablock FlyingVehicleData(HAPCFlyer) : AirVehicleDamageProfile +datablock FlyingVehicleData(HAPCFlyer) : HavocDamageProfile { spawnOffset = "0 0 6"; @@ -51,6 +51,8 @@ datablock FlyingVehicleData(HAPCFlyer) : AirVehicleDamageProfile cameraOffset = 2; cameraLag = 8.5; explosion = LargeAirVehicleExplosion; + explosionDamage = 0.5; + explosionRadius = 5.0; maxDamage = 3.50; destroyedLevel = 3.50; @@ -82,7 +84,7 @@ datablock FlyingVehicleData(HAPCFlyer) : AirVehicleDamageProfile // Turbo Jet jetForce = 5000; minJetEnergy = 55; - jetEnergyDrain = 2.8; + jetEnergyDrain = 3.6; vertThrustMultiple = 2.0; @@ -104,13 +106,16 @@ datablock FlyingVehicleData(HAPCFlyer) : AirVehicleDamageProfile bodyFriction = 0; bodyRestitution = 0.3; minRollSpeed = 0; - minImpactSpeed = 8; // If hit ground at speed above this then it's an impact. Meters/second - softImpactSpeed = 10; // Sound hooks. This is the soft hit. - hardImpactSpeed = 25; // Sound hooks. This is the hard hit. - speedDamageScale = 0.03; + softImpactSpeed = 12; // Sound hooks. This is the soft hit. + hardImpactSpeed = 15; // Sound hooks. This is the hard hit. - collDamageThresholdVel = 20.0; - collDamageMultiplier = 0.03; + // Ground Impact Damage (uses DamageType::Ground) + minImpactSpeed = 12; // If hit ground at speed above this then it's an impact. Meters/second + speedDamageScale = 0.060; + + // Object Impact Damage (uses DamageType::Impact) + collDamageThresholdVel = 12; + collDamageMultiplier = 0.080; // minTrailSpeed = 15; @@ -126,10 +131,10 @@ datablock FlyingVehicleData(HAPCFlyer) : AirVehicleDamageProfile //wheelImpactSound = WheelImpactSound; // - softSplashSoundVelocity = 15.0; - mediumSplashSoundVelocity = 30.0; - hardSplashSoundVelocity = 60.0; - exitSplashSoundVelocity = 20.0; + softSplashSoundVelocity = 5.0; + mediumSplashSoundVelocity = 8.0; + hardSplashSoundVelocity = 12.0; + exitSplashSoundVelocity = 8.0; exitingWater = VehicleExitWaterHardSound; impactWaterEasy = VehicleImpactWaterSoftSound; diff --git a/base/scripts/vehicles/vehicle_mpb.cs b/base/scripts/vehicles/vehicle_mpb.cs index 39304d6..6d028e3 100644 --- a/base/scripts/vehicles/vehicle_mpb.cs +++ b/base/scripts/vehicles/vehicle_mpb.cs @@ -72,7 +72,7 @@ datablock SensorData(MPBDeployedSensor) : VehiclePulseSensor jamRadius = 50; }; -datablock WheeledVehicleData(MobileBaseVehicle) : GroundVehicleDamageProfile +datablock WheeledVehicleData(MobileBaseVehicle) : MPBDamageProfile { spawnOffset = "0 0 1.0"; @@ -98,9 +98,9 @@ datablock WheeledVehicleData(MobileBaseVehicle) : GroundVehicleDamageProfile cameraOffset = 6; cameraLag = 1.5; explosion = LargeGroundVehicleExplosion; + explosionDamage = 0.5; + explosionRadius = 5.0; - noEnemyControl = 1; - maxSteeringAngle = 0.3; // 20 deg. // Used to test if the station can deploy @@ -111,9 +111,6 @@ datablock WheeledVehicleData(MobileBaseVehicle) : GroundVehicleDamageProfile stationPoints[5] = "2.3 -7.38703 -0.65"; stationPoints[6] = "2.3 -11.8 -0.65"; - collDamageThresholdVel = 10.0; - collDamageMultiplier = 0.025; - // Rigid Body mass = 2000; bodyFriction = 0.8; @@ -123,10 +120,16 @@ datablock WheeledVehicleData(MobileBaseVehicle) : GroundVehicleDamageProfile gyroDamping = 0.3; stabilizerForce = 10; minDrag = 10; - minImpactSpeed = 5; - softImpactSpeed = 13; // Play SoftImpact Sound - hardImpactSpeed = 20; // Play HardImpact Sound - speedDamageScale = 0.06; + softImpactSpeed = 20; // Play SoftImpact Sound + hardImpactSpeed = 25; // Play HardImpact Sound + + // Ground Impact Damage (uses DamageType::Ground) + minImpactSpeed = 25; + speedDamageScale = 0.220; + + // Object Impact Damage (uses DamageType::Impact) + collDamageThresholdVel = 28; + collDamageMultiplier = 0.040; // Engine engineTorque = 4.5 * 745; @@ -171,10 +174,10 @@ datablock WheeledVehicleData(MobileBaseVehicle) : GroundVehicleDamageProfile wheelImpactSound = WheelImpactSound; // - softSplashSoundVelocity = 15.0; - mediumSplashSoundVelocity = 30.0; - hardSplashSoundVelocity = 60.0; - exitSplashSoundVelocity = 20.0; + softSplashSoundVelocity = 5.0; + mediumSplashSoundVelocity = 8.0; + hardSplashSoundVelocity = 12.0; + exitSplashSoundVelocity = 8.0; exitingWater = VehicleExitWaterSoftSound; impactWaterEasy = VehicleImpactWaterSoftSound; diff --git a/base/scripts/vehicles/vehicle_shrike.cs b/base/scripts/vehicles/vehicle_shrike.cs index 8d3e276..c0b8b84 100644 --- a/base/scripts/vehicles/vehicle_shrike.cs +++ b/base/scripts/vehicles/vehicle_shrike.cs @@ -44,7 +44,7 @@ datablock AudioProfile(ShrikeBlasterDryFireSound) // VEHICLE CHARACTERISTICS //************************************************************** -datablock FlyingVehicleData(ScoutFlyer) : AirVehicleDamageProfile +datablock FlyingVehicleData(ScoutFlyer) : ShrikeDamageProfile { spawnOffset = "0 0 2"; @@ -66,6 +66,8 @@ datablock FlyingVehicleData(ScoutFlyer) : AirVehicleDamageProfile cameraOffset = 2.5; cameraLag = 0.9; explosion = VehicleExplosion; + explosionDamage = 0.5; + explosionRadius = 5.0; maxDamage = 1.40; destroyedLevel = 1.40; @@ -77,12 +79,6 @@ datablock FlyingVehicleData(ScoutFlyer) : AirVehicleDamageProfile rotationalDrag = 900; // Anguler Drag (dampens the drift after you stop moving the mouse...also tumble drag) rechargeRate = 0.8; - // Turbo Jet - jetForce = 2000; // Afterburner thrust (this is in addition to normal thrust) - minJetEnergy = 28; // Afterburner can't be used if below this threshhold. - vertThrustMultiple = 2.0; - - jetEnergyDrain = 2.8; // Energy use of the afterburners (low number is less drain...can be fractional) // Auto stabilize speed maxAutoSpeed = 15; // Autostabilizer kicks in when less than this speed. (meters/second) autoAngularForce = 400; // Angular stabilizer force (this force levels you out when autostabilizer kicks in) autoLinearForce = 300; // Linear stabilzer force (this slows you down when autostabilizer kicks in) @@ -99,17 +95,26 @@ datablock FlyingVehicleData(ScoutFlyer) : AirVehicleDamageProfile hoverHeight = 5; // Height off the ground at rest createHoverHeight = 3; // Height off the ground when created + // Turbo Jet + jetForce = 2000; // Afterburner thrust (this is in addition to normal thrust) + minJetEnergy = 28; // Afterburner can't be used if below this threshhold. + jetEnergyDrain = 2.8; // Energy use of the afterburners (low number is less drain...can be fractional) // Auto stabilize speed + vertThrustMultiple = 2.0; + // Rigid body mass = 150; // Mass of the vehicle bodyFriction = 0; // Don't mess with this. bodyRestitution = 0.5; // When you hit the ground, how much you rebound. (between 0 and 1) minRollSpeed = 0; // Don't mess with this. - minImpactSpeed = 8; // If hit ground at speed above this then it's an impact. Meters/second - softImpactSpeed = 10; // Sound hooks. This is the soft hit. + softImpactSpeed = 14; // Sound hooks. This is the soft hit. hardImpactSpeed = 25; // Sound hooks. This is the hard hit. - speedDamageScale = 0.04; - collDamageThresholdVel = 20.0; + // Ground Impact Damage (uses DamageType::Ground) + minImpactSpeed = 23; // If hit ground at speed above this then it's an impact. Meters/second + speedDamageScale = 0.06; + + // Object Impact Damage (uses DamageType::Impact) + collDamageThresholdVel = 23.0; collDamageMultiplier = 0.02; // @@ -126,10 +131,10 @@ datablock FlyingVehicleData(ScoutFlyer) : AirVehicleDamageProfile //wheelImpactSound = WheelImpactSound; // - softSplashSoundVelocity = 15.0; - mediumSplashSoundVelocity = 30.0; - hardSplashSoundVelocity = 60.0; - exitSplashSoundVelocity = 20.0; + softSplashSoundVelocity = 10.0; + mediumSplashSoundVelocity = 15.0; + hardSplashSoundVelocity = 20.0; + exitSplashSoundVelocity = 10.0; exitingWater = VehicleExitWaterMediumSound; impactWaterEasy = VehicleImpactWaterSoftSound; diff --git a/base/scripts/vehicles/vehicle_tank.cs b/base/scripts/vehicles/vehicle_tank.cs index 7bca460..787b032 100644 --- a/base/scripts/vehicles/vehicle_tank.cs +++ b/base/scripts/vehicles/vehicle_tank.cs @@ -100,7 +100,7 @@ datablock AudioProfile(AssaultMortarIdleSound) // VEHICLE CHARACTERISTICS //************************************************************** -datablock HoverVehicleData(AssaultVehicle) : GroundVehicleDamageProfile +datablock HoverVehicleData(AssaultVehicle) : TankDamageProfile { spawnOffset = "0 0 4"; @@ -129,15 +129,14 @@ datablock HoverVehicleData(AssaultVehicle) : GroundVehicleDamageProfile cameraOffset = 3; cameraLag = 1.5; explosion = LargeGroundVehicleExplosion; + explosionDamage = 0.5; + explosionRadius = 5.0; maxSteeringAngle = 0.5; // 20 deg. maxDamage = 3.15; destroyedLevel = 3.15; - collDamageThresholdVel = 20.0; - collDamageMultiplier = 0.03; - isShielded = true; rechargeRate = 1.0; energyPerDamagePoint = 135; @@ -154,10 +153,16 @@ datablock HoverVehicleData(AssaultVehicle) : GroundVehicleDamageProfile gyroDamping = 0.3; stabilizerForce = 20; minDrag = 10; - minImpactSpeed = 5; - softImpactSpeed = 5; // Play SoftImpact Sound - hardImpactSpeed = 15; // Play HardImpact Sound - speedDamageScale = 0.06; + softImpactSpeed = 15; // Play SoftImpact Sound + hardImpactSpeed = 18; // Play HardImpact Sound + + // Ground Impact Damage (uses DamageType::Ground) + minImpactSpeed = 17; + speedDamageScale = 0.060; + + // Object Impact Damage (uses DamageType::Impact) + collDamageThresholdVel = 17; + collDamageMultiplier = 0.070; dragForce = 40 / 20; vertFactor = 0.0; @@ -201,10 +206,10 @@ datablock HoverVehicleData(AssaultVehicle) : GroundVehicleDamageProfile forwardJetEmitter = TankJetEmitter; // - softSplashSoundVelocity = 15.0; - mediumSplashSoundVelocity = 30.0; - hardSplashSoundVelocity = 60.0; - exitSplashSoundVelocity = 20.0; + softSplashSoundVelocity = 5.0; + mediumSplashSoundVelocity = 10.0; + hardSplashSoundVelocity = 15.0; + exitSplashSoundVelocity = 10.0; exitingWater = VehicleExitWaterMediumSound; impactWaterEasy = VehicleImpactWaterSoftSound; @@ -346,7 +351,7 @@ datablock TurretImageData(AssaultPlasmaTurretBarrel) usesEnergy = true; useMountEnergy = true; fireEnergy = 3.75; - minEnergy = 3.75; + minEnergy = 20.0; // Turret parameters activationMS = 4000; @@ -398,9 +403,10 @@ datablock TurretImageData(AssaultPlasmaTurretBarrel) stateName[5] = "Deactivate"; stateSequence[5] = "Activate"; stateDirection[5] = false; - stateTimeoutValue[5] = 1; - stateTransitionOnLoaded[5] = "ActivateReady"; - stateTransitionOnTimeout[5] = "Dead"; + stateTimeoutValue[5] = 30; +// stateTransitionOnLoaded[5] = "ActivateReady"; +// stateTransitionOnTimeout[5] = "Dead"; + stateTransitionOnTimeout[5] = "ActivateReady"; stateName[6] = "Dead"; stateTransitionOnLoaded[6] = "ActivateReady"; diff --git a/base/scripts/vehicles/vehicle_wildcat.cs b/base/scripts/vehicles/vehicle_wildcat.cs index 6c653b8..30b11e3 100644 --- a/base/scripts/vehicles/vehicle_wildcat.cs +++ b/base/scripts/vehicles/vehicle_wildcat.cs @@ -31,7 +31,7 @@ datablock AudioProfile(ScoutThrustSound) // VEHICLE CHARACTERISTICS //************************************************************** -datablock HoverVehicleData(ScoutVehicle) : GravCycleDamageProfile +datablock HoverVehicleData(ScoutVehicle) : WildcatDamageProfile { spawnOffset = "0 0 1"; @@ -54,6 +54,8 @@ datablock HoverVehicleData(ScoutVehicle) : GravCycleDamageProfile numMountPoints = 1; isProtectedMountPoint[0] = true; explosion = VehicleExplosion; + explosionDamage = 0.5; + explosionRadius = 5.0; lightOnly = 1; @@ -67,17 +69,20 @@ datablock HoverVehicleData(ScoutVehicle) : GravCycleDamageProfile minJetEnergy = 15; jetEnergyDrain = 1.3; - collDamageThresholdVel = 20.0; - collDamageMultiplier = 0.01; - // Rigid Body mass = 400; bodyFriction = 0.1; bodyRestitution = 0.5; - minImpactSpeed = 10; - softImpactSpeed = 10; // Play SoftImpact Sound - hardImpactSpeed = 25; // Play HardImpact Sound - speedDamageScale = 0.008; + softImpactSpeed = 20; // Play SoftImpact Sound + hardImpactSpeed = 28; // Play HardImpact Sound + + // Ground Impact Damage (uses DamageType::Ground) + minImpactSpeed = 29; + speedDamageScale = 0.010; + + // Object Impact Damage (uses DamageType::Impact) + collDamageThresholdVel = 23; + collDamageMultiplier = 0.040; dragForce = 25 / 45.0; vertFactor = 0.0; @@ -119,10 +124,10 @@ datablock HoverVehicleData(ScoutVehicle) : GravCycleDamageProfile wheelImpactSound = WheelImpactSound; // - softSplashSoundVelocity = 20.0; - mediumSplashSoundVelocity = 50.0; - hardSplashSoundVelocity = 100.0; - exitSplashSoundVelocity = 20.0; + softSplashSoundVelocity = 10.0; + mediumSplashSoundVelocity = 20.0; + hardSplashSoundVelocity = 30.0; + exitSplashSoundVelocity = 10.0; exitingWater = VehicleExitWaterSoftSound; impactWaterEasy = VehicleImpactWaterSoftSound; diff --git a/base/scripts/voiceBinds.cs b/base/scripts/voiceBinds.cs index 2f0cc76..0bff5b5 100644 --- a/base/scripts/voiceBinds.cs +++ b/base/scripts/voiceBinds.cs @@ -23,7 +23,7 @@ startChatMenu( "G Global" ); addChat( "S Great shot!", 'ChatGreatShot' ); endChatMenu(); startChatMenu( "R Respond" ); - addChat( "A Any time", 'ChatAnyTime' ); + addChat( "A Anytime", 'ChatAnyTime' ); addChat( "D Don't know", 'ChatDontKnow' ); addChat( "T Thanks", 'ChatThanks' ); addChat( "W Wait", 'ChatWait' ); @@ -193,10 +193,10 @@ startChatMenu( "W Warning" ); addChat( "W Watch your shooting", 'ChatWarnShoot' ); endChatMenu(); -startChatMenu( "V Very quick" ); +startChatMenu( "V Very Quick" ); addChat( "Y Yes", 'ChatTeamYes' ); addChat( "N No", 'ChatTeamNo' ); - addChat( "A Any time", 'ChatWelcome' ); + addChat( "A Anytime", 'ChatWelcome' ); addChat( "B Base secure?", 'ChatIsBaseSecure' ); addChat( "C Cease fire", 'ChatCeaseFire' ); addChat( "D Don't know", 'ChatDunno' ); diff --git a/base/scripts/voiceChat.cs b/base/scripts/voiceChat.cs index 44ba6af..880946b 100644 --- a/base/scripts/voiceChat.cs +++ b/base/scripts/voiceChat.cs @@ -218,12 +218,74 @@ function serverCmdListenToNone(%client) } //------------------------------------------------------------------------------ -function serverCmdSetVoiceChannels(%client, %number) +// Client bind functions: +//------------------------------------------------------------------------------ +function voiceCapStart() +{ + $voiceCaptureStarted = true; + + // client can send voice? (dont bother recording.. server will reject it anyway) + if(($Audio::serverChannels == 0) || ($Audio::serverEncodingLevel < $pref::Audio::encodingLevel)) + { + if($Audio::serverChannels == 0) + addMessageHudLine("\c2System:\cr server has disabled voice communication."); + else + { + switch($Audio::serverEncodingLevel) + { + case 0: %level = "Low"; + case 1: %level = "Medium"; + default: %level = "High"; + } + + addMessageHudLine("\c2System:\cr server has voice level capped at [\c1" @ %level @ "\cr]."); + } + + $voiceCaptureStarted = false; + return; + } + + vcRecordingHud.setVisible(true); + voiceCommHud.setVisible(true); + resizeVoiceCommWindow(); + alxCaptureStart(); +} + +function voiceCapStop() +{ + if(!$voiceCaptureStarted) + return; + + vcRecordingHud.setVisible(false); + if($numTalking < 1) + voiceCommHud.setVisible(false); + alxCaptureStop(); +} + +//------------------------------------------------------------------------------ +function serverCmdSetVoiceInfo(%client, %channels, %decodingMask, %encodingLevel) { %wasEnabled = %client.listenEnabled(); - %client.setVoiceChannels(%number); - if ( %wasEnabled != ( %number > 0 ) ) + // server has voice comm turned off? + if($Audio::maxVoiceChannels == 0) + %decodingMask = 0; + else + %decodingMask &= (1 << ($Audio::maxEncodingLevel + 1)) - 1; + + if($Audio::maxEncodingLevel < %encodingLevel) + %encodingLevel = $Audio::maxEncodingLevel; + + if($Audio::maxVoiceChannels < %channels) + %channels = $Audio::maxVoiceChannels; + + %client.setVoiceChannels(%channels); + %client.setVoiceDecodingMask(%decodingMask); + %client.setVoiceEncodingLevel(%encodingLevel); + + commandToClient(%client, 'SetVoiceInfo', %channels, %decodingMask, %encodingLevel); + + if ( %wasEnabled != ( %channels > 0 ) ) updateCanListenState( %client ); } diff --git a/base/scripts/weapTurretCode.cs b/base/scripts/weapTurretCode.cs index b007c16..dae4d2d 100644 --- a/base/scripts/weapTurretCode.cs +++ b/base/scripts/weapTurretCode.cs @@ -111,6 +111,7 @@ function TurretDeployedCamera::onAdd(%this, %obj) { Parent::onAdd(%this, %obj); %obj.mountImage(DeployableCameraBarrel, 0, true); + %obj.setRechargeRate(%this.rechargeRate); } function TurretDeployedCamera::onDestroyed(%this, %obj, %prevState) @@ -397,8 +398,9 @@ function MobileTurretBase::onDamage() function MobileTurretBase::damageObject(%this, %targetObject, %sourceObject, %position, %amount, %damageType) { //If vehicle turret is hit then apply damage to the vehicle - %vehicle = %damageObj.getObjectMount(); - %vehicle.getDataBlock().damageObject(%vehicle, %sourceObject, %position, %amount, %damageType); + %vehicle = %targetObject.getObjectMount(); + if(%vehicle) + %vehicle.getDataBlock().damageObject(%vehicle, %sourceObject, %position, %amount, %damageType); } function MobileTurretBase::onEndSequence(%data, %obj, %thread) diff --git a/base/scripts/weapons/ELFGun.cs b/base/scripts/weapons/ELFGun.cs index 14ee48f..e2dad44 100644 --- a/base/scripts/weapons/ELFGun.cs +++ b/base/scripts/weapons/ELFGun.cs @@ -50,7 +50,49 @@ datablock AudioProfile(ELFHitTargetSound) }; //-------------------------------------- -// Projectile +// Sparks +//-------------------------------------- +datablock ParticleData(ELFSparks) +{ + dragCoefficient = 1; + gravityCoefficient = 0.0; + inheritedVelFactor = 0.2; + constantAcceleration = 0.0; + lifetimeMS = 200; + lifetimeVarianceMS = 0; + textureName = "special/blueSpark"; + colors[0] = "0.8 0.8 1.0 1.0"; + colors[1] = "0.8 0.8 1.0 1.0"; + colors[2] = "0.8 0.8 1.0 0.0"; + sizes[0] = 0.35; + sizes[1] = 0.15; + sizes[2] = 0.0; + times[0] = 0.0; + times[1] = 0.5; + times[2] = 1.0; + +}; + +datablock ParticleEmitterData(ELFSparksEmitter) +{ + ejectionPeriodMS = 5; + periodVarianceMS = 0; + ejectionVelocity = 4; + velocityVariance = 2; + ejectionOffset = 0.0; + thetaMin = 0; + thetaMax = 180; + phiReferenceVel = 0; + phiVariance = 360; + overrideAdvances = false; + orientParticles = true; +// lifetimeMS = 100; + particles = "ELFSparks"; +}; + + +//-------------------------------------- +// Projectile //-------------------------------------- datablock ELFProjectileData(BasicELF) { @@ -77,6 +119,7 @@ datablock ELFProjectileData(BasicELF) textures[1] = "special/ELFLightning"; textures[2] = "special/BlueImpact"; + emitter = ELFSparksEmitter; }; //-------------------------------------- diff --git a/base/scripts/weapons/cameraGrenade.cs b/base/scripts/weapons/cameraGrenade.cs index b205b40..3e9d6e9 100644 --- a/base/scripts/weapons/cameraGrenade.cs +++ b/base/scripts/weapons/cameraGrenade.cs @@ -133,6 +133,8 @@ datablock TurretData(TurretDeployedCamera) : TurretDamageProfile thetaMax = 180; //thetaNull = 90; + deployedObject = true; + isShielded = false; energyPerDamagePoint = 40; maxEnergy = 30; diff --git a/base/scripts/weapons/missileLauncher.cs b/base/scripts/weapons/missileLauncher.cs index 0309540..873a7e4 100644 --- a/base/scripts/weapons/missileLauncher.cs +++ b/base/scripts/weapons/missileLauncher.cs @@ -641,11 +641,11 @@ datablock SeekerProjectileData(ShoulderMissile) lifetimeMS = 6000; muzzleVelocity = 10.0; - maxVelocity = 65.0; + maxVelocity = 80.0; turningSpeed = 90.0; acceleration = 200.0; - proximityRadius = 5; + proximityRadius = 3; terrainAvoidanceSpeed = 180; terrainScanAhead = 25; diff --git a/base/scripts/webbrowser.cs b/base/scripts/webbrowser.cs index beac24e..354880a 100644 --- a/base/scripts/webbrowser.cs +++ b/base/scripts/webbrowser.cs @@ -79,6 +79,18 @@ function ExecuteSearch(%id) DatabaseQueryArray(BrowserSearchPane.query,0,trim($BrowserSearchField) TAB 0 TAB 100 TAB 0, BrowserSearchPane, BrowserSearchPane.key); } //----------------------------------------------------------------------------- +function getTribeMember(%tribeName) +{ + %bResult = false; + %CRec = wonGetAuthInfo(); + for(%tribeNo = 0;%tribeNo < getField(getRecord(%CRec,1),0); %tribeNo++) + { + if(strupr(%tribeName) $= strupr(getField(getRecord(%CRec,2+%tribeNo),0))) + %bResult = true; + } + return %bResult; +} +//----------------------------------------------------------------------------- function CreateTribe() { $CreateTribeName = ""; @@ -172,10 +184,8 @@ function EditDescriptionApply() { %desc = EditDescriptionText.getValue(); TProfileHdr.Desc = %desc; - error("ETYPE: " @ TWBText.editType); if(TWBText.editType $= "tribe") { - error("TRIBENAME: " @ TProfileHdr.tribename); TribePane.key = LaunchGui.key++; TribePane.state = "editTribeDesc"; canvas.SetCursor(ArrowWaitCursor); @@ -183,7 +193,6 @@ function EditDescriptionApply() } else { - error("PLAYERNAME: " @ TProfileHdr.playername); TWBText.key = LaunchGui.key++; TWBText.state = "editWarriorDesc"; canvas.SetCursor(ArrowWaitCursor); @@ -250,6 +259,7 @@ function GetProfileHdr(%type, %line) W_History.setVisible(1); W_Tribes.setVisible(1); %isMe = getField(getRecord(wonGetAuthInfo(),0),0)$=twbTitle.name; + TProfileHdr.isMe = %isMe; if(%isMe) { W_BuddyList.setText("BUDDYLIST"); @@ -344,17 +354,6 @@ function LinkEditWarrior() //----------------------------------------------------------------------------- function LinkEditWarriorDesc(%player, %handler) { -// if(%handler.editType $= "tribe") -// if(trim(%player) !$= "") -// { -// %handler.tribe = %player; -// %handler.editType = "tribe"; -// } -// else -// { -// TWBText.editType = "warrior"; -// } - Canvas.pushDialog(BrowserEditInfoDlg); EditDescriptionText.setValue(TProfileHdr.Desc); } @@ -382,10 +381,8 @@ function LinkEditMember(%player, %tribe, %pv, %title,%owner) // Get callers rank in members tribe for(%i=0;%i1)) { - error("TRIBE MATCH FOUND" TAB getField(getREcord(%ai,2+%i),4)); %callerPv = getField(getRecord(%ai,2+%i),4); break; } @@ -400,7 +397,6 @@ function LinkEditMember(%player, %tribe, %pv, %title,%owner) if(getField(getRecord(%ai,0),0) $= getField(twbTitle.getValue(),0)) //if the caller is the member to be edited { - error("CALLER IS MEMBER" TAB %rnk TAB %pv TAB %callerPv); switch( %pv ) { case 0: @@ -427,7 +423,6 @@ function LinkEditMember(%player, %tribe, %pv, %title,%owner) } else { - error("CALLER IS NOT MEMBER" TAB %rnk TAB %pv TAB %callerPv); switch( %rnk ) { case 1: @@ -600,24 +595,20 @@ function TAM_OnAction(%caller) TribeAdminMemberDlg.vPerm = %caller; } //----------------------------------------------------------------------------- -function updateNewTagPreview() -{ - %ntag = TAD_NewTag.getValue(); - %playerName = GetField(GetRecord(WonGetAuthInfo(),0),0); - if ( $NewTagAppend ) - TAD_PreviewTag.setValue( %playerName @ %ntag); - else - TAD_PreviewTag.setValue(%ntag @ %playerName); -} -//----------------------------------------------------------------------------- function updateTribeTagPreview() { %warrior = getField( WONGetAuthInfo(), 0 ); + + // Validate the tribe tag: %tag = CT_TagText.getValue(); + %realTag = StripMLControlChars( %tag ); + if ( %tag !$= %realTag ) + CT_TagText.setValue( %realTag ); + if ( $CreateTribeAppend ) - CT_PreviewText.setValue( %warrior @ %tag ); + CT_PreviewText.setValue( %warrior @ %realTag ); else - CT_PreviewText.setValue( %tag @ %warrior ); + CT_PreviewText.setValue( %realTag @ %warrior ); } //-- TribeAndWarriorBrowserGui ----------------------------------------------- @@ -638,7 +629,6 @@ function TribeAndWarriorBrowserGui::onWake(%this) %warrior = getField( %info, 0 ); TWBTabView.view( %warrior, "Warrior" ); w_profile.setValue(1); - w_tribes.setValue(1); // Add tabs for the player's tribal pages: %tribeCount = getField( getRecord( %info, 1 ), 0 ); //%cert @@ -681,8 +671,8 @@ function TribeAndWarriorBrowserGui::onSleep(%this) //==-- CreateTribeDlg ------------------------------------------------------- function CreateTribeDlg::onWake( %this ) { - rbAppendTab.setValue(1); -// updateTribeTagPreview(); + //rbAppendTab.setValue(1); + updateTribeTagPreview(); } //----------------------------------------------------------------------------- function CreateTribeDlg::CreateTribe(%this) @@ -705,7 +695,7 @@ function CreateTribeDlg::onDatabaseQueryResult(%this,%status,%resultString,%key) { if ( %this.key != %key ) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) @@ -737,7 +727,7 @@ function CreateTribeDlg::onDatabaseRow(%this,%row,%isLastRow,%key) { if( %this.key != %key ) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); } //==-- TribeAdminMemberDlg --------------------------------------------------- function TribeAdminMemberDlg::onWake(%this) @@ -749,7 +739,7 @@ function TribeAdminMemberDlg::onDatabaseQueryResult( %this, %status, %resultStri { if ( %this.key != %key ) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) @@ -773,7 +763,7 @@ function TribeAdminMemberDlg::onDatabaseRow(%this,%row,%isLastRow,%key) { if ( %this.key != %key ) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); } //----------------------------------------------------------------------------- function TribeAdminMemberDlg::connectionTerminated( %this, %key ) @@ -800,7 +790,7 @@ function BrowserSearchPane::onDatabaseQueryResult(%this, %status, %resultStatus, { if(%key != %this.key) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) @@ -846,18 +836,16 @@ function BrowserSearchPane::onDatabaseRow(%this, %row, %isLastRow, %key) { if(%key != %this.key) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); switch$(%this.state) { case "tribe": %line = getTribeName(getFields(%row, 1),0) TAB getField(%row, 2); - error("TLine: " @ %line); BrowserSearchMatchList.addRow(%this.rowNum++, %line); if(%isLastRow) %this.state = "done"; case "warrior": %line = getFields(%row,1); - error("WLine: " @ %line); BrowserSearchMatchList.addRow(%this.rowNum++, %line); if(%isLastRow) %this.state = "done"; @@ -1059,13 +1047,14 @@ function TWBText::onDatabaseQueryResult(%this,%status,%resultString,%key) { if(%this.key != %key) return; - echo("TWB RECV: " @ %status); +// echo("TWB RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) { case "editWarriorDesc": %this.state = "done"; + WP_WarriorDescription.setText(EditDescriptionText.getValue()); Canvas.popDialog(BrowserEditInfoDlg); messageBoxOK("COMPLETE","Warrior Description Changed","W_profile.setValue(1);"); WarriorPropertiesDlg.pendingChanges=""; @@ -1090,24 +1079,13 @@ function TWBText::onDatabaseRow(%this,%row,%isLastRow, %key) { if(!%this.key == %key) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); } //----------------------------------------------------------------------------- function TWBText::connectionTerminated( %this, %key ) { TWBTabView.refresh(); } -//==-- TribeAttribDlg -------------------------------------------------------- -function TribeAttribDlg::onWake(%this) -{ - TribeAttribDlg.tribeName = %tribeName; - $CurrentTribeTag = %TribeTag; - $NewTagAppend = %appending; - $NewTribeTag = ""; - $NewTagPreview = ""; - Canvas.RePaint(); - updateNewTagPreview(); -} //----------------------------------------------------------------------------- //==-- TribePane -------------------------------------------------------------- //----------------------------------------------------------------------------- @@ -1155,7 +1133,7 @@ function TribePane::onDatabaseQueryResult(%this, %status, %resultString , %key) { if ( %this.key != %key ) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) @@ -1192,8 +1170,9 @@ function TribePane::onDatabaseQueryResult(%this, %status, %resultString , %key) %this.state = "done"; GetProfileHdr(0,getFields(%status,2)); TWBText.Clear(); + %isMember = getTribeMember(TProfileHdr.TribeName); %Tdesc = "Recruiting: " @ - (TProfileHdr.recruiting ? "YES Request Invite" : "NO"); + (TProfileHdr.recruiting ? (%isMember ? "YES" : "YES Request Invite") : "NO"); %Tdesc = %Tdesc @ "" NL ""; TWBText.setText(%TDesc); TProfileHdr.Desc = %resultString; @@ -1279,7 +1258,7 @@ function TribePane::onDatabaseRow(%this, %row, %isLastRow, %key) { if ( %this.key != %key ) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); switch$(%this.state) { case "tribeRoster": @@ -1467,7 +1446,7 @@ function PlayerPane::onDatabaseQueryResult(%this,%status,%resultString,%key) { if(%this.key != %key) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) @@ -1481,26 +1460,16 @@ function PlayerPane::onDatabaseQueryResult(%this,%status,%resultString,%key) PlayerPix.setBitmap(TProfileHdr.playerGfx); else PlayerPix.setBitmap($PlayerGfx); -// if(%isCaller) -// { -// %newText = "OPTIONS:\n\n"; -// %newText = %newText @ "Edit Warrior Name\n"; -// %newText = %newText @ "Edit Description\n"; -// } - %profileText = "" @ %newText @ "\nPLAYER PROFILE:\n\n"; - %profileText = %profileText @ "Registered:" SPC "" @ TProfileHdr.registered @ "\n"; - %profileText = %profileText @ "Online:" SPC (TProfileHdr.onLine ? "YES":"NO") @ "\n"; + %profileText = " \n"; + %profileText = %profileText @ "Registered:" SPC TProfileHdr.registered @ "\n"; + %profileText = %profileText @ "Online: " SPC (TProfileHdr.onLine ? "YES":"NO") @ "\n"; if(trim(TProfileHdr.playerURL) !$= "") - %profileText = %profileText @ "WebSite:" SPC ""@TProfileHdr.playerURL@"\n"; + %profileText = %profileText @ "WebSite: " SPC ""@TProfileHdr.playerURL@"\n\n"; else - %profileText = %profileText @ "WebSite:" SPC "TRIBES 2 BABY!\n"; + %profileText = %profileText @ "WebSite: " SPC "www.tribes2.com\n\n"; -// W_Text.setText(W_Text.getText() @ "Preferred Armor:" SPC "SCOUT\n"); -// W_Text.setText(W_Text.getText() @ "Preferred Weapon:" SPC "SNIPER RIFLE\n"); -// W_Text.setText(W_Text.getText() @ "Preferred Game:" SPC "CTF\n"); -// W_Text.setText(W_Text.getText() @ "Preferred Role:" SPC "DEFENSE\n"); - %profileText = %profileText @ ""; + %profileText = %profileText @ ""; W_Text.setText(%profileText @ %resultString); TProfileHdr.Desc = %resultString; if( w_memberlist.rowCount() ==0 ) @@ -1598,12 +1567,15 @@ function PlayerPane::onDatabaseQueryResult(%this,%status,%resultString,%key) MessageBoxOK("CONFIRMED",getField(%status,1)); case "changePlayerName": %this.state = "done"; - echo("wus:"@WonUpdateCertificate()); +// echo("wus:"@WonUpdateCertificate()); TProfileHdr.playername = NewNameEdit.getValue(); wp_currentname.setText(NewNameEdit.getValue()); twbTabView.setTabText(twbTabView.getSelectedId(),NewNameEdit.getValue()); w_profile.setValue(1); MessageBoxOK("CONFIRMED","Warrior name has been changed." NL "This will require you to close and restart the game to ensure proper function","WarriorPropertiesDlg.onWake();"); + case "clearWarriorDescription": + %this.state = "done"; + MessageBoxOK("CONFIRMED","Warrior Description Cleared"); } } else if (getSubStr(getField(%status,1),0,9) $= "ORA-04061") @@ -1623,7 +1595,7 @@ function PlayerPane::onDatabaseRow(%this,%row,%isLastRow,%key) { if(%this.key != %key) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); switch$(%this.state) { case "warriorHistory": @@ -1803,7 +1775,7 @@ function W_MemberList::onRightMouseDown( %this, %column, %row, %mousePos ) } function w_MemberList::onAdd(%this) { - W_MemberList.addStyle( 1, "Univers Condensed", 12 , "150 150 150", "100 100 000", "000 000 100" ); + W_MemberList.addStyle( 1, "Univers", 12 , "150 150 150", "200 200 200", "60 60 60" ); } //==-------------------------------------------------------------------------- function WarriorPopupDlg::onWake( %this ) @@ -1946,7 +1918,7 @@ function MemberList::onRightMouseDown( %this, %column, %row, %mousePos ) } function Memberlist::onAdd(%this) { - MemberList.addStyle( 1, "Univers Condensed", 12 , "150 150 150", "100 100 000", "000 000 100" ); + MemberList.addStyle( 1, "Univers", 12 , "150 150 150", "200 200 200", "60 60 60" ); } //----------------------------------------------------------------------------- function TribeMemberPopupDlg::onWake( %this ) @@ -2137,7 +2109,7 @@ function TribePropertiesDlg::ClearDescription(%this) TP_TribeDescription.setText(""); TProfileHdr.Desc = ""; TWBText.editType = "tribe"; - canvas.SetCursor(ArrowWaitCursor); + canvas.SetCursor(ArrowWaitCursor); DatabaseQuery(15,TProfileHdr.tribename TAB getRecordCount(%desc) TAB %desc,TribePane,TribePane.key); } //----------------------------------------------------------------------------- @@ -2150,12 +2122,18 @@ function TribePropertiesDlg::UpdateDescription(%this) function TribePropertiesDlg::RefreshTag(%this) { %this.pendingChanges = "YES"; + %playerName = GetField( WonGetAuthInfo(), 0 ); + + // Validate the tribe tag: %ntag = TP_NewTag.getValue(); - %playerName = GetField(GetRecord(WonGetAuthInfo(),0),0); + %realTag = StripMLControlChars( %ntag ); + if ( %ntag !$= %realTag ) + TP_NewTag.setValue( %realTag ); + if ( TP_PrePendFlagBtn.getValue()==0 ) - TP_PreviewTag.setValue( %playerName @ %ntag); + TP_PreviewTag.setValue( %playerName @ %realTag ); else - TP_PreviewTag.setValue(%ntag @ %playerName); + TP_PreviewTag.setValue( %realTag @ %playerName ); } //----------------------------------------------------------------------------- function TribePropertiesDlg::LoadGfxPane(%this) @@ -2209,6 +2187,7 @@ function WarriorPropertiesDlg::onWake(%this) UrlEdit.setValue(TProfileHdr.playerURL); WP_CurrentName.setValue(TProfileHdr.playername); NewNameEdit.setValue(""); + WP_WarriorDescription.setText(TProfileHdr.Desc); %this.LoadGfxPane(); } //----------------------------------------------------------------------------- @@ -2220,6 +2199,8 @@ function WarriorPropertiesDlg::Close(%this) else { Canvas.popDialog(%this); + w_GraphicsControl.setVisible(0); + W_ProfilePane.setVisible(1); W_Profile.setValue(1); } } @@ -2233,27 +2214,31 @@ function WarriorPropertiesDlg::EditDescription(%this) //----------------------------------------------------------------------------- function WarriorPropertiesDlg::ClearDescription(%this) { - MessageBoxYesNo("CONFIRM","Clear your Players Description?","doClearDescription();",""); + MessageBoxYesNo("CONFIRM","Clear your Players Description?","WarriorPropertiesDlg.doClearDescription();",""); } //----------------------------------------------------------------------------- function WarriorPropertiesDlg::doClearDescription(%this) { PlayerPane.key = LaunchGui.key++; - TProfileHdr.Desc = "no description"; + PlayerPane.state = "clearWarriorDescription"; + TProfileHdr.Desc = "NONE"; TWBText.editType = "warrior"; canvas.SetCursor(ArrowWaitCursor); %this.pendingChanges = ""; - DatabaseQuery(17,TProfileHdr.Playername TAB getRecordCount(%desc) TAB %desc,PlayerPane,PlayerPane.key); + EditDescriptionText.setText("No Description On File"); + WP_WarriorDescription.setText(EditDescriptionText.getText()); + DatabaseQuery(17,TProfileHdr.Desc,PlayerPane,PlayerPane.key); } //----------------------------------------------------------------------------- function WarriorPropertiesDlg::LoadGfxPane(%this) { PlayerGraphic.setBitmap(PlayerPix.bitmap); %ctrl = WarriorGraphicsList; + %width = getSubStr(%ctrl.getExtent(),0,3)-4; %fileSpec = "*.jpg"; %ctrl.clearColumns(); %ctrl.clear(); - %ctrl.addColumn( 0, "FILENAME", 100, 0, 140 ); + %ctrl.addColumn( 0, "FILENAME",%width, 0, 200 ); %id = -1; %rowId = ""; for ( %file = findFirstFile( %fileSpec ); %file !$= ""; %file = findNextFile( %fileSpec ) ) diff --git a/base/scripts/webemail.cs b/base/scripts/webemail.cs index 382b9f3..81d5fe6 100644 --- a/base/scripts/webemail.cs +++ b/base/scripts/webemail.cs @@ -118,15 +118,14 @@ function EmailMessageDelete() //----------------------------------------------------------------------------- function DoEmailDelete(%qnx, %mid, %owner, %key, %row) { - error("QNX: " @ %qnx TAB %mid TAB %row); EM_ReplyBtn.setActive( false ); EM_ReplyToAllBtn.setActive( false ); EM_ForwardBtn.setActive( false ); EM_DeleteBtn.setActive( false ); EM_BlockBtn.setActive( false ); - EmailMessageVector.deleteLine(EmailMessageVector.getLineIndexByTag(%mid)); EM_Browser.removeRowByIndex( %row ); + EmailMessageVector.deleteLine(EmailMessageVector.getLineIndexByTag(%mid)); if(%qnx==6) EmailGui.dumpCache(); @@ -300,7 +299,7 @@ function EmailGetTextDisplay(%text) else %curList = ","; - while((%pos = strpos(%curList, ",", %strStart)) != -1 && %cl++ < 50) + while((%pos = strpos(%curList, ",", %strStart)) != -1) { if(%strStart==0) %to = trim(getLinkNameOnly(getSubStr(%curList, %strStart, %pos-%strStart))); @@ -321,7 +320,7 @@ function EmailGetTextDisplay(%text) else %curList = ","; - while((%pos = strpos(%curList, ",", %strStart)) != -1 && %ck++<50) + while((%pos = strpos(%curList, ",", %strStart)) != -1) { if(%strStart==0) %ccLine = getLinkNameOnly(getSubStr(%curList, %strStart, %pos-%strStart)); @@ -362,13 +361,13 @@ function CheckEmail(%calledFromSched) { if(EmailGui.checkingEmail) { - echo("Check In Progress"); +// echo("Check In Progress"); return; } if(EmailGui.checkSchedule && !%calledFromSched) { - echo("Email Schedule " @ EmailGui.checkSchedule @ "Cancelled"); +// echo("Email Schedule " @ EmailGui.checkSchedule @ "Cancelled"); cancel(EmailGui.checkSchedule); // cancel schedule } EmailGui.checkSchedule = ""; @@ -431,7 +430,7 @@ function EMailComposeDlg::onDatabaseQueryResult(%this, %status, %RowCount_Result { if(%this.key != %key) return; - echo("RECV: " @ %status TAB %RowCount_Result); +// echo("RECV: " @ %status TAB %RowCount_Result); if(getField(%status,0)==0) { switch$(%this.state) @@ -460,6 +459,8 @@ function EmailComposeDlg::Cancel(%this) //----------------------------------------------------------------------------- function EmailComposeDlg::SendMail(%this) { + $EmailToAddress = Email_ToEdit.getValue(); + $EmailSubject = EMail_Subject.getValue(); // NEED TO CHECK FOR DUPLICATES if(trim($EmailToAddress) $= "") MessageBoxOK("No Address","TO Address may not be left blank. Please enter a player name to send this message to."); @@ -476,7 +477,7 @@ function EMailBlockDlg::onDatabaseQueryResult(%this,%status,%ResultString,%key) { if(%this.key != %key) return; - echo("RECV: " @ %status TAB %ResultString); +// echo("RECV: " @ %status TAB %ResultString); if(getField(%status,0)==0) { switch$(%this.state) @@ -506,7 +507,7 @@ function EMailBlockDlg::onDatabaseRow(%this,%row,%isLastRow,%key) { if(%this.key != %key) return; - echo("RECV: " @ %row TAB %isLastRow); +// echo("RECV: " @ %row TAB %isLastRow); switch$(%this.state) { case "names": @@ -595,7 +596,7 @@ function AddressDlg::onDatabaseQueryResult(%this,%status,%resultString,%key) { if(%this.key != %key) return; - echo("RECV: " @ %status TAB %resultString); +// echo("RECV: " @ %status TAB %resultString); if(getField(%status,0)==0) { switch$(%this.state) @@ -663,7 +664,7 @@ function AddressDlg::onDatabaseRow(%this,%row,%isLastRow,%key) if(%this.key != %key) return; - echo("RECV : " @ %row); +// echo("RECV : " @ %row); switch$(%this.state) { case "memberList": @@ -913,7 +914,6 @@ function AddressDlg::onWake(%this) //-- EMailGui ---------------------------------------------------------------- function EmailGui::onWake(%this) { - error("EMailGui.onWake" TAB %this.cacheFile); // Make these buttons inactive until a message is selected: EM_ReplyBtn.setActive( false ); EM_ReplyToAllBtn.setActive( false ); @@ -976,7 +976,7 @@ function EMailGui::onDatabaseQueryResult(%this, %status, %RowCount_Result, %key) { if(%this.key != %key) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) @@ -988,6 +988,7 @@ function EMailGui::onDatabaseQueryResult(%this, %status, %RowCount_Result, %key) %this.messageCount = 0; %this.message = ""; %this.state = "NewMail"; + %this.getCache(); } else { @@ -1000,7 +1001,7 @@ function EMailGui::onDatabaseQueryResult(%this, %status, %RowCount_Result, %key) EmailGui.btnClicked = false; } %this.checkSchedule = schedule(1000 * 60 * 5, 0, CheckEmail, true); - echo("scheduling Email check " @ %this.checkSchedule @ " in 5 minutes"); +// echo("scheduling Email check " @ %this.checkSchedule @ " in 5 minutes"); } case "sendMail": %this.state = "done"; @@ -1054,7 +1055,7 @@ function EMailGui::onDatabaseRow(%this, %row,%isLastRow,%key) if(%this.key != %key) return; - echo("RECV: " @ %row NL %isLastRow); +// echo("RECV: " @ %row NL %isLastRow); switch$(%this.state) { case "DeletedMail": @@ -1075,10 +1076,7 @@ function EMailGui::onDatabaseRow(%this, %row,%isLastRow,%key) EmailMessageVector.pushBackLine(%this.message, getField(%this.message, 0)); if(%isLastRow) %this.outputVector(); - case "NewMail": - if(%this.messageCount++ == 1) - %this.getCache(); - + case "NewMail": %this.checkingEmail = ""; %ID = getField(%row,0); %senderQuad = getFields(%row,1,4); @@ -1110,7 +1108,7 @@ function EMailGui::onDatabaseRow(%this, %row,%isLastRow,%key) EmailGui.dumpCache(); EmailGui.loadCache(); %this.checkSchedule = schedule(1000 * 60 * 5, 0, CheckEmail, true); - echo("scheduling Email check " @ %this.checkSchedule @ " in 5 minutes"); +// echo("scheduling Email check " @ %this.checkSchedule @ " in 5 minutes"); } } } @@ -1175,8 +1173,7 @@ function EmailGui::loadCache( %this ) EM_Browser.clear(); EMailMessageVector.clear(); EMailInboxBodyText.setText(""); - %fileName = $EmailCachePath @ "email0"; - error("EMAIL CACHE" @ %fileName); + %fileName = $EmailCachePath @ "email0"; %file = new FileObject(); if ( %this.cacheFile $= "" ) { @@ -1220,17 +1217,6 @@ function EmailGui::dumpCache( %this ) { %guid = getField( WONGetAuthInfo(), 3 ); if ( %this.cacheFile $= "" ) %this.cacheFile = "email0"; -// { -// %base = $EmailCachePath @ "email"; -// %num = 0; -// %cacheFile = %base @ %num; -// while ( isFile( %cacheFile ) ) -// { -// %num++; -// %cacheFile = %base @ %num; -// } -// %this.cacheFile = %cacheFile; -// } EmailMessageVector.dump( $EmailCachePath @ %this.cacheFile, %guid ); } //----------------------------------------------------------------------------- diff --git a/base/scripts/webforums.cs b/base/scripts/webforums.cs index 364417e..bf7f9ca 100644 --- a/base/scripts/webforums.cs +++ b/base/scripts/webforums.cs @@ -67,32 +67,6 @@ if(!isObject(ForumsMessageVector)) new MessageVector(ForumsMessageVector); } //----------------------------------------------------------------------------- -function ForumsGui::CheesyGradient(%this,%sender,%text,%startColor,%endColor) -{ - - %gText = ""; - if(%endColor > %startColor) - { - %interval = %endColor - %startColor; - for(%x=0;%x"; - } - } - else - { - %interval = %startColor - %endColor; - for(%x=0;%x"; - } - } - error("CG:"@ %startColor TAB %endColor TAB %interval); - - %gText = %gText @ ""; - error("CHEESY:" @ %gText); -} -//----------------------------------------------------------------------------- function DateStrCompare(%date1,%date2) { %d1 = getSubStr(%date1,0,2); @@ -283,7 +257,7 @@ function ForumsMessageAddRow(%text) if(ForumsMessageList.getRowId(%i) == %parentId) { %parentRow = ForumsMessageList.getRowText(%i); - echo("Found parent"); +// echo("Found parent"); break; } } @@ -365,6 +339,7 @@ function ForumsOpenThread(%tid) //----------------------------------------------------------------------------- function ForumsPost() { + $ForumsSubject = FP_SubjectEdit.getValue(); if ( trim($ForumsSubject) $= "" ) { MessageBoxOK( "POST FAILED", "Your post cannot be accepted without text in the Subject line.", @@ -469,9 +444,18 @@ function ForumsReply() //----------------------------------------------------------------------------- function GetQuotedText() { - ForumsBodyText.setValue("\"" @ trim(ForumsText.getText()) @ "\"\n\n"); - ForumsBodyText.MakeFirstResponder(1); - ForumsBodyText.setCursorPosition(3600); + if(ForumsComposeDlg.parentPost == 0) + { + ForumsBodyText.setValue("ALL YOUR BASE ARE BELONG TO US\n\n"); + ForumsBodyText.MakeFirstResponder(1); + ForumsBodyText.setCursorPosition(3600); + } + else + { + ForumsBodyText.setValue("\"" @ trim(ForumsText.getText()) @ "\"\n\n"); + ForumsBodyText.MakeFirstResponder(1); + ForumsBodyText.setCursorPosition(3600); + } // ForumsBodyText.setCursorPosition(strLen(ForumsBodyTExt.getText())+5); } //----------------------------------------------------------------------------- @@ -504,7 +488,7 @@ function GetTopicsList() ForumsTopicsList.clear(); canvas.SetCursor(ArrowWaitCursor); ForumsTopicsList.clearList(); - DatabaseQueryArray(8,200,ForumsComposeDlg.forum,ForumsGui,ForumsGui.key); + DatabaseQueryArray(8,80,ForumsComposeDlg.forum,ForumsGui,ForumsGui.key); ForumsTopicsList.refreshFlag = 0; } //----------------------------------------------------------------------------- @@ -589,7 +573,7 @@ function ForumsGui::onDatabaseQueryResult(%this,%status,%resultString,%key) { if(%this.key != %key) return; - echo("RECV: " @ %status TAB %resultString); +// echo("RECV: " @ %status TAB %resultString); if(getField(%status,0)==0) { switch$(%this.state) @@ -716,7 +700,7 @@ function ForumsGui::onDatabaseRow(%this,%row,%isLastRow,%key) { if(%this.key != %key) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); %forumTID = getField(ForumsList.getRowTextbyId(ForumsList.getSelectedID()),2); switch$(%this.state) { @@ -749,7 +733,6 @@ function ForumsGui::onDatabaseRow(%this,%row,%isLastRow,%key) ForumShell.setTitle("FORUMS: " @ getField(ForumsList.getRowTextbyID(ForumsList.getSelectedID()),0)); ForumsTopicsList.updateReadStatus(); %this.refreshFlag = false; - error("TID: " @ ForumsMessageVector.tid); if ( ForumsGui.LaunchTopic !$= "" ) { ForumsTopicsList.selectTopic( ForumsGui.LaunchTopic ); @@ -927,7 +910,7 @@ function TopicsPopupDlg::onWake( %this ) //----------------------------------------------------------------------------- function TopicsPopupMenu::onSelect( %this, %id, %text ) { - echo("TPM RECV: " @ %id TAB %text); +// echo("TPM RECV: " @ %id TAB %text); switch( %id ) { case 0: // 0 Reset Cache @@ -1122,7 +1105,6 @@ function ForumsMessageList::loadCache( %this, %forumTID) ForumsMessageVector.clear(); ForumsMessageList.clear(); ForumsMessageVector.tid = %forumTID; - error("BFLAG: " @ ForumsGui.bflag TAB %forumTID); switch( ForumsGui.bflag ) { case 0: @@ -1225,11 +1207,10 @@ function ForumsMessageList::loadCache( %this, %forumTID) FO_EditBtn.visible = true; } } -// error( "** ADDING MESSAGE FROM CACHE - " @ %text @ " **" ); if(%this.allRead && DateStrCompare(%this.lastDate,%date)) %text = setRecord( %text, 0, "1" ); - echo( "** ADDING MESSAGE FROM CACHE - " @ %postId @ " **" ); +// echo( "** ADDING MESSAGE FROM CACHE - " @ %postId @ " **" ); ForumsMessageVector.pushBackLine( %text, %postId ); } } @@ -1319,7 +1300,7 @@ function ForumsMessagelist::onDatabaseQueryResult(%this,%status,%resultString,%k { if(%this.key != %key) return; - echo("RECV: " @ %status TAB %resultString); +// echo("RECV: " @ %status TAB %resultString); if(getField(%status,0)==0) { switch$(%this.state) diff --git a/base/scripts/webnews.cs b/base/scripts/webnews.cs index ede3343..e605ede 100644 --- a/base/scripts/webnews.cs +++ b/base/scripts/webnews.cs @@ -87,7 +87,7 @@ function NewsGui::onDatabaseQueryResult(%this, %status, %RowCount_Result, %key) { if(%key != %this.key) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); %this.maxDate = " "; %this.minDate = " "; if(getField(%status,0)==0) @@ -151,7 +151,7 @@ function NewsGui::onDatabaseRow(%this, %row,%isLastRow,%key) { if ( %key != %this.key ) return; - echo("RECV: " @ %row); +// echo("RECV: " @ %row); %this.article[%this.articleCount] = %row; %this.recordSet--; if ( %this.articleCount == 0 ) @@ -228,7 +228,7 @@ function NewsPostDlg::onDatabaseQueryResult(%this, %status, %RowCount_Result, %k { if(%key != %this.key) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { switch$(%this.state) @@ -281,9 +281,7 @@ function NewsText::onURL(%this, %url) Canvas.pushDialog( NewsPostDlg ); case "deletenews": - NewsPostDlg.key = LaunchGui.key++; - NewsPostDlg.state = "delete"; - DatabaseQuery(3,getFields(%url,2), NewsPostDlg, NewsPostDlg.Key); + MessageBoxYesNo("CONFIRM","Delete this Article?","NewsPostDlg.doNewsDelete(\"" @ getField(%url,2) TAB getField(%url,3) @ "\");","canvas.setCursor(DefaultCursor);"); case "topiclink": %articleId = getField(%url,2); @@ -294,6 +292,13 @@ function NewsText::onURL(%this, %url) } } //----------------------------------------------------------------------------- +function NewsPostDlg::doNewsDelete(%this,%fields) +{ + %this.key = LaunchGui.key++; + %this.state = "delete"; + DatabaseQuery(3,%fields, %this, %this.key); +} +//----------------------------------------------------------------------------- function NewsHeadlines::onSelect( %this, %id, %text ) { NewsText.scrollToTag( %id ); @@ -302,7 +307,6 @@ function NewsHeadlines::onSelect( %this, %id, %text ) function NewsGui::getPreviousNewsItems( %this ) { // Fetch the next batch of newer news items: - error("FETCHING PREV NEWS ITEMS"); if ( %this.set == 1 ) return; canvas.SetCursor(ArrowWaitCursor); @@ -316,7 +320,6 @@ function NewsGui::getPreviousNewsItems( %this ) function NewsGui::getNextNewsItems( %this ) { // Fetch the next batch of older news items: - error("FETCHING NEXT NEWS ITEMS"); canvas.SetCursor(ArrowWaitCursor); NewsGui.key = LaunchGui.key++; %this.state = "status"; @@ -329,7 +332,7 @@ function NewsMOTDText::onDatabaseQueryResult(%this, %status, %RowCount_Result, % { if(%key != %this.key) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) { NewsEditMOTDBtn.setVisible( getField(%status,2)); @@ -366,7 +369,7 @@ function NewsEditMotdDlg::OnDatabaseQueryResult(%this, %status, %RowCount_Result { if(%key != %this.key) return; - echo("RECV: " @ %status); +// echo("RECV: " @ %status); if(getField(%status,0)==0) %this.state = "proceed"; else if (getSubStr(getField(%status,1),0,9) $= "ORA-04061") diff --git a/base/scripts/webstuff.cs b/base/scripts/webstuff.cs index e609ee9..0d6471e 100644 --- a/base/scripts/webstuff.cs +++ b/base/scripts/webstuff.cs @@ -162,6 +162,15 @@ function HandleDatabaseProxyResponse(%prefix, %params) function DatabaseQueryi(%astr, %args, %proxyObject, %key) { + if ($IRCClient::state !$= IDIRC_CONNECTED) + { + IRCClient::connect(); + if (%proxyObject !$= "") + %proxyObject.onDatabaseQueryResult("1\tORA-04061", "", %key); + + return; + } + // maxRows will be empty $NextDatabaseQueryId++; %id = $NextDatabaseQueryId; @@ -175,8 +184,6 @@ function DatabaseQueryi(%astr, %args, %proxyObject, %key) %args = strreplace(%args, "\\", "\\\\"); %args = strreplace(%args, "\n", "\\n"); - echo("Called DBQueryi - astr: " @ %astr @ " args: " @ %args); - %len = strlen(%args); %i = 0; while(%i+400 < %len) @@ -201,5 +208,5 @@ function DatabaseQueryArray(%ordinal, %maxRows, %args, %proxyObject, %key) function WONUpdateCertificateDone(%errCode, %errStr) { - echo("Got cert back from WON: " @ %errCode @ " = " @ %errStr); + IRCClient::relogin(); } \ No newline at end of file diff --git a/base/version.cs b/base/version.cs index 8e40092..c207feb 100644 --- a/base/version.cs +++ b/base/version.cs @@ -1 +1 @@ -buildVersion.setValue( "MAR 14, 2001, 11:22 PM (dmoore)" ); +buildVersion.setValue( "MAR 28, 2001, 2:09 PM (dmoore)" ); diff --git a/console_start.cs b/console_start.cs index 9b7c039..38ecd8d 100644 --- a/console_start.cs +++ b/console_start.cs @@ -96,6 +96,19 @@ function startAudio() } } +//------------------------------------------------------------------------------ +function repaintCanvas() +{ + if ( isObject( Canvas ) ) + Canvas.repaint(); +} + +function resetCanvas() +{ + if ( isObject( Canvas ) ) + Canvas.reset(); +} + //------------------------------------------------------------------------------ for($i = 1; $i < $Game::argc ; $i++) { @@ -108,14 +121,21 @@ for($i = 1; $i < $Game::argc ; $i++) if (!stricmp(fileExt($arg), ".dif")) { $LaunchMode = "InteriorView"; + //$SkipLogin = true; $TestObjectFileName = $arg; echo($TestObjectFileName); } else if(!stricmp(fileExt($arg), ".dif\"")) { $LaunchMode = "InteriorView"; + //$SkipLogin = true; $TestObjectFileName = getSubStr($arg,1, strlen($arg) - 2); } + else if ( $arg $= "-mod" && $hasNextArg ) + { + setModPaths( $nextArg ); + $i += 2; + } else if($arg $= "-dedicated") { $LaunchMode = "DedicatedServer"; @@ -296,6 +316,8 @@ if($winConsoleEnabled) if( $Pref::useImmersion ) enableImmersion( true ); +$showImmersionDialog = $Pref::useImmersion && $ImmEnabled; + switch( $pref::Shell::lastBackground ) { case 0: @@ -353,7 +375,20 @@ function EULADlg::onWake( %this ) NL "Tribes 2." ); %file = new FileObject(); - if ( %file.openForRead( "Eula.txt" ) ) + %fileOpenSuccess = false; + if (isT2UkBuild()) + { + // Uk EULA + %fileOpenSuccess = %file.openForRead("UKEULA.TXT"); + } + else + { + // US+ EULA + %fileOpenSuccess = %file.openForRead("EULA.TXT"); + } + + + if ( %fileOpenSuccess ) { while ( !%file.isEOF() ) { @@ -394,6 +429,13 @@ function LoginProcess(%editAcct) StartupGui.loginSchedule = StartupGui.schedule( 1000, checkLoginDone,%editAcct ); } +function PasswordProcess() +{ + LoginMessagePopup( "PLEASE WAIT", "Attempting to email you your login password..." ); + WONStartEmailFetch($LoginName); + StartupGui.loginSchedule = StartupGui.schedule( 1000, checkLoginDone,false,true ); +} + //------------------------------------------------------------------------------ function LoginMessageBox( %title, %message, %buttonText, %callback ) { @@ -443,7 +485,7 @@ function EditAccountDlg::onDontUpdate(%this) schedule(0,0,LoginDone); } -function StartupGui::checkLoginDone( %this, %editAcct ) +function StartupGui::checkLoginDone( %this, %editAcct,%emailCheck ) { %result = WONLoginResult(); %code = getField( %result, 1 ); @@ -462,9 +504,13 @@ function StartupGui::checkLoginDone( %this, %editAcct ) switch$(%codeText) { case "WS_DBProxyServ_InvalidUserName": - %msg = "Account Creation Failed - Invalid login name. Login names may only contain letters, numbers and underlines, and must be from 3 to 16 characters in length."; + if(%emailCheck) + %msg = "Email Password Failed - Invalid login name. Please check the login name and try again."; + else + %msg = "Account Creation Failed - Invalid login name. Login names may only contain letters, numbers and underlines, and must be from 3 to 16 characters in length."; case "WS_AuthServ_BadCDKey": - %msg = "Account Creation Failed - Bad CD Key. Please check the CD key for errors."; + case "WS_DBProxyServ_InvalidCDKey": + %msg = "Account Creation Failed - Invalid CD Key. Please check the CD key for errors."; case "WS_TimedOut": %msg = "Login Failed - Server timed out. Your internet connection may be having problems or the servers may be temporarily unavailable."; case "WS_DBProxyServ_KeyInUse": @@ -493,7 +539,12 @@ function StartupGui::checkLoginDone( %this, %editAcct ) %msg = "Account Creation Failed - Your warrior name may not contain profanity. Please choose another warrior name."; default: if(%code <= -2900 && %code >= -2999) - %msg = "Account Creation Failed - That warrior name is already in use. Please choose another warrior name and try again."; + { + if(%code = -2902) + %msg = "Account Creation Failed - That CDKey is already in use." @ %code; + else + %msg = "Account Creation Failed - That warrior name is already in use. Please choose another warrior name and try again. Code = " @ %code; + } else %msg = "Login Failed - Your internet connection may be having problems or the servers may be temporarily unavailable. (Error code: " @ %codeText @ ")"; } @@ -523,6 +574,10 @@ function StartupGui::checkLoginDone( %this, %editAcct ) $CreateAccountSendInfo = %code; Canvas.pushDialog(EditAccountDlg); } + else if(%emailCheck) + { + Canvas.popDialog( LoginMessagePopupDlg ); + } else { schedule( 0, 0, "LoginDone" ); @@ -657,6 +712,7 @@ function CleanUpAndGo() Canvas.setContent( "" ); Canvas.setCursor( "" ); LoginMessagePopupDlg.delete(); + LoginMessageBoxDlg.delete(); ImmSplashDlg.delete(); EULADlg.delete(); if ( !$pref::SkipIntro ) @@ -667,7 +723,6 @@ function CleanUpAndGo() if ( !$SkipLogin ) { EditAccountDlg.delete(); - LoginMessageBoxDlg.delete(); LoginDlg.delete(); CreateAccountDlg.delete(); CloseButtonProfile.delete(); @@ -745,6 +800,7 @@ function CreateAccountDlg::onSubmit() function hideImmSplashDlg() { Canvas.popDialog( ImmSplashDlg ); + StartLoginProcess(); } //------------------------------------------------------------------------------ @@ -764,13 +820,20 @@ function checkIntroDone() function StartLoginProcess() { - Canvas.setCursor( "DefaultCursor" ); if ( !$pref::AcceptedEULA ) { Canvas.pushDialog( EULADlg ); return; } + if ( $showImmersionDialog ) + { + $showImmersionDialog = false; + Canvas.pushDialog( ImmSplashDlg ); + schedule( 2500, 0, hideImmSplashDlg ); + return; + } + if ( !$SkipLogin ) { if ( $LaunchMode $= "Normal" && !$fromLauncher ) @@ -809,15 +872,20 @@ if ($LaunchMode $= "DedicatedServer" || { $Con::logBufferEnabled = false; if($Login) + { + $PlayingOnline = true; LoginProcess(); + } else { if($SkipLogin) { + $PlayingOnline = false; exec("console_end.cs"); } else { + $PlayingOnline = true; WONServerLogin(); schedule(1000, 0, dedCheckLoginDone); } @@ -1080,6 +1148,55 @@ else }; }; + // Message Box dialog: + new GuiControl(LoginMessageBoxDlg) { + profile = "DlgBackProfile"; + horizSizing = "width"; + vertSizing = "height"; + position = "0 0"; + extent = "640 480"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + + new ShellPaneCtrl(LoginMessageBoxFrame) { + profile = "ShellDlgPaneProfile"; + horizSizing = "center"; + vertSizing = "center"; + position = "170 137"; + extent = "300 206"; + minExtent = "48 92"; + visible = "1"; + helpTag = "0"; + + new GuiMLTextCtrl(LoginMessageBoxText) { + profile = "ShellMediumTextProfile"; + horizSizing = "center"; + vertSizing = "bottom"; + position = "32 39"; + extent = "236 18"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + lineSpacing = "2"; + }; + new ShellBitmapButton(LoginMessageBoxButton) { + profile = "ShellButtonProfile"; + horizSizing = "center"; + vertSizing = "bottom"; + position = "70 140"; + extent = "120 38"; + minExtent = "32 38"; + visible = "1"; + command = "LoginMessageBoxButtonProcess();"; + accelerator = "return"; + helpTag = "0"; + text = "OK"; + simpleStyle = "0"; + }; + }; + }; + // Immersion splash dialog: new GuiControl (ImmSplashDlg) { profile = "GuiDefaultProfile"; @@ -1101,7 +1218,7 @@ else visible = "1"; helpTag = "0"; - new GuiBitmapCtrl() { + new GuiChunkedBitmapCtrl() { profile = "GuiDefaultProfile"; horizSizing = "width"; vertSizing = "height"; @@ -1110,7 +1227,7 @@ else minExtent = "8 8"; visible = "1"; helpTag = "0"; - bitmap = "gui/ImmersionLogo.png"; + bitmap = "gui/Immersion.jpg"; wrap = "0"; }; }; @@ -1215,195 +1332,164 @@ else // (copied from LoginGui.gui, LoginMessageBoxDlg.gui and CreateAccountDlg.gui) // Login dialog: new GuiControl(LoginDlg) { - profile = "GuiDefaultProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "0 0"; - extent = "640 480"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; + profile = "GuiDefaultProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "0 0"; + extent = "640 480"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; - new ShellPaneCtrl() { - profile = "ShellDlgPaneProfile"; - horizSizing = "center"; - vertSizing = "center"; - position = "90 156"; - extent = "460 167"; - minExtent = "48 92"; - visible = "1"; - helpTag = "0"; - text = "LOGIN"; - noTitleBar = "0"; + new ShellPaneCtrl() { + profile = "ShellDlgPaneProfile"; + horizSizing = "center"; + vertSizing = "center"; + position = "72 143"; + extent = "495 194"; + minExtent = "48 92"; + visible = "1"; + helpTag = "0"; + text = "LOGIN"; + maxLength = "255"; + noTitleBar = "0"; - new GuiTextCtrl() { - profile = "ShellTextRightProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "30 47"; - extent = "85 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "Account Name:"; - }; - new ShellTextEditCtrl(LoginEditBox) { - profile = "NewTextEditProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "111 39"; - extent = "180 38"; - minExtent = "32 38"; - visible = "1"; - variable = "$LoginName"; - altCommand = "LoginProcess();"; - helpTag = "0"; - historySize = "0"; - maxLength = "16"; - password = "0"; - glowOffset = "9 9"; - }; - new GuiTextCtrl() { - profile = "ShellTextRightProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "30 77"; - extent = "85 22"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - text = "Password:"; - }; - new GuiLoginPasswordCtrl(LoginPasswordBox) { - profile = "NewTextEditProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "111 68"; - extent = "180 38"; - minExtent = "32 38"; - visible = "1"; - variable = "$LoginPassword"; - altCommand = "LoginProcess();"; - helpTag = "0"; - historySize = "0"; - maxLength = "16"; - password = "1"; - glowOffset = "9 9"; - }; - new ShellToggleButton() { - profile = "ShellRadioProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "118 106"; - extent = "160 27"; - minExtent = "26 27"; - visible = "1"; - variable = "$pref::RememberPassword"; - helpTag = "0"; - text = "REMEMBER PASSWORD"; - }; - new ShellBitmapButton() { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "291 39"; - extent = "144 38"; - minExtent = "32 38"; - visible = "1"; - command = "LoginProcess(false);"; - helpTag = "0"; - text = "LOG IN"; - simpleStyle = "0"; - }; - new ShellBitmapButton() { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "291 70"; - extent = "144 38"; - minExtent = "32 38"; - visible = "1"; - command = "CreateAccount();"; - helpTag = "0"; - text = "CREATE NEW ACCOUNT"; - simpleStyle = "0"; - }; - new ShellBitmapButton() { - profile = "ShellButtonProfile"; - horizSizing = "right"; - vertSizing = "bottom"; - position = "290 102"; - extent = "144 38"; - minExtent = "32 38"; - visible = "1"; - command = "LoginProcess(true);"; - helpTag = "0"; - text = "EDIT ACCOUNT"; - simpleStyle = "0"; - }; - new ShellBitmapButton(LaunchToolbarCloseButton) { - profile = "CloseButtonProfile"; - horizSizing = "left"; - vertSizing = "bottom"; - position = "411 0"; - extent = "33 26"; - minExtent = "33 26"; - visible = "1"; - command = "quit();"; - accelerator = "escape"; - helpTag = "0"; - simpleStyle = "1"; - }; - }; - }; - - // Message Box dialog: - new GuiControl(LoginMessageBoxDlg) { - profile = "DlgBackProfile"; - horizSizing = "width"; - vertSizing = "height"; - position = "0 0"; - extent = "640 480"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - - new ShellPaneCtrl(LoginMessageBoxFrame) { - profile = "ShellDlgPaneProfile"; - horizSizing = "center"; - vertSizing = "center"; - position = "170 137"; - extent = "300 206"; - minExtent = "48 92"; - visible = "1"; - helpTag = "0"; - - new GuiMLTextCtrl(LoginMessageBoxText) { - profile = "ShellMediumTextProfile"; - horizSizing = "center"; - vertSizing = "bottom"; - position = "32 39"; - extent = "236 18"; - minExtent = "8 8"; - visible = "1"; - helpTag = "0"; - lineSpacing = "2"; - }; - new ShellBitmapButton(LoginMessageBoxButton) { - profile = "ShellButtonProfile"; - horizSizing = "center"; - vertSizing = "bottom"; - position = "70 140"; - extent = "120 38"; - minExtent = "32 38"; - visible = "1"; - command = "LoginMessageBoxButtonProcess();"; - accelerator = "return"; - helpTag = "0"; - text = "OK"; - simpleStyle = "0"; - }; - }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "37 47"; + extent = "85 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Account Name:"; + maxLength = "255"; + }; + new ShellTextEditCtrl(LoginEditBox) { + profile = "NewTextEditProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "118 39"; + extent = "180 38"; + minExtent = "32 38"; + visible = "1"; + variable = "$LoginName"; + altCommand = "LoginProcess();"; + helpTag = "0"; + maxLength = "16"; + historySize = "0"; + password = "0"; + glowOffset = "9 9"; + }; + new GuiTextCtrl() { + profile = "ShellTextRightProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "37 77"; + extent = "85 22"; + minExtent = "8 8"; + visible = "1"; + helpTag = "0"; + text = "Password:"; + maxLength = "255"; + }; + new GuiLoginPasswordCtrl(LoginPasswordBox) { + profile = "NewTextEditProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "118 69"; + extent = "180 38"; + minExtent = "32 38"; + visible = "1"; + variable = "$LoginPassword"; + altCommand = "LoginProcess();"; + helpTag = "0"; + maxLength = "16"; + historySize = "0"; + password = "1"; + glowOffset = "9 9"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "300 39"; + extent = "147 38"; + minExtent = "32 38"; + visible = "1"; + command = "LoginProcess(false);"; + helpTag = "0"; + text = "LOG IN"; + simpleStyle = "0"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "300 69"; + extent = "147 38"; + minExtent = "32 38"; + visible = "1"; + command = "CreateAccount();"; + helpTag = "0"; + text = "CREATE NEW ACCOUNT"; + simpleStyle = "0"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "300 99"; + extent = "147 38"; + minExtent = "32 38"; + visible = "1"; + command = "LoginProcess(true);"; + helpTag = "0"; + text = "EDIT ACCOUNT"; + simpleStyle = "0"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "300 129"; + extent = "147 38"; + minExtent = "32 38"; + visible = "1"; + command = "quit();"; + accelerator = "escape"; + helpTag = "0"; + text = "QUIT"; + simpleStyle = "0"; + }; + new ShellToggleButton() { + profile = "ShellRadioProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "122 104"; + extent = "167 27"; + minExtent = "26 27"; + visible = "1"; + variable = "$pref::RememberPassword"; + helpTag = "0"; + text = "REMEMBER PASSWORD"; + maxLength = "255"; + }; + new ShellBitmapButton() { + profile = "ShellButtonProfile"; + horizSizing = "right"; + vertSizing = "bottom"; + position = "118 129"; + extent = "180 38"; + minExtent = "32 38"; + visible = "1"; + command = "PasswordProcess(true);"; + helpTag = "0"; + text = "EMAIL ME MY PASSWORD"; + simpleStyle = "0"; + }; + }; }; // Edit Account dialog: @@ -1871,13 +1957,19 @@ else $LoginName = $pref::LastLoginName; } + // Set the default cursor so it shows in all login modes + Canvas.setCursor( "DefaultCursor" ); + + // Check for software rendering and bail, if that's what it is... + if ( ($platform $= "Linux") && + ((strstr($pref::Video::defaultsRenderer, "Indirect") != -1) || + (strstr($pref::Video::defaultsRenderer, "Mesa X11") != -1)) ) { + LoginMessageBox( "ERROR", "Your 3D renderer (" @ $pref::Video::defaultsRenderer @ ") does not appear to be configured for hardware acceleration.", "OK", "quit();" ); + return; + } + // Finally, let's get it on: Canvas.setContent( StartupGui ); -// if ( $ImmEnabled ) -// { -// Canvas.pushDialog( ImmSplashDlg ); -// schedule( 2500, 0, hideImmSplashDlg ); -// } if ( !$pref::SkipIntro ) {