What's new

Discussion [RELEASE] Increase Stats In System Link

  • Thread starter R1ch4rd
  • Start date
  • Views 3,709
R

R1ch4rd

Like a baaaws
Messages
396
Reaction score
62
Code:
incStatsSL(Stat, Amount)
{
CurrentStat = self getPlayerData(Stat);
i = (CurrentStat + Amount);
self setPlayerData(Stat, i );
}

Works by setting i as the current data, then adding whatever you want onto it, and using setPlayerData to set both added together as the score/kills/wins.

This has been tested by me, and works 100%.

Eg:
Code:
incStatsSL("score", 100000);

Enjoy!
 
I

Im Too Modified

Enthusiast
Messages
96
Reaction score
3
Sounds good, may be using this soon.
 
R

R1ch4rd

Like a baaaws
Messages
396
Reaction score
62
^ Let me know how it goes. Anyone else got anything to say?
 
D

DJJama

Enthusiast
Messages
302
Reaction score
14
Good stuff.

I have just tested and it worked :smile:

Top coding

Jama
 
R

Random Hunter

Enthusiast
Messages
80
Reaction score
27
Can I add days played by this syntax ?
 
R

R1ch4rd

Like a baaaws
Messages
396
Reaction score
62
^ Use ^
Code:
self.timePlayed["other"] = 172800;
The 172800 is seconds, so to add one day set it *** 86400.
 
R

Random Hunter

Enthusiast
Messages
80
Reaction score
27
^ Use ^
Code:
self.timePlayed["other"] = 172800;
The 172800 is seconds, so to add one day set it *** 86400.

Thanks but does it work in sys-link ?
 
D

DJJama

Enthusiast
Messages
302
Reaction score
14
It should as the code itself works.

Give it a try.

Jama
 
D

Dwack

Now employed at Dominoes!
Messages
4,550
Reaction score
2,947
Last time I checked Days Played does not work in SystemLink
 
X

xXMockeyXx

Enthusiast
Messages
836
Reaction score
77
If this works. Wouldn't this also work with a player's prestige or rank?
 
C

Cliche 7S

Enthusiast
Messages
525
Reaction score
28
Nice maybe i can give this to a free sys link and even lower my chances of being banned
 
R

Random Hunter

Enthusiast
Messages
80
Reaction score
27
Last time I checked Days Played does not work in SystemLink
Yes I Tried it :|(

Would you please give a working syntax

+

Code:
   self.timePlayed["other"] = 60*60*24*20;
Is this working ??
 
R

R1ch4rd

Like a baaaws
Messages
396
Reaction score
62
Last time I checked Days Played does not work in SystemLink

I thought it did. If it doesn't, my bad.

If this works. Wouldn't this also work with a player's prestige or rank?

Rank already works in System Link.
Code:
self setPlayerData( "experience" , 2516000 );
I think you have to be host to get the Prestige mod working, but I'm not sure.

Nice maybe i can give this to a free sys link and even lower my chances of being banned
:smile:
 
R

R1ch4rd

Like a baaaws
Messages
396
Reaction score
62
Yes I Tried it :|(

Would you please give a working syntax

+

Code:
   self.timePlayed["other"] = 60*60*24*20;
Is this working ??

Does it or does it not work in System Link.

Also
Code:
   self.timePlayed["other"] = 1728000;
 
Top Bottom