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

Swapping perk machines every 5 rounds

broken avatar :(
Created 8 years ago
by fusorf
0 Members and 1 Guest are viewing this topic.
1,979 views
broken avatar :(
×
broken avatar :(
Location: fr
Date Registered: 25 July 2015
Last active: 2 years ago
Posts
121
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
//This is a comment
Signature
×
fusorf's Groups
fusorf's Contact & Social LinksfusorffusorfFireFusorf
Hello everyone.

I am using HarryBo21's swapping perk machine prefab (like in moon).
The script is designed like so : the perks swap every rounds. But I would like them to swap every 5 rounds.

I already tried this, without sucess:


in _zombiemode_perks.gsc

line 1244
Code Snippet
Plaintext
harrybo21_perks_spawn_swapping_perk_machine()
{
//fusorf edit
if(level.round_number % 5 == 0)
{
[...]


The above code does not work, the perk machines still swaps every round.
Marked as best answer by fusorf 8 years ago
broken avatar :(
×
broken avatar :(
OnionmanVere Bo21
Location: ieu dnt wnt 2 no
Date Registered: 27 September 2013
Last active: 1 year ago
Posts
1,864
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Mapper
My Groups
More
Personal Quote
ok
Signature
Aye mate you don't know me so y don't you shut tf up ok buddy :)

×
Scobalula's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Box Mappers Elite
Box Mappers Elite
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
Scobalula's Contact & Social Links
Hello everyone.

I am using HarryBo21's swapping perk machine prefab (like in moon).
The script is designed like so : the perks swap every rounds. But I would like them to swap every 5 rounds.

I already tried this, without sucess:


in _zombiemode_perks.gsc

line 1244
Code Snippet
Plaintext
harrybo21_perks_spawn_swapping_perk_machine()
{
//fusorf edit
if(level.round_number % 5 == 0)
{
[...]


The above code does not work, the perk machines still swaps every round.

In the function "harrybo21_perks_swapping_perk_watch_for_reset()" try:


Code Snippet
Plaintext
harrybo21_perks_swapping_perk_watch_for_reset()
{
while( 1 )
{
level waittill( "between_round_over" );
triggers = getEntArray( "harrybo21_swapping_vending", "script_noteworthy" );
if ( !isDefined( triggers ) || triggers.size < 1 || level.round_number % 5 != 0) // Check here, continue if not valid round.
continue;

level.round_swapped = false;
}
}

broken avatar :(
×
broken avatar :(
Location: fr
Date Registered: 25 July 2015
Last active: 2 years ago
Posts
121
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
//This is a comment
×
fusorf's Groups
fusorf's Contact & Social LinksfusorffusorfFireFusorf
In the function "harrybo21_perks_swapping_perk_watch_for_reset()" try:


Code Snippet
Plaintext
harrybo21_perks_swapping_perk_watch_for_reset()
{
while( 1 )
{
level waittill( "between_round_over" );
triggers = getEntArray( "harrybo21_swapping_vending", "script_noteworthy" );
if ( !isDefined( triggers ) || triggers.size < 1 || level.round_number % 5 != 0) // Check here, continue if not valid round.
continue;

level.round_swapped = false;
}
}


Works perfectly, thank you very much :D
broken avatar :(
×
broken avatar :(
OnionmanVere Bo21
Location: ieu dnt wnt 2 no
Date Registered: 27 September 2013
Last active: 1 year ago
Posts
1,864
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Mapper
My Groups
More
Personal Quote
ok
×
Scobalula's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Box Mappers Elite
Box Mappers Elite
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
Scobalula's Contact & Social Links
Works perfectly, thank you very much :D

Glad to be of assistance. \ :gusta: \

 
Loading ...