QoE Update — 2
## Added - **`Spectator` use cooldown** (`UseCooldown` in skillsInfo.json, default 0.5s) — every press destroyed and recreated the camera prop, with no rate limit. - **`SkillUtils.ClearCursesFor(playerIndex)`** — clears a leaving player's curse bookkeeping from both sides (as curser and as victim). - **`SkillUtils.AnyCurseCapacity(player)`** — reports whether a player still has any enemy left that is under the curse limit. - **`Spectator.PlayerDisconnect`** handler. - **`Thief`** added to the curse skill set. ## Changed - **`CurseSkillPerPlayer` is ignored in GameMode 1 (TeamSkills), 2 (SameSkills) and 5 (Debug).** - **Curse target menus no longer go empty.** When every living enemy is already at the limit, the menu falls back to the unfiltered list and the claim is forced through. - `C4Camouflage` `MaxPerServer` -1 -> 1
This commit is contained in:
parent
b0b50a224f
commit
7292ab1787
9 changed files with 101 additions and 35 deletions
|
|
@ -104,6 +104,9 @@ namespace src
|
|||
|
||||
if (SkillUtils.TryClaimCurse(curser.Index, victimIndex)) return true;
|
||||
|
||||
if (!SkillUtils.AnyCurseCapacity(curser))
|
||||
return SkillUtils.TryClaimCurse(curser.Index, victimIndex, true);
|
||||
|
||||
var curserEvent = PlayerManager.GetPlayerFromEvent(curser);
|
||||
curserEvent?.PrintToChat($" {ChatColors.Red}{curserEvent.GetTranslation("curse_limit_info", victim.PlayerName)}");
|
||||
return false;
|
||||
|
|
@ -122,7 +125,7 @@ namespace src
|
|||
SkillsUsedThisMap.TryAdd(skill, 0);
|
||||
}
|
||||
|
||||
if (Enum.TryParse<Skills>(skill, out var parsedSkill) && SkillUtils.IsCurseSkill(parsedSkill))
|
||||
if (SkillUtils.CurseLimitEnabled && SkillUtils.IsCurseSkill(skill))
|
||||
{
|
||||
if (methodName == "DisableSkill" && param?.Length > 0 && param[0] is CCSPlayerController curser && curser.IsValid)
|
||||
SkillUtils.ReleaseCurse(curser.Index);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue