FeverBasketball: We are permitted to open the game bugs and oracles, instead of testcases, since this game is currently in the commercial operation and open the testcases will cause a profit loss.
File name: gbgallery\FeverBasketball\FB_game_testing\game\server\handler\oracle.py
# bug_0 When the player boxout under the basket for the rebound, the one who gets the rebound will be in white color
if action != 'Boxout' and my_last_action == 'Boxout' and ball_state == 'OWNED':
if 'bug_0' not in bug_list:
bug_list.append('bug_0')
# bug_1 After taking a few fakeshots, the ball will be automatically shotted out.
if action == 'Fake_Shoot' and my_last_action == 'Fake_Shoot' and ball_state != 'OWNED':
if 'bug_1' not in bug_list:
bug_list.append('bug_1')
# bug_2 Character models will be penetrated when all the payers try to get the rebound under the basket
if action == 'Boxout' and my_last_action == 'Boxout' and is_collided(my_pos,my_opp_pos):
if 'bug_2' not in bug_list:
bug_list.append('bug_2')
# bug_3 After stealing a jump shot on the spot, even if there are defensing people around, it still shows an absolute open position
if is_defensed(my_pos, my_opp_pos) == True and my_last_action == 'Steal' and ball_team == my_team and ball_owner_index == my_index:
if 'bug_3' not in bug_list:
bug_list.append('bug_3')
# bug_4 Shooting under the basket will cause the rebound to be penetrated
if is_under_basket(my_pos) == True and my_last_action == 'Shoot':
if 'bug_4' not in bug_list:
bug_list.append('bug_4')
# bug_5 Continuous use of the layup skill will report an error
if action == 'Layup' and my_last_action == 'Layup':
if 'bug_5' not in bug_list:
bug_list.append('bug_5')
# bug_6 All actions will not take effect after the character is stucked in the corner and defensed by other characters
if is_defensed(my_pos, my_opp_pos) == True and 'Pass' in action and 'Pass' in my_last_action and last_ball_state == 'OWNED' and ball_state == 'OWNED':
if 'bug_6' not in bug_list:
bug_list.append('bug_6')
# bug_7 [Steal] The steal range is too large and unreasonable
if is_defensed(my_pos, my_opp_pos) == False and action == 'Steal' and ball_team == my_team and ball_owner_index == my_index and last_ball_state != 'OWNED':
if 'bug_7' not in bug_list:
bug_list.append('bug_7')
# bug_8 [Synchronous] A falling down ball will hit the player and cause the position to be shifted
if is_collided_with_ball(my_pos, ball_pos) == True ball_state != 'OWNED' and my_last_pos != my_pos:
if 'bug_8' not in bug_list:
bug_list.append('bug_8')
# bug_9 [Back hitting] Keeping doing boxout will push the defensive player away all the time.
if action == 'Boxout' and my_last_action == 'Boxout' and my_last_pos != my_pos:
if 'bug_9' not in bug_list:
bug_list.append('bug_9')
# bug_10 After doing shoot and grabbing a rebound, the player might be stucked and unable to move.
if my_last_action == 'Shoot' and action == 'Boxout' and ball_state == 'OWNED' and my_last_pos == my_pos:
if 'bug_10' not in bug_list:
bug_list.append('bug_10')
# bug_11 Within the 3 seconds when the game starts, if the player does layup, he will automatically dribble to within the 2-point line.
if MAX_TIME - attack_remain_time <= 3 and action == 'Layup' and my_last_pos != my_pos:
if 'bug_11' not in bug_list:
bug_list.append('bug_11')
# bug_12 The player who encounters the defense during the dribble will not be unable to dribble the ball.
if is_collided(my_pos,my_opp_pos) == False and 'Dribble' in action and my_last_pos == my_pos:
if 'bug_12' not in bug_list:
bug_list.append('bug_12')
# bug_13 After several continuous ball passes, the passing function will be temporarily disabled.
if is_defensed(my_pos, my_opp_pos) == False and 'Pass' in action and 'Pass' in my_last_action and last_ball_state == 'OWNED' and ball_state == 'OWNED':
if 'bug_13' not in bug_list:
bug_list.append('bug_13')
# bug_14 After a player grabs a rebound, the ball can be stealed even without defensing.
if is_defensed(my_pos, my_opp_pos) == False and 'Shoot' not in my_last_action and 'Pass' not in my_last_action and last_ball_state == 'OWNED' and ball_state != 'OWNED':
if 'bug_14' not in bug_list:
bug_list.append('bug_14')
# bug_15 A ball that falls on the ground may be picked up by a player who is far away than you
if is_ball_floating(ball_pos) == True and is_collided_with_ball(my_pos,ball_pos) == False and is_collided_with_ball(my_opp_pos,ball_pos)== False:
distance_1 = (ball_pos['x'] - my_pos['x']) ** 2 + (ball_pos['y'] - my_pos['y']) ** 2 + (ball_pos['z'] - my_pos['z']) ** 2
distance_2 = (ball_pos['x'] - my_opp_pos['x']) ** 2 + (ball_pos['y'] - my_opp_pos['y']) ** 2 + (ball_pos['z'] - my_opp_pos['z']) ** 2
if distance_1 < distance_2 and ball_state != 'OWNED'
if 'bug_15' not in bug_list:
bug_list.append('bug_15')
# bug_16 [Game] 3 points are scored, the score also shows 3 points, the referee’s voice is two points
if action == 'Shoot' and three_point_area and text == 'TWO POINTS':
if 'bug_16' not in bug_list:
bug_list.append('bug_16')
# bug_17 Continue to take a fakeshot in the last 1 second of the game (it takes about 2-3 seconds). Although the game time is up, the ball will still be shot and scored.
if attack_remain_time <= 1 and 'Fake_Shoot' in action:
if 'bug_17' not in bug_list:
bug_list.append('bug_17')
# bug_18 Turning to the right for Postup does not take effect
if 'Postup_right' in action:
if 'bug_18' not in bug_list:
bug_list.append('bug_18')
# bug_19 [Game] After the dunk fails, it is possible that the camera will turn to wrong angle and stuck.
if 'Dunk' in action and action_state and last_scores == scores:
if 'bug_19' not in bug_list:
bug_list.append('bug_19')
# bug_20 Do the Post-up will shift the player position.
if is_defensed(my_pos,my_opp_pos) and 'Postup' in action and 'Postup' in my_last_action and my_last_pos != my_pos:
if 'bug_20' not in bug_list:
bug_list.append('bug_20')
2.Mini_Chinese_Ghost_Story:
File name: gbgallery\Mini_Chinese_Ghost_Story\role.py
In class "Role", users can access the specific implementation of bug oracles.
For example in the following image:
We check bug_5 if the point, out_atk and temp_damege, since these 3 values has a limitation of value scope. if the values are out of limitation, it causes the game to behave abnormally, aka, a bug.
See more examples in the source file.
3.Mini_Justice_Online:
File name: gbgallery\Mini_Justice_Online\env\task.py
In class "Task", users can access the specific implementation of bug oracles.
For example in the following image:
We check bug_9 if the the selected item brings the player a mis-matched skill, this bug can happen because of lack of conditional check.
See more examples in the source file.
4.TowerDefense:
File name: gbgallery\TowerDefense\game\program\server\object_server_1\object\playermap.py
Search for key word "bug", users can access the specific implementation of bug oracles.
For example in the following image:
We check bug_13 if the the tower's new attack value remains the same with original values. This bug happens because of up-stream defects of code. This will cause the update of tower attack value to be failure.
See more examples in the source file.
5.Tank:
File name: gbgallery\Tank\server\game\object_server_1\object\skill.py
Search for key word "bug", users can access the specific implementation of bug oracles.
For example in the following image:
We check bug_14 if the the player tank's position is the very close to the enemy tank, but they are different groups. It means that the tank are in the same grid, they overlaps with each other. This is a bug since this is not permitted in the Tank game. This happens because lack of program to handle this situation.
See more examples in the source file.