diff options
author | GriffinR <griffin.g.richards@gmail.com> | 2020-08-21 14:47:55 -0400 |
---|---|---|
committer | GriffinR <griffin.g.richards@gmail.com> | 2020-08-21 14:57:17 -0400 |
commit | fbb70b372743fca1c9323e0011a498e672d4707b (patch) | |
tree | 0296dddcfc6fafa27141ce7fecf47bbf6e6e33d9 /data | |
parent | 469ec5f248ce3f3708940dfaedcb1b1c2d6d3380 (diff) |
Document contest AI scripts
Diffstat (limited to 'data')
-rw-r--r-- | data/contest_ai_scripts.s | 1131 |
1 files changed, 586 insertions, 545 deletions
diff --git a/data/contest_ai_scripts.s b/data/contest_ai_scripts.s index bb8d32f57..e47ccb4c8 100644 --- a/data/contest_ai_scripts.s +++ b/data/contest_ai_scripts.s @@ -13,848 +13,889 @@ enum MON_4 .align 2 -gContestAIChecks:: @ 82DE350 - .4byte AI_CheckForBadMove @ CONTEST_AI_CHECK_BAD_MOVE - .4byte AI_CheckForCombo @ CONTEST_AI_CHECK_COMBO +gContestAI_ScriptsTable:: @ 82DE350 + .4byte AI_CheckBadMove @ CONTEST_AI_CHECK_BAD_MOVE + .4byte AI_CheckCombo @ CONTEST_AI_CHECK_COMBO .4byte AI_CheckBoring @ CONTEST_AI_CHECK_BORING .4byte AI_CheckExcitement @ CONTEST_AI_CHECK_EXCITEMENT .4byte AI_CheckOrder @ CONTEST_AI_CHECK_ORDER - .4byte AI_CheckForGoodMove @ CONTEST_AI_CHECK_GOOD_MOVE + .4byte AI_CheckGoodMove @ CONTEST_AI_CHECK_GOOD_MOVE .4byte AI_Erratic @ CONTEST_AI_ERRATIC - .4byte AI_Nothing // 0x00000080 - .4byte AI_Nothing // 0x00000100 - .4byte AI_Nothing // 0x00000200 - .4byte AI_Nothing // 0x00000400 - .4byte AI_Nothing // 0x00000800 - .4byte AI_Nothing // 0x00001000 - .4byte AI_Nothing // 0x00002000 - .4byte AI_Nothing // 0x00004000 - .4byte AI_Nothing // 0x00008000 - .4byte AI_Nothing // 0x00010000 - .4byte AI_Nothing // 0x00020000 - .4byte AI_Nothing // 0x00040000 - .4byte AI_Nothing // 0x00080000 - .4byte AI_Nothing // 0x00100000 - .4byte AI_Nothing // 0x00200000 - .4byte AI_Nothing // 0x00400000 - .4byte AI_Nothing // 0x00800000 - .4byte AI_Nothing // 0x01000000 - .4byte AI_Nothing // 0x02000000 - .4byte AI_Nothing // 0x04000000 - .4byte AI_Nothing // 0x08000000 - .4byte AI_Nothing // 0x10000000 - .4byte AI_Nothing // 0x20000000 - .4byte AI_Nothing // 0x40000000 - .4byte AI_Nothing // 0x80000000 - - -@ Unreferenced AI routine to encourage moves that improve condition on the first -@ appeal. Additionally, it checks the turn order of the user and the effect -@ type, but the code is buggy and doesn't affect the score. - if_appeal_num_not_eq 0, ContestUnreferenced_80 - if_effect_not_eq CONTEST_EFFECT_IMPROVE_CONDITION_PREVENT_NERVOUSNESS, ContestUnreferenced_80 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_1 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_2 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_3 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_4 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_5 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_6 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_7 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_8 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_9 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_10 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_11 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_12 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_13 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_14 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_15 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_16 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_17 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_18 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_19 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_20 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_21 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_22 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_23 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_24 + .4byte AI_Nothing @ CONTEST_AI_DUMMY_25 + + +@ Unused. Encourages improving condition on the 1st appeal, or startling mons if the users turn is later +AI_CheckTiming: + if_appeal_num_not_eq 0, AI_CheckTiming_SkipCondition + if_effect_not_eq CONTEST_EFFECT_IMPROVE_CONDITION_PREVENT_NERVOUSNESS, AI_CheckTiming_SkipCondition score +10 -ContestUnreferenced_80: - call ContestUnreferenced_0D - end -ContestUnreferenced_0D: - if_user_order_more_than MON_2, ContestUnreferenced_end - if_effect_type_not_eq 2, ContestUnreferenced_end - if_effect_type_not_eq 3, ContestUnreferenced_end - score +10 @ unreachable -ContestUnreferenced_end: - end - -@ Unreferenced AI routine that doesn't make much sense. - if_appeal_num_eq 0, ContestUnreferenced_0F_1 - if_appeal_num_eq 1, ContestUnreferenced_0F_2 - if_appeal_num_eq 2, ContestUnreferenced_0F_3 - if_appeal_num_eq 3, ContestUnreferenced_0F_4 - if_last_appeal ContestUnreferenced_0F_5 - end -ContestUnreferenced_0F_1: - if_user_order_not_eq MON_1, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_2, ContestUnreferenced_2B_2 - if_user_order_not_eq MON_3, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_4, ContestUnreferenced_2B_1 - end -ContestUnreferenced_2B_1: - if_effect_type_eq 1, ContestUnreferenced_score - end -ContestUnreferenced_2B_2: - if_effect_type_eq 1, ContestUnreferenced_score - end - if_effect_type_eq 1, ContestUnreferenced_score - end -ContestUnreferenced_0F_2: - if_user_order_not_eq MON_1, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_2, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_3, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_4, ContestUnreferenced_2B_1 - end -ContestUnreferenced_0F_3: - if_user_order_not_eq MON_1, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_2, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_3, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_4, ContestUnreferenced_2B_1 - end -ContestUnreferenced_0F_4: - if_user_order_not_eq MON_1, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_2, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_3, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_4, ContestUnreferenced_2B_1 - end -ContestUnreferenced_0F_5: - if_user_order_not_eq MON_1, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_2, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_3, ContestUnreferenced_2B_1 - if_user_order_not_eq MON_4, ContestUnreferenced_2B_1 - end -ContestUnreferenced_score: +AI_CheckTiming_SkipCondition: + call AI_CheckTiming_TryStartle + end +AI_CheckTiming_TryStartle: + if_user_order_more_than MON_2, AI_CheckTiming_End + if_effect_type_not_eq CONTEST_EFFECT_TYPE_STARTLE_MON, AI_CheckTiming_End + if_effect_type_not_eq CONTEST_EFFECT_TYPE_STARTLE_MONS, AI_CheckTiming_End + score +10 +AI_CheckTiming_End: + end + +@ Unused, doesnt make much sense +@ Encourages using an avoid being startled move +@ The various appeal and turn checks are pointless, it will always encourage these moves +AI_AvoidStartle: + if_appeal_num_eq 0, AI_AvoidStartle_1stAppeal + if_appeal_num_eq 1, AI_AvoidStartle_2ndAppeal + if_appeal_num_eq 2, AI_AvoidStartle_3rdAppeal + if_appeal_num_eq 3, AI_AvoidStartle_4thAppeal + if_last_appeal AI_AvoidStartle_LastAppeal + end +AI_AvoidStartle_1stAppeal: + if_user_order_not_eq MON_1, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_2, AI_AvoidStartle_EncourageIfAvoidMove2 + if_user_order_not_eq MON_3, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_4, AI_AvoidStartle_EncourageIfAvoidMove + end +AI_AvoidStartle_EncourageIfAvoidMove: + if_effect_type_eq CONTEST_EFFECT_TYPE_AVOID_STARTLE, AI_AvoidStartle_Encourage + end +AI_AvoidStartle_EncourageIfAvoidMove2: + if_effect_type_eq CONTEST_EFFECT_TYPE_AVOID_STARTLE, AI_AvoidStartle_Encourage + end +AI_AvoidStartle_EncourageIfAvoidMove3: + if_effect_type_eq CONTEST_EFFECT_TYPE_AVOID_STARTLE, AI_AvoidStartle_Encourage + end +AI_AvoidStartle_2ndAppeal: + if_user_order_not_eq MON_1, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_2, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_3, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_4, AI_AvoidStartle_EncourageIfAvoidMove + end +AI_AvoidStartle_3rdAppeal: + if_user_order_not_eq MON_1, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_2, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_3, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_4, AI_AvoidStartle_EncourageIfAvoidMove + end +AI_AvoidStartle_4thAppeal: + if_user_order_not_eq MON_1, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_2, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_3, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_4, AI_AvoidStartle_EncourageIfAvoidMove + end +AI_AvoidStartle_LastAppeal: + if_user_order_not_eq MON_1, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_2, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_3, AI_AvoidStartle_EncourageIfAvoidMove + if_user_order_not_eq MON_4, AI_AvoidStartle_EncourageIfAvoidMove + end +AI_AvoidStartle_Encourage: score +10 end - +AI_AvoidStartle_End: end -@ Unreferenced AI routine to encourage the most appealing move. - if_most_appealing_move ContestUnreferenced_score2 +@ Unused +AI_PreferMostAppealingMove: + if_most_appealing_move AI_PreferMostAppealingMove_Encourage end -ContestUnreferenced_score2: +AI_PreferMostAppealingMove_Encourage: score +10 end +@ Discourages using the same move multiple times if it would get boring AI_CheckBoring: if_effect_eq CONTEST_EFFECT_REPETITION_NOT_BORING, AI_CheckBoring_NotBoring - if_move_used_count_eq 1, AI_CheckBoring_FirstRepeat - if_move_used_count_eq 2, AI_CheckBoring_SecondRepeat - if_move_used_count_eq 3, AI_CheckBoring_ThirdRepeat - if_move_used_count_eq 4, AI_CheckBoring_FourthRepeat + if_move_used_count_eq 1, AI_CheckBoring_1stRepeat + if_move_used_count_eq 2, AI_CheckBoring_2ndRepeat + if_move_used_count_eq 3, AI_CheckBoring_3rdRepeat + if_move_used_count_eq 4, AI_CheckBoring_4thRepeat @ No repeats end -AI_CheckBoring_FirstRepeat: +AI_CheckBoring_1stRepeat: score -5 end -AI_CheckBoring_SecondRepeat: +AI_CheckBoring_2ndRepeat: score -15 end -AI_CheckBoring_ThirdRepeat: +AI_CheckBoring_3rdRepeat: score -20 end -AI_CheckBoring_FourthRepeat: +AI_CheckBoring_4thRepeat: score -25 end AI_CheckBoring_NotBoring: end +@ Strongly encourages using an exciting move if user is in a position to receive the max excitement bonus +@ Encourages using exciting moves in general +@ If the user doesnt have a good exciting move to use, then encourage lowering excitement to prevent +@ opponents from benefitting from the excitement AI_CheckExcitement: - if_move_excitement_less_than 0, AI_contest09_081DC2AB - if_move_excitement_eq 0, AI_contest7D_4_081DC2AB - if_move_excitement_eq 1, AI_contest3D_081DC2AB - end -AI_contest09_081DC2AB: - if_excitement_eq 4, AI_contest0F_1_081DC2AB - if_excitement_eq 3, AI_contest0F_2_081DC2AB - if_user_has_exciting_move AI_end_081DC2AB + if_move_excitement_less_than 0, AI_CheckExcitement_Negative + if_move_excitement_eq 0, AI_CheckExcitement_Neutral + if_move_excitement_eq 1, AI_CheckExcitement_Positive + end +AI_CheckExcitement_Negative: + if_excitement_eq 4, AI_CheckExcitement_Negative_1AwayFromMax + if_excitement_eq 3, AI_CheckExcitement_Negative_2AwayFromMax + if_user_has_exciting_move AI_CheckExcitement_End score +15 end -AI_contest0F_1_081DC2AB: - if_user_order_not_eq MON_1, AI_contest7D_1_081DC2AB - if_random_less_than 51, AI_end_081DC2AB +AI_CheckExcitement_Negative_1AwayFromMax: + if_user_order_not_eq MON_1, AI_CheckExcitement_Negative_1AwayFromMax_Not1stUp + if_random_less_than 51, AI_CheckExcitement_End score +20 end -AI_contest7D_1_081DC2AB: - if_random_less_than 127, AI_end_081DC2AB +AI_CheckExcitement_Negative_1AwayFromMax_Not1stUp: + if_random_less_than 127, AI_CheckExcitement_End score -10 end -AI_contest0F_2_081DC2AB: - if_user_order_not_eq MON_1, AI_contest7D_3_081DC2AB - if_last_appeal AI_score_081DC2AB -AI_contest7D_2_081DC2AB: - if_random_less_than 51, AI_end_081DC2AB +AI_CheckExcitement_Negative_2AwayFromMax: + if_user_order_not_eq MON_1, AI_CheckExcitement_Negative_2AwayFromMax_Not1stUp + if_last_appeal AI_CheckExcitement_Negative_2AwayFromMax_LastAppeal + if_random_less_than 51, AI_CheckExcitement_End score +10 end -AI_score_081DC2AB: +AI_CheckExcitement_Negative_2AwayFromMax_LastAppeal: score +15 end -AI_contest7D_3_081DC2AB: - if_random_less_than 127, AI_end_081DC2AB +AI_CheckExcitement_Negative_2AwayFromMax_Not1stUp: + if_random_less_than 127, AI_CheckExcitement_End score +10 end -AI_contest7D_4_081DC2AB: - if_random_less_than 127, AI_end_081DC2AB +AI_CheckExcitement_Neutral: + if_random_less_than 127, AI_CheckExcitement_End score +10 end -AI_contest3D_081DC2AB: - if_move_used_count_more_than 0, AI_contest29_081DC2AB - if_user_order_not_eq MON_1, AI_contest7D_5_081DC2AB - if_excitement_not_eq 4, AI_contest7D_5_081DC2AB +AI_CheckExcitement_Positive: + if_move_used_count_more_than 0, AI_CheckExcitement_Positive_Repeat + if_user_order_not_eq MON_1, AI_CheckExcitement_Positive_Not1stUpForMax + if_excitement_not_eq 4, AI_CheckExcitement_Positive_Not1stUpForMax score +30 end -AI_contest7D_5_081DC2AB: - if_random_less_than 100, AI_end_081DC2AB +AI_CheckExcitement_Positive_Not1stUpForMax: + if_random_less_than 100, AI_CheckExcitement_End score +10 end -AI_contest29_081DC2AB: - if_effect_not_eq CONTEST_EFFECT_REPETITION_NOT_BORING, AI_end_081DC2AB - if_user_order_not_eq MON_1, AI_contest7D_5_081DC2AB - if_excitement_not_eq 4, AI_contest7D_5_081DC2AB +AI_CheckExcitement_Positive_Repeat: + if_effect_not_eq CONTEST_EFFECT_REPETITION_NOT_BORING, AI_CheckExcitement_End + if_user_order_not_eq MON_1, AI_CheckExcitement_Positive_Not1stUpForMax + if_excitement_not_eq 4, AI_CheckExcitement_Positive_Not1stUpForMax score +30 end -AI_end_081DC2AB: +AI_CheckExcitement_End: end -AI_CheckForCombo: - if_would_finish_combo AI_score_081DC348 - call AI_contest3F_081DC348 - call AI_contest45_081DC348 +@ Strongly encourages using a move if it would finish a combo +@ Encourages using a move if it would start a combo, esp if the user goes earlier +@ Discourages starting a combo in the last round +@ Discourages using a combo finisher when its combo starter hasnt been used yet +AI_CheckCombo: + if_would_finish_combo AI_CheckCombo_WouldFinish + call AI_CheckCombo_CheckStarter + call AI_CheckCombo_CheckFinisherWithoutStarter end -AI_contest3F_081DC348: - if_move_used_count_not_eq 0, AI_end_081DC348 - if_not_combo_starter AI_end_081DC348 - if_user_order_eq MON_1, AI_contest04_1_081DC348 - if_user_order_eq MON_2, AI_contest04_2_081DC348 - if_user_order_eq MON_3, AI_contest04_3_081DC348 - if_user_order_eq MON_4, AI_contest04_4_081DC348 +AI_CheckCombo_CheckStarter: + if_move_used_count_not_eq 0, AI_CheckCombo_End + if_not_combo_starter AI_CheckCombo_End + if_user_order_eq MON_1, AI_CheckCombo_Starter1stUp + if_user_order_eq MON_2, AI_CheckCombo_Starter2ndUp + if_user_order_eq MON_3, AI_CheckCombo_Starter3rdUp + if_user_order_eq MON_4, AI_CheckCombo_StarterLast end -AI_contest45_081DC348: - if_not_combo_finisher AI_end_081DC348 +AI_CheckCombo_CheckFinisherWithoutStarter: + if_not_combo_finisher AI_CheckCombo_End score -10 end -AI_score_081DC348: +AI_CheckCombo_WouldFinish: score +25 end -AI_contest04_1_081DC348: - if_last_appeal AI_contest7D_081DC348 - if_random_less_than 150, AI_end_081DC348 +AI_CheckCombo_Starter1stUp: + if_last_appeal AI_CheckCombo_StarterOnLastAppeal + if_random_less_than 150, AI_CheckCombo_End score +10 end -AI_contest04_2_081DC348: - if_last_appeal AI_contest7D_081DC348 - if_random_less_than 125, AI_end_081DC348 +AI_CheckCombo_Starter2ndUp: + if_last_appeal AI_CheckCombo_StarterOnLastAppeal + if_random_less_than 125, AI_CheckCombo_End score +10 end -AI_contest04_3_081DC348: - if_last_appeal AI_contest7D_081DC348 - if_random_less_than 50, AI_end_081DC348 +AI_CheckCombo_Starter3rdUp: + if_last_appeal AI_CheckCombo_StarterOnLastAppeal + if_random_less_than 50, AI_CheckCombo_End score +10 end -AI_contest04_4_081DC348: - if_last_appeal AI_contest7D_081DC348 +AI_CheckCombo_StarterLast: + if_last_appeal AI_CheckCombo_StarterOnLastAppeal score +10 end -AI_contest7D_081DC348: - if_random_less_than 125, AI_end_081DC348 +AI_CheckCombo_StarterOnLastAppeal: + if_random_less_than 125, AI_CheckCombo_End score -15 end -AI_end_081DC348: - end - -AI_CheckForGoodMove: - if_effect_eq CONTEST_EFFECT_BETTER_WITH_GOOD_CONDITION, ContestEffect39 - if_effect_eq CONTEST_EFFECT_NEXT_APPEAL_EARLIER, ContestEffect40 - if_effect_eq CONTEST_EFFECT_NEXT_APPEAL_LATER, ContestEffect41 - if_effect_eq CONTEST_EFFECT_REPETITION_NOT_BORING, ContestEffect3 - if_effect_eq CONTEST_EFFECT_IMPROVE_CONDITION_PREVENT_NERVOUSNESS, ContestEffect38 - if_effect_eq CONTEST_EFFECT_DONT_EXCITE_AUDIENCE, ContestEffect47 - if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, ContestEffect31 - if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONE, ContestEffect32 - if_effect_eq CONTEST_EFFECT_BETTER_WHEN_AUDIENCE_EXCITED, ContestEffect46 - if_effect_eq CONTEST_EFFECT_WORSEN_CONDITION_OF_PREV_MONS, ContestEffect27 - if_effect_eq CONTEST_EFFECT_SHIFT_JUDGE_ATTENTION, ContestEffect16or17 - if_effect_eq CONTEST_EFFECT_STARTLE_MON_WITH_JUDGES_ATTENTION, ContestEffect16or17 - if_effect_eq CONTEST_EFFECT_MAKE_FOLLOWING_MONS_NERVOUS, ContestEffect_FollowingMonsNervous - if_effect_eq CONTEST_EFFECT_JAMS_OTHERS_BUT_MISS_ONE_TURN, ContestEffect18 - end - -ContestEffect39: - if_user_condition_eq 3, ContestEffect39_score1 - if_user_condition_eq 2, ContestEffect39_score2 - if_user_condition_eq 1, ContestEffect39_score3 - if_user_condition_eq 0, ContestEffect39_score4 - end -ContestEffect39_score1: +AI_CheckCombo_End: + end + +@ Checks if move should be encouraged based on its effect +AI_CheckGoodMove: + if_effect_eq CONTEST_EFFECT_BETTER_WITH_GOOD_CONDITION, AI_CGM_BetterWithGoodCondition + if_effect_eq CONTEST_EFFECT_NEXT_APPEAL_EARLIER, AI_CGM_NextAppealEarlier + if_effect_eq CONTEST_EFFECT_NEXT_APPEAL_LATER, AI_CGM_NextAppealLater + if_effect_eq CONTEST_EFFECT_REPETITION_NOT_BORING, AI_CGM_RepetitionNotBoring + if_effect_eq CONTEST_EFFECT_IMPROVE_CONDITION_PREVENT_NERVOUSNESS, AI_CGM_ImproveCondition + if_effect_eq CONTEST_EFFECT_DONT_EXCITE_AUDIENCE, AI_CGM_DontExciteAudience + if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, AI_CGM_AppealAsGoodAsPrevOnes + if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONE, AI_CGM_AppealAsGoodAsPrevOne + if_effect_eq CONTEST_EFFECT_BETTER_WHEN_AUDIENCE_EXCITED, AI_CGM_BetterWhenAudienceExcited + if_effect_eq CONTEST_EFFECT_WORSEN_CONDITION_OF_PREV_MONS, AI_CGM_WorsenConditionOfPrevMons + if_effect_eq CONTEST_EFFECT_SHIFT_JUDGE_ATTENTION, AI_CGM_TargetMonWithJudgesAttention + if_effect_eq CONTEST_EFFECT_STARTLE_MON_WITH_JUDGES_ATTENTION, AI_CGM_TargetMonWithJudgesAttention + if_effect_eq CONTEST_EFFECT_MAKE_FOLLOWING_MONS_NERVOUS, AI_CGM_MakeFollowingMonsNervous + if_effect_eq CONTEST_EFFECT_JAMS_OTHERS_BUT_MISS_ONE_TURN, AI_CGM_JamsOthersButMissOneTurn + end + +AI_CGM_BetterWithGoodCondition: + if_user_condition_eq 3, AI_CGM_BetterWithGoodCondition_3 + if_user_condition_eq 2, AI_CGM_BetterWithGoodCondition_2 + if_user_condition_eq 1, AI_CGM_BetterWithGoodCondition_1 + if_user_condition_eq 0, AI_CGM_BetterWithGoodCondition_0 + end +AI_CGM_BetterWithGoodCondition_3: score +20 end -ContestEffect39_score2: - if_random_less_than 125, ContestEffectEnd +AI_CGM_BetterWithGoodCondition_2: + if_random_less_than 125, AI_CGM_End score +15 end -ContestEffect39_score3: - if_random_less_than 125, ContestEffectEnd +AI_CGM_BetterWithGoodCondition_1: + if_random_less_than 125, AI_CGM_End score +5 end -ContestEffect39_score4: +AI_CGM_BetterWithGoodCondition_0: score -20 end -ContestEffect40: - if_effect_in_user_moveset CONTEST_EFFECT_BETTER_IF_FIRST, ContestEffectEnd - if_random_less_than 50, ContestEffectEnd +AI_CGM_NextAppealEarlier: + if_user_doesnt_have_move CONTEST_EFFECT_BETTER_IF_FIRST, AI_CGM_End + if_random_less_than 50, AI_CGM_End score +20 end -ContestEffect41: - if_effect_in_user_moveset CONTEST_EFFECT_BETTER_IF_LAST, ContestEffectEnd - if_random_less_than 50, ContestEffectEnd +AI_CGM_NextAppealLater: + if_user_doesnt_have_move CONTEST_EFFECT_BETTER_IF_LAST, AI_CGM_End + if_random_less_than 50, AI_CGM_End score +20 end -ContestEffect3: - if_user_order_not_eq MON_4, ContestEffectEnd - if_random_less_than 50, ContestEffectEnd +AI_CGM_RepetitionNotBoring: + if_user_order_not_eq MON_4, AI_CGM_End + if_random_less_than 50, AI_CGM_End score +15 end - if_last_appeal ContestEffect3_7D - if_random_less_than 220, ContestEffect3_score + +AI_CGM_Unused: + if_last_appeal AI_CGM_Unused_LastAppeal + if_random_less_than 220, AI_CGM_Unused_Discourage score +10 end -ContestEffect3_7D: - if_random_less_than 20, ContestEffectEnd +AI_CGM_Unused_LastAppeal: + if_random_less_than 20, AI_CGM_End score +15 end -ContestEffect3_score: +AI_CGM_Unused_Discourage: score -20 end -ContestEffect38: - if_effect_in_user_moveset CONTEST_EFFECT_BETTER_WITH_GOOD_CONDITION, ContestEffect38_contest04 - if_user_condition_eq 3, ContestEffect38_score1 - if_random_less_than 50, ContestEffectEnd +@ Enourages improving condition, esp if user has moves better with good condition or on 1st appeal +@ Discourages improving condition if at max condition, or if last appeal +AI_CGM_ImproveCondition: + if_user_doesnt_have_move CONTEST_EFFECT_BETTER_WITH_GOOD_CONDITION, AI_CGM_ImproveCondition_CheckAppealNum + if_user_condition_eq 3, AI_CGM_ImproveCondition_AtMax + if_random_less_than 50, AI_CGM_End score +15 end -ContestEffect38_score1: +AI_CGM_ImproveCondition_AtMax: score -10 end -ContestEffect38_contest04: - if_last_appeal ContestEffect38_score2 - if_appeal_num_eq 0, ContestEffect38_random - if_move_used_count_eq 1, ContestEffectEnd - if_random_less_than 125, ContestEffectEnd +AI_CGM_ImproveCondition_CheckAppealNum: + if_last_appeal AI_CGM_ImproveCondition_LastAppeal + if_appeal_num_eq 0, AI_CGM_ImproveCondition_FirstAppeal + if_move_used_count_eq 1, AI_CGM_End + if_random_less_than 125, AI_CGM_End score +10 end -ContestEffect38_random: - if_random_less_than 100, ContestEffectEnd +AI_CGM_ImproveCondition_FirstAppeal: + if_random_less_than 100, AI_CGM_End score +10 end -ContestEffect38_score2: +AI_CGM_ImproveCondition_LastAppeal: score -10 end -ContestEffect47: - if_move_used_count_eq 1, ContestEffectEnd - if_user_order_eq MON_1, ContestEffect47_random - if_user_order_eq MON_2, ContestEffect47_random - if_not_last_appeal ContestEffectEnd - if_user_has_exciting_move ContestEffectEnd - if_excitement_less_than 1, ContestEffectEnd +@ Encourage stopping audience excitement early in the appeal, or last appeal if no better options +AI_CGM_DontExciteAudience: + if_move_used_count_eq 1, AI_CGM_End + if_user_order_eq MON_1, AI_CGM_DontExciteAudience_EarlyTurn + if_user_order_eq MON_2, AI_CGM_DontExciteAudience_EarlyTurn + if_not_last_appeal AI_CGM_End + if_user_has_exciting_move AI_CGM_End + if_excitement_less_than 1, AI_CGM_End score +10 end -ContestEffect47_random: - if_random_less_than 127, ContestEffectEnd +AI_CGM_DontExciteAudience_EarlyTurn: + if_random_less_than 127, AI_CGM_End score +10 end -ContestEffect31: - if_user_order_eq MON_2, ContestEffect31_score1 - if_user_order_eq MON_3, ContestEffect31_score2 - if_user_order_eq MON_4, ContestEffect31_score3 +@ Encourages move the later the user goes +AI_CGM_AppealAsGoodAsPrevOnes: + if_user_order_eq MON_2, AI_CGM_AppealAsGoodAsPrevOnes_2ndUp + if_user_order_eq MON_3, AI_CGM_AppealAsGoodAsPrevOnes_3rdUp + if_user_order_eq MON_4, AI_CGM_AppealAsGoodAsPrevOnes_Last end -ContestEffect31_score1: +AI_CGM_AppealAsGoodAsPrevOnes_2ndUp: score +5 end -ContestEffect31_score2: +AI_CGM_AppealAsGoodAsPrevOnes_3rdUp: score +15 end -ContestEffect31_score3: +AI_CGM_AppealAsGoodAsPrevOnes_Last: score +20 end -ContestEffect32: - if_user_order_eq MON_1, ContestEffect32_score1 - if_user_order_eq MON_2, ContestEffect32_score2 - if_user_order_eq MON_3, ContestEffect32_score3 - if_user_order_eq MON_4, ContestEffect32_score5 +@ Encourages move more for each opponent who will have a turn before the user +AI_CGM_AppealAsGoodAsPrevOne: + if_user_order_eq MON_1, AI_CGM_AppealAsGoodAsPrevOne_1stUp + if_user_order_eq MON_2, AI_CGM_AppealAsGoodAsPrevOne_2ndUp + if_user_order_eq MON_3, AI_CGM_AppealAsGoodAsPrevOne_3rdUp + if_user_order_eq MON_4, AI_CGM_AppealAsGoodAsPrevOne_Last end -ContestEffect32_score1: +AI_CGM_AppealAsGoodAsPrevOne_1stUp: score -10 end -ContestEffect32_score2: - if_cannot_participate MON_1, ContestEffectEnd +AI_CGM_AppealAsGoodAsPrevOne_2ndUp: + if_cannot_participate MON_1, AI_CGM_End score +5 end -ContestEffect32_score3: - if_cannot_participate MON_1, ContestEffect32_score4 +AI_CGM_AppealAsGoodAsPrevOne_3rdUp: + if_cannot_participate MON_1, AI_CGM_AppealAsGoodAsPrevOne_3rdUp_CheckMon2 score +5 - goto ContestEffect32_score4 + goto AI_CGM_AppealAsGoodAsPrevOne_3rdUp_CheckMon2 end -ContestEffect32_score4: - if_cannot_participate MON_2, ContestEffectEnd +AI_CGM_AppealAsGoodAsPrevOne_3rdUp_CheckMon2: + if_cannot_participate MON_2, AI_CGM_End score +5 end -ContestEffect32_score5: - if_cannot_participate MON_1, ContestEffect32_score6 +AI_CGM_AppealAsGoodAsPrevOne_Last: + if_cannot_participate MON_1, AI_CGM_AppealAsGoodAsPrevOne_Last_CheckMon2 score +5 - goto ContestEffect32_score6 + goto AI_CGM_AppealAsGoodAsPrevOne_Last_CheckMon2 end -ContestEffect32_score6: - if_cannot_participate MON_2, ContestEffect32_score7 +AI_CGM_AppealAsGoodAsPrevOne_Last_CheckMon2: + if_cannot_participate MON_2, AI_CGM_AppealAsGoodAsPrevOne_Last_CheckMon3 score +5 - goto ContestEffect32_score7 + goto AI_CGM_AppealAsGoodAsPrevOne_Last_CheckMon3 end -ContestEffect32_score7: - if_cannot_participate MON_3, ContestEffectEnd +AI_CGM_AppealAsGoodAsPrevOne_Last_CheckMon3: + if_cannot_participate MON_3, AI_CGM_End score +5 end -ContestEffect46: - if_user_order_eq MON_1, ContestEffect46_05 - if_user_order_more_than MON_1, ContestEffect46_score4 +@ Encourage move if audience is close to full exictement and user goes first +@ See bug note, only does this on 1st appeal (when it will never happen) +AI_CGM_BetterWhenAudienceExcited: + if_user_order_eq MON_1, AI_CGM_BetterWhenAudienceExcited_1stUp + if_user_order_more_than MON_1, AI_CGM_BetterWhenAudienceExcited_Not1stUp end -ContestEffect46_05: - if_appeal_num_not_eq 0, ContestEffect46_score1 - if_excitement_eq 4, ContestEffect46_score2 - if_excitement_eq 3, ContestEffect46_score3 +AI_CGM_BetterWhenAudienceExcited_1stUp: + @ BUG: Should be if_appeal_num_eq 0 + @ 1st up on 1st appeal excitement will always be 0 + if_appeal_num_not_eq 0, AI_CGM_BetterWhenAudienceExcited_Not1stAppeal + if_excitement_eq 4, AI_CGM_BetterWhenAudienceExcited_1AwayFromMax + if_excitement_eq 3, AI_CGM_BetterWhenAudienceExcited_2AwayFromMax end -ContestEffect46_score1: - if_random_less_than 125, ContestEffectEnd +AI_CGM_BetterWhenAudienceExcited_Not1stAppeal: + if_random_less_than 125, AI_CGM_End score -15 end -ContestEffect46_score2: - if_random_less_than 125, ContestEffectEnd +AI_CGM_BetterWhenAudienceExcited_1AwayFromMax: + if_random_less_than 125, AI_CGM_End score +20 end -ContestEffect46_score3: - if_random_less_than 125, ContestEffectEnd +AI_CGM_BetterWhenAudienceExcited_2AwayFromMax: + if_random_less_than 125, AI_CGM_End score +15 end -ContestEffect46_score4: - if_random_less_than 178, ContestEffectEnd +AI_CGM_BetterWhenAudienceExcited_Not1stUp: + if_random_less_than 178, AI_CGM_End score +10 end -ContestEffect27: - if_user_order_eq MON_1, ContestEffectEnd - goto ContestEffect27_55_1 +@ Encourage move more for each condition star the prev mons have +AI_CGM_WorsenConditionOfPrevMons: + if_user_order_eq MON_1, AI_CGM_End + goto AI_CGM_WorsenConditionOfPrevMons_CheckMon1 end -ContestEffect27_55_1: - if_cannot_participate MON_1, ContestEffect27_noscore - if_condition_eq MON_1, 0, ContestEffect27_noscore - if_condition_eq MON_1, 1, ContestEffect27_score1 - if_condition_eq MON_1, 2, ContestEffect27_score2 - if_condition_eq MON_1, 3, ContestEffect27_score3 +AI_CGM_WorsenConditionOfPrevMons_CheckMon1: + if_cannot_participate MON_1, AI_CGM_WorsenConditionOfPrevMons_TryCheckMon2 + if_condition_eq MON_1, 0, AI_CGM_WorsenConditionOfPrevMons_TryCheckMon2 + if_condition_eq MON_1, 1, AI_CGM_WorsenConditionOfPrevMons_Mon1Has1Star + if_condition_eq MON_1, 2, AI_CGM_WorsenConditionOfPrevMons_Mon1Has2Stars + if_condition_eq MON_1, 3, AI_CGM_WorsenConditionOfPrevMons_Mon1Has3Stars end -ContestEffect27_score1: - if_random_less_than 125, ContestEffect27_55_2 +AI_CGM_WorsenConditionOfPrevMons_Mon1Has1Star: + if_random_less_than 125, AI_CGM_WorsenConditionOfPrevMons_CheckMon2 score +5 - if_user_order_more_than MON_2, ContestEffect27_55_2 + if_user_order_more_than MON_2, AI_CGM_WorsenConditionOfPrevMons_CheckMon2 end -ContestEffect27_score2: - if_random_less_than 125, ContestEffect27_55_2 +AI_CGM_WorsenConditionOfPrevMons_Mon1Has2Stars: + if_random_less_than 125, AI_CGM_WorsenConditionOfPrevMons_CheckMon2 score +10 - if_user_order_more_than MON_2, ContestEffect27_55_2 + if_user_order_more_than MON_2, AI_CGM_WorsenConditionOfPrevMons_CheckMon2 end -ContestEffect27_score3: - if_random_less_than 125, ContestEffect27_55_2 +AI_CGM_WorsenConditionOfPrevMons_Mon1Has3Stars: + if_random_less_than 125, AI_CGM_WorsenConditionOfPrevMons_CheckMon2 score +15 - if_user_order_more_than MON_2, ContestEffect27_55_2 + if_user_order_more_than MON_2, AI_CGM_WorsenConditionOfPrevMons_CheckMon2 end -ContestEffect27_noscore: - if_user_order_more_than MON_2, ContestEffect27_55_2 +AI_CGM_WorsenConditionOfPrevMons_TryCheckMon2: + if_user_order_more_than MON_2, AI_CGM_WorsenConditionOfPrevMons_CheckMon2 end -ContestEffect27_55_2: - if_cannot_participate MON_2, ContestEffect27_noscore2 - if_condition_eq MON_2, 0, ContestEffect27_noscore2 - if_condition_eq MON_2, 1, ContestEffect27_score4 - if_condition_eq MON_2, 2, ContestEffect27_score5 - if_condition_eq MON_2, 3, ContestEffect27_score6 +AI_CGM_WorsenConditionOfPrevMons_CheckMon2: + if_cannot_participate MON_2, AI_CGM_WorsenConditionOfPrevMons_TryCheckMon3 + if_condition_eq MON_2, 0, AI_CGM_WorsenConditionOfPrevMons_TryCheckMon3 + if_condition_eq MON_2, 1, AI_CGM_WorsenConditionOfPrevMons_Mon2Has1Star + if_condition_eq MON_2, 2, AI_CGM_WorsenConditionOfPrevMons_Mon2Has2Stars + if_condition_eq MON_2, 3, AI_CGM_WorsenConditionOfPrevMons_Mon2Has3Stars end -ContestEffect27_score4: - if_random_less_than 125, ContestEffect27_55_3 +AI_CGM_WorsenConditionOfPrevMons_Mon2Has1Star: + if_random_less_than 125, AI_CGM_WorsenConditionOfPrevMons_CheckMon3 score +5 - if_user_order_more_than MON_3, ContestEffect27_55_3 + if_user_order_more_than MON_3, AI_CGM_WorsenConditionOfPrevMons_CheckMon3 end -ContestEffect27_score5: - if_random_less_than 125, ContestEffect27_55_3 +AI_CGM_WorsenConditionOfPrevMons_Mon2Has2Stars: + if_random_less_than 125, AI_CGM_WorsenConditionOfPrevMons_CheckMon3 score +10 - if_user_order_more_than MON_3, ContestEffect27_55_3 + if_user_order_more_than MON_3, AI_CGM_WorsenConditionOfPrevMons_CheckMon3 end -ContestEffect27_score6: - if_random_less_than 125, ContestEffect27_55_3 +AI_CGM_WorsenConditionOfPrevMons_Mon2Has3Stars: + if_random_less_than 125, AI_CGM_WorsenConditionOfPrevMons_CheckMon3 score +15 - if_user_order_more_than MON_3, ContestEffect27_55_3 + if_user_order_more_than MON_3, AI_CGM_WorsenConditionOfPrevMons_CheckMon3 end -ContestEffect27_noscore2: - if_user_order_more_than MON_3, ContestEffect27_55_3 +AI_CGM_WorsenConditionOfPrevMons_TryCheckMon3: + if_user_order_more_than MON_3, AI_CGM_WorsenConditionOfPrevMons_CheckMon3 end -ContestEffect27_55_3: - if_cannot_participate MON_3, ContestEffect27_end - if_condition_eq MON_3, 0, ContestEffect27_end - if_condition_eq MON_3, 1, ContestEffect27_score7 - if_condition_eq MON_3, 2, ContestEffect27_score8 - if_condition_eq MON_3, 3, ContestEffect27_score9 +AI_CGM_WorsenConditionOfPrevMons_CheckMon3: + if_cannot_participate MON_3, AI_CGM_WorsenConditionOfPrevMons_end + if_condition_eq MON_3, 0, AI_CGM_WorsenConditionOfPrevMons_end + if_condition_eq MON_3, 1, AI_CGM_WorsenConditionOfPrevMons_Mon3Has1Star + if_condition_eq MON_3, 2, AI_CGM_WorsenConditionOfPrevMons_Mon3Has2Stars + if_condition_eq MON_3, 3, AI_CGM_WorsenConditionOfPrevMons_Mon3Has3Stars end -ContestEffect27_score7: - if_random_less_than 125, ContestEffectEnd +AI_CGM_WorsenConditionOfPrevMons_Mon3Has1Star: + if_random_less_than 125, AI_CGM_End score +5 end -ContestEffect27_score8: - if_random_less_than 125, ContestEffectEnd +AI_CGM_WorsenConditionOfPrevMons_Mon3Has2Stars: + if_random_less_than 125, AI_CGM_End score +10 end -ContestEffect27_score9: - if_random_less_than 125, ContestEffectEnd +AI_CGM_WorsenConditionOfPrevMons_Mon3Has3Stars: + if_random_less_than 125, AI_CGM_End score +15 end -ContestEffect27_end: +AI_CGM_WorsenConditionOfPrevMons_end: end -ContestEffect16or17: - if_user_order_eq MON_1, ContestEffectEnd - goto ContestEffect16or17_55 +@ Encourage if a prev mon has started a combo, esp if they havent completed it yet +@ BUG: Incorrectly uses if_used_combo_starter below, instead of if_not_used_combo_starter +@ As a result it encourages move if a prev mon has not begun a combo +AI_CGM_TargetMonWithJudgesAttention: + if_user_order_eq MON_1, AI_CGM_End + goto AI_CGM_TargetMonWithJudgesAttention_CheckMon1 end -ContestEffect16or17_55: - if_cannot_participate MON_1, ContestEffect16or17_0E_1 - if_used_combo_starter_eq MON_1, TRUE, ContestEffect16or17_0E_1 - if_random_less_than 125, ContestEffect16or17_0E_1 +AI_CGM_TargetMonWithJudgesAttention_CheckMon1: + if_cannot_participate MON_1, AI_CGM_TargetMonWithJudgesAttention_CheckMon2 + if_used_combo_starter MON_1, AI_CGM_TargetMonWithJudgesAttention_CheckMon2 + if_random_less_than 125, AI_CGM_TargetMonWithJudgesAttention_CheckMon2 score +2 - if_not_completed_combo MON_1, ContestEffect16or17_0E_1 + if_not_completed_combo MON_1, AI_CGM_TargetMonWithJudgesAttention_CheckMon2 score +8 end -ContestEffect16or17_0E_1: - if_user_order_eq MON_2, ContestEffectEnd - if_cannot_participate MON_2, ContestEffect16or17_0E_2 - if_used_combo_starter_eq MON_2, TRUE, ContestEffect16or17_0E_2 - if_random_less_than 125, ContestEffect16or17_0E_2 +AI_CGM_TargetMonWithJudgesAttention_CheckMon2: + if_user_order_eq MON_2, AI_CGM_End + if_cannot_participate MON_2, AI_CGM_TargetMonWithJudgesAttention_CheckMon3 + if_used_combo_starter MON_2, AI_CGM_TargetMonWithJudgesAttention_CheckMon3 + if_random_less_than 125, AI_CGM_TargetMonWithJudgesAttention_CheckMon3 score +2 - if_not_completed_combo MON_2, ContestEffect16or17_0E_2 + if_not_completed_combo MON_2, AI_CGM_TargetMonWithJudgesAttention_CheckMon3 score +8 end -ContestEffect16or17_0E_2: - if_user_order_eq MON_3, ContestEffectEnd - if_cannot_participate MON_3, ContestEffectEnd - if_used_combo_starter_eq MON_3, TRUE, ContestEffectEnd - if_random_less_than 125, ContestEffectEnd +AI_CGM_TargetMonWithJudgesAttention_CheckMon3: + if_user_order_eq MON_3, AI_CGM_End + if_cannot_participate MON_3, AI_CGM_End + if_used_combo_starter MON_3, AI_CGM_End + if_random_less_than 125, AI_CGM_End score +2 - if_not_completed_combo MON_3, ContestEffectEnd + if_not_completed_combo MON_3, AI_CGM_End score +8 end -ContestEffect_FollowingMonsNervous: - if_user_order_eq MON_4, ContestEffectEnd - goto ContestEffect_FollowingMonsNervous_CheckMon4 +@ Encourage making mons nervous that have started a combo and can appeal after the user +AI_CGM_MakeFollowingMonsNervous: + if_user_order_eq MON_4, AI_CGM_End + goto AI_CGM_MakeFollowingMonsNervous_CheckMon4 end -ContestEffect_FollowingMonsNervous_CheckMon4: - if_cannot_participate MON_4, ContestEffect_FollowingMonsNervous_CheckMon3 - if_used_combo_starter_eq MON_4, FALSE, ContestEffect_FollowingMonsNervous_CheckMon3 +AI_CGM_MakeFollowingMonsNervous_CheckMon4: + if_cannot_participate MON_4, AI_CGM_MakeFollowingMonsNervous_CheckMon3 + if_not_used_combo_starter MON_4, AI_CGM_MakeFollowingMonsNervous_CheckMon3 score +5 - if_random_less_than 125, ContestEffect16or17_0E_1 + if_random_less_than 125, AI_CGM_TargetMonWithJudgesAttention_CheckMon2 score +5 end -ContestEffect_FollowingMonsNervous_CheckMon3: - if_user_order_eq MON_3, ContestEffectEnd - if_cannot_participate MON_3, ContestEffect_FollowingMonsNervous_CheckMon2 - if_used_combo_starter_eq MON_3, FALSE, ContestEffect_FollowingMonsNervous_CheckMon2 +AI_CGM_MakeFollowingMonsNervous_CheckMon3: + if_user_order_eq MON_3, AI_CGM_End + if_cannot_participate MON_3, AI_CGM_MakeFollowingMonsNervous_CheckMon2 + if_not_used_combo_starter MON_3, AI_CGM_MakeFollowingMonsNervous_CheckMon2 score +5 - if_random_less_than 125, ContestEffect16or17_0E_2 + if_random_less_than 125, AI_CGM_TargetMonWithJudgesAttention_CheckMon3 score +5 end -ContestEffect_FollowingMonsNervous_CheckMon2: - if_user_order_eq MON_2, ContestEffectEnd - if_cannot_participate MON_2, ContestEffectEnd - if_used_combo_starter_eq MON_2, FALSE, ContestEffectEnd +AI_CGM_MakeFollowingMonsNervous_CheckMon2: + if_user_order_eq MON_2, AI_CGM_End + if_cannot_participate MON_2, AI_CGM_End + if_not_used_combo_starter MON_2, AI_CGM_End score +5 - if_random_less_than 125, ContestEffectEnd + if_random_less_than 125, AI_CGM_End score +5 end -ContestEffect18: - if_last_appeal ContestEffect18_score1 - goto ContestEffect18_0E +@ Encourages move if users turn is later, or if its the last appeal +AI_CGM_JamsOthersButMissOneTurn: + if_last_appeal AI_CGM_JamsOthersButMissOneTurn_LastAppeal + goto AI_CGM_JamsOthersButMissOneTurn_TurnOrder end -ContestEffect18_score1: +AI_CGM_JamsOthersButMissOneTurn_LastAppeal: score +5 - goto ContestEffect18_0E + goto AI_CGM_JamsOthersButMissOneTurn_TurnOrder end -ContestEffect18_0E: - if_user_order_eq MON_1, ContestEffect18_score2 - if_user_order_eq MON_2, ContestEffect18_random1 - if_user_order_eq MON_3, ContestEffect18_random2 - if_user_order_eq MON_4, ContestEffect18_random3 +AI_CGM_JamsOthersButMissOneTurn_TurnOrder: + if_user_order_eq MON_1, AI_CGM_JamsOthersButMissOneTurn_1stUp + if_user_order_eq MON_2, AI_CGM_JamsOthersButMissOneTurn_2ndUp + if_user_order_eq MON_3, AI_CGM_JamsOthersButMissOneTurn_3rdUp + if_user_order_eq MON_4, AI_CGM_JamsOthersButMissOneTurn_Last end -ContestEffect18_score2: +AI_CGM_JamsOthersButMissOneTurn_1stUp: score -15 end -ContestEffect18_random1: - if_random_less_than 125, ContestEffectEnd +AI_CGM_JamsOthersButMissOneTurn_2ndUp: + if_random_less_than 125, AI_CGM_End score -10 end -ContestEffect18_random2: - if_random_less_than 125, ContestEffectEnd +AI_CGM_JamsOthersButMissOneTurn_3rdUp: + if_random_less_than 125, AI_CGM_End score +5 end -ContestEffect18_random3: - if_random_less_than 125, ContestEffectEnd +AI_CGM_JamsOthersButMissOneTurn_Last: + if_random_less_than 125, AI_CGM_End score +15 end -ContestEffectEnd: +AI_CGM_End: end @ Randomly encourage moves in Cute, Smart, and Tough contests. AI_Erratic: - if_contest_type_eq CONTEST_CATEGORY_CUTE, Erratic_CuteSmartTough - if_contest_type_eq CONTEST_CATEGORY_SMART, Erratic_CuteSmartTough - if_contest_type_eq CONTEST_CATEGORY_TOUGH, Erratic_CuteSmartTough + if_contest_type_eq CONTEST_CATEGORY_CUTE, AI_Erratic_CuteSmartTough + if_contest_type_eq CONTEST_CATEGORY_SMART, AI_Erratic_CuteSmartTough + if_contest_type_eq CONTEST_CATEGORY_TOUGH, AI_Erratic_CuteSmartTough end -Erratic_CuteSmartTough: - if_random_less_than 125, Erratic_NoScoreIncrease +AI_Erratic_CuteSmartTough: + if_random_less_than 125, AI_Erratic_End score +10 end -Erratic_NoScoreIncrease: - end - -AI_CheckForBadMove: - if_effect_eq CONTEST_EFFECT_STARTLE_FRONT_MON, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MON, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_BADLY_STARTLE_FRONT_MON, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MON_2, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONE, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_BETTER_IF_SAME_TYPE, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_BETTER_IF_DIFF_TYPE, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_AFFECTED_BY_PREV_APPEAL, ContestEffect2_8 - if_effect_eq CONTEST_EFFECT_SLIGHTLY_STARTLE_PREV_MONS, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MONS, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_BADLY_STARTLE_PREV_MONS, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MONS_2, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_MON_WITH_JUDGES_ATTENTION, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_SHIFT_JUDGE_ATTENTION, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_JAMS_OTHERS_BUT_MISS_ONE_TURN, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_MONS_SAME_TYPE_APPEAL, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_BADLY_STARTLE_MONS_WITH_GOOD_APPEALS, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_MONS_COOL_APPEAL, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_MONS_BEAUTY_APPEAL, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_MONS_CUTE_APPEAL, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_MONS_SMART_APPEAL, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_STARTLE_MONS_TOUGH_APPEAL, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_BADLY_STARTLES_MONS_IN_GOOD_CONDITION, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_WORSEN_CONDITION_OF_PREV_MONS, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, ContestEffect2_9 - if_effect_eq CONTEST_EFFECT_MAKE_FOLLOWING_MON_NERVOUS, ContestEffect2_25 - if_effect_eq CONTEST_EFFECT_MAKE_FOLLOWING_MONS_NERVOUS, ContestEffect2_26 - if_effect_eq CONTEST_EFFECT_DONT_EXCITE_AUDIENCE, ContestEffect2_26 - if_effect_eq CONTEST_EFFECT_IMPROVE_CONDITION_PREVENT_NERVOUSNESS, ContestEffect2_38 - if_effect_eq CONTEST_EFFECT_AVOID_STARTLE_ONCE, ContestEffect2_4 - if_effect_eq CONTEST_EFFECT_AVOID_STARTLE, ContestEffect2_4 - if_effect_eq CONTEST_EFFECT_AVOID_STARTLE_SLIGHTLY, ContestEffect2_4 - if_effect_eq CONTEST_EFFECT_GREAT_APPEAL_BUT_NO_MORE_MOVES, ContestEffect2_2 - end - -ContestEffect2_8: - if_user_order_eq MON_1, ContestEffect2_8_score1 - if_user_order_eq MON_2, ContestEffect2_8_score2 - if_user_order_eq MON_3, ContestEffect2_8_score3 - if_user_order_eq MON_4, ContestEffect2_8_score4 - end -ContestEffect2_8_score1: +AI_Erratic_End: + end + +@ Checks if move should be discouraged based on its effect +AI_CheckBadMove: + if_effect_eq CONTEST_EFFECT_STARTLE_FRONT_MON, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MON, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_BADLY_STARTLE_FRONT_MON, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MON_2, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONE, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_BETTER_IF_SAME_TYPE, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_BETTER_IF_DIFF_TYPE, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_AFFECTED_BY_PREV_APPEAL, AI_CBM_DependsOnPrevMon + if_effect_eq CONTEST_EFFECT_SLIGHTLY_STARTLE_PREV_MONS, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MONS, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_BADLY_STARTLE_PREV_MONS, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_PREV_MONS_2, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_MON_WITH_JUDGES_ATTENTION, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_SHIFT_JUDGE_ATTENTION, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_JAMS_OTHERS_BUT_MISS_ONE_TURN, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_MONS_SAME_TYPE_APPEAL, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_BADLY_STARTLE_MONS_WITH_GOOD_APPEALS, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_MONS_COOL_APPEAL, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_MONS_BEAUTY_APPEAL, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_MONS_CUTE_APPEAL, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_MONS_SMART_APPEAL, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_STARTLE_MONS_TOUGH_APPEAL, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_BADLY_STARTLES_MONS_IN_GOOD_CONDITION, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_WORSEN_CONDITION_OF_PREV_MONS, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, AI_CBM_DependsOnPrevMons + if_effect_eq CONTEST_EFFECT_MAKE_FOLLOWING_MON_NERVOUS, AI_CBM_DependsOnNextMon + if_effect_eq CONTEST_EFFECT_MAKE_FOLLOWING_MONS_NERVOUS, AI_CBM_DependsOnNextMons + if_effect_eq CONTEST_EFFECT_DONT_EXCITE_AUDIENCE, AI_CBM_DependsOnNextMons + if_effect_eq CONTEST_EFFECT_IMPROVE_CONDITION_PREVENT_NERVOUSNESS, AI_CBM_ImproveCondition + if_effect_eq CONTEST_EFFECT_AVOID_STARTLE_ONCE, AI_CBM_AvoidStartle + if_effect_eq CONTEST_EFFECT_AVOID_STARTLE, AI_CBM_AvoidStartle + if_effect_eq CONTEST_EFFECT_AVOID_STARTLE_SLIGHTLY, AI_CBM_AvoidStartle + if_effect_eq CONTEST_EFFECT_GREAT_APPEAL_BUT_NO_MORE_MOVES, AI_CBM_NoMoreMoves + end + +@ If previous mon is skipping turn (or user is first), discourage move +AI_CBM_DependsOnPrevMon: + if_user_order_eq MON_1, AI_CBM_DependsOnPrevMon_1stUp + if_user_order_eq MON_2, AI_CBM_DependsOnPrevMon_2ndUp + if_user_order_eq MON_3, AI_CBM_DependsOnPrevMon_3rdUp + if_user_order_eq MON_4, AI_CBM_DependsOnPrevMon_Last + end +AI_CBM_DependsOnPrevMon_1stUp: score -10 end -ContestEffect2_8_score2: - if_can_participate MON_1, ContestEffectEnd2 +AI_CBM_DependsOnPrevMon_2ndUp: + if_can_participate MON_1, AI_CBM_End score -10 end -ContestEffect2_8_score3: - if_can_participate MON_2, ContestEffectEnd2 +AI_CBM_DependsOnPrevMon_3rdUp: + if_can_participate MON_2, AI_CBM_End score -10 end -ContestEffect2_8_score4: - if_can_participate MON_3, ContestEffectEnd2 +AI_CBM_DependsOnPrevMon_Last: + if_can_participate MON_3, AI_CBM_End score -10 end -ContestEffect2_9: - if_user_order_eq MON_1, ContestEffect2_9_score1 - if_user_order_eq MON_2, ContestEffect2_9_score2 - if_user_order_eq MON_3, ContestEffect2_9_score3 - if_user_order_eq MON_4, ContestEffect2_9_score4 +@ If previous mons are all skipping turns (or user is first), discourage move +AI_CBM_DependsOnPrevMons: + if_user_order_eq MON_1, AI_CBM_DependsOnPrevMons_1stUp + if_user_order_eq MON_2, AI_CBM_DependsOnPrevMons_2ndUp + if_user_order_eq MON_3, AI_CBM_DependsOnPrevMons_3rdUp + if_user_order_eq MON_4, AI_CBM_DependsOnPrevMons_Last end -ContestEffect2_9_score1: +AI_CBM_DependsOnPrevMons_1stUp: score -20 end -ContestEffect2_9_score2: - if_can_participate MON_1, ContestEffectEnd2 +AI_CBM_DependsOnPrevMons_2ndUp: + if_can_participate MON_1, AI_CBM_End score -15 end -ContestEffect2_9_score3: - if_can_participate MON_1, ContestEffectEnd2 - if_can_participate MON_2, ContestEffectEnd2 +AI_CBM_DependsOnPrevMons_3rdUp: + if_can_participate MON_1, AI_CBM_End + if_can_participate MON_2, AI_CBM_End score -15 end -ContestEffect2_9_score4: - if_can_participate MON_1, ContestEffectEnd2 - if_can_participate MON_2, ContestEffectEnd2 - if_can_participate MON_3, ContestEffectEnd2 +AI_CBM_DependsOnPrevMons_Last: + if_can_participate MON_1, AI_CBM_End + if_can_participate MON_2, AI_CBM_End + if_can_participate MON_3, AI_CBM_End score -15 end -ContestEffect2_25: - if_user_order_eq MON_1, ContestEffect2_25_score1 - if_user_order_eq MON_2, ContestEffect2_25_score2 - if_user_order_eq MON_3, ContestEffect2_25_score3 +@ If next mon is skipping turn (or user is last), discourage move +AI_CBM_DependsOnNextMon: + if_user_order_eq MON_1, AI_CBM_DependsOnNextMon_1stUp + if_user_order_eq MON_2, AI_CBM_DependsOnNextMon_2ndUp + if_user_order_eq MON_3, AI_CBM_DependsOnNextMon_3rdUp score -10 end -ContestEffect2_25_score1: - if_can_participate MON_2, ContestEffectEnd2 +AI_CBM_DependsOnNextMon_1stUp: + if_can_participate MON_2, AI_CBM_End score -10 end -ContestEffect2_25_score2: - if_can_participate MON_3, ContestEffectEnd2 +AI_CBM_DependsOnNextMon_2ndUp: + if_can_participate MON_3, AI_CBM_End score -10 end -ContestEffect2_25_score3: - if_can_participate MON_4, ContestEffectEnd2 +AI_CBM_DependsOnNextMon_3rdUp: + if_can_participate MON_4, AI_CBM_End score -10 end -ContestEffect2_26: - if_user_order_eq MON_1, ContestEffect2_26_score1 - if_user_order_eq MON_2, ContestEffect2_26_score2 - if_user_order_eq MON_3, ContestEffect2_26_score3 +@ If next mons are all skipping turns (or user is last), discourage move +AI_CBM_DependsOnNextMons: + if_user_order_eq MON_1, AI_CBM_DependsOnNextMons_1stUp + if_user_order_eq MON_2, AI_CBM_DependsOnNextMons_2ndUp + if_user_order_eq MON_3, AI_CBM_DependsOnNextMons_3rdUp score -10 end -ContestEffect2_26_score1: - if_can_participate MON_2, ContestEffectEnd2 - if_can_participate MON_3, ContestEffectEnd2 - if_can_participate MON_4, ContestEffectEnd2 +AI_CBM_DependsOnNextMons_1stUp: + if_can_participate MON_2, AI_CBM_End + if_can_participate MON_3, AI_CBM_End + if_can_participate MON_4, AI_CBM_End score -10 end -ContestEffect2_26_score2: - if_can_participate MON_3, ContestEffectEnd2 - if_can_participate MON_4, ContestEffectEnd2 +AI_CBM_DependsOnNextMons_2ndUp: + if_can_participate MON_3, AI_CBM_End + if_can_participate MON_4, AI_CBM_End score -10 end -ContestEffect2_26_score3: - if_can_participate MON_4, ContestEffectEnd2 +AI_CBM_DependsOnNextMons_3rdUp: + if_can_participate MON_4, AI_CBM_End score -10 end -ContestEffect2_38: - if_user_condition_less_than 3, ContestEffectEnd2 +@ If at max condition, discourage move +AI_CBM_ImproveCondition: + if_user_condition_less_than 3, AI_CBM_End score -20 end -ContestEffect2_4: - if_user_order_eq MON_1, ContestEffect2_4_score1 - if_user_order_eq MON_2, ContestEffect2_4_score2 - if_user_order_eq MON_3, ContestEffect2_4_score3 +@ If there are no upcoming mons who can make an appeal (or if user is last), discourage move +@ Identical to AI_CBM_DependsOnNextMons +AI_CBM_AvoidStartle: + if_user_order_eq MON_1, AI_CBM_AvoidStartle_1stUp + if_user_order_eq MON_2, AI_CBM_AvoidStartle_2ndUp + if_user_order_eq MON_3, AI_CBM_AvoidStartle_3rdUp score -10 end -ContestEffect2_4_score1: - if_can_participate MON_2, ContestEffectEnd2 - if_can_participate MON_3, ContestEffectEnd2 - if_can_participate MON_4, ContestEffectEnd2 +AI_CBM_AvoidStartle_1stUp: + if_can_participate MON_2, AI_CBM_End + if_can_participate MON_3, AI_CBM_End + if_can_participate MON_4, AI_CBM_End score -10 end -ContestEffect2_4_score2: - if_can_participate MON_3, ContestEffectEnd2 - if_can_participate MON_4, ContestEffectEnd2 +AI_CBM_AvoidStartle_2ndUp: + if_can_participate MON_3, AI_CBM_End + if_can_participate MON_4, AI_CBM_End score -10 end -ContestEffect2_4_score3: - if_can_participate MON_4, ContestEffectEnd2 +AI_CBM_AvoidStartle_3rdUp: + if_can_participate MON_4, AI_CBM_End score -10 end -ContestEffect2_2: - if_appeal_num_eq 0, ContestEffect2_2_score1 - if_appeal_num_eq 1, ContestEffect2_2_score2 - if_appeal_num_eq 2, ContestEffect2_2_score3 - if_appeal_num_eq 3, ContestEffect2_2_score4 - if_last_appeal ContestEffect2_2_score5 +@ Very good if its the last appeal, otherwise discourage move +AI_CBM_NoMoreMoves: + if_appeal_num_eq 0, AI_CBM_NoMoreMoves_1stAppeal + if_appeal_num_eq 1, AI_CBM_NoMoreMoves_2ndAppeal + if_appeal_num_eq 2, AI_CBM_NoMoreMoves_3rdAppeal + if_appeal_num_eq 3, AI_CBM_NoMoreMoves_4thAppeal + if_last_appeal AI_CBM_NoMoreMoves_LastAppeal end -ContestEffect2_2_score1: - if_random_less_than 20, ContestEffectEnd2 +AI_CBM_NoMoreMoves_1stAppeal: + if_random_less_than 20, AI_CBM_End score -15 end -ContestEffect2_2_score2: - if_random_less_than 40, ContestEffectEnd2 +AI_CBM_NoMoreMoves_2ndAppeal: + if_random_less_than 40, AI_CBM_End score -15 end -ContestEffect2_2_score3: - if_random_less_than 60, ContestEffectEnd2 +AI_CBM_NoMoreMoves_3rdAppeal: + if_random_less_than 60, AI_CBM_End score -15 end -ContestEffect2_2_score4: - if_random_less_than 80, ContestEffectEnd2 +AI_CBM_NoMoreMoves_4thAppeal: + if_random_less_than 80, AI_CBM_End score -15 end -ContestEffect2_2_score5: - if_random_less_than 20, ContestEffectEnd2 +AI_CBM_NoMoreMoves_LastAppeal: + if_random_less_than 20, AI_CBM_End score +20 end -ContestEffectEnd2: +AI_CBM_End: end +@ Encourages/discourages move affected by the move order +@ e.g. use BETTER_IF_FIRST moves if user is first, dont use AVOID_STARTLE moves if last AI_CheckOrder: - if_user_order_eq MON_1, AI_effectcheck1_081DCA4C - if_user_order_eq MON_2, AI_effectcheck2_081DCA4C - if_user_order_eq MON_3, AI_effectcheck3_081DCA4C - if_user_order_eq MON_4, AI_effectcheck4_081DCA4C + if_user_order_eq MON_1, AI_CheckOrder_1stUp + if_user_order_eq MON_2, AI_CheckOrder_2ndUp + if_user_order_eq MON_3, AI_CheckOrder_3rdUp + if_user_order_eq MON_4, AI_CheckOrder_Last end -AI_effectcheck1_081DCA4C: - if_effect_eq CONTEST_EFFECT_BETTER_IF_FIRST, AI_score1_081DCA4C - if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_score2_081DCA4C - if_effect_type_eq 1, AI_random1_081DCA4C +AI_CheckOrder_1stUp: + if_effect_eq CONTEST_EFFECT_BETTER_IF_FIRST, AI_CheckOrder_1stUp_Encourage + if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_CheckOrder_1stUp_Discourage + if_effect_type_eq CONTEST_EFFECT_TYPE_AVOID_STARTLE, AI_CheckOrder_1stUp_RandomEncourage end -AI_score1_081DCA4C: +AI_CheckOrder_1stUp_Encourage: score +15 end -AI_score2_081DCA4C: +AI_CheckOrder_1stUp_Discourage: score -15 end -AI_random1_081DCA4C: - if_random_less_than 100, ContestEffectEnd2 +AI_CheckOrder_1stUp_RandomEncourage: + if_random_less_than 100, AI_CBM_End score +10 end -AI_effectcheck2_081DCA4C: - if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_score3_081DCA4C - if_effect_type_eq 1, AI_random2_081DCA4C +AI_CheckOrder_2ndUp: + if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_CheckOrder_2ndUp_Discourage + if_effect_type_eq CONTEST_EFFECT_TYPE_AVOID_STARTLE, AI_CheckOrder_2ndUp_RandomEncourage end -AI_score3_081DCA4C: +AI_CheckOrder_2ndUp_Discourage: score -5 end -AI_random2_081DCA4C: - if_random_less_than 125, ContestEffectEnd2 +AI_CheckOrder_2ndUp_RandomEncourage: + if_random_less_than 125, AI_CBM_End score +10 end -AI_effectcheck3_081DCA4C: - if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_score4_081DCA4C - if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, AI_score4_081DCA4C - if_effect_eq CONTEST_EFFECT_USER_MORE_EASILY_STARTLED, AI_score4_081DCA4C +AI_CheckOrder_3rdUp: + if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_CheckOrder_3rdUp_Encourage + if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, AI_CheckOrder_3rdUp_Encourage + if_effect_eq CONTEST_EFFECT_USER_MORE_EASILY_STARTLED, AI_CheckOrder_3rdUp_Encourage end -AI_score4_081DCA4C: +AI_CheckOrder_3rdUp_Encourage: score +5 end -AI_effectcheck4_081DCA4C: - if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_score5_081DCA4C - if_effect_eq CONTEST_EFFECT_BETTER_IF_LAST, AI_score5_081DCA4C - if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, AI_score5_081DCA4C - if_effect_eq CONTEST_EFFECT_USER_MORE_EASILY_STARTLED, AI_score5_081DCA4C - if_effect_eq CONTEST_EFFECT_JAMS_OTHERS_BUT_MISS_ONE_TURN, AI_score7_081DCA4C - if_effect_type_eq 1, AI_score6_081DCA4C - if_effect_type_eq 3, AI_random3_081DCA4C +AI_CheckOrder_Last: + if_effect_eq CONTEST_EFFECT_BETTER_WHEN_LATER, AI_CheckOrder_Last_StronglyEncourage + if_effect_eq CONTEST_EFFECT_BETTER_IF_LAST, AI_CheckOrder_Last_StronglyEncourage + if_effect_eq CONTEST_EFFECT_APPEAL_AS_GOOD_AS_PREV_ONES, AI_CheckOrder_Last_StronglyEncourage + if_effect_eq CONTEST_EFFECT_USER_MORE_EASILY_STARTLED, AI_CheckOrder_Last_StronglyEncourage + if_effect_eq CONTEST_EFFECT_JAMS_OTHERS_BUT_MISS_ONE_TURN, AI_CheckOrder_Last_Encourage + if_effect_type_eq CONTEST_EFFECT_TYPE_AVOID_STARTLE, AI_CheckOrder_Last_Discourage + if_effect_type_eq CONTEST_EFFECT_TYPE_STARTLE_MONS, AI_CheckOrder_Last_RandomEncourage end -AI_score5_081DCA4C: +AI_CheckOrder_Last_StronglyEncourage: score +15 end -AI_score6_081DCA4C: +AI_CheckOrder_Last_Discourage: score -10 end -AI_random3_081DCA4C: - if_random_less_than 125, ContestEffectEnd2 +AI_CheckOrder_Last_RandomEncourage: + if_random_less_than 125, AI_CBM_End score +10 end -AI_score7_081DCA4C: +AI_CheckOrder_Last_Encourage: score +5 end |