diff --git a/english/localizedstrings/reimagined.str b/english/localizedstrings/reimagined.str index 62ad14fd..8d902f34 100644 --- a/english/localizedstrings/reimagined.str +++ b/english/localizedstrings/reimagined.str @@ -1272,6 +1272,9 @@ LANG_ENGLISH "Lightning Staff Required" REFERENCE ZM_TOMB_MISSING_ICE_STAFF LANG_ENGLISH "Ice Staff Required" +REFERENCE ZM_TOMB_RPT +LANG_ENGLISH "You have all perks" + REFERENCE ZOMBIE_BANK_WITHDRAW_PROMPT LANG_ENGLISH "Hold ^3[{+activate}]^7 to withdraw &&1" diff --git a/scripts/zm/replaced/_zm_perk_random.gsc b/scripts/zm/replaced/_zm_perk_random.gsc index a71da8ee..cae6be8e 100644 --- a/scripts/zm/replaced/_zm_perk_random.gsc +++ b/scripts/zm/replaced/_zm_perk_random.gsc @@ -71,4 +71,64 @@ can_buy_perk() return false; return true; +} + +wunderfizzstub_update_prompt(player) +{ + self setcursorhint("HINT_NOICON"); + + if (!self trigger_visible_to_player(player)) + return false; + + self.hint_parm1 = undefined; + + if (isdefined(self.stub.trigger_target.is_locked) && self.stub.trigger_target.is_locked) + { + self.hint_string = &"ZM_TOMB_RPU"; + return false; + } + else if (self.stub.trigger_target.is_current_ball_location) + { + if (isdefined(self.stub.trigger_target.machine_user)) + { + if (isdefined(self.stub.trigger_target.grab_perk_hint) && self.stub.trigger_target.grab_perk_hint) + { + n_purchase_limit = player get_player_perk_purchase_limit(); + + if (player.num_perks >= n_purchase_limit) + { + self.hint_string = &"ZM_TOMB_RPT"; + return false; + } + else + { + self.hint_string = &"ZM_TOMB_RPP"; + return true; + } + } + else + return false; + } + else + { + n_purchase_limit = player get_player_perk_purchase_limit(); + + if (player.num_perks >= n_purchase_limit) + { + self.hint_string = &"ZM_TOMB_RPT"; + return false; + } + else + { + self.hint_string = &"ZM_TOMB_RPB"; + self.hint_parm1 = level._random_zombie_perk_cost; + return true; + } + } + } + else + { + self.hint_string = &"ZM_TOMB_RPE"; + return false; + } } \ No newline at end of file diff --git a/scripts/zm/zm_tomb/zm_tomb_reimagined.gsc b/scripts/zm/zm_tomb/zm_tomb_reimagined.gsc index 2d42955b..1e8dff32 100644 --- a/scripts/zm/zm_tomb/zm_tomb_reimagined.gsc +++ b/scripts/zm/zm_tomb/zm_tomb_reimagined.gsc @@ -52,6 +52,7 @@ main() replaceFunc(maps\mp\zombies\_zm_craftables::update_open_table_status, scripts\zm\replaced\_zm_craftables::update_open_table_status); replaceFunc(maps\mp\zombies\_zm_perk_random::machine_selector, scripts\zm\replaced\_zm_perk_random::machine_selector); replaceFunc(maps\mp\zombies\_zm_perk_random::trigger_visible_to_player, scripts\zm\replaced\_zm_perk_random::trigger_visible_to_player); + replaceFunc(maps\mp\zombies\_zm_perk_random::wunderfizzstub_update_prompt, scripts\zm\replaced\_zm_perk_random::wunderfizzstub_update_prompt); replaceFunc(maps\mp\zombies\_zm_powerup_zombie_blood::zombie_blood_powerup, scripts\zm\replaced\_zm_powerup_zombie_blood::zombie_blood_powerup); replaceFunc(maps\mp\zombies\_zm_riotshield_tomb::doriotshielddeploy, scripts\zm\replaced\_zm_riotshield_tomb::doriotshielddeploy); replaceFunc(maps\mp\zombies\_zm_riotshield_tomb::trackriotshield, scripts\zm\replaced\_zm_riotshield_tomb::trackriotshield);