diff --git a/src/data/microtf2/Minigames.txt b/src/data/microtf2/Minigames.txt index b4df2a05..50748575 100644 --- a/src/data/microtf2/Minigames.txt +++ b/src/data/microtf2/Minigames.txt @@ -196,7 +196,7 @@ "enabled" "1" "BackgroundMusic" "gemidyne/warioware/{version}/minigames/bgm/23.mp3" "EntryPoint" "Minigame23_EntryPoint" - "BackgroundMusic_Length" "4.101188" + "BackgroundMusic_Length" "6.0" } "24" { diff --git a/src/scripting/Minigames/Minigame23.sp b/src/scripting/Minigames/Minigame23.sp index dd53d6b6..ad5e6623 100644 --- a/src/scripting/Minigames/Minigame23.sp +++ b/src/scripting/Minigames/Minigame23.sp @@ -6,11 +6,23 @@ public void Minigame23_EntryPoint() { + g_pfOnMinigameSelectedPre.AddFunction(INVALID_HANDLE, Minigame23_OnMinigameSelectedPre); g_pfOnMinigameSelected.AddFunction(INVALID_HANDLE, Minigame23_OnMinigameSelected); g_pfOnPlayerDeath.AddFunction(INVALID_HANDLE, Minigame23_OnPlayerDeath); g_pfOnPlayerTakeDamage.AddFunction(INVALID_HANDLE, Minigame23_OnPlayerTakeDamage); } +public void Minigame23_OnMinigameSelectedPre() +{ + if (g_iActiveMinigameId != 23) + { + return; + } + + g_bIsBlockingTaunts = false; + g_bIsBlockingKillCommands = false; +} + public void Minigame23_OnMinigameSelected(int client) { if (g_iActiveMinigameId != 23) @@ -30,6 +42,7 @@ public void Minigame23_OnMinigameSelected(int client) player.Class = TFClass_Soldier; player.RemoveAllWeapons(); player.GiveWeapon(775); + player.SetGodMode(false); } } @@ -55,7 +68,7 @@ public void Minigame23_OnPlayerDeath(int victimId, int attackerId) } } -public DamageBlockResults Minigame23_OnPlayerTakeDamage(int victimId, int attackerId, float damage, int damageType) +public DamageBlockResults Minigame23_OnPlayerTakeDamage(int victimId, int attackerId, float damage, int damageCustom) { if (g_bIsMinigameActive && g_iActiveMinigameId == 23) { @@ -65,9 +78,14 @@ public DamageBlockResults Minigame23_OnPlayerTakeDamage(int victimId, int attack bool victimValid = victim.IsValid && victim.IsParticipating; bool attackerValid = attacker.IsValid && attacker.IsParticipating; - if (attackerValid && victimValid && victim.ClientId != attacker.ClientId && damageType == TF_CUSTOM_TAUNT_GRENADE) + PrintToChatAll("Minigame23_OnPlayerTakeDamage: damageCustom is %i (looking for %i)", damageCustom, TF_CUSTOM_TAUNT_GRENADE); + + if (attackerValid && victimValid && victim.ClientId != attacker.ClientId && damageCustom == TF_CUSTOM_TAUNT_GRENADE) { attacker.TriggerSuccess(); + + PrintToChatAll("Minigame23_OnPlayerTakeDamage: attacker success (%i)", attacker.ClientId); + return EDamageBlockResult_AllowDamage; } } diff --git a/src/translations/de/microtf2.phrases.txt b/src/translations/de/microtf2.phrases.txt index 7e169865..933f9701 100644 --- a/src/translations/de/microtf2.phrases.txt +++ b/src/translations/de/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "de" "DOPPEL SPRUNG!" + "de" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/es/microtf2.phrases.txt b/src/translations/es/microtf2.phrases.txt index dc08c661..7a4fc7be 100644 --- a/src/translations/es/microtf2.phrases.txt +++ b/src/translations/es/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "es" "¡SALTO DOBLE!" + "es" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/fr/microtf2.phrases.txt b/src/translations/fr/microtf2.phrases.txt index 79d3b339..30b89005 100644 --- a/src/translations/fr/microtf2.phrases.txt +++ b/src/translations/fr/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "fr" "DOUBLE SAUT !" + "fr" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/it/microtf2.phrases.txt b/src/translations/it/microtf2.phrases.txt index 5085fc1e..ebd0d965 100644 --- a/src/translations/it/microtf2.phrases.txt +++ b/src/translations/it/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "it" "DOPPIO SALTO!" + "it" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/microtf2.phrases.txt b/src/translations/microtf2.phrases.txt index 0d8902f0..6ab51f4a 100644 --- a/src/translations/microtf2.phrases.txt +++ b/src/translations/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "en" "DOUBLE JUMP!" + "en" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/pl/microtf2.phrases.txt b/src/translations/pl/microtf2.phrases.txt index 5061e676..ad2fe748 100644 --- a/src/translations/pl/microtf2.phrases.txt +++ b/src/translations/pl/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "pl" "WYKONAJ PODWÓJNY SKOK!" + "pl" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/pt/microtf2.phrases.txt b/src/translations/pt/microtf2.phrases.txt index 5e4909b0..b013d711 100644 --- a/src/translations/pt/microtf2.phrases.txt +++ b/src/translations/pt/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "pt" "SALTO DUPLO!" + "pt" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/pt_p/microtf2.phrases.txt b/src/translations/pt_p/microtf2.phrases.txt index 62655c43..22141239 100644 --- a/src/translations/pt_p/microtf2.phrases.txt +++ b/src/translations/pt_p/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "pt_p" "SALTO DUPLO!" + "pt_p" "TAUNT KILL!" } "Minigame24_Caption" { diff --git a/src/translations/ru/microtf2.phrases.txt b/src/translations/ru/microtf2.phrases.txt index 978f51cd..cce4258a 100644 --- a/src/translations/ru/microtf2.phrases.txt +++ b/src/translations/ru/microtf2.phrases.txt @@ -453,7 +453,7 @@ } "Minigame23_Caption" { - "ru" "ДВОЙНОЙ ПРЫЖОК!" + "ru" "TAUNT KILL!" } "Minigame24_Caption" {