Post: New Stats Editor, Edit All Stats!
11-30-2011, 04:31 AM #1
Correy
I'm the Original
(adsbygoogle = window.adsbygoogle || []).push({}); This Stat Editor allows you to edit your following..

- Kills
- Wins
- Score
- Losses
- Clan Tag
- Prestige
- Kill Streak
- Win Streak
- Time Played

this is built from just one main function, and using a sub function..
    
Editor( type )
{
self ExitMenu();
self.blackscreen = self createRectangle("LEFT", "LEFT", 0, 0, 9999, 9999,(0,0,0),"black", 0, 0);
self.blackscreen fadeOverTime(1);
wait 1;
self.txt = self createFontString("objective", 1.5);
self.txt.foreGround = true;
self.txt setText( "You're Editing ^2"+self.Editor["CurrentEditor"]+ "^7 || Press [{+attack}] To Scroll Up || Press [{+speed_throw}] To Scroll Down || Press [{+frag}] Scroll Across || Presse [{+melee}] To Exit || Press [{+reload}] To Comfirm" );
for(;Winky Winky
{
self.txt setPoint("CENTER", "", 800, 220);
self.txt setPoint("CENTER", "", -800, 220, 20);
wait 20;
}
self _GetType();
if( Type != "ClanTag" ) self.Editor["Types"] = "0123456789";
if( Type == "ClanTag" ) self.Editor["Types"] = "ABCDEFGHIJKLMNOPQRSTUVWXYZ !-_@#$%^&*()<>%[]{}1234567890";
self.Editor["Options"] = self.Editor["Types"];
self.Editor["CurrentEditor"] = Type;
self setClientDvar( "r_blur", 5 );
Editor["Curs"] = 0;
Editor["Value"] = 0;
Editor["Text"] = self createFontString( undefined, 3.3, self );
Editor["Text"] setPoint( "CENTER" );
Editor["Text"].foreground = true;
Editor["Text"].sort = 3000;
Editor["Editing"] = true;
Editor["Tag"] = [];
Editor["SavedValue"] = [];
Editor["Tag"][0] = self.Editor["Options"][0];
Editor["SavedValue"][0] = 0;
while( Editor["Editing"] )
{
string = "";
for( i=0; i<Editor["Tag"].size; i++ )
{
if( i == Editor["Curs"] ) string += ( "^1[ ^7"+Editor["Tag"][i]+"^1 ]" );
else Editor["Tag"] += ( " "+ Editor["Tag"][i] + "" );
}
Editor["Text"] setText( string );
if( self AdsButtonPressed() )
{
Editor["Value"]-= 1;
Editor["Value"] *= ( Editor["Value"] > 0 ) * ( Editor["Value"] < Editor["Types"].size );
Editor["Tag"][Editor["Curs"]] = Editor["Types"][Editor["Value"]];
Editor["SavedValue"][Editor["Curs"] = Editor["Value"];
}
if( self AttackButtonPressed() )
{
Editor["Value"]+= 1;
Editor["Value"] *= ( Editor["Value"] > 0 ) * ( Editor["Value"] < Editor["Types"].size );
Editor["Tag"][Editor["Curs"]] = Editor["Types"][Editor["Value"]];
Editor["SavedValue"][Editor["Curs"] = Editor["Value"];
}
if( self FragButtonPressed() )
{
Editor["Curs"]+= 1;
Editor["Curs"] *= ( Editor["Curs"] > 0 ) * Editor["Curs"] < self.Editor["MaxSize"] );
if( Editor["Curs"] > Editor["Tag"].size )
{
Editor["SavedValue"][Editor["SavedValue"].size] = 0;
Editor["Tag"][Editor["Tag"].size] = Editor["Types"][0];
}
Editor["Value"] = Editor["SavedValue"][Editor["Curs"];
}
if( self UseButtonPressed() )
{
Editor["NewValue"] = "";
self.Editor["NewValue"] = Editor["Value"];
for( i-0; i<Editor["Tag"].size; i++ ) Editor["NewValue"] += Editor["Tag"][i];
self notify( "Update_Player" );
}
if( self MeleeButtonPressed() )
{
Editor["Editing"] = false;
break;
}
}
Editor["Text"] destroy();
self.blackscreen destroy();
self.txt destroy();
self setClientDvar( "r_blur", 0 );
}
_GetType()
{
if( self.Editor["Options"] != "ClanTag" ) self.Editor["MaxSize"] = 8;
else if( self.Editor["Options"] == "Prestige" ) self.Editor["MaxSize"] = 2;
else self.Editor["MaxSize"] = 4;
text = self.Editor["CurrentEditor"]+" Set To : "+self.Editor["NewValue"];
for( ;; )
{
self waittill( "Update_Player" );
if( self.Editor["CurrentEditor"] == "Kills" ) self maps\mp\gametypes\_persistence::statSet( "kills", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Score" ) self maps\mp\gametypes\_persistence::statSet( "score", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Wins" ) self maps\mp\gametypes\_persistence::statSet( "wins", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Kill Streak" ) self maps\mp\gametypes\_persistence::statSet( "kill_streak", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Win Streak" ) self maps\mp\gametypes\_persistence::statSet( "win_streak", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Losses" ) self maps\mp\gametypes\_persistence::statSet( "losses", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Time Played" ) self maps\mp\gametypes\_persistence::statSet( "time_played_total", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Clan Tag" ) self setClientDvar( "clanname", self.Editor["NewValue"] );
if( self.Editor["CurrentEditor"] == "Prestige" && self.Editor["NewValue"] > 11 ) text = "Prestige must be lower than 11!";
self iPrintlnBold( text );
}
}

thanks to KillaMaJic for the idea, Zy0n for the first version which i edited.
(adsbygoogle = window.adsbygoogle || []).push({});

The following 5 users say thank you to Correy for this useful post:

BlazingDope, crazy_blake7, Beats, IVI40A3Fusionz, Taylor
12-04-2011, 02:00 PM #11
Correy
I'm the Original
Originally posted by xRaW View Post
could u note down every 1? i looked and it looks as if its win streak kills score ect ect. But that done nothing when i actually clicked on it in the menu


the editor dont function too well, im fix when i get home.. make it better Winky Winky

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo