UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

Get how many times a certain thing happens ex. Total times swiped, time reloaded

broken avatar :(
Created 12 years ago
by Centric
0 Members and 1 Guest are viewing this topic.
1,915 views
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 2 April 2014
Last active: 3 months ago
Posts
480
Respect
Forum Rank
Perk Hacker
Primary Group
Donator ♥
My Groups
More
My Contact & Social Links
More
Personal Quote
If it's not perfect, you'll never see it.
Signature
Learn by doing, not copy and pasting.

Enjoy my 2015 contest map, a simple map with bo1-bo2 features
http://ugx-mods.com/forum/index.php?topic=14968.msg149200#
×
Centric's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Centric's Contact & Social Linkscentric_centriccInvictable
Title says it all, how would I check the total time a player reloads, fire, gets hit, downs, how many revives, etc.
Marked as best answer by Centric 12 years ago
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 6 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
Signature
×
MakeCents's Groups
Mapper Has released one or more maps to the UGX-Mods community.
Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
Title says it all, how would I check the total time a player reloads, fire, gets hit, downs, how many revives, etc.

There already are some stats you have listed being tracked. You can find this information in _zombiemode.gsc in the form of:
Code Snippet
Plaintext
//self.stats["stat"] //for example:
self.stats["downs"]
Those stats are easy to get. The stats not already being tracked you could track yourself.

You would thread functions on each player to add more stats like below:
Code Snippet
Plaintext
//you would thread TrackStats() somewhere
TrackStats(){
flag_wait( "all_players_connected" );
players = get_players();
for(i=0;i<players.size;i++){
players[i] thread Tracker("reload_start");
// players[i] thread Tracker("stat"); //add more stat = what you notify when what you want to track happens
}
}
Tracker(stat){
self.stats[stat] = 0;
while(1){
self waittill( stat );
self.stats[stat] = self.stats[stat] + 1;
wait(.1);
// iprintlnbold(stat + " " + self.stats[stat]); //uncomment to see if it is working
}
}

Then you can have another script to do whatever it is with those stats the same way, with self.stats["stat"]. Anyway, I don't know of an easier way.
Last Edit: October 05, 2014, 04:56:36 pm by MakeCents
broken avatar :(
×
broken avatar :(
Location: se
Date Registered: 30 July 2013
Last active: 2 years ago
Posts
517
Respect
Forum Rank
Zombie Enslaver
Primary Group
Scripter
My Groups
More
My Contact & Social Links
More
×
Ege115's Groups
Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
Ege115's Contact & Social LinksEge115
There's also a notify for when the clip is re filled. So you can wait for when the player starts reloading, AND then you can make it wait for the ammo to be re filled.
And the notify for when the clip is re filled looks like this,
Code Snippet
Plaintext
self waittill("reload");
Just so you know if you ever need it.
Last Edit: October 05, 2014, 04:17:43 pm by Ege115

 
Loading ...