T1 Stand Alone Flag Cap Score Hud?

Nicodemus
11-20-2002, 07:10 PM
Does one exist? I just recently thought it might be kinda nice to see it without hitting score list.

HotCheese
11-20-2002, 07:22 PM
well you can make it standalone but if you do it'll break whatever other scripts you have

Nicodemus
11-20-2002, 07:26 PM
:huh:

Shinigami
11-20-2002, 07:34 PM
Two scripts parsing for the same events

Nicodemus
11-20-2002, 07:44 PM
... what are you talkin about? I just want a team score hud that will work with presto/newopts.

Savage
11-20-2002, 07:48 PM
then it wouldn't be standalone.




vgx.

Nicodemus
11-20-2002, 07:53 PM
uhm, if it works alone it'd work with presto/newopts, thx for the needless input.

back on track here, does one exist?

Ragnafrak
11-20-2002, 08:08 PM
Originally posted by 0NiCoDeMuS0
uhm, if it works alone it'd work with presto/newopts, thx for the needless input.

back on track here, does one exist? what he's trying to say is that standalone means doesn't require other script (or script packs)..

if ur looking for one that works with presto and stripped at the same time, good luck.. but a good one for presto is AO's, and a good one for stripped is (ta da, the one that came with it).. or daerid's.. gonna need to ask a stripped user for that one

http://www.slingscripts.com
if you can't find AO's hud there, u deserve to die

BrokenSoul
11-20-2002, 09:05 PM
ao's ctf hud works with presto but i had a prob with it. my scripts tab for newopt would get fucked every now and then. i have evita's its the same hud and works better for me. here is the link http://heimdal_sg3.tripod.com/evita.html
any of those scripts can be used with presto/newopts i'd suggest you get the ammo hud one too its nice.

Hindsight
11-20-2002, 09:17 PM
Originally posted by Savage v2.0
then it wouldn't be standalone.
vgx. :rofl:

TooSmoothe
11-21-2002, 01:13 AM
Copy and past this on a notepad and put it in config/presto
exec("scorehud.cs"); in autoexec.cs

// -----------------------
// ScoreHUD.cs version 0.3 (Me...Courtesy, took out the objectives shit and edited some other stuff so it would just look nicer and smaller)
// -----------------------

// Written by Joe Chott (verxion@pobox.com AKA Verxion) with MUCH help from Presto,
// who is THE MAN! Everyone should really let him know how much
// he helps the scripting community.

// ************************* ************************* ************************* *******
// These lines are where you customize the location of the hud.

// Use this line to place ScoreHUD at an absolute position
// $ScoreHud::position = "6 182 120 30";

// Or use this line to put it under DynHUD (if you have that enabled)
$ScoreHud::position = "left(hudDyn) bottom(hudDyn)-1 width(hudDyn) 22";

// ************************* ************************* ************************* *******

// Include files

Include("presto\\TeamTrak.cs");
Include("presto\\HUD.cs");
Include("presto\\Event.cs");

// This function deals with our initial connection to the game
// We need to assume the score is zip to zip, and we tell the
// player that we don't know for sure by putting a question mark
// after the score. The code to "manually" sync the scores is
// not really ready for prime time yet, but I will post it when
// it is.

function ScoreHud::OnConnect() {

// The two teams initial scores on connect.

$ScoreHud::score[0] = 0;
$ScoreHud::score[1] = 0;

// Both teams scores are currently un-synced.

$ScoreHud::sync[0] = " ";
$ScoreHud::sync[1] = " ";


// Since we have new data, update the hud.

HUD::Update(ScoreHud);
}

// When a new mission starts, we KNOW the score, and we know that nobody
// has the objective, so we update those variables accordingly

function ScoreHud::OnChangeMission () {
$ScoreHud::score[0] = 0;
$ScoreHud::score[1] = 0;
$ScoreHud::sync[0] = "";
$ScoreHud::sync[1] = "";

// Since we have new data, update the hud.

HUD::Update(ScoreHud);
}

// This just increments the score for the correct team when there is a
// flag capture.

function ScoreHud::ProcessCapture( %team) {

// Calculate the team number that scored (incoming team is the team
// whose flag was captured, therefore, the OTHER team gets the point.

%scoringTeam = 1 - %team;

// Increment their score

$ScoreHud::score[%scoringTeam]++;

// A nifty little blink of the new score (courtesy of Presto)

ScoreHud::Blink(%scoringT eam, 0);
}

// Setup the appropriate fonts for the blink function coming up.

$ScoreHud::blinkFont[0] = "<f2>";
$ScoreHud::blinkFont[1] = "<f3>";

// This is the update function for the hud. It makes sure the status of the
// objective is counted into the score, and shows the score of both teams,
// along with the status of the objective.

function ScoreHud::Update() {

// This is going to setup our blinking score.

%score[0] = $ScoreHud::blinkFont[$scoreHud::blink[0] == true] @
($ScoreHud::score[0] + ($ScoreHud::objective == "0")) @ $ScoreHud::sync[0];
%score[1] = $ScoreHud::blinkFont[$scoreHud::blink[1] == true] @
($ScoreHud::score[1] + ($ScoreHud::objective == "1")) @ $ScoreHud::sync[1];

// Just for readabilities sake, lets make some vars to describe the teams.

%myTeam = Team::Friendly();
%enemyTeam = Team::Enemy();

// Ok, this is gonna be "Score: 0 to 0" type of format.

HUD::AddTextLine(ScoreHUD , "<f1> Us : " @ %score[%myTeam] @
"<f1> Them: " @ %score[%enemyTeam]);



// Tell the HUD handler that we don't need to be polled.

return 0;
}




// Detects when you change teams so it can re-display correctly.

function ScoreHud::TeamChange(%cli ent) {
if (%client != getManagerId())
return;

HUD::Update(ScoreHud);
}

// This function is the brainchild of Presto. I just changed his indention
// method to match my code. :) This function is recursive, and all it does
// is call itself repeatedly, 8 times, alternating the color of the score so
// it draws your eyes there. :)

function ScoreHud::Blink(%team, %mode) {
if (%mode == 8)
$ScoreHud::blink[%team] = "";
else {
$ScoreHud::blink[%team] = !$ScoreHud::blink[%team];
schedule("ScoreHud::Blink("@%team@", "@ (%mode + 1) @");", 0.3);
}
HUD::Update(ScoreHud);
}

// Instantiate our hud

HUD::New(ScoreHud, ScoreHud::Update, $scoreHUD::position);
HUD::Display(ScoreHud);

// Setup our callbacks for events

Event::Attach(eventClient ChangeTeam, ScoreHud::TeamChange);
Event::Attach(eventObject iveTaken, ScoreHud::ProcessObjectiv e);
Event::Attach(eventConnec tionAccepted, ScoreHud::OnConnect);
Event::Attach(eventChange Mission, ScoreHud::OnChangeMission );
Event::Attach(eventFlagCa ptured, ScoreHud::ProcessCapture) ;
Event::Attach(eventClient Message, ScoreHud::ParseClientMess age);

Nicodemus
11-21-2002, 02:04 AM
Doesn't work :(

TooSmoothe
11-21-2002, 03:18 AM
are you putting it in config/presto?

CoJack
11-21-2002, 10:24 AM
ya i couldn't get it working either. i settled for tiny's caphud. real small hud. i like it. try it out.
http://www.tribalwar.com/junk/huds2.php

CoJack
11-21-2002, 10:49 AM
sorry, but i had dynhud set to "false" which was why i wasn't seeing it,vgo! looks alright i guess. i still like tiny's smallcaphud though. gj nonetheless

CoJack
11-21-2002, 11:05 AM
well what i thought was your hud wasn't. there's another hud separate from dynhud that i thought was yours. hud keeps track of points,kills, and i assume caps.
i deleted your code and still have the hud though, so...

sorry, but i never had dynhud enabled. when i starting playing tribes 3yrs ago. my friend LuRcH sent me his config and i've always just played around with it. i use to use flea's scripts but they're buggy as shit. went over to poop's. seems to work better.