ProPack init and final release

This commit is contained in:
wcinquan 2014-07-11 23:55:47 -04:00
commit c541a465b8
25 changed files with 5166 additions and 0 deletions

View file

@ -0,0 +1,133 @@
// #category = ProPack
// #name = ProPack Auto Chat
// #version = 6.81
// #date = June 30, 2001
// #warrior = MeBaD
// #web = http://propack.tribes2.org
// #description = Auto Chat functions for ProPack
// #credit = Neofight, Widow, Blotter
// #status = vgrd
package ProPackAutoChat {
function ProPackAutoGenBoom(%msgType, %msgString, %victimname, %vgen, %vposs, %killername, %kgen, %kposs, %damageType) {
if ($ProPackPrefs::AutoGenBoom) {
if (Strstr(%msgString, "You received a") != -1) { // Make sure it's you
commandtoserver('TeamMessageSent', "Gens dead!~wene.generator");
}
}
}
function ProPackAutoVPadBoom(%msgType, %msgString, %victimname, %vgen, %vposs, %killername, %kgen, %kposs, %damageType) {
if ($ProPackPrefs::AutoVPadBoom) {
if (Strstr(%msgString, "You received a") != -1) { // Make sure it's you
commandToServer('CannedChat', 'ChatEnemyVehicleDestroyed', false );
}
}
}
function ProPackAutoTaunt(%msgType, %msgString, %victimname, %vgen, %vposs, %killername, %kgen, %kposs, %damageType) {
if ($ProPackPrefs::Autotaunt) {
$ProPackTauntCount++;
if ($ProPackTauntCount > 7) {
$ProPackTauntCount = 0;
}
%killer = StripNameColors(detag(%killername));
if ((Strstr($PPName, %killer) != -1) && (Strlen(%killer) > 0)) {
issueChatCmd( $ProPackAutoTauntCM, $ProPackTauntCount );
}
}
}
function TauntLikeHell(%this) {
if (%this) {
cancel($YOUSPAMMINGBASTARD);
$ProPackTauntCount++;
if ($ProPackTauntCount > 7) {
$ProPackTauntCount = 0;
}
issueChatCmd( $ProPackAutoTauntCM, $ProPackTauntCount );
$YOUSPAMMINGBASTARD = schedule(500, 0, "TauntLikeHell", %this);
} else {
cancel($YOUSPAMMINGBASTARD);
}
}
// Enables Editable chat menu's + ProPack Taunt variable
function addChat(%keyDesc, %command) {
if ($ProPackAutoTauntCM $= "") {
$ProPackAutoTauntCM = $CurrentChatMenu;
}
%key = firstWord(%keyDesc);
%text = restWords(%keyDesc);
%cm = $CurrentChatMenu;
if (strstr(%command, "~w") != -1) { // with a ~ it must be custom!
%wav = firstWord(%command);
%isteam = restWords(%command);
%NewText = %text @ %wav;
%cm.bindCmd(keyboard, %key, "ProPackIssueChat(\"" @ %isteam @ "\",\"" @ %NewText @ "\");", "");
} else {
parent::addChat(%keyDesc, %command); // so Custom voice packs can work
return; // so it dosen't screw up the menu counts
}
%cm.option[%cm.optionCount] = %key @ ": " @ %text;
%cm.command[%cm.optionCount] = %command;
%cm.isMenu[%cm.optionCount] = 0;
%cm.optionCount++;
}
function ProPackIssueChat(%where, %what) {
if (%where $= "Team") {
commandtoserver('TeamMessageSent', %what);
} else {
commandtoserver('MessageSent', %what);
}
cancelChatMenu();
}
function DispatchLaunchMode() {
addMessageCallBack('MsgLegitKill', ProPackAutoTaunt);
addMessageCallBack('msgGenDes', ProPackAutoGenBoom);
addMessageCallBack('msgVSDes', ProPackAutoVPadBoom);
parent::DispatchLaunchMode();
}
function EnemyMute(%val) {
if (%val) {
for (%i = 0; %i < PlayerListGroup.getCount(); %i++) {
%object = PlayerListGroup.getObject(%i);
if (%object.teamid != $PPTeam) {
if ((%object.chatMuted) && (!$EnemyTeamMuted)) {
// fixes the double bug stuff
} else {
commandToServer( 'TogglePlayerMute', %object.clientId ); //only mutes your enemy
}
} else {
if (%object.chatMuted) commandToServer( 'TogglePlayerMute', %object.clientId ); //clears any muted players on your team
}
}
schedule(1000, 0, "MuteNotice");
}
}
function MuteNotice() {
if ($EnemyTeamMuted) {
$EnemyTeamMuted = false;
addMessageHudLine( "\c4*** \c2Enemy Team Unmuted \c4***");
} else {
$EnemyTeamMuted = true;
addMessageHudLine( "\c4*** \c2Enemy Team Muted \c4***");
}
}
};
activatePackage(ProPackAutoChat);

View file

@ -0,0 +1,95 @@
// #category = ProPack
// #name = ProPack Demo
// #version = 6.82
// #date = September 29, 2001
// #warrior = Neofight
// #email = neofight@tribes2.org
// #description = Static line like T1's old chat in InfoHud displays when you are recording a demo, reminds you to start one when in tourney mode, automatically names your demos for you and auto-stops them at the end of a map.
// #status = beta 6
// #credit = DEDEN, MeBaD, Blotter, FSB-AO
// Match demo reminder set-up
if(!isObject(MatchDemo)) {
new ScriptObject(MatchDemo) {
on = 0;
};
}
package ProPackDemo {
function beginDemoRecord() {
error("demo started");
if(isDemo()) return;
stopDemoRecord(); // make sure that current recording stream is stopped
$DemoCount = 0;
%name = getField( $pref::Player[$pref::Player::Current], 0 );
for(%found = true; %found; $DemoCount++ ) {
%demonum = $DemoCount;
while (strlen(%demonum) < 4) %demonum = "0" @ %demonum;
%file = "recordings/" @ %name @ " - " @ $MissionName @ " - " @ %demonum @ ".rec";
%found = isFile(%file);
}
$DemoFile = %file;
$ProInfoDemo = "<color:FF33FF>DEMO";
AddProInfoLine("<color:FF0000>Demo: <color:FFFF00>[<color:00FF00>" @ $DemoFile @ "<color:FFFF00>]");
saveDemoSettings();
startRecord(%file);
if(!isRecordingDemo()) { // make sure start worked
deleteFile($DemoFile);
$ProInfoDemo = "";
AddProInfoLine("<color:FF0000>Demo FAILED: <color:00FF00>[<color:FF0000>" @ $DemoFile @ "<color:00FF00>]");
$DemoFile = "";
}
}
function demoRecordComplete() {
// tell the user
if($DemoFile !$= "") {
$ProInfoDemo = "";
AddProInfoLine("<color:FF0000>Demo End: <color:00FF00>[<color:FFFF00>" @ $DemoFile @ "<color:00FF00>]");
$DemoFile = "";
}
}
function DemoReset(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6, %a7, %a8, %a9, %a10) {
if(strstr(%msgString, "Free For All") != -1)
MatchDemo.on = 0;
}
function ProPackDemoRemind(%msgType, %msgString, %time) {
if( !isRecordingDemo() && !isPlayingDemo() && MatchDemo.on && (strstr(%msgString, "Match starts in") != -1) ) {
if( %time $= "15") AddProInfoLine("<color:00FF00>Start Demo!" @ $ProInfoDemo);
if( %time $= "10") AddProInfoLine("<color:FFFF00>Start Demo Now!" @ $ProInfoDemo);
if( %time $= "5" ) AddProInfoLine("<color:FF0000>Start Demo Now Fool!" @ $ProInfoDemo);
}
}
// --- Overrides ---
function clientCmdPickTeamMenu(%teamA, %teamB) {
parent::clientCmdPickTeamMenu( %teamA, %teamB );
MatchDemo.on = 1;
}
function scheduleStopDemo() {
schedule(3000, 0, demoRecordComplete);
schedule(3000, 0, stopDemoRecord);
}
function stopDemoRecord() {
parent::stopDemoRecord();
if(MatchDemo.on) MatchDemo.on = 0;
}
function DispatchLaunchMode() {
addmessagecallback('MsgGameOver', scheduleStopDemo);
addMessageCallback('MsgMissionStart', ProPackDemoRemind);
addMessageCallback('MsgAdminForce', DemoReset);
addMessageCallback('MsgVotePassed', DemoReset);
parent::DispatchLaunchMode();
}
};
activatepackage(ProPackDemo);

View file

@ -0,0 +1,173 @@
// #hide
// #category = ProPack
// #name = ProPack Fixes
// #version = 6.91
// #date = November 21, 2001
// #warrior = Neofight
// #description = Compilation of little T2 fixes from a variety of authors
// #status = Growing as fixes are discovered
// #credit = MeBaD, WegBert, Halide, liq, UberGuy, jsut, Neofight
// If the screenshots path doesn't exist, create it.
$ProShotDirectory = new FileObject();
$ProShotDirectory.openForWrite("screenshots/");
$ProShotDirectory.close();
$ProShotDirectory.delete();
$ProShotDirectory = "";
package Fixes {
// FixRemap.cs
// by WegBert
function redoBrokenMapping( %actionMap, %device, %action, %cmd, %newIndex ) {
%actionMap.bind( %device, %action, %cmd );
OP_RemapList.setRowById( %newIndex, buildFullMapString( %newIndex ) );
}
function RemapInputCtrl::onInputEvent( %this, %device, %action ) {
Parent::onInputEvent( %this, %device, %action );
if (%this.mode !$= "consoleKey") {
switch$ ( OP_ControlsPane.group ) {
case "Observer":
%actionMap = observerMap;
%cmd = $ObsRemapCmd[%this.index];
default:
%actionMap = moveMap;
%cmd = $RemapCmd[%this.index];
}
%prevMap = %actionMap.getCommand( %device, %action );
if (%prevMap !$= %cmd && %prevMap !$= "") {
%mapName = getMapDisplayName( %device, %action );
%prevMapIndex = findRemapCmdIndex( %prevMap );
if (%prevMapIndex == -1) {
if (MessageBoxOKDlg.isAwake())
Canvas.popDialog(MessageBoxOKDlg);
MessageBoxYesNo( "FIXREMAP WARNING",
"\"" @ %mapName @ "\" is bound to the function \"" @ %prevMap @ "\"! The function may exist in a user script. do you still want to undo this mapping?",
"redoBrokenMapping(" @ %actionMap @ ", " @ %device @ ", \"" @ %action @ "\", \"" @ %cmd @ "\", " @ %this.index @ ");", "" );
}
}
}
}
// Shrike reticle fix
// Halide
function CommanderMapGui::onSleep(%this) {
parent::onSleep(%this);
schedule(200,0,"ClientCmdDisplayHuds");
}
// FOV Fix version 1.0
// liq
function ClientCmdDisplayHuds() {
parent::ClientCmdDisplayHuds();
schedule(150, 0, setFov, $pref::Player::defaultFov);
schedule(1000, 0, setFov, $pref::Player::defaultFov); // safety net
}
// Eliminate CenterPrint
// MeBaD
function clientCmdCenterPrint( %message, %time, %lines ) {
clientCmdBottomPrint( %message, %time, %lines );
}
// T1-esque screenshots
// UberGuy
function doScreenShot(%val) {
%fileName = "";
if(!%val) {
for(%found = true; %found; $ProPack::screenCount++ ) {
%suffix = $ProPack::screenCount @ ".";
while (strlen(%suffix) < 5) %suffix = "0" @ %suffix;
%fileName = "screenshots/ScreenShot" @ %suffix @ "png";
%found = isFile(%fileName);
}
screenShot("base/" @ %fileName);
}
}
// .dso deletion on exit
// UberGuy
function quit() {
%cnt = 0;
%tmpObj = new ScriptObject() {};
for(%file = findFirstFile("*.dso"); %file !$= ""; %file = findNextFile("*.dso")) {
%tmpObj.file[%cnt++] = %file;
}
for (%i=0; %i<%cnt; %i++) {
deleteFile(%tmpObj.file[%i]);
}
%tmpObj.delete();
return parent::quit();
}
// TeamChat during Debrief GUI
// UberGuy
function DebriefGui::onWake(%this) {
parent::onWake(%this);
%bind = moveMap.getBinding(TeamMessageHud);
debriefMap.bind(getField(%bind, 0), getField(%bind, 1), TeamDebriefChat);
}
// Distinguish between global chat...
function toggleDebriefChat() {
DB_ChatEntry.teamChat = false;
parent::toggleDebriefChat();
}
// ... and team chat
function teamDebriefChat() {
DB_ChatEntry.teamChat = true;
Canvas.pushDialog(DB_ChatDlg);
}
// Send that chat message
function DB_ChatEntry::sendChat(%this) {
%text = %this.getValue();
if (%text !$= "") {
if (%this.teamChat) commandToServer('teamMessageSent', %text);
else commandToServer('messageSent', %text);
}
%this.setValue("");
MessageHud_Edit.setValue("");
Canvas.popDialog(DB_ChatDlg);
// No parent call
}
// Chathud Fix
// Qing
function resizeChatHud( %val ) {
if ( %val ) {
MainChatHud.nextChatHudLen();
for(%i = 1; %i < 20; %i++)
schedule(%i * 10 ,0,pageDownMessageHud);
}
}
// StaticWaypointFix
// jsut
function CommanderTree::processCommand(%this, %command, %target, %typeTag) {
parent::processCommand(%this, %command, %target, %typeTag);
// special case?
if(%typeTag < 0) {
switch$(getTaggedString(%command)) {
// waypoints: tree owns the waypoint targets
case "CreateWayPoint":
%target.settext(%this.currentWaypointID);
return;
}
}
}
// no ammo weapon switch
// Neofight
function clientCmdSetAmmoHudCount(%amount) {
if(%amount == 0)
nextWeapon(true);
parent::clientCmdSetAmmoHudCount(%amount);
}
// Hudmover calls for the new TR2 huds to be moveable
// Neofight
function PlayGui::onWake(%this) {
parent::onWake(%this);
if(isObject(HM) && isObject(HudMover)) {
hudmover::addhud(TR2EventHud, "TR2 Event Hud");
hudmover::addhud(TR2BonusHud, "TR2 Jackpot Hud");
hudmover::addhud(TR2_ThrowStrength, "TR2 Throw Indicator");
}
}
};
activatePackage(Fixes);

View file

@ -0,0 +1,155 @@
// #category = ProPack
// #name = ProPack Flag
// #version = 6.98
// #date = October 7, 2001
// #warrior = Neofight
// #email = neofight@tribes2.org
// #web = http://propack.tribes2.org
// #description = Transparent flag event pop-ups
// #status = beta
// #credit = Crunchy
package ProPackFlag {
function ProPackFlagHandleReturned(%msgType, %msgString, %clientname, %teamName, %team) {
%team = StripNameColors(detag(%team));
%name = StripNameColors(detag(%clientname));
ProPackFlagPopup(%name, %team, "returned", "<color:33FF33>", "<color:FF3333>");
}
function ProPackFlagHandleTaken(%msgType, %msgString, %clientname, %teamName, %team) {
%team = StripNameColors(detag(%team));
%name = StripNameColors(detag(%clientname));
ProPackFlagPopup(%name, %team, "took", "<color:FF3333>", "<color:33FF33>");
}
function ProPackFlagTR2Taken(%msgType, %msgString, %clientname, %teamName, %team) {
%team = StripNameColors(detag(%team));
%name = StripNameColors(detag(%clientname));
if ($IHaveFlag) {
ProPackFlagPopup(%name, %team, "took", "<color:33FF33>", "<color:33FF33>");
} else if (StrStr(%msgString, "Teammate") != -1) {
ProPackFlagPopup(%name, %team, "took", "<color:33FF33>", "<color:33FF33>");
} else {
ProPackFlagPopup(%name, %team, "took", "<color:FF3333>", "<color:FF3333>");
}
}
function ProPackFlagHandleDropped(%msgType, %msgString, %clientname, %teamName, %team) {
%team = StripNameColors(detag(%team));
%name = StripNameColors(detag(%clientname));
ProPackFlagPopup(%name, %team, "dropped", "<color:FFAA33>", "<color:FFAA33>");
}
function ProPackFlagHandleCapped(%msgType, %msgString, %clientname, %teamName, %team) {
%team = StripNameColors(detag(%team));
%name = StripNameColors(detag(%clientname));
ProPackFlagPopup(%name, %team, "captured", "<color:FF0000>", "<color:00FF00>");
}
function ProPackFlagPopup(%clientname, %team, %action, %team1color, %team2color) {
%teamName = $clTeamScore[%team, 0];
%name = StripNameColors(detag(%clientname));
%color = (%team == $PPTeam) ? %team1color : %team2color;
if (ProPackFlag.schedule != 0) cancel(ProPackFlag.schedule);
if ($IHaveFlag) {
%text = %color@"You" SPC %action SPC "the flag!";
} else if ( %name $= "0" || %name $= $PPName ) {
if (%action $= "took") %action = "taken";
%text = %color@"The" SPC %teamname SPC "flag was" SPC %action@"!";
} else {
%text = %clientname SPC %color@%action SPC "the" SPC %teamName SPC "flag!";
}
ProPackFlagText.setText("<just:center>"@%text);
if ($ProPackPrefs::FlagHudActive) {
ProPackFlag.setVisible(true);
} else {
ProPackFlag.setVisible(false);
}
ProPackFlag.schedule = schedule(5000, 0, eval, "ProPackFlag.setVisible(false);");
ProPackFlag.schedule = schedule(5000, 0, "ProPackFlagClearPopup");
}
function ProPackFlagClearPopup() {
ProPackFlagText.setText("");
}
function ProPackFlagCreate() {
ProPackFlagDestroy();
%ProFlagX = getWord($pref::Video::resolution, 0) * 0.5 - 160;
%ProFlagY = getWord($pref::Video::resolution, 1) * 0.8;
new ShellFieldCtrl(ProPackFlag) {
profile = "GuiConsoleProfile";
horizSizing = "center";
vertSizing = "center";
position = %ProFlagX SPC %ProFlagY;
extent = "320 20";
minExtent = "8 8";
visible = "1";
new GuiMLTextCtrl(ProPackFlagText) {
profile = "ProPackTextCtrl";
horizSizing = "center";
vertSizing = "center";
position = "0 0";
extent = "318 18";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
};
playgui.add(ProPackFlag);
}
function ProPackFlagDestroy() {
if (isObject(ProPackFlag)) {
playGui.remove(ProPackFlag);
ProPackFlag.delete();
}
}
// --- Overrides ---
function clientCmdTogglePlayHuds(%val) {
if ( (%val) && ($ProPackPrefs::FlagHudActive) ) {
ProPackFlag.setVisible(true);
} else {
ProPackFlag.setVisible(false);
}
parent::clientCmdTogglePlayHuds(%val);
}
function PlayGui::onWake(%this) {
parent::onWake(%this);
if (!isObject(ProPackFlag)) schedule(3000, 0, "ProPackFlagCreate");
if(isObject(HM) && isObject(HudMover)) hudmover::addhud(ProPackFlag, "ProPackFlag");
}
function DispatchLaunchMode() {
addMessageCallback('MsgCTFFlagTaken', ProPackFlagHandleTaken);
addMessageCallback('MsgCTFFlagDropped', ProPackFlagHandleDropped);
addMessageCallback('MsgCTFFlagCapped', ProPackFlagHandleCapped);
addMessageCallback('MsgCTFFlagReturned', ProPackFlagHandleReturned);
addMessageCallback('MsgTeamRabbitFlagTaken', ProPackFlagHandleTaken);
addMessageCallback('MsgTeamRabbitFlagDropped', ProPackFlagHandleDropped);
addMessageCallback('MsgTeamRabbitFlagReturned', ProPackFlagHandleReturned);
addMessageCallback('MsgTR2FlagTaken', ProPackFlagTR2Taken);
addMessageCallback('MsgTR2FlagDropped', ProPackFlagHandleDropped);
parent::DispatchLaunchMode();
}
};
activatePackage(ProPackFlag);

View file

@ -0,0 +1,79 @@
// #category = ProPack
// #name = ProPack Flag Trixy
// #version = 0.1
// #date = June 30, 2001
// #warrior = MeBaD
// #web = http://propack.tribes2.org
// #description = Tricc Flag Stats
// #credit = (From AutoChat: Neofight, Widow, Blotter)
// #status = Workin
package ProPackFlagTrixy {
function ProPackAutoGotFlag(%msgType, %msgString, %victimname, %vgen, %vposs, %killername, %kgen, %kposs, %damageType) {
if ($ProPackPrefs::AutoGotFlag) {
if (Strstr(%msgString, "You took the") != -1) { // Make sure it's you as the taker!
$ProPackYellHelp = schedule( 5000, 0, "commandToServer", 'CannedChat', 'ChatHelp', false ); // issue's the command
if ($ProPackPrefs::AutoGrabSpeed) {
%speed = mFloor(getControlObjectSpeed() * 3.6);
// New settings for classic
if (%speed < 100) {
%saying = $ProPackPrefs::GrabSpeedText1;
} else if (%speed < 175) {
%saying = $ProPackPrefs::GrabSpeedText2;
} else if (%speed < 250) {
%saying = $ProPackPrefs::GrabSpeedText3;
} else if (%speed < 300) {
%saying = $ProPackPrefs::GrabSpeedText4;
} else {
%saying = $ProPackPrefs::GrabSpeedText5;
}
if (%speed > $ProPackPrefs::FlagGrabClocked) {
$ProPackPrefs::FlagGrabClocked = %speed;
$ProPackPrefs::MapGrabSpeed = $MissionName;
%words = "You clocked a NEW record of: ";
export("$ProPackPrefs::*", "prefs/ProPackPrefs.cs", false);
} else {
%words = "Current Record: ";
}
if ($ProPackPrefs::AddPeek) {
commandtoserver('TeamMessageSent', "\c2" @ %saying @ " \c4[\c1" @ %speed @ " kph\c4] \c2InBound Peek \c4[\c1" @ $ProPackPeekSpd @ " kph\c4]~wflg.flag");
ClientCmdbottomprint("<color:FF6666>" @ %words @ "<color:6666FF>" @ $ProPackPrefs::FlagGrabClocked @ " <color:FF6666> Map : <color:6666FF>" @ $ProPackPrefs::MapGrabSpeed @
"\n<color:FF6666>Route Peek Record:<color:6666FF>" @ $ProPackPrefs::SpeedPeekRecord, 5, 2);
$ProPackPeekSpd = 0; // Reset so the outbound route is on it's own
} else {
commandtoserver('TeamMessageSent', "\c2" @ %saying @ " \c4[\c1" @ %speed @ " kph\c4]~wflg.flag");
ClientCmdbottomprint("<color:FF6666>" @ %words @ "<color:6666FF>" @ $ProPackPrefs::FlagGrabClocked @ " <color:FF6666> Map : <color:6666FF>" @ $ProPackPrefs::MapGrabSpeed, 5);
}
}
}
}
}
function YouDeadWhileRaggin(%msgType, %msgString) {
if ((detag(%msgType) $= "MsgCTFFlagCapped") && (Strstr(%msgString, "You captured the") != -1)) {
if ($ProPackPrefs::AutoGotFlag) {
if ($ProPackPrefs::AddPeek) {
commandtoserver('TeamMessageSent', "\c2Capped at->\c4[\c1" @ mFloor(getControlObjectSpeed() * 3.6) @ " kph\c4] \c2Return Peek->\c4[\c1" @ $ProPackPeekSpd @ " kph\c4]~wgbl.woohoo");
$ProPackPeekSpd = 0;
} else {
commandtoserver('TeamMessageSent', "\c2Capped at->\c4[\c1" @ mFloor(getControlObjectSpeed() * 3.6) @ " kph\c4]~wgbl.woohoo");
}
}
}
cancel($ProPackYellHelp); // so you don't yell help for no reason!
}
function DispatchLaunchMode() {
addMessageCallBack('MsgCTFFlagTaken', ProPackAutoGotFlag);
addMessageCallBack('MsgCTFFlagDropped', YouDeadWhileRaggin);
addMessageCallBack('MsgCTFFlagCapped', YouDeadWhileRaggin);
parent::DispatchLaunchMode();
}
};
activatePackage(ProPackFlagTrixy);

View file

@ -0,0 +1,378 @@
// #category = ProPack
// #name = ProPack Info
// #version = 6.52
// #description = Transparent, mesage-filtering, kill-stripping, color-coded, information-rich HUD from hell.
// #status = Beta
// #date = June 3, 2001
// #web = http://propack.tribes2.org
// #warrior = MeBaD
// #credit = Neofight, UberGuy, Ego
package ProPackInfo {
function ClearProPackInfo() {
$ProInfoline[1] = "";
$ProInfoline[2] = "";
$ProInfoline[3] = "";
$ProInfoline[4] = "";
$ProInfoline[5] = "";
$ProInfoline[6] = "";
$ProInfoDemo = "";
$ProInfoTask = "";
AddProInfoLine(%null);
}
function AddProInfoLine(%text, %msgType) {
$ProInfoline[1] = $ProInfoline[2];
$ProInfoline[2] = $ProInfoline[3];
$ProInfoline[3] = $ProInfoline[4];
$ProInfoline[4] = $ProInfoline[5];
$ProInfoline[5] = $ProInfoline[6];
$ProInfoline[6] = %text;
ProPackInfoText.setText($ProInfoline[1] @ "\n" @
$ProInfoline[2] @ "\n" @
$ProInfoline[3] @ "\n" @
$ProInfoline[4] @ "\n" @
$ProInfoline[5] @ "\n" @
$ProInfoline[6] @ "\n" @
$ProInfoDemo SPC $ProInfoTask);
}
function clientTaskCompleted() {
if((TaskList.currentTask != -1) && isObject(TaskList.currentTask)) {
%temptask = $ProInfoTask;
$ProInfoTask = "";
AddProInfoLine(%temptask @ "<color:0000FF> Completed!");
}
parent::clientTaskCompleted();
}
function clientCmdAcceptedTask(%desc) {
$ProInfoTask = "<color:FFFF00>" @ StripNameColors(%desc);
AddProInfoLine("<color:0000FF>Task:<color:00FF00> " @ $ProInfoTask );
}
// This mutes the [V**] keys and fixes the dynamix "error" not allowing us to edit the chat menu :\
function clientCmdChatMessage(%sender, %voice, %pitch, %msgString, %a1, %a2, %a3, %a4, %a5, %a6, %a7, %a8, %a9, %a10) {
%message = detag( %msgString );
%voice = detag( %voice ); // Moved the original detag fix to here so all sounds can be used.
if($ProPackPrefs::MuteSpammers) {
//stfu spammers!!!!!
if($SpammerSTFU[%sender] $= %message) {
return;
}
$SpammerSTFU[%sender] = %message;
}
// Mute out [VGX] stuff - Uber Chat with a slight twist
if ($ProPackPrefs::MuteDefaultKeys) {
%color = getSubStr(%message,0,1);
if (%color $= "[") {
%pos = strpos(%message,"]");
%color = getSubStr(%message,%pos+2,1); //Skip end ] and color code
%pos+=3;
}
%message = %color @ getSubStr(%message,%pos,strlen(%message)-%pos);
}
if ( ( %message $= "" ) || isClientChatMuted( %sender ) )
return;
// search for wav tag marker
%wavStart = strstr( %message, "~w" );
if ( %wavStart == -1 )
addMessageHudLine( %message );
else
if(strstr(%message, "~wK") !=-1) { //THANKS to Ego for the voicepack.cs fix!!!
%voice = "custom"; //Assign our base directory here.
%wav = getSubStr(%message, %wavStart + 3, 1000); //Move the name three spaces for our delim
%wavFile = "voice/" @ %voice @ "/" @ %wav @ ".wav";
if (%pitch < 0.5 || %pitch > 2.0)
%pitch = 1.0;
%wavLengthMS = alxGetWaveLen(%wavFile) * %pitch;
if ( $ClientChatHandle[%sender] != 0 )
alxStop( $ClientChatHandle[%sender] );
$ClientChatHandle[%sender] = alxCreateSource( AudioChat, %wavFile );
if (%pitch != 1.0)
alxSourcef($ClientChatHandle[%sender], "AL_PITCH", %pitch);
alxPlay( $ClientChatHandle[%sender] );
%message = getSubStr(%message, 0, %wavStart);
addMessageHudLine(%message);
}
else
{
%wav = getSubStr(%message, %wavStart + 2, 1000);
if (%voice !$= "")
%wavFile = "voice/" @ %voice @ "/" @ %wav @ ".wav";
else
%wavFile = %wav;
//only play voice files that are < 5000ms in length
if (%pitch < 0.5 || %pitch > 2.0)
%pitch = 1.0;
%wavLengthMS = alxGetWaveLen(%wavFile) * %pitch;
if (%wavLengthMS < $MaxMessageWavLength )
{
if ( $ClientChatHandle[%sender] != 0 )
alxStop( $ClientChatHandle[%sender] );
$ClientChatHandle[%sender] = alxCreateSource( AudioChat, %wavFile );
//pitch the handle
if (%pitch != 1.0)
alxSourcef($ClientChatHandle[%sender], "AL_PITCH", %pitch);
alxPlay( $ClientChatHandle[%sender] );
}
else
error( "** WAV file \"" @ %wavFile @ "\" is too long! **" );
%message = getSubStr(%message, 0, %wavStart);
addMessageHudLine(%message);
}
}
function addMessageHudLine(%text) {
if ($ProPackPrefs::MuteToolsActive) {
// these are the 4 exceptions with either no callback or a shitty one
if (($ProPackPrefs::MuteToolsHackzorLoadout !$= "") && (Strstr(%text, "Inventory set") != -1 || Strstr(%text, "Inventory updated") != -1)) {
switch$ ($ProPackPrefs::MuteToolsHackzorLoadout) {
case "Append-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorLoadout_Append SPC StripNameColors(%text));
case "Alter/Split-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorLoadout_Append);
case "BottomPrint":
clientCmdBottomPrint($ProPackPrefs::MuteToolsHackzorLoadout_Append SPC StripNameColors(%text), 3, 1);
}
return;
}
if (($ProPackPrefs::MuteToolsHackzorKitPickup !$= "") && (Strstr(%text, "picked up a repair kit.") != -1)) {
switch$ ($ProPackPrefs::MuteToolsHackzorKitPickup) {
case "Append-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorKitPickup_Append SPC StripNameColors(%text));
case "Alter/Split-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorKitPickup_Append);
case "BottomPrint":
clientCmdBottomPrint($ProPackPrefs::MuteToolsHackzorKitPickup_Append, 3, 1);
}
return;
}
if (($ProPackPrefs::MuteToolsHackzorPackOn !$= "") && ((Strstr(%text, "pack on.") != -1) || (Strstr(%text, "pack activated.") != -1))) {
switch$ ($ProPackPrefs::MuteToolsHackzorPackOn) {
case "Append-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorPackOn_Append SPC StripNameColors(%text));
case "Alter/Split-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorPackOn_Append);
case "BottomPrint":
clientCmdBottomPrint($ProPackPrefs::MuteToolsHackzorPackOn_Append SPC StripNameColors(%text), 3, 1);
}
return;
}
if (($ProPackPrefs::MuteToolsHackzorPackOff !$= "") && (Strstr(%text, "pack off.") != -1)) {
switch$ ($ProPackPrefs::MuteToolsHackzorPackOff) {
case "Append-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorPackOff_Append SPC StripNameColors(%text));
case "Alter/Split-to-InfoHud":
AddProInfoLine($ProPackPrefs::MuteToolsHackzorPackOff_Append);
case "BottomPrint":
clientCmdBottomPrint($ProPackPrefs::MuteToolsHackzorPackOff_Append SPC StripNameColors(%text), 3, 1);
}
return;
}
}
parent::addMessageHudLine(%text);
}
// from Uber's chat with a ProPack twist
function defaultMessageCallback(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6, %a7, %a8, %a9, %a10) {
if ( %msgString $= "" ) return;
%subType = detag(%msgType);
%msgs = %msgString;
if ($ProPackPrefs::MuteToolsActive) { // this IS defaultmessagecallback IF it is muted
%ProPackCheckMute = $ProPackPrefs::MuteTools[%subType];
if ((%ProPackCheckMute !$= "") && (%subType !$= "")) { //($ProPackPrefs::InfoHudActive) ?? duh .. it should be anyhow :o
if (Strstr(%msgString, "picked up a repair kit.") == -1) {
switch$ (%ProPackCheckMute) {
case "Append-to-InfoHud":
%fill = true;
AddProInfoLine($ProPackPrefs::MuteTools[%subType @ "_Append"] @ StripNameColors(detag(%msgs)));
case "Alter/Split-to-InfoHud":
%fill = true;
AddProInfoLine($ProPackPrefs::MuteTools[%subType @ "_Append"]);
case "BottomPrint":
%fill = true;
clientCmdBottomPrint($ProPackPrefs::MuteTools[%subType @ "_Append"], 3, 1);
default: // case "Mute":
%fill = true;
}
} else {
%fill = false; // let it pass to AddMessageHudLine cause it's easier to handle
}
}
if (%fill) {
%message = detag( %msgString );
// search for wav tag marker
%wavStart = strstr( %message, "~w" );
if ( %wavStart != -1 ) {
%wav = getSubStr( %message, %wavStart + 2, 1000 );
%wavLengthMS = alxGetWaveLen( %wav );
if ( %wavLengthMS <= $MaxMessageWavLength ) {
alxPlay(alxCreateSource( AudioChat, %wav ));
} else {
error( "WAV file \"" @ %wav @ "\" is too long! **" );
}
}
return; // wav only
}
}
if ($ProPackPrefs::CKillsActive) {
if ( %subType $= "msgSuicide" || %subType $= "msgVehicleCrash" || %subType $= "msgTR2Knockdown" || (strstr(%subType,"Kill") != -1 )) {
%vict = detag(%a1);
%kllr = detag(%a4);
if ($MyPlayerID[%vict].teamId == $PPTeam) {
if (StripNameColors(%vict) $= $PPName) {
%Provc = "\c3";
%vc = "<color:00FFCC>";
} else {
%Provc = "\c1";
%vc = "<color:00FF00>";
}
} else {
%Provc = "\c5";
%vc = "<color:FF0000>";
}
if ($MyPlayerID[%kllr].teamId == $PPTeam) {
if (StripNameColors(%kllr) $= $PPName) {
%Prokc = "\c3";
%kc = "<color:00FFCC>";
} else {
%Prokc = "\c1";
%kc = "<color:00FF00>";
}
} else {
%Prokc = "\c5";
%kc = "<color:FF0000>";
}
if (($ProPackPrefs::DeathMessages) && ($ProPackPrefs::InfoHudActive)) {
if (%subType $= "msgVehicleCrash")
%a7 = 36; // to fix the nexuscamping crap in CTF
%weapon = ProNoSpacedWeaponName(%a7); //%weapon = $DamageTypeText[%a7];
%kllr = StripNameColors(%kllr);
%vict = StripNameColors(%vict);
if (%kllr $= %vict) {
%weapon = "Suicide";
%vict = "";
}
if ((Strlen(%weapon) < 1)) {
return;
} else {
%msg = %kc@%kllr @ " <color:CCFF00>" @ %weapon @ " " @ %vc@%vict;
}
AddProInfoLine(%msg);
return; // mute from normal chat menu
} else {
if (%vict !$= "") {
%msgs = strreplace(%msgs,%vict,%Provc@%vict@"\c0");
}
if (%kllr !$= "" && %kllr !$= %vict) {
%msgs = strreplace(%msgs,%kllr,%Prokc@%kllr@"\c0");
}
}
}
}
parent::defaultMessageCallback(%msgType, %msgs, %a1, %a2, %a3, %a4, %a5, %a6, %a7, %a8, %a9, %a10);
}
//-------------------------------------
// Handle ProInfo Chat Menu GUI
//-------------------------------------
function ProPackInfoCreate() {
ProPackInfoDestroy();
%ProInfoX = getWord(outerChatHud.position, 0) + getWord(outerChatHud.extent, 0) + 4;
%ProInfoY = 0;
new ShellFieldCtrl(ProPackInfo) {
profile = "GuiConsoleProfile";
horizSizing = "center";
vertSizing = "center";
position = %ProInfoX SPC %ProInfoY;
extent = "280 124";
minExtent = "8 8";
visible = "1";
new GuiMLTextCtrl(ProPackInfoText) {
profile = "ProPackTextCtrl";
horizSizing = "center";
vertSizing = "center";
position = "0 0";
extent = "280 124";
minExtent = "4 4";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = -1;
};
};
playgui.add(ProPackInfo);
}
function ProPackInfoDestroy() {
if (isObject(ProPackInfo)) {
playgui.remove(ProPackInfo);
ProPackInfo.delete();
}
}
// --- Overrides ---
function clientCmdTogglePlayHuds(%val) {
if ($ProPackPrefs::InfoHudActive) {
ProPackInfo.setVisible(%val);
}
parent::clientCmdTogglePlayHuds(%val);
}
function demoPlaybackComplete() {
ClearProPackInfo();
parent::demoPlaybackComplete();
}
function Disconnect() {
ClearProPackInfo();
parent::Disconnect();
}
function PlayGui::onWake(%this) {
parent::onWake(%this);
if (!isobject(ProPackInfo)) schedule(3000, 0, "ProPackInfoCreate");
if(isObject(HM) && isObject(HudMover)) hudmover::addhud(ProPackInfo, "ProPackInfo");
}
function DispatchLaunchMode() {
addMessageCallBack('MsgGameOver', ClearProPackInfo);
addMessageCallBack('MsgArenaRoundEnd', ClearProPackInfo);
addMessageCallBack('MsgSiegeHalftime', ClearProPackInfo);
addMessageCallBack('MsgMissionDropInfo', ClearProPackInfo);
addMessageCallBack('MsgAdminChangeMission', ClearProPackInfo);
parent::DispatchLaunchMode();
}
};
activatePackage(ProPackInfo);

View file

@ -0,0 +1,74 @@
// #category = ProPack
// #name = ProPack Join & Retry
// #version = 1.21
// #date = October 13, 2001
// #warrior = Neofight
// #description = Join & Retry
// #status = Good enough ;)
// #credit = PJ
package JoinRetry {
function onConnectRequestRejected( %msg ) {
switch$(%msg) {
case "CR_INVALID_CONNECT_PACKET":
%error = "Network error - badly formed network packet - this should not happen!";
case "CR_AUTHENTICATION_FAILED":
%error = "Failed to authenticate with server. Please restart TRIBES 2 and try again.";
case "CR_YOUAREBANNED":
%error = "You are not allowed to play on this server.";
case "CR_SERVERFULL":
%error = "This server is full.";
default:
%error = "Connection error. Please try another server. Error code: (" @ %msg @ ")";
}
DisconnectedCleanup();
if(%msg !$= "CR_SERVERFULL") {
MessageBoxOK( "REJECTED", %error);
} else {
$RetryTimer = 3;
AutoConnect();
}
}
function AutoConnect() {
Canvas.popDialog( MessageBoxOKDlg );
MessageBoxOK("Retrying Server", "<just:center>\n<color:999999>Server: <color:FFFF00>" @ $JoinGameAddress @ "\n<color:999999>This server is <color:FF0000>full<color:999999>.\n<color:999999>Retrying in <color:00FF00>" @ $RetryTimer @ " <color:999999>seconds.", "ConnectButtonResult();" );
if($RetryTimer == 0) {
Canvas.popDialog( MessageBoxOKDlg );
JoinGame($JoinGameAddress);
} else {
$RetryTimer--;
$RetrySchedule = schedule(1000, 0, "AutoConnect");
}
}
function ConnectButtonResult() {
cancel($RetrySchedule);
Canvas.popDialog( MessageBoxOKDlg );
}
function OP_LaunchScreenMenu::init( %this ) {
%this.clear();
%this.add( "Join Game", 1 );
%this.add( "Host Game", 2 );
%this.add( "Warrior Setup", 3 );
%this.add( "Email", 4 );
%this.add( "Chat", 5 );
%this.add( "Browser", 6 );
}
function OpenLaunchTabs(%gotoWarriorSetup) {
switch$($pref::Shell::LaunchGui) {
case "Join Game" :
GM_TabView.setSelected(1);
case "Host Game" :
GM_TabView.setSelected(2);
}
parent::OpenLaunchTabs(%gotoWarriorSetup);
}
};
activatePackage(JoinRetry);

View file

@ -0,0 +1,148 @@
// #category = ProPack
// #name = ProPack Multi
// #version = 4.38
// #date = 10/5/2001
// #warrior = Neofight
// #email = neofight@tribes2.org
// #web = http://propack.tribes2.org
// #description = FPS, Ping, Speed, Altitude all toggleable within ProPackInterface
// #status = Beta 3
// #Credit = Crunchy, MeBaD
package ProPackMulti {
// --- PING ---
function NetBarHud::infoUpdate(%this, %ping, %packetLoss, %sendPackets, %sendBytes, %receivePackets, %receiveBytes) {
parent::infoUpdate(%this, %ping, %packetLoss, %sendPackets, %sendBytes, %receivePackets, %receiveBytes);
$ppping = mFloor(%ping);
}
function ProPackPingRateCheck() {
if ($ppping > 999) $ppping = 999;
if ($ppping < 75) {
%ProPackPingText = "00FF00";
} else if ( ($ppping >= 125) && ($ppping < 150) ) {
%ProPackPingText = "FFFF00";
} else if ($ppping >= 150) {
%ProPackPingText = "FF0000";
} else {
%ProPackPingText = "FFFFFF";
}
return "<color:" @ %ProPackPingText @ ">" @ $ppping;
}
// --- FPS ---
function ProPackFPSRateCheck() {
if ($fps::real < 30) {
%ProPackFPSText = "FF0000";
} else if (($fps::real >= 60) && ($fps::real < 90)) {
%ProPackFPSText = "FFFF00";
} else if ($fps::real >= 90) {
%ProPackFPSText = "00FF00";
} else {
%ProPackFPSText = "FFFFFF";
}
return "<color:" @ %ProPackFPSText @ ">" @ mFloor($fps::real);
}
// --- HUD Text ---
function ProPackMultiUpdate() {
cancel($ProPackMultiSchedule);
%speed = mFloor(getControlObjectSpeed() * 3.6);
if ($ProPackPrefs::FPSHud) {
$ProMulti[1] = "<just:left><color:FFFF11>FPS <just:right>" @ ProPackFPSRateCheck() @ "\n";
}
if ($ProPackPrefs::PingHud) {
$ProMulti[2] = "<just:left><color:FFFF11>Ping <just:right>" @ ProPackPingRateCheck() @ "\n";
}
if ($ProPackPrefs::SpeedHud) {
$ProMulti[4] = "<just:left><color:FFFF11>Spd <just:right><color:FFFFFF>" @ %speed @ "\n";
}
if ($ProPackPrefs::AltHud) {
$ProMulti[3] = "<just:left><color:FFFF11>Alt <just:right><color:FFFFFF>" @ getControlObjectAltitude() @ "\n";
}
if ($ProPackPrefs::PeekSpeedHud) {
if (%speed == 0) { // Reset if you stop
$ProPackPeekSpd = 0;
} else if ((%speed > $ProPackPeekSpd) && ($ProPackPrefs::AddPeek)) { // Added in for Peek Speed
$ProPackPeekSpd = %speed;
// Debug - addMessageHudLine( "\c4***\c2Peek Speed: [" @ $ProPackPeekSpd @ "]\c4***");
}
if ($ProPackPrefs::SpeedPeekRecord < %speed) {
$ProPackPrefs::SpeedPeekRecord = %speed;
}
$ProMulti[5] = "<just:left><color:FFFF11>Peek <just:right><color:FFFFFF>" @ $ProPackPeekSpd @ "\n";
}
ProPackMultiText.setText($ProMulti[1] @ $ProMulti[2] @ $ProMulti[3] @ $ProMulti[4] @ $ProMulti[5]);
$ProPackMultiSchedule = schedule(500, 0, "ProPackMultiUpdate");
}
// --- MultiGUI ---
function ProPackMultiCreate() {
ProPackMultiDestroy();
%ProMultiX = getWord($pref::Video::resolution, 0) - 44;
%ProMultiY = getWord(hudClusterBack.position, 1) + getWord(hudClusterBack.extent, 1) + 2;
new ShellFieldCtrl(ProPackMulti) {
profile = "GuiConsoleProfile";
horizSizing = "left";
vertSizing = "bottom";
position = %ProMultiX SPC %ProMultiY;
extent = "42 80";
minExtent = "8 8";
visible = "1";
new GuiMLTextCtrl(ProPackMultiText) {
profile = "ProPackTextCtrl";
horizSizing = "right";
vertSizing = "bottom";
position = "0 0";
extent = "42 80";
visible = "1";
};
};
playGui.add(ProPackMulti);
$ProPackMultiSchedule = schedule(1000, 0, "ProPackMultiUpdate");
}
function ProPackMultiDestroy() {
if ($ProPackMultiSchedule !$= "")
cancel($ProPackMultiSchedule);
if (isObject(ProPackMulti)) {
playGui.remove(ProPackMulti);
ProPackMulti.delete();
}
}
// --- Overrides ---
function clientCmdTogglePlayHuds(%val) {
ProPackMulti.setVisible(%val);
parent::clientCmdTogglePlayHuds(%val);
}
function PlayGui::onWake(%this) {
parent::onWake(%this);
if (!isobject(ProPackMulti)) {
schedule(3000, 0, "ProPackMultiCreate");
schedule(3000, 0, "ProPackMultiUpdate");
}
if(isObject(HM) && isObject(HudMover)) hudmover::addhud(ProPackMulti, "ProPackMulti");
}
};
activatePackage(ProPackMulti);

View file

@ -0,0 +1,838 @@
// #category = ProPack
// #name = ProPack Objective
// #version = 6.99
// #description = Simple, small, transparent, information-rich, non-ghey objectives HUD.
// #status = Beta 2
// #date = 11/14/2001
// #warrior = MeBaD
// #credit = Neofight
// #web = http://propack.tribes2.org
// Positions
$ProScorePOS[1280] = "1095 42";
$ProScorePOS[1152] = "963 42";
$ProScorePOS[1024] = "847 42";
$ProScorePOS[800] = "617 42";
// Arena Support information
$ArenaSupport::LocalVersion = 1.0;
$ArenaSupport::RemoteVersion = 0;
$ArenaSupport::TeamCount = 2;
package ProPackObjective {
//***************************************//
// The One and Only ObjectiveHUD //
//***************************************//
function teamScoreIs(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::teamScoreIs(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%teamNum = detag(%a1);
%score = detag(%a2);
if(%score $= "") %score = 0;
UpdateProScore(%teamNum, %score);
}
function YourScoreIs(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::YourScoreIs(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
$ProScoreis = detag(%a1);
$ProScore[1] = $ProScoreis;
$ProScore[2] = "";
UpdateProScore(1);
}
function ClientCmdDisplayHuds() {
switch$ ($HudMode) {
case "Pilot":
ProHudStatus.setVisible($ProPackPrefs::StatusHudActive);
ProHudScore.setVisible($ProPackPrefs::ScoreHudActive);
case "Passenger":
ProHudStatus.setVisible($ProPackPrefs::StatusHudActive);
ProHudScore.setVisible($ProPackPrefs::ScoreHudActive);
case "Object":
ProHudStatus.setVisible($ProPackPrefs::StatusHudActive);
PPTR2CarrierHealth.setVisible($ProPackPrefs::StatusHudActive);
ProHudScore.setVisible($ProPackPrefs::ScoreHudActive);
case "Observer":
ProHudStatus.setVisible(false);
PPTR2CarrierHealth.setVisible(false);
ProHudScore.setVisible($ProPackPrefs::ScoreHudActive);
case "PickTeam":
ProHudStatus.setVisible(false);
PPTR2CarrierHealth.setVisible(false);
ProHudScore.setVisible($ProPackPrefs::ScoreHudActive);
case "SiegeHalftime":
ProHudStatus.setVisible(false);
ProHudScore.setVisible(false);
default:
ProHudStatus.setVisible(false);
PPTR2CarrierHealth.setVisible(false);
ProHudScore.setVisible(false);
}
parent::ClientCmdDisplayHuds();
}
function setupObjHud(%gameType) {
for (%i = 1; %i < 3; %i++) {
$ProTeam[%i] = "";
$ProScore[%i] = "";
$ProStatus[%i] = "";
}
$ProScoreis = "";
$ProSingleScore = "";
$ProDMKills = "";
$ProDMDeaths = "";
$ProSiegeTeamCheck = 0;
switch$ (%gameType) {
case BountyGame:
$ProSingleScore = "Score: ";
case RabbitGame:
$ProSingleScore = "Score: ";
case DMGame:
$ProSingleScore = "Score: ";
case SiegeGame:
$ProSingleScore = "->";
$ProSiegeTeamCheck = 1;
case HuntersGame:
$ProSingleScore = "Score: ";
case TeamRabbitGame:
// just for grins
case ArenaGame:
// just for grins
case TR2Game:
// just for grins
}
echo("Overriding gametype for ProPackObjectiveHud ... " @ %gameType);
UpdateProStatus();
parent::setupObjHud(%gameType);
}
//---------------------------------------------------------------
// Handle all hunters Events
//---------------------------------------------------------------
function huntAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::huntAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%teamNum = detag(%a1);
%teamName = detag(%a2);
%score = detag(%a3);
$ProTeam[%teamNum] = %teamName;
$ProScore[%teamNum] = %score;
UpdateProScore();
}
function huntYouHaveFlags(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::huntYouHaveFlags(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%numFlags = detag(%a1);
$ProStatus[1] = "<color:FFFF00>Flags: " @ %numFlags;
%FlagValue = 0;
for (%i = %numFlags; %i > 0; %i--) {
%FlagValue = %FlagValue + %i;
}
$ProStatus[2] = "<color:00FF00>Value: " @ %FlagValue;
UpdateProStatus();
}
//---------------------------------------------------------------
// Handle all Siege Events
//---------------------------------------------------------------
function siegeAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::siegeAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%teamNum = detag(%a1);
if(detag(%a3))
%role = "CAPTURE";
else
%role = "PROTECT";
if ($PPTeam == %teamNum) {
$ProScore[1] = %role;
$ProScore[2] = "";
UpdateProScore(1);
}
}
function siegeRolesSwitched(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::siegeRolesSwitched(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%newOff = detag(%a2);
%newDef = %newOff == 1 ? 2: 1;
if ($PPTeam == %newOff) {
$ProScore[1] = "CAPTURE";
} else if ($PPTeam == %newDef) {
$ProScore[1] = "PROTECT";
} else {
$ProScore[1] = "";
}
$ProScore[2] = "";
UpdateProScore(1);
}
function ProSiegeRoleSwitch(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
if ($ProSiegeTeamCheck) {
if (Strstr($ProScore[1], PROTECT) != -1) {
$ProScore[1] = "CAPTURE";
} else {
$ProScore[1] = "PROTECT";
}
$ProScore[2] = "";
UpdateProScore(1);
}
}
//---------------------------------------------------------------
// Handle all Wabbit Events
//---------------------------------------------------------------
function rabbitFlagTaken(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::rabbitFlagTaken(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%bunny = StripNameColors(detag(%a1));
if ( %bunny $= detag($PPName) ) {
$ProStatus[1] = "<font:Univers bold:16><color:00FF00>RUN!!!";
} else {
$ProStatus[1] = %bunny;
}
UpdateProStatus();
}
function rabbitFlagDropped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::rabbitFlagDropped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
$ProStatus[1] = "<color:FFFF00>< Dropped >";
UpdateProStatus();
}
function rabbitFlagReturned(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::rabbitFlagReturned(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
$ProStatus[1] = "<color:00FF00>< Home >";
UpdateProStatus();
}
function rabbitFlagStatus(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::rabbitFlagStatus(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%flagStatus = StripNameColors(detag(%a1));
$ProStatus[1] = %flagStatus;
UpdateProStatus();
}
//---------------------------------------------------------------
// Handle all Team Wabbit Events: Neo's adaptation of the release from the mod author, Juno
//---------------------------------------------------------------
function teamRabbitAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
%teamNum = detag(%a1);
%teamName = detag(%a2);
%flagStatus = detag(%a3);
%score = detag(%a4);
$ProScore[%teamNum] = "";
$ProStatus[%teamNum] = "";
$ProScore[%teamNum] = %score;
$ProTeam[%teamNum] = %teamName;
$ProStatus[%teamNum] = %flagStatus;
UpdateProScore(%teamNum, %score);
UpdateProStatus();
}
function teamRabbitFlagTaken(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
%index = detag(%a3);
%bunny = detag(%a4);
if ( %bunny $= detag($PPName) ) {
%bunny = "<font:Univers bold:16><color:00FF00>RUN!!!";
}
switch (%index) {
case 1:
$ProStatus[1] = "";
$ProStatus[2] = %bunny;
case 2:
$ProStatus[1] = %bunny;
$ProStatus[2] = "";
}
UpdateProStatus();
}
function teamRabbitFlagDropped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
%index = detag(%a2);
switch (%index) {
case 1:
$ProStatus[1] = "";
$ProStatus[2] = "<color:FFFF00><Dropped>";
case 2:
$ProStatus[1] = "<color:FFFF00><Dropped>";
$ProStatus[2] = "";
}
UpdateProStatus();
}
function teamRabbitFlagReturned(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
$ProStatus[1] = "";
$ProStatus[2] = "";
UpdateProStatus();
}
function teamRabbitFlagStatus(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
%flagStatus = StripNameColors(detag(%a1));
%team = detag(%a2);
switch (%team) {
case 1:
$ProStatus[1] = "";
$ProStatus[2] = %flagStatus;
case 2:
$ProStatus[1] = %flagStatus;
$ProStatus[2] = "";
}
UpdateProStatus();
}
//---------------------------------------------------------------
// TR2 Events de Neo
//---------------------------------------------------------------
function TR2HudInit(%msgType, %msgString, %team1, %team2, %score1, %score2, %flagLoc, %carrierHealth, %currentBonus) {
parent::TR2HudInit(%msgType, %msgString, %team1, %team2, %score1, %score2, %flagLoc, %carrierHealth, %currentBonus);
%team1Name = detag(%team1);
%team2Name = detag(%team2);
%team1Score = detag(%score1);
%team2Score = detag(%score2);
%flagStatus = detag(%flagLoc);
if(%team1Score $= "") %team1Score = 0;
if(%team2Score $= "") %team2Score = 0;
// Set the values
$ProTeam[1] = %team1Name;
$ProTeam[2] = %team2Name;
$ProScore[1] = %team1Score;
$ProScore[2] = %team2Score;
$ProStatus[1] = "<color:FFFF00>" @ %flagStatus;
// Update the huds
UpdateProScore(1, %team1Score);
UpdateProScore(2, %team2Score);
UpdateProStatus();
}
function TR2FlagTaken (%msgType, %msgString, %client, %team, %flagteam, %clientnamebase) {
%bunny = StripNameColors(detag(%client));
if ($IHaveFlag) {
$ProStatus[1] = "<font:Univers bold:16><color:00FF00>RUN!!!";
PPTR2CarrierHealth.setVisible(false);
} else if (StrStr(%msgString, "Teammate") != -1) {
$ProStatus[1] = "<color:33FF33>" @ %bunny;
PPTR2CarrierHealth.profile.fillColor = "0 255 0";
PPTR2CarrierHealth.setVisible(true);
} else {
$ProStatus[1] = "<color:FF3333>" @ %bunny;
PPTR2CarrierHealth.profile.fillColor = "255 0 0";
PPTR2CarrierHealth.setVisible(true);
}
UpdateProStatus();
}
function handleTR2FlagDropped(%msgType, %msgString, %client, %team, %flagteam) {
parent::handleTR2FlagDropped(%msgType, %msgString, %client, %team, %flagteam);
$ProStatus[1] = "<color:FFAA33><Dropped>";
PPTR2CarrierHealth.setVisible(false);
UpdateProStatus();
}
function handleTR2FlagStatus(%msgType, %msgString, %location) {
parent::handleTR2FlagStatus(%msgType, %msgString, %location);
%location = detag(%location);
$ProStatus[1] = "<color:FFFF00>" @ %location;
PPTR2CarrierHealth.setVisible(false);
UpdateProStatus();
}
function handleTR2CarrierHealth(%msgType, %msgString, %amt, %team) {
parent::handleTR2CarrierHealth(%msgType, %msgString, %amt, %team);
PPTR2CarrierHealth.setValue(%amt);
}
function handleTR2SetScore(%msgType, %msgString, %team, %score) {
parent::handleTR2SetScore(%msgType, %msgString, %team, %score);
%team = detag(%team);
%score = detag(%score);
$ProScore[%team] = %score;
UpdateProScore(%team);
}
//---------------------------------------------------------------
// Handle all Death Match Events
//---------------------------------------------------------------
function dmKill(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::dmKill(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
$ProDMKills = detag(%a1);
$ProScore[1] = "<color:00FF00>" @ $ProDMKills @ "<color:FFFF00> / <color:FF0000>" @ $ProDMDeaths @ "<color:FFFF00> " @ $ProScoreis;
UpdateProScore(1);
}
function dmPlayerDies(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::dmPlayerDies(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
$ProDMDeaths = detag(%a1);
$ProScore[1] = "<color:00FF00>" @ $ProDMKills @ "<color:FFFF00> / <color:FF0000>" @ $ProDMDeaths @ "<color:FFFF00> " @ $ProScoreis;
UpdateProScore(1);
}
//---------------------------------------------------------------
// Handle All Arena Events: Neo's adaptation of the 1.0 release from the mod author, Teribaen
//---------------------------------------------------------------
function arenaVersionMsg( %msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6 ) {
%version = detag(%a1);
%versionString = detag(%a2);
$ArenaSupport::RemoteVersion = %version;
commandToServer( 'ArenaSupportHello', $ArenaSupport::LocalVersion );
}
function arenaServerState( %msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6 ) {
%teamCount = detag(%a1);
$ArenaSupport::TeamCount = %teamCount;
}
function arenaAddTeam( %msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6 ) {
%teamNum = detag(%a1);
if ( %teamNum > 2 ) return;
%teamName = detag(%a2);
%score = detag(%a3);
if(%score $= "") %score = 0;
%ProaliveCount = detag(%a4);
%PrototalCount = detag(%a5);
if(%ProaliveCount $= "") %ProaliveCount = 0;
if(%PrototalCount $= "") %PrototalCount = 0;
$ProScore[%teamNum] = "";
$ProStatus[%teamNum] = "";
if ( $ArenaSupport::TeamCount == 2 ) {
$ProTeam[%teamNum] = %teamName;
$ProScore[%teamNum] = %score;
// switch the status lines for Arena so it is more intuitive
if(%teamNum == 1) %teamNum = 2;
else if (%teamNum == 2) %teamNum = 1;
$ProStatus[%teamNum] = %ProaliveCount @ "/" @ %PrototalCount;
}
UpdateProStatus();
}
// Update the alive/total player count for a team in the status hud
function arenaTeamState(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
%teamNum = detag(%a1);
if ( %teamNum > 2 ) return;
%ProaliveCount = detag(%a2);
%PrototalCount = detag(%a3);
if(%ProaliveCount $= "") %ProaliveCount = 0;
if(%PrototalCount $= "") %PrototalCount = 0;
// Switch the status lines for arena so it is more intuitive
// Display alive/total counts for the teams
if ( $ArenaSupport::TeamCount == 2 ) {
if(%teamNum == 1) %teamNum = 2;
else if (%teamNum == 2) %teamNum = 1;
$ProStatus[%teamNum] = %ProaliveCount @ "/" @ %PrototalCount;
}
UpdateProStatus();
}
//---------------------------------------------------------------
// Handle all Cap and Hold Events
//---------------------------------------------------------------
function cnhAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::cnhAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%teamNum = detag(%a1);
%teamName = detag(%a2);
%score = detag(%a3);
if(%score $= "") %score = 0;
%sLimit = detag(%a4);
$ProStatus[%teamNum] = "Held : " @ detag(%a5);
$ProTeam[%teamNum] = %teamName;
$ProScore[%teamNum] = "+" @ (%sLimit - %score);
UpdateProScore(%teamNum, $ProScore);
UpdateProStatus();
}
function hudFlipFlopsHeld(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::hudFlipFlopsHeld(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%teamNum = detag(%a1);
if (%teamNum == "2") %line = "1";
else %line = "2";
$ProStatus[%line] = "Held : " @ detag(%a2);
UpdateProStatus();
}
function cnhTeamCap(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::cnhTeamCap(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%teamNum = detag(%a4);
%score = detag(%a5);
%sLimit = detag(%a6);
%string = %sLimit - %score;
UpdateProScore(%teamNum, "+" @ %string);
}
//---------------------------------------------------------------
// Handle all Bounty Events
//---------------------------------------------------------------
function bountyTargetIs(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::bountyTargetIs(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%hit = detag(%a1);
if(%hit $= "")
%hit = "< Waiting >";
$ProStatus[1] = StripNameColors(%hit);
$ProStatus[2] = "";
UpdateProStatus();
}
function bountyTargetDropped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::bountyTargetDropped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
$ProStatus[1] = "";
$ProStatus[2] = "< Waiting >";
UpdateProStatus();
}
//---------------------------------------------------------------
// Handle all CTF Events
//---------------------------------------------------------------
function ctfAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::ctfAddTeam(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%teamNum = detag(%a1);
%teamName = detag(%a2);
%flagStatus = detag(%a3);
%score = detag(%a4);
if (%flagStatus $= "<At Base>") {
%flagStatus = "";
}
// NULL out before setting
$ProScore[%teamNum] = "";
$ProStatus[%teamNum] = "";
$ProScore[%teamNum] = %score;
$ProTeam[%teamNum] = %teamName;
$ProStatus[%teamNum] = %flagStatus;
UpdateProScore(%teamNum, %score);
UpdateProStatus();
}
function ctfFlagTaken(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::ctfFlagTaken(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%team = detag(%a3);
%taker = detag(%a4);
if ( StripNameColors(%taker) $= detag($PPName) ) {
$ProStatus[%team] = "<font:Univers bold:16><color:00FF00>RUN!!!";
} else {
$ProStatus[%team] = %taker;
}
UpdateProStatus();
}
function ctfFlagDropped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::ctfFlagDropped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%team = detag(%a3);
$ResetTimer = 1;
if (%team == "1")
CTFReturnUpdate("1", "46", "1");
else
CTFReturnUpdate("2", "46", "1");
}
function ctfFlagCapped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::ctfFlagCapped(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
$ProStatus[1] = "";
$ProStatus[2] = "";
UpdateProStatus();
}
function ctfFlagReturned(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
parent::ctfFlagReturned(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6);
%team = detag(%a3);
$ProStatus[%team] = "";
UpdateProStatus();
}
function CTFReturnUpdate(%line,%time,%new) {
if ((Strstr($ProStatus[%line], "< ENEMY: ") != -1) || (Strstr($ProStatus[%line], "< YOURS: ") != -1) || (%new == "1")) {
if ($ResetTimer == "1") {
%newtime = "45";
if (ProHudStatus.schedule[%line] !$= "") {
cancel(ProHudStatus.schedule[%line]);
ProHudStatus.schedule[%line] = "";
}
$ResetTimer = 0;
} else {
%newtime = (%time - 1);
}
// See if status has changed no need to update
if (%line == $PPTeam)
%whom = "YOURS:";
else
%whom = "ENEMY:";
$ProStatus[%line] = "<color:FFFF00>< " @ %whom @ " " @ %newtime @ " >";
ProHudStatus.schedule[%line] = schedule(1000, 0, "CTFReturnUpdate", %line, %newtime);
}
UpdateProStatus();
}
//---------------------------------------------------------------
// Hud Update Functions
//---------------------------------------------------------------
function doUpdateGhettoList() {
parent::doUpdateGhettoList();
UpdateProScore();
}
function UpdateProScore(%team, %amount) {
if ((%team) && (%amount)) {
$ProScore[%team] = %amount;
}
if ($PPTeam == "1") {
%color[1] = "00FF00";
%color[2] = "FFFFFF";
} else {
%color[2] = "00FF00";
%color[1] = "FFFFFF";
}
if (($ProPackPrefs::OBHudActive) && ($ProPackPrefs::ScoreHudActive)) {
ProHudScore.setVisible(true);
} else {
ProHudScore.setVisible(false);
}
if (isobject($hudposProHudScore)) {
ProHudScore.position = $hudposProHudScore;
} else {
ProHudScore.position = $ProScorePOS[getWord($pref::Video::resolution, 0)];
}
if (StrLen($ProTeam[1]) < 1) {
ProHudScoreText.setText("<just:left><font:Univers condensed:16><color:" @ %color[1] @ ">" @ $ProSingleScore SPC $ProScore[1]);
} else {
ProHudScoreText.setText("<just:left><font:Univers condensed:16><color:" @ %color[1] @ ">" @ $ProTeamCount[1] @ " - " @ getword($ProTeam[1], 0) @ " : " @ $ProScore[1] @ "\n" @
"<just:left><font:Univers condensed:16><color:" @ %color[2] @ ">" @ $ProTeamCount[2] @ " - " @ getword($ProTeam[2], 0) @ " : " @ $ProScore[2] );
}
}
function UpdateProStatus() {
if ((strlen($ProStatus[1]) < 1) && (strlen($ProStatus[2]) < 1)) {
ProHudStatusText.setText("");
ProHudStatus.setVisible(false);
} else {
if ($PPTeam == 1) %otherteam = 2;
else if ($PPTeam == 2) %otherteam = 1;
else %otherteam = 0;
if (($ProPackPrefs::OBHudActive) && ($ProPackPrefs::StatusHudActive)) {
ProHudStatus.setVisible(true);
} else {
ProHudStatus.setVisible(false);
PPTR2CarrierHealth.setVisible(false);
}
ProHudStatusText.setText("<just:center><color:FF0000>" @ $ProStatus[$PPTeam] @
"\n<just:center><color:00FF00>" @ $ProStatus[%otherteam]);
}
}
//--------------------------------------
// GUI
//--------------------------------------
function ProHudCreate() {
ProHudDestroy();
%ProStatusX = getWord($pref::Video::resolution, 0) * 0.50 - 100;
%ProStatusY = getWord($pref::Video::resolution, 1) * 0.66;
new ShellFieldCtrl(ProHudStatus) {
profile = "GuiConsoleProfile";
horizSizing = "center";
vertSizing = "bottom";
position = %ProStatusX SPC %ProStatusY;
extent = "200 50";
minExtent = "8 8";
visible = "0";
new GuiMLTextCtrl(ProHudStatusText) {
profile = "ProPackTextCtrl";
horizSizing = "center";
vertSizing = "top";
position = "0 0";
extent = "200 50";
minExtent = "8 8";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new GuiProgressCtrl(PPTR2CarrierHealth) {
profile = "TR2CarrierHudProfile";
horizSizing = "center";
vertSizing = "bottom";
position = "50 40";
extent = "100 10";
minExtent = "10 10";
visible = "0";
hideCursor = "0";
bypassHideCursor = "0";
helpTag = "0";
};
};
playgui.add(ProHudStatus);
new ShellFieldCtrl(ProHudScore) {
profile = "GuiConsoleProfile";
horizSizing = "center";
vertSizing = "center";
position = "844 42";
extent = "104 40";
minExtent = "8 8";
visible = "0";
new GuiMLTextCtrl(ProHudScoreText) {
profile = "ProPackTextCtrl";
horizSizing = "center";
vertSizing = "center";
position = "0 0";
extent = "102 38";
minExtent = "8 8";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
};
playgui.add(ProHudScore);
}
function ProHudDestroy() {
if (isObject(ProHudStatus)) {
playgui.remove(ProHudStatus);
ProHudStatus.delete();
}
if (isObject(ProHudScore)) {
playgui.remove(ProHudScore);
ProHudScore.delete();
}
}
//-------------------
// Override hud.cs
//-------------------
function ClientCmdDisplayHuds() {
parent::ClientCmdDisplayHuds();
objectiveHud.setVisible(getProReverse($ProPackPrefs::OBHudActive));
}
function updateDemoPlaybackStatus() { // turns on the default objective hud in demo mode
parent::updateDemoPlaybackStatus();
objectiveHud.setVisible(true);
}
function restoreAllHuds() {
parent::restoreAllHuds();
objectiveHud.setVisible(getProReverse($ProPackPrefs::OBHudActive));
}
function clientCmdTogglePlayHuds(%val) {
parent::clientCmdTogglePlayHuds(%val);
objectiveHud.setVisible(getProReverse($ProPackPrefs::OBHudActive));
if ( (%val) && ($ProPackPrefs::ScoreHudActive) ) {
ProHudScore.setVisible(true);
} else {
ProHudScore.setVisible(false);
PPTR2CarrierHealth.setVisible(false);
}
if ( (%val) && ($ProPackPrefs::StatusHudActive) ) {
ProHudStatus.setVisible(true);
} else {
ProHudStatus.setVisible(false);
PPTR2CarrierHealth.setVisible(false);
}
}
function PlayGui::onWake(%this) {
parent::onWake(%this);
if (!isObject(ProHudScore)) schedule(3000, 0, "ProHudCreate");
if(isObject(HM) && isObject(HudMover)) hudmover::addhud(ProHudScore, "ProPackScore");
if(isObject(HM) && isObject(HudMover)) hudmover::addhud(ProHudStatus, "ProPackStatus");
}
function DispatchLaunchMode() {
addMessageCallback('MsgClientJoinTeam', ProSiegeRoleSwitch); // switching Teams
addMessageCallback('MsgTeamRabbitAddTeam', teamRabbitAddTeam);
addMessageCallback('MsgTeamRabbitFlagTaken', teamRabbitFlagTaken);
addMessageCallback('MsgTeamRabbitFlagDropped', teamRabbitFlagDropped);
addMessageCallback('MsgTeamRabbitFlagReturned', teamRabbitFlagReturned);
addMessageCallback('MsgTeamRabbitFlagStatus', teamRabbitFlagStatus);
addMessageCallback('MsgArenaVersion', arenaVersionMsg );
addMessageCallback('MsgArenaServerState', arenaServerState);
addMessageCallback('MsgArenaAddTeam', arenaAddTeam);
addMessageCallback('MsgArenaTeamState', arenaTeamState);
addMessageCallback('MsgTR2FlagTaken', TR2FlagTaken);
parent::DispatchLaunchMode();
}
};
activatePackage(ProPackObjective);

View file

@ -0,0 +1,110 @@
// #category = ProPack
// #name = ProPack Observed
// #version = 2.2
// #date = August 13, 2001
// #warrior = Neofight
// #email = neofight@tribes2.org
// #web = http://propack.tribes2.org
// #description = Can't remember who is watching? Now you know.
// #status = Beta 2
// #credit = MeBaD
package ProPackObserved {
function ProPackCheckObserv(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
%messagetype = detag(%msgType);
%messagestring = detag(%msgString);
%observername = detag(%a1);
if ((%messagetype $= "Observer") && (Strstr(%messagestring, "is now observing you.") != -1)) {
if ($ProPackPrefs::WaveToObserver) commandToServer('CannedChat', 'ChatAnimWave', false);
$ProPackObCount++;
$ProPackObserver[$ProPackObCount] = %observername;
} else if ((%messagetype $= "ObserverEnd") && (Strstr(%messagestring, "is no longer observing you.") != -1) || (%messagetype $= "MsgClientJoinTeam") || (%messagetype $= "MsgClientDrop")) {
for (%i = 1; %i <= $ProPackObCount; %i++) {
if ($ProPackObserver[%i] $= %observername) {
//echo("Client erased : " @ $ProPackObserver[%i]);
$ProPackObserver[%i] = "";
$ProPackObCount--;
//SqueezeObserverLines(%i);
}
}
}
%count = "1";
while ($ProPackObserver[%count] !$= "") {
%ProPackObserverName = %ProPackObserverName @ $ProPackObserver[%count] @ "\n";
%count++;
}
ProPackObserved.setVisible(true);
ProPackObservedText.setText("<just:right><color:FF00FF>" @ %ProPackObserverName);
}
function SqueezeObserverLines(%num) {
for (%i = %num; %i <= $ProPackObCount; %i++) {
%x = %i + 1;
$ProPackObserver[%i] = $ProPackObserver[%x];
}
%count = "1";
while ($ProPackObserver[%count] !$= "") {
%ProPackObserverName = %ProPackObserverName @ "\n" @ $ProPackObserver[%count];
%count++;
}
ProPackObservedText.setText("<just:right><color:FF00FF>" @ %ProPackObserverName);
}
function ProPackObservedCreate() {
ProPackObservedDestroy();
%ProObsX = getWord($pref::Video::resolution, 0) - 146; //- width of the hud + small space
%ProObsY = getWord(hudClusterBack.position, 1) + getWord(hudClusterBack.extent, 1) + 2 + 64 + 2;
new ShellFieldCtrl(ProPackObserved) {
profile = "GuiConsoleProfile";
horizSizing = "left";
vertSizing = "bottom";
position = %ProObsX SPC %ProObsY;
extent = "144 100";
minExtent = "8 8";
visible = "0";
new GuiMLTextCtrl(ProPackObservedText) {
profile = "ProPackTextCtrl";
horizSizing = "right";
vertSizing = "bottom";
position = "0 0";
extent = "144 100";
visible = "1";
};
};
playGui.add(ProPackObserved);
}
function ProPackObservedDestroy() {
if (isObject(ProPackObserved)) {
playGui.remove(ProPackObserved);
ProPackObserved.delete();
}
}
function clientCmdTogglePlayHuds(%val) {
ProPackObserved.setVisible(%val);
parent::clientCmdTogglePlayHuds(%val);
}
function PlayGui::onWake(%this) {
parent::onWake(%this);
if (!isObject(ProPackObserved)) schedule(3000, 0, "ProPackObservedCreate"); // POS video prefs
if(isObject(HM) && isObject(HudMover)) hudmover::addhud(ProPackObserved, "ProPackObserved");
}
function DispatchLaunchMode() {
addMessageCallback('Observer', ProPackCheckObserv);
addMessageCallback('ObserverEnd', ProPackCheckObserv);
addMessageCallback('MsgClientJoinTeam', ProPackCheckObserv);
addMessageCallback('MsgClientDrop', ProPackCheckObserv);
parent::DispatchLaunchmode();
}
};
activatePackage(ProPackObserved);

View file

@ -0,0 +1,60 @@
// #category = ProPack
// #name = ProPack Throw
// #version = 3.01
// #status = Beta 3
// #date = July 4, 2001
// #warrior = Neofight
// #email = neofight@tribes2.org
// #web = http://propack.tribes2.org
// #description = Full-force repair kits, grenades, mines, drop grenades, and an option to beacon your mines!
// #Credit = Happy & Runar
function ProKit(%val) {
if (%val)
throw(RepairKit);
}
function DropGrenades(%val) {
if (%val) {
throw(Grenade);
throw(FlareGrenade);
throw(FlashGrenade);
throw(CameraGrenade);
throw(ConcussionGrenade);
}
}
function BeaconMine(%val) {
if (%val) {
use(mine);
use(beacon);
use(beacon);
}
}
function ProGrenade(%val) {
if(%val)
commandToServer('endThrowCount');
else
commandToServer('startThrowCount');
$mvTriggerCount4 += $mvTriggerCount4 & 1 == %val ? 2 : 1;
}
function ProMine(%val) {
if (%val)
commandToServer( 'endThrowCount' );
else
commandToServer( 'startThrowCount' );
$mvTriggerCount5++;
}
package ProPackThrow {
// When you die the server clears the throw count, so we start it up again when we respawn.
function updateActionMaps() {
parent::updateActionMaps();
commandToServer( 'startThrowCount' );
}
};
activatePackage(ProPackThrow);

View file

@ -0,0 +1,522 @@
// #category = ProPack
// #name = ProPack Tracker
// #version = 5.89
// #description = Death/Kill stat tracking by weapon w/ optional pop-ups
// #status = close to final ;p
// #date = June 3, 2001
// #warrior = MeBaD
// #web = http://propack.tribes2.org
// #credit = Neofight
$isLTon = "1"; // make activate LifeTimeStatsFULLStats default to turning on (big screen)
$discscreenshots = "0"; // disabled by default
$trackerleft[1280] = "415 562";
$trackerright[1280] = "665 562";
$trackerleft[1152] = "351 482";
$trackerright[1152] = "601 482";
$trackerleft[1024] = "287 425";
$trackerright[1024] = "537 425";
$trackerleft[800] = "175 275";
$trackerright[800] = "425 275";
package ProPackTracker {
// Activate ReCall of last print
function ActivateReCall(%val) {
if (%val) {
TrackerPopup($RecallLeft, $RecallRight, 7);
if ((Strlen($RecallLeft) < 1) || (Strlen($RecallRight) < 1)) {
%printthis = "<color:FFFF00>No event in buffer... YET";
} else {
%printthis = "<color:FFFFFF><font:Univers condensed:16> Recall of Last Event";
}
clientCmdBottomPrint(%printthis, 5, 1);
}
}
// Activate Full display of all kills
function ActivateLifeTime(%val) {
if (%val) {
if ($isLTon == "2") {
clientcmdTogglePlayHuds(true);
FullTrackStats.setVisible(false);
FullTrackStatsText.setText(""); // clear that big buffer
FullTrackStatsRightText.setText(""); // clear that big buffer
FullTrackStatsLeftText.setText(""); // clear that big buffer
clientCmdBottomPrint("Returning to game", 1, 1);
$isLTon = "1";
} else {
clientcmdTogglePlayHuds(false);
FullTrackStats.BuildFULLprintout();
$isLTon++;
}
}
}
// Activate AutoScreenshot
function ActivateAutoSC(%val) {
if (%val) {
if ($discscreenshots == "1") {
$discscreenshots = "0";
%word = "DISABLED";
%color = "FF0000"; // red
} else {
$discscreenshots = "1";
%word = "ENABLED";
%color = "99FF00"; // green
}
clientCmdBottomPrint("<color:FFFFFF><font:Univers condensed:16> Auto Screenshots : <font:Univers bold:16><color:" @ %color @ ">" @ %word, 5, 1);
}
}
//---------------------------
// Control the hud events
//---------------------------
function handleClientJoin(%msgType, %msgString, %clientName, %clientId, %targetId, %isAI, %isAdmin, %isSuperAdmin, %isSmurf, %guid) {
parent::handleClientJoin(%msgType, %msgString, %clientName, %clientId, %targetId, %isAI, %isAdmin, %isSuperAdmin, %isSmurf, %guid);
if(StrStr(%msgString, "Welcome to Tribes") != -1) {
ProClearGameTrack();
}
}
function FullTrackStats::BuildFULLprintout() {
%weapons = "<font:Univers bold:8>\n<font:Univers bold:16><just:left>";
for (%i = 1; %i < 31; %i++) {
%weapon = ProNoSpacedWeaponName(%i);
if (Strlen(%weapon) > 0) {
if ((%i != 7) && ((%i > 0) && (%i < 12)) || (%i == 31)) {
%ThisLTKills = ProhandleLifeTime(%weapon, "2", "kills");
%ThisLTDeaths = ProhandleLifeTime(%weapon, "2", "deaths");
%weapons = %weapons @ " " @ %weapon @ "\n";
%leftstats = %leftstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $GameKills[%weapon] @ "<color:FFFFFF> - <color:FF0000>" @ $GameDeaths[%weapon] @ "\n";
%rightstats = %rightstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ %ThisLTKills @ "<color:FFFFFF> - <color:FF0000>" @ %ThisLTDeaths @ "\n";
}
}
}
// adds the rest of them .. heh
%weapons = %weapons @ " headshots\n rearshocks\n carrierkills\n flagreturns\n";
%leftstats = %leftstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $GameKills[lasertohead] @ "\n";
%leftstats = %leftstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $GameKills[rearshock] @ "\n";
%leftstats = %leftstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $carrierkills @ "\n";
%leftstats = %leftstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $returnsthisgame @ "\n";
%rightstats = %rightstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $LifeTime::Kills_lasertohead @ "\n";
%rightstats = %rightstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $LifeTime::Kills_rearshock @ "\n";
%rightstats = %rightstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $LifeTime::CTFCarrierKills @ "\n";
%rightstats = %rightstats @ "<font:Univers bold:16><just:center><color:FFFF00>" @ $LifeTime::CTFReturns @ "\n";
// main big window
// Game Box
FullTrackStats.setVisible(true);
FullTrackStatsText.setText("<just:center><font:Univers bold:18>All your Stats are belong to " @ $PPName @ "\n\n" @
"<font:Univers bold:16><color:00FF99>Weapon Current Kills/Deaths LifeTime Kills/Deaths\n<color:FFFFFF><font:Univers condensed:16>" @
%weapons );
FullTrackStatsLeftText.setText(%leftstats);
FullTrackStatsRightText.setText(%rightstats);
}
function ProCheckFlagReturn(%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
if ($ProPackPrefs::TrackerActive) {
%msg = detag(%msgString);
%subType = detag(%msgType);
%printflagloadout = 0;
if (Strstr(%msg, "You returned your flag") != -1) { //MsgCTFFlagReturned
$returnsthisgame++;
$LifeTime::CTFReturns++;
%word = "Flag Returns";
$FlagPrintGame = $returnsthisgame;
$FlagPrintLife = $LifeTime::CTFReturns;
%printflagloadout = 1;
}
if ((%subType $= "msgCarKill") && (Strstr(%msg, "You received") != -1)) { //Player check added for the 'Classic' Mod
$carrierkills++;
$LifeTime::CTFCarrierKills++;
%word = "FlagCarrier Kills";
$FlagPrintGame = $carrierkills;
$FlagPrintLife = $LifeTime::CTFCarrierKills;
%printflagloadout = 1;
}
if (%printflagloadout == "1") {
%printleft = "Current " @ %word @ "\n";
%printleft = %printleft @ "<color:FFFF00>" @ $FlagPrintGame;
%printright = %printright @ "LifeTime " @ %word @ "\n";
%printright = %printright @ "<color:FFFF00>" @ $FlagPrintLife;
TrackerPopup(%printleft, %printright, 7);
$RecallLeft = %printleft;
$RecallRight = %printright;
}
}
}
function ProHeadshot (%msgType, %msgString, %a1, %a2, %a3, %a4, %a5, %a6) {
if ($ProPackPrefs::TrackerHeadshotSound) {
%msg = detag(%msgString);
if (Strstr(%msg, "You received") != -1)
alxPlay(alxCreateSource(AudioChat, "headshot.wav"));
}
}
function ProHeadshotKill() {
if ($ProPackPrefs::TrackerActive) {
$GameKills[lasertohead]++;
$LifeTime::Kills_lasertohead++;
// left box
%printleft = "Current Headshot kills \n";
%printleft = %printleft @ "<color:FFFF00>" @ $GameKills[lasertohead];
// right box
%printright = %printright @ "LifeTime Headshot kills \n";
%printright = %printright @ "<color:FFFF00>" @ $LifeTime::Kills_lasertohead;
TrackerPopup(%printleft, %printright, 7);
$RecallLeft = %printleft;
$RecallRight = %printright;
}
if ($ProPackPrefs::TrackerHeadshotSound) {
%handle[1] = alxCreateSource(AudioChat, "headshot.wav");
%handle[2] = alxCreateSource(AudioChat, "wbslap.wav");
for (%i = 1; %i < 3; %i++) {
alxPlay(%handle[%i]);
}
}
}
function ProRearshockKill() {
if ($ProPackPrefs::TrackerActive) {
$GameKills[rearshock]++;
$LifeTime::Kills_rearshock++;
// left box
%printleft = "Current Rearshock kills \n";
%printleft = %printleft @ "<color:FFFF00>" @ $GameKills[rearshock];
// right box
%printright = %printright @ "LifeTime Rearshock kills \n";
%printright = %printright @ "<color:FFFF00>" @ $LifeTime::Kills_rearshock;
TrackerPopup(%printleft, %printright, 7);
$RecallLeft = %printleft;
$RecallRight = %printright;
}
}
function ProTrackKill(%msgType, %msgString, %victimName, %victimGender, %victimPoss, %killerName, %killerGender, %killerPoss, %damageType) {
if ($ProPackPrefs::TrackerActive) {
%doweprint = 0;
%CoolshotCheck = detag(%msgType);
%ProdamageType = detag(%damageType);
%ProkillerName = StripNameColors(detag(%killerName));
%ProvictimName = StripNameColors(detag(%victimName));
if ((%CoolshotCheck $= "MsgHeadshotKill") && (Strstr(%ProkillerName, $PPName) != -1)) {
ProHeadshotKill();
return;
}
if ( ((%CoolshotCheck $= "msgRearshot") || (%CoolshotCheck $= "MsgRearshotKill")) && (Strstr(%ProkillerName, $PPName) != -1) ) {
ProRearshockKill();
return;
}
%ProWeaponUsed = ProNoSpacedWeaponName(%ProdamageType); //%ProWeaponUsed = $DamageTypeText[%damageType]
if (Strlen(%ProWeaponUsed) < 1) {
return; // default is ghey!
}
// Killed Someone
if (Strstr(%Prokillername, $PPName) != -1) {
$GameKills[%ProWeaponUsed]++;
%LifeTimeDeathPrint = ProhandleLifeTime(%ProWeaponUsed, "2", "Deaths");
%LifeTimeKillPrint = ProhandleLifeTime(%ProWeaponUsed, "1", "Kills");
if ((Strstr(%ProWeaponUsed, "disc") != -1) && ($discscreenshots == "1")) {
clientcmdTogglePlayHuds(false);
schedule(500, 0, "doScreenShot"); // let the disc settle in .. heh
schedule(900, 0, "clientcmdTogglePlayHuds", true);
}
%doweprint = 1;
}
// Death by someone
if (Strstr(%Provictimname, $PPName) != -1) {
$GameDeaths[%ProWeaponUsed]++;
%LifeTimeDeathPrint = ProhandleLifeTime(%ProWeaponUsed, "1", "Deaths");
%LifeTimeKillPrint = ProhandleLifeTime(%ProWeaponUsed, "2", "Kills");
%doweprint = 1;
}
if (%doweprint == 1) {
%printleft = "Current " @ %ProWeaponUsed @ " Kills \n";
%printleft = %printleft @ "<color:FFFF00>" @ $GameKills[%ProWeaponUsed] @ "<color:FFFFFF> - <color:FF0000>" @ $GameDeaths[%ProWeaponUsed];
%printright = %printright @ "LifeTime " @ %ProWeaponUsed @ " Kills \n";
%printright = %printright @ "<color:FFFF00>" @ %LifeTimeKillPrint @ "<color:FFFFFF> - <color:FF0000>" @ %LifeTimeDeathPrint;
TrackerPopup(%printleft, %printright, 7);
$RecallLeft = %printleft;
$RecallRight = %printright;
}
}
}
function ProClearGameTrack() {
for (%i = 0; %i < 36; %i++) {
%WeaponName = ProNoSpacedWeaponName(%i);
$GameKills[%WeaponName] = 0;
$GameDeaths[%WeaponName] = 0;
}
$returnsthisgame = 0;
$carrierkills = 0;
$gameKills[lasertohead] = 0;
$gameKills[rearshock] = 0;
echo("Clearing Game Kills...");
}
function Disconnect() { // override disconnect just to add export
ProBackupLTKills();
ProClearGameTrack();
parent::Disconnect();
}
function ProBackupLTKills() {
export("$LifeTime::*", "prefs/LifeTimeKills.cs", false);
echo("Saved LifeTime Kills");
}
function ProhandleLifeTime(%weapon,%add,%type) {
// %weapon, display[2] or add[1], death or kill
if (%add == "1") { // got kill :) || death :(
if (%type $= "Kills") { $LifeTime::Kills_[%weapon]++; return $LifeTime::Kills_[%weapon]; }
if (%type $= "Deaths") { $LifeTime::Deaths_[%weapon]++; return $LifeTime::Deaths_[%weapon]; }
} else { // display
if (%type $= "Kills") { return $LifeTime::Kills_[%weapon]; }
if (%type $= "Deaths") { return $LifeTime::Deaths_[%weapon]; }
}
}
function DispatchLaunchMode() {
if (!isPlayingDemo()) {
addMessageCallback('MsgGameOver', ProBackupLTKills);
addMessageCallBack('MsgClientReady', ProClearGameTrack); // set everything to 0 when your ready for it
addMessageCallback('MsgCTFFlagReturned', ProCheckFlagReturn);
addMessageCallBack('msgCarKill', ProCheckFlagReturn);
addMessageCallBack('MsgLegitKill', ProTrackKill);
addMessageCallBack('MsgHeadshotKill', ProTrackKill);
addMessageCallBack('msgHeadshot', ProHeadshot);
addMessageCallBack('MsgRearshotKill', ProTrackKill); // Added for 'Classic' Mod
addMessageCallBack('msgRearshot', ProTrackKill); // Added for 'Classic' Mod
addMessageCallBack('msgTR2Knockdown', ProTrackKill); // Added for TR2
}
parent::DispatchLaunchMode();
}
//-----------------
// GUI Stuff now :)
//-----------------
function TransTrackHudCreate() {
TransTrackHudDestroy();
$TransTrackLeft = new ShellFieldCtrl(TransTrackLeft) {
profile = "GuiConsoleProfile";
horizSizing = "center";
vertSizing = "center";
position = "175 275";
extent = "200 50";
minExtent = "8 8";
visible = "0";
new GuiMLTextCtrl(TransPrintLeftText) {
profile = "ProPackTextCtrl";
horizSizing = "center";
vertSizing = "center";
position = "3 5";
extent = "190 40";
minExtent = "8 8";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
};
playgui.add($TransTrackLeft);
$TransTrackRight = new ShellFieldCtrl(TransTrackRight) {
profile = "GuiConsoleProfile";
horizSizing = "center";
vertSizing = "center";
position = "425 275";
extent = "200 50";
minExtent = "8 8";
visible = "0";
new GuiMLTextCtrl(TransPrintRightText) {
profile = "ProPackTextCtrl";
horizSizing = "center";
vertSizing = "center";
position = "3 5";
extent = "190 40";
minExtent = "8 8";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
};
playgui.add($TransTrackRight);
$FullTrackStats = new ShellFieldCtrl(FullTrackStats) {
profile = "GuiChatBackProfile";
horizSizing = "center";
vertSizing = "center";
position = "0 0";
extent = "400 324";
minExtent = "8 8";
visible = "0";
new GuiMLTextCtrl(FullTrackStatsText) {
profile = "ProPackTextCtrl";
horizSizing = "right";
vertSizing = "bottom";
position = "3 5";
extent = "390 290";
minExtent = "8 8";
visible = "1";
helpTag = "0";
lineSpacing = "3";
allowColorChars = "1";
maxChars = "-1";
};
new ShellFieldCtrl(FullTrackStatsLeft) {
profile = "GuiChatBackProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "90 60";
extent = "150 264";
minExtent = "8 8";
visible = "1";
new GuiMLTextCtrl(FullTrackStatsLeftText) {
profile = "ProPackTextCtrl";
horizSizing = "right";
vertSizing = "bottom";
position = "2 7";
extent = "140 264";
minExtent = "8 8";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
};
new ShellFieldCtrl(FullTrackStatsRight) {
profile = "GuiChatBackProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "250 60";
extent = "150 264";
minExtent = "8 8";
visible = "1";
new GuiMLTextCtrl(FullTrackStatsRightText) {
profile = "ProPackTextCtrl";
horizSizing = "right";
vertSizing = "bottom";
position = "2 7";
extent = "140 264";
minExtent = "8 8";
visible = "1";
helpTag = "0";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
};
};
playgui.add($FullTrackStats);
$TransTrackHudBuild = true;
}
function TransTrackHudDestroy() {
if ($TransTrackHudBuild) {
playgui.remove($TransTrackRight);
playgui.remove($TransTrackLeft);
TransTrackLeft.delete();
TransTrackRight.delete();
$TransTrackLeft = "";
$TransTrackRight = "";
playgui.remove($FullTrackStats);
FullTrackStats.delete();
$FullTrackStats = "";
$TransTrackHudBuild = false;
}
}
function LoadingGui::onWake(%this) {
if (!$TransTrackHudBuild) {
TransTrackHudCreate();
}
parent::onWake(%this);
}
function TrackerPopup(%leftprint, %rightprint, %time ) {
if ($ProPackPrefs::TrackerPopup) {
%sectime = (%time * 1000); // make all time in seconds
TransTrackLeft.position = $trackerleft[getWord($pref::Video::resolution, 0)];
TransPrintLeftText.setText("<font:Univers condensed:16><just:center>" @ %leftprint);
TransTrackRight.position = $trackerright[getWord($pref::Video::resolution, 0)];
TransPrintRightText.setText("<font:Univers condensed:16><just:center>" @ %rightprint);
TransTrackLeft.setVisible(true);
TransTrackRight.setVisible(true);
schedule(%sectime, 0, eval, "TransTrackLeft.setVisible(false);");
schedule(%sectime, 0, eval, "TransTrackRight.setVisible(false);");
}
}
};
activatePackage(ProPackTracker);

View file

@ -0,0 +1,67 @@
// #category = ProPack
// #name = ProPack VehicleKeys
// #version = 2.2
// #date = July 29, 2001
// #warrior = Neofight
// #email = neofight@tribes2.org
// #web = http://propack.tribes2.org
// #description = hard-coded vehicle keys = same on all maps; toggleable teleport option
// #status = Good enough
// #Credit = jsut, Silverspirit
package ProVehicleKeys {
function VehicleHud::onWake(%this) {
parent::onWake(%this);
if (isObject(hudMap)) {
hudMap.pop();
hudMap.delete();
}
new ActionMap(hudMap);
hudMap.blockBind(moveMap, toggleInventoryHud);
hudMap.blockBind(moveMap, toggleScoreScreen);
hudMap.blockBind(moveMap, toggleCommanderMap);
hudMap.bindCmd(keyboard, escape, "", "VehicleHud.onCancel();" );
hudMap.bindCmd(keyboard, "1", "", "VehicleHud.QuickBuy( \"scoutVehicle\" );");
hudMap.bindCmd(keyboard, "2", "", "VehicleHud.QuickBuy( \"AssaultVehicle\" );");
hudMap.bindCmd(keyboard, "3", "", "VehicleHud.QuickBuy( \"mobileBaseVehicle\" );");
hudMap.bindCmd(keyboard, "4", "", "VehicleHud.QuickBuy( \"scoutFlyer\" );");
hudMap.bindCmd(keyboard, "5", "", "VehicleHud.QuickBuy( \"BomberFlyer\" );");
hudMap.bindCmd(keyboard, "6", "", "VehicleHud.QuickBuy( \"hapcFlyer\" );");
hudMap.push();
}
function VehicleHud::QuickBuy(%this, %id) {
parent::QuickBuy(%this,$ProQuickBuy[%id]);
}
function VehicleHud::addLine(%this, %tag, %lineNum, %name, %count) {
$ProQuickBuy[%name] = %lineNum;
return parent::addLine(%this, %tag, %lineNum, %name, %count);
}
function VehicleHud::onSleep(%this) {
parent::onSleep(%this);
$ProQuickBuy["scoutVehicle"] = "";
$ProQuickBuy["AssaultVehicle"] = "";
$ProQuickBuy["mobileBaseVehicle"] = "";
$ProQuickBuy["scoutFlyer"] = "";
$ProQuickBuy["BomberFlyer"] = "";
$ProQuickBuy["hapcFlyer"] = "";
}
function ProPackTeleportToggle(%val) {
if(%val) {
if($pref::Vehicle::pilotTeleport $= "1") {
clientCmdBottomPrint( "Teleport Off", 2, 1 );
$pref::Vehicle::pilotTeleport = "0";
toggleVehicleTeleportPref();
} else {
clientCmdBottomPrint( "Teleport On", 2, 1 );
$pref::Vehicle::pilotTeleport = "1";
toggleVehicleTeleportPref();
}
}
}
};
activatePackage(ProVehicleKeys);

View file

@ -0,0 +1,976 @@
//--- OBJECT WRITE BEGIN --- ProPack In-game Interface
new GuiControl(ProPackGui) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "height";
position = "0 0";
extent = "640 480";
minExtent = "8 8";
visible = "1";
new ShellPaneCtrl(ProPackParent) {
profile = "ShellPaneProfile";
horizSizing = "center";
vertSizing = "center";
position = "0 0";
extent = "640 480";
minExtent = "48 92";
visible = "1";
text = "ProPack::InterFace";
longTextBuffer = "0";
noTitleBar = "0";
new ShellTabButton(ProPackHudOptionsBtn) {
profile = "ShellTabProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "15 40";
extent = "189 38";
minExtent = "48 38";
visible = "1";
command = "ProPackGui.setFrameList(ProPackHudOptions);";
text = "Hud Transparent Options";
longTextBuffer = "0";
maxLength = "255";
};
new ShellTabButton(ProPackAutoChatBtn) {
profile = "ShellTabProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "15 80";
extent = "189 38";
minExtent = "48 38";
visible = "1";
command = "ProPackGui.setFrameList(ProPackAutoChat);";
text = "AutoChat Options";
longTextBuffer = "0";
maxLength = "255";
};
new ShellTabButton(ProPackTrackerBtn) {
profile = "ShellTabProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "15 120";
extent = "189 38";
minExtent = "48 38";
visible = "1";
command = "ProPackGui.setFrameList(ProPackTracker);";
text = "Kill Tracking Options";
longTextBuffer = "0";
maxLength = "255";
};
new ShellTabButton(ProPackInfoHudBtn) {
profile = "ShellTabProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "15 160";
extent = "189 38";
minExtent = "48 38";
visible = "1";
command = "ProPackGui.setFrameList(ProPackInfoHud);";
text = "InfoHud Options (Split Chat)";
longTextBuffer = "0";
maxLength = "255";
};
new ShellTabButton(ProPackOBHudBtn) {
profile = "ShellTabProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "15 200";
extent = "189 38";
minExtent = "48 38";
visible = "1";
command = "ProPackGui.setFrameList(ProPackOBHud);";
text = "NEW ObjectiveHud Options";
longTextBuffer = "0";
maxLength = "255";
};
new ShellTabButton(ProPackMultiBtn) {
profile = "ShellTabProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "15 240";
extent = "189 38";
minExtent = "48 38";
visible = "1";
command = "ProPackGui.setFrameList(ProPackMulti);";
text = "Multi Hud FPS/Ping/Alt/Speed";
longTextBuffer = "0";
maxLength = "255";
};
new ShellTabButton(ProPackMuteBtn) {
profile = "ShellTabProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "15 280";
extent = "189 38";
minExtent = "48 38";
visible = "1";
command = "ProPackGui.setFrameList(ProPackMute);";
text = "Mute/Alter Tools";
longTextBuffer = "0";
maxLength = "255";
};
new ShellTabFrame(ProPackHudOptionsFrame) {
profile = "ShellTabFrameProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "199 33";
extent = "419 424";
minExtent = "254 26";
visible = "1";
isVertical = "1";
useCloseButton = "0";
edgeInset = "0";
new GuiMLTextCtrl(ProPackHudOptionsNotes) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "bottom";
position = "11 11";
extent = "397 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellToggleButton(ProPackOuterChatHud) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 125";
extent = "190 27";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::outerChatHudVar";
text = "ChatHud Background";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackChatMenuHud) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 155";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::ChatMenuHudVar";
text = "ChatMenu Background";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackmainVoteHud) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 185";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::mainVoteHudVar";
text = "Vote Status Hud";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackHudClusterBack) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 215";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::HudClusterBack";
text = "Health/Energy/Compass";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackretFrameHud) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 245";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::retFrameHud";
text = "Reticle Frame Outline";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackAmmoHud) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 275";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::ammoHud";
text = "AmmoHud (Bottom left of reticle)";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackBottomPrintDlg) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 305";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::bottomprintdlgVar";
text = "Bottom Print Dlg";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackTR2EventPopup) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 335";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::TR2EventPopupVar";
text = "TR2 Event Popup";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackTR2BonusHud) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 365";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::TR2BonusHudVar";
text = "TR2 Bonus Hud";
longTextBuffer = "0";
maxLength = "255";
};
};
new ShellTabFrame(ProPackAutoChatFrame) {
profile = "ShellTabFrameProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "199 33";
extent = "419 424";
minExtent = "254 26";
visible = "0";
isVertical = "1";
useCloseButton = "0";
edgeInset = "0";
new GuiMLTextCtrl(ProPackAutoChatNotes) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "bottom";
position = "11 11";
extent = "397 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellToggleButton(ProPackWaveToObserver) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 95";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::WaveToObserver";
text = "Greet Observers (Local)";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackAutoTaunt) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::AutoTaunt";
text = "AutoTaunt (Local)";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackMuteSpammers) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "222 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::MuteSpammers";
text = "Mute Repeated Messages";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackAutoGotFlag) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 155";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::AutoGotFlag";
text = "Auto Got Flag (HELP!)";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackAutoGenBoom) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 185";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::AutoGenBoom";
text = "Auto Gen Boom";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackAutoVPadBoom) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "222 185";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::AutoVPadBoom";
text = "Auto V-Pad Boom";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackAutoGrabSpeed) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "10 215";
extent = "191 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::AutoGrabSpeed";
text = "Team: (Flag) Grab Speed";
longTextBuffer = "0";
maxLength = "255";
};
new GuiMLTextCtrl(ProPackGrabInfo) {
profile = "GuiDefaultProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "20 255";
extent = "110 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellTextEditCtrl(ProPackGrab1) {
profile = "NewTextEditProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "125 245";
extent = "295 38";
minExtent = "32 38";
visible = "1";
maxLength = "35";
deniedSound = "InputDeniedSound";
glowOffset = "9 9";
};
new ShellTextEditCtrl(ProPackGrab2) {
profile = "NewTextEditProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "125 273";
extent = "295 38";
minExtent = "32 38";
visible = "1";
maxLength = "35";
deniedSound = "InputDeniedSound";
glowOffset = "9 9";
};
new ShellTextEditCtrl(ProPackGrab3) {
profile = "NewTextEditProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "125 301";
extent = "295 38";
minExtent = "32 38";
visible = "1";
maxLength = "35";
deniedSound = "InputDeniedSound";
glowOffset = "9 9";
};
new ShellTextEditCtrl(ProPackGrab4) {
profile = "NewTextEditProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "125 329";
extent = "295 38";
minExtent = "32 38";
visible = "1";
maxLength = "35";
deniedSound = "InputDeniedSound";
glowOffset = "9 9";
};
new ShellTextEditCtrl(ProPackGrab5) {
profile = "NewTextEditProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "125 357";
extent = "295 38";
minExtent = "32 38";
visible = "1";
maxLength = "35";
deniedSound = "InputDeniedSound";
glowOffset = "9 9";
};
new ShellToggleButton(ProPackAddPeekActive) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "222 215";
extent = "191 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::AddPeek";
text = "Peek Speed";
longTextBuffer = "0";
maxLength = "255";
};
};
new ShellTabFrame(ProPackTrackerFrame) {
profile = "ShellTabFrameProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "199 33";
extent = "419 424";
minExtent = "254 26";
visible = "0";
isVertical = "1";
useCloseButton = "0";
edgeInset = "0";
new GuiMLTextCtrl(ProPackTrackerNotes) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "bottom";
position = "11 11";
extent = "397 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellToggleButton(ProPackTrackerActivate) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::TrackerActive";
text = "Track Stats";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackKillPopup) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "26 155";
extent = "175 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::TrackerPopup";
text = "Kill Popup";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackHeadShotSounds) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "26 185";
extent = "175 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::TrackerHeadShotSound";
text = "Head Shot Sounds";
longTextBuffer = "0";
maxLength = "255";
};
};
new ShellTabFrame(ProPackInfoHudFrame) {
profile = "ShellTabFrameProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "199 33";
extent = "419 424";
minExtent = "254 26";
visible = "0";
isVertical = "1";
useCloseButton = "0";
edgeInset = "0";
new GuiMLTextCtrl(ProPackInfoHudNotes) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "bottom";
position = "11 11";
extent = "397 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellToggleButton(ProPackInfoHudActivate) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackprefs::InfoHudActivate";
text = "Info Hud Activated";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackSplitDeathMsg) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "26 155";
extent = "175 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::DeathMessages";
text = "Split Death Messages";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackMuteChatDisplay) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "222 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::MuteChatDisplay";
text = "Mute Chat [V**] Display";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackColorKills) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "222 155";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::CKillsActive";
text = "Color Kills";
longTextBuffer = "0";
maxLength = "255";
};
};
new ShellTabFrame(ProPackOBHudFrame) {
profile = "ShellTabFrameProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "199 33";
extent = "419 424";
minExtent = "254 26";
visible = "0";
isVertical = "1";
useCloseButton = "0";
edgeInset = "0";
new GuiMLTextCtrl(ProPackOBHudNotes) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "bottom";
position = "11 11";
extent = "397 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellToggleButton(ProPackOBHudActivate) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::OBHudActive";
text = "New Objective Hud Activated";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackScoreHudActivate) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "26 155";
extent = "175 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::ScoreHudActive";
text = "Score Hud Activated";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackStatusHudActivate) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "26 185";
extent = "175 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::StatusHudActive";
text = "Status Hud Activated";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackFlagHudActivate) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "222 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::FlagHudActive";
text = "New Flag Status Hud Activated";
longTextBuffer = "0";
maxLength = "255";
};
};
new ShellTabFrame(ProPackMultiFrame) {
profile = "ShellTabFrameProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "199 33";
extent = "419 424";
minExtent = "254 26";
visible = "0";
isVertical = "1";
useCloseButton = "0";
edgeInset = "0";
new GuiMLTextCtrl(ProPackMultiNotes) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "bottom";
position = "11 11";
extent = "397 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellToggleButton(ProPackFPSHudActive) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 125";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::FPSHud";
text = "FPS Hud";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackPingHudActive) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 155";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::PingHud";
text = "Ping Hud";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackSpeedHudActive) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 185";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::SpeedHud";
text = "Speed Hud";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackAltHudActive) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 215";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::AltHud";
text = "Altitude Hud";
longTextBuffer = "0";
maxLength = "255";
};
new ShellToggleButton(ProPackPeekSpdActive) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "11 245";
extent = "190 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::PeekSpeedHud";
text = "Speed Peek Hud";
longTextBuffer = "0";
maxLength = "255";
};
};
new ShellTabFrame(ProPackMuteFrame) {
profile = "ShellTabFrameProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "199 33";
extent = "419 424";
minExtent = "254 26";
visible = "0";
isVertical = "1";
useCloseButton = "0";
edgeInset = "0";
new GuiMLTextCtrl(ProPackMuteNotes) {
profile = "GuiDefaultProfile";
horizSizing = "width";
vertSizing = "bottom";
position = "11 11";
extent = "397 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
new ShellToggleButton(ProPackMuteToolsActivate) {
profile = "ShellRadioProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "21 103";
extent = "388 30";
minExtent = "26 27";
visible = "1";
variable = "$ProPackPrefs::MuteToolsActive";
text = "Alter/Split Tools Active";
longTextBuffer = "0";
maxLength = "255";
};
new ShellScrollCtrl(ProPackMuteListParent) {
profile = "NewScrollCtrlProfile";
horizSizing = "width";
vertSizing = "height";
position = "11 131";
extent = "408 289";
minExtent = "24 52";
visible = "1";
helpTag = "0";
willFirstRespond = "1";
hScrollBar = "alwaysOff";
vScrollBar = "alwaysOn";
constantThumbHeight = "0";
defaultLineHeight = "15";
childMargin = "0 0";
fieldBase = "gui/shll_field";
new GuiScrollContentCtrl(ProPackMuteToolsList) {
profile = "GuiDefaultProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "4 4";
extent = "384 297";
minExtent = "8 8";
visible = "1";
helpTag = "0";
new GuiChatMenuTreeCtrl(ProPackMuteToolsTree) {
profile = "ShellTreeViewProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "0 0";
extent = "409 280";
minExtent = "8 8";
visible = "1";
altCommand = "ProPackGui.editSelectedMuteListItem();";
helpTag = "0";
tabSize = "16";
imagesBitmap = "gui/shll_treeView.png";
numImages = "13";
textOffset = "2";
fullRowSelect = "0";
itemHeight = "15";
altFontColor = "6 215 245 255";
altFontColorHL = "6 215 245 255";
altFontColorSE = "25 56 68 255";
dirty = "0";
};
};
};
};
};
};
//--- OBJECT WRITE END ---
//--- OBJECT WRITE BEGIN --- Mute options Popup
new GuiControl(ProPackEditMuteItem) {
profile = "DlgBackProfile";
horizSizing = "width";
vertSizing = "height";
position = "0 0";
extent = "640 480";
minExtent = "8 8";
visible = "1";
helpTag = "0";
new ShellPaneCtrl(ProPackEditTitle) {
profile = "ShellDlgPaneProfile";
horizSizing = "center";
vertSizing = "center";
position = "150 110";
extent = "400 300";
minExtent = "48 92";
visible = "1";
helpTag = "0";
text = "Edit::";
noTitleBar = "0";
new GuiTextCtrl() {
profile = "ShellTextRightProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "21 42";
extent = "80 22";
minExtent = "8 8";
visible = "1";
helpTag = "0";
text = "Action:";
};
new ShellPopupMenu(ProPackEditMuteActions) {
profile = "ShellPopupProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "97 34";
extent = "249 36";
minExtent = "49 36";
visible = "1";
helpTag = "0";
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 = "21 80";
extent = "80 22";
minExtent = "8 8";
visible = "1";
helpTag = "0";
text = "Alter Text:";
};
new ShellTextEditCtrl() {
profile = "NewTextEditProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "97 72";
extent = "249 38";
minExtent = "32 38";
visible = "1";
variable = "$ProPackGui::AlterText";
helpTag = "0";
historySize = "0";
maxLength = "100";
password = "0";
glowOffset = "9 9";
};
new GuiMLTextCtrl(ProPackEditNotes) {
profile = "ProPackTextCTRL";
horizSizing = "right";
vertSizing = "bottom";
position = "19 113";
extent = "368 100";
minExtent = "8 8";
visible = "1";
lineSpacing = "2";
allowColorChars = "1";
maxChars = "-1";
};
// cancel - commit offset
//- 270 - 130
//- 50 [135] (30) [135] 50
new ShellBitmapButton() {
profile = "ShellButtonProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "215 245";
extent = "135 38";
minExtent = "32 38";
visible = "1";
command = "ProPackGui.setMuteItem();";
helpTag = "0";
text = "Commit Changes";
simpleStyle = "0";
};
new ShellBitmapButton() {
profile = "ShellButtonProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "50 245";
extent = "135 38";
minExtent = "32 38";
visible = "1";
command = "ProPackEditMuteActions.clear();Canvas.popDialog(ProPackEditMuteItem);";
accelerator = "escape";
helpTag = "0";
text = "Cancel";
simpleStyle = "0";
};
};
};
//--- OBJECT WRITE END ---

Binary file not shown.

After

Width:  |  Height:  |  Size: 327 B