rui vieira
Veteran
- Messages
- 23
- Reaction score
- 5
- Points
- 783
can some one help me with this script getting bad syntax
devgui_award_challenge( n_index )
{
while( n_index == 4 )
{
s_team_stats = level._challenges.s_team;
s_team_stats.n_completed = 1;
s_team_stats.n_medals_held = 1;
a_keys = getarraykeys( level._challenges.s_team.a_stats );
s_stat = level._challenges.s_team.a_stats[ a_keys[ 0]];
s_stat.b_medal_awarded = 1;
s_stat.b_reward_claimed = 0;
a_players = get_players();
foreach( player in a_players )
{
s_stat.a_b_player_rewarded[player.characterindex] = 0;
player setclientfieldtoplayer( s_stat.s_parent.cf_complete, 1 );
}
foreach( m_board in level.a_m_challenge_boards )
{
m_board showpart( s_stat.str_glow_tag );
}
}
a_keys = getarraykeys( level._challenges.a_players[ 0].a_stats );
a_players = get_players();
foreach( player in a_players )
{
s_player_data = level._challenges.a_players[ player.characterindex];
s_player_data.n_completed++;
s_player_data.n_medals_held++;//Testing bad syntax
s_stat = s_player_data.a_stats[ a_keys[ n_index - 1]];
s_stat.b_medal_awarded = 1;
s_stat.b_reward_claimed = 0;
player setclientfieldtoplayer( s_stat.s_parent.cf_complete, 1 );
foreach( m_board in level.a_m_challenge_boards )
{
m_board showpart( s_stat.str_glow_tag );
}
}
}
devgui_award_challenge( n_index )
{
while( n_index == 4 )
{
s_team_stats = level._challenges.s_team;
s_team_stats.n_completed = 1;
s_team_stats.n_medals_held = 1;
a_keys = getarraykeys( level._challenges.s_team.a_stats );
s_stat = level._challenges.s_team.a_stats[ a_keys[ 0]];
s_stat.b_medal_awarded = 1;
s_stat.b_reward_claimed = 0;
a_players = get_players();
foreach( player in a_players )
{
s_stat.a_b_player_rewarded[player.characterindex] = 0;
player setclientfieldtoplayer( s_stat.s_parent.cf_complete, 1 );
}
foreach( m_board in level.a_m_challenge_boards )
{
m_board showpart( s_stat.str_glow_tag );
}
}
a_keys = getarraykeys( level._challenges.a_players[ 0].a_stats );
a_players = get_players();
foreach( player in a_players )
{
s_player_data = level._challenges.a_players[ player.characterindex];
s_player_data.n_completed++;
s_player_data.n_medals_held++;//Testing bad syntax
s_stat = s_player_data.a_stats[ a_keys[ n_index - 1]];
s_stat.b_medal_awarded = 1;
s_stat.b_reward_claimed = 0;
player setclientfieldtoplayer( s_stat.s_parent.cf_complete, 1 );
foreach( m_board in level.a_m_challenge_boards )
{
m_board showpart( s_stat.str_glow_tag );
}
}
}