diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..6313b56 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* text=auto eol=lf diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..4ff757f --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,67 @@ +name: Build workflow + +on: + push: + branches: master + paths-ignore: '**.md' + pull_request: + paths-ignore: '**.md' + release: + types: published + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@main + + - name: Checkout sendproxy + uses: actions/checkout@main + with: + repository: arthurdead/sendproxy + path: sendproxy + + - name: Set up spcomp + uses: rumblefrog/setup-sp@master + with: + version: 1.11.x + + - name: Compile plugin + working-directory: addons/sourcemod/scripting/ + env: + include: ${{ github.workspace }}/sendproxy/sourcemod/scripting/include/ + run: | + mkdir ../plugins + spcomp64 -v2 -E -i$include misere.sp -o ../plugins/misere.smx + + - name: Create archive + run: | + 7za a -r misere.zip addons/ models/ + + - name: Upload artifact + uses: actions/upload-artifact@main + with: + name: package + path: misere.zip + + upload-release: + runs-on: ubuntu-latest + needs: build + if: github.event_name == 'release' + + steps: + - name: Download artifact + uses: actions/download-artifact@main + with: + name: package + + - name: Upload release asset + uses: actions/upload-release-asset@main + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: misere.zip + asset_name: misere.zip + asset_content_type: application/zip diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..de3ccd9 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## 0.1.0 (2022-08-13) + +- Initial release diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..14e2f77 --- /dev/null +++ b/LICENSE @@ -0,0 +1,373 @@ +Mozilla Public License Version 2.0 +================================== + +1. Definitions +-------------- + +1.1. "Contributor" + means each individual or legal entity that creates, contributes to + the creation of, or owns Covered Software. + +1.2. "Contributor Version" + means the combination of the Contributions of others (if any) used + by a Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + means Source Code Form to which the initial Contributor has attached + the notice in Exhibit A, the Executable Form of such Source Code + Form, and Modifications of such Source Code Form, in each case + including portions thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + (a) that the initial Contributor has attached the notice described + in Exhibit B to the Covered Software; or + + (b) that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the + terms of a Secondary License. + +1.6. "Executable Form" + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + means a work that combines Covered Software with other material, in + a separate file or files, that is not Covered Software. + +1.8. "License" + means this document. + +1.9. "Licensable" + means having the right to grant, to the maximum extent possible, + whether at the time of the initial grant or subsequently, any and + all of the rights conveyed by this License. + +1.10. "Modifications" + means any of the following: + + (a) any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered + Software; or + + (b) any new file in Source Code Form that contains any Covered + Software. + +1.11. "Patent Claims" of a Contributor + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the + License, by the making, using, selling, offering for sale, having + made, import, or transfer of either its Contributions or its + Contributor Version. + +1.12. "Secondary License" + means either the GNU General Public License, Version 2.0, the GNU + Lesser General Public License, Version 2.1, the GNU Affero General + Public License, Version 3.0, or any later versions of those + licenses. + +1.13. "Source Code Form" + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that + controls, is controlled by, or is under common control with You. For + purposes of this definition, "control" means (a) the power, direct + or indirect, to cause the direction or management of such entity, + whether by contract or otherwise, or (b) ownership of more than + fifty percent (50%) of the outstanding shares or beneficial + ownership of such entity. + +2. License Grants and Conditions +-------------------------------- + +2.1. Grants + +Each Contributor hereby grants You a world-wide, royalty-free, +non-exclusive license: + +(a) under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + +(b) under Patent Claims of such Contributor to make, use, sell, offer + for sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + +The licenses granted in Section 2.1 with respect to any Contribution +become effective for each Contribution on the date the Contributor first +distributes such Contribution. + +2.3. Limitations on Grant Scope + +The licenses granted in this Section 2 are the only rights granted under +this License. No additional rights or licenses will be implied from the +distribution or licensing of Covered Software under this License. +Notwithstanding Section 2.1(b) above, no patent license is granted by a +Contributor: + +(a) for any code that a Contributor has removed from Covered Software; + or + +(b) for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + +(c) under Patent Claims infringed by Covered Software in the absence of + its Contributions. + +This License does not grant any rights in the trademarks, service marks, +or logos of any Contributor (except as may be necessary to comply with +the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + +No Contributor makes additional grants as a result of Your choice to +distribute the Covered Software under a subsequent version of this +License (see Section 10.2) or under the terms of a Secondary License (if +permitted under the terms of Section 3.3). + +2.5. Representation + +Each Contributor represents that the Contributor believes its +Contributions are its original creation(s) or it has sufficient rights +to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + +This License is not intended to limit any rights You have under +applicable copyright doctrines of fair use, fair dealing, or other +equivalents. + +2.7. Conditions + +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted +in Section 2.1. + +3. Responsibilities +------------------- + +3.1. Distribution of Source Form + +All distribution of Covered Software in Source Code Form, including any +Modifications that You create or to which You contribute, must be under +the terms of this License. You must inform recipients that the Source +Code Form of the Covered Software is governed by the terms of this +License, and how they can obtain a copy of this License. You may not +attempt to alter or restrict the recipients' rights in the Source Code +Form. + +3.2. Distribution of Executable Form + +If You distribute Covered Software in Executable Form then: + +(a) such Covered Software must also be made available in Source Code + Form, as described in Section 3.1, and You must inform recipients of + the Executable Form how they can obtain a copy of such Source Code + Form by reasonable means in a timely manner, at a charge no more + than the cost of distribution to the recipient; and + +(b) You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter + the recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + +You may create and distribute a Larger Work under terms of Your choice, +provided that You also comply with the requirements of this License for +the Covered Software. If the Larger Work is a combination of Covered +Software with a work governed by one or more Secondary Licenses, and the +Covered Software is not Incompatible With Secondary Licenses, this +License permits You to additionally distribute such Covered Software +under the terms of such Secondary License(s), so that the recipient of +the Larger Work may, at their option, further distribute the Covered +Software under the terms of either this License or such Secondary +License(s). + +3.4. Notices + +You may not remove or alter the substance of any license notices +(including copyright notices, patent notices, disclaimers of warranty, +or limitations of liability) contained within the Source Code Form of +the Covered Software, except that You may alter any license notices to +the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + +You may choose to offer, and to charge a fee for, warranty, support, +indemnity or liability obligations to one or more recipients of Covered +Software. However, You may do so only on Your own behalf, and not on +behalf of any Contributor. You must make it absolutely clear that any +such warranty, support, indemnity, or liability obligation is offered by +You alone, and You hereby agree to indemnify every Contributor for any +liability incurred by such Contributor as a result of warranty, support, +indemnity or liability terms You offer. You may include additional +disclaimers of warranty and limitations of liability specific to any +jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +--------------------------------------------------- + +If it is impossible for You to comply with any of the terms of this +License with respect to some or all of the Covered Software due to +statute, judicial order, or regulation then You must: (a) comply with +the terms of this License to the maximum extent possible; and (b) +describe the limitations and the code they affect. Such description must +be placed in a text file included with all distributions of the Covered +Software under this License. Except to the extent prohibited by statute +or regulation, such description must be sufficiently detailed for a +recipient of ordinary skill to be able to understand it. + +5. Termination +-------------- + +5.1. The rights granted under this License will terminate automatically +if You fail to comply with any of its terms. However, if You become +compliant, then the rights granted under this License from a particular +Contributor are reinstated (a) provisionally, unless and until such +Contributor explicitly and finally terminates Your grants, and (b) on an +ongoing basis, if such Contributor fails to notify You of the +non-compliance by some reasonable means prior to 60 days after You have +come back into compliance. Moreover, Your grants from a particular +Contributor are reinstated on an ongoing basis if such Contributor +notifies You of the non-compliance by some reasonable means, this is the +first time You have received notice of non-compliance with this License +from such Contributor, and You become compliant prior to 30 days after +Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent +infringement claim (excluding declaratory judgment actions, +counter-claims, and cross-claims) alleging that a Contributor Version +directly or indirectly infringes any patent, then the rights granted to +You by any and all Contributors for the Covered Software under Section +2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all +end user license agreements (excluding distributors and resellers) which +have been validly granted by You or Your distributors under this License +prior to termination shall survive termination. + +************************************************************************ +* * +* 6. Disclaimer of Warranty * +* ------------------------- * +* * +* Covered Software is provided under this License on an "as is" * +* basis, without warranty of any kind, either expressed, implied, or * +* statutory, including, without limitation, warranties that the * +* Covered Software is free of defects, merchantable, fit for a * +* particular purpose or non-infringing. The entire risk as to the * +* quality and performance of the Covered Software is with You. * +* Should any Covered Software prove defective in any respect, You * +* (not any Contributor) assume the cost of any necessary servicing, * +* repair, or correction. This disclaimer of warranty constitutes an * +* essential part of this License. No use of any Covered Software is * +* authorized under this License except under this disclaimer. * +* * +************************************************************************ + +************************************************************************ +* * +* 7. Limitation of Liability * +* -------------------------- * +* * +* Under no circumstances and under no legal theory, whether tort * +* (including negligence), contract, or otherwise, shall any * +* Contributor, or anyone who distributes Covered Software as * +* permitted above, be liable to You for any direct, indirect, * +* special, incidental, or consequential damages of any character * +* including, without limitation, damages for lost profits, loss of * +* goodwill, work stoppage, computer failure or malfunction, or any * +* and all other commercial damages or losses, even if such party * +* shall have been informed of the possibility of such damages. This * +* limitation of liability shall not apply to liability for death or * +* personal injury resulting from such party's negligence to the * +* extent applicable law prohibits such limitation. Some * +* jurisdictions do not allow the exclusion or limitation of * +* incidental or consequential damages, so this exclusion and * +* limitation may not apply to You. * +* * +************************************************************************ + +8. Litigation +------------- + +Any litigation relating to this License may be brought only in the +courts of a jurisdiction where the defendant maintains its principal +place of business and such litigation shall be governed by laws of that +jurisdiction, without reference to its conflict-of-law provisions. +Nothing in this Section shall prevent a party's ability to bring +cross-claims or counter-claims. + +9. Miscellaneous +---------------- + +This License represents the complete agreement concerning the subject +matter hereof. If any provision of this License is held to be +unenforceable, such provision shall be reformed only to the extent +necessary to make it enforceable. Any law or regulation which provides +that the language of a contract shall be construed against the drafter +shall not be used to construe this License against a Contributor. + +10. Versions of the License +--------------------------- + +10.1. New Versions + +Mozilla Foundation is the license steward. Except as provided in Section +10.3, no one other than the license steward has the right to modify or +publish new versions of this License. Each version will be given a +distinguishing version number. + +10.2. Effect of New Versions + +You may distribute the Covered Software under the terms of the version +of the License under which You originally received the Covered Software, +or under the terms of any subsequent version published by the license +steward. + +10.3. Modified Versions + +If you create software not governed by this License, and you want to +create a new license for such software, you may create and use a +modified version of this License if you rename the license and remove +any references to the name of the license steward (except to note that +such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary +Licenses + +If You choose to distribute Source Code Form that is Incompatible With +Secondary Licenses under the terms of this version of the License, the +notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +------------------------------------------- + + This Source Code Form is subject to the terms of the Mozilla Public + License, v. 2.0. If a copy of the MPL was not distributed with this + file, You can obtain one at http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular +file, then You may include the notice in a location (such as a LICENSE +file in a relevant directory) where a recipient would be likely to look +for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice +--------------------------------------------------------- + + This Source Code Form is "Incompatible With Secondary Licenses", as + defined by the Mozilla Public License, v. 2.0. diff --git a/README.md b/README.md new file mode 100644 index 0000000..dc6fc4d --- /dev/null +++ b/README.md @@ -0,0 +1,23 @@ +# Misère PASS Time + +Custom TF2 gamemode based on PASS Time, where the team who moves the JACK furthest from the center loses. + +## Overview + +- Each team has a team-colored sphere called the "zone", whose radius represents the furthest distance from the center of the map that any team member has stood while carrying the JACK. There is no way to decrease the zone's size. The team with the smallest zone at the end of the round wins. +- The goal is to force the enemy team to inadvertently expand their zone. This is done mainly by throwing the JACK at enemies while they are standing outside of the zone, or using knockback (e.g. airblast) to push out an enemy who is currently holding the JACK. +- Standard PASS Time goals can still be scored, but they only serve to expedite the end of the round; the winner is still the team with the smallest zone. Normal overtime rules also still apply (overtime only occurs if both teams have equal goals). +- Suiciding by using the `kill`/`explode` commands or changing class is blocked while near (or carrying) the JACK. Friendly fire is enabled to allow teammates to kill each other as means to avoid the JACK. +- To keep players from hiding in spawn, teams can open each other's spawn doors and the JACK can be carried into spawn areas. Players are given 8 seconds of spawn protection, during which they cannot carry the JACK. +- Using jumper weapons or taunting no longer prevents players from carrying the JACK. Other conditions still do, though (e.g. uber, hauling a building). + +## Installation + +This plugin requires SourceMod 1.11+ and [SendProxy Manager](https://github.com/arthurdead/sendproxy). + +1. Download `misere.zip` from the [latest release](https://github.com/osyu/misere/releases/latest). +2. Extract it and copy all folders into `tf/` on your gameserver. +3. If you're using FastDL, copy the `models` folder there too. +4. Load the plugin or restart your server. + +The plugin only affects PASS Time maps. diff --git a/addons/sourcemod/gamedata/misere.txt b/addons/sourcemod/gamedata/misere.txt new file mode 100644 index 0000000..9fd2afb --- /dev/null +++ b/addons/sourcemod/gamedata/misere.txt @@ -0,0 +1,206 @@ +"Games" +{ + "tf" + { + "Offsets" + { + "CTFGameRules::SetWinningTeam" + { + "linux" "161" + "windows" "160" + } + "CFilterTFTeam::PassesFilterImpl" + { + "linux" "196" + "windows" "195" + } + "CTFPlayer::IsAllowedToPickUpFlag" + { + "linux" "481" + "windows" "480" + } + } + "Signatures" + { + "CTFPasstimeLogic::BCanPlayerPickUpBall" + { + "library" "server" + "linux" "@_ZNK16CTFPasstimeLogic20BCanPlayerPickUpBallEP9CTFPlayerP17HudNotification_t" + "windows" "\x55\x8B\xEC\x57\x8B\x7D\x2A\x85\xFF\x74\x2A\xC7\x07\x00\x00\x00\x00" + } + "CPasstimeGun::BValidPassTarget" + { + "library" "server" + "linux" "@_ZN12CPasstimeGun16BValidPassTargetEP9CTFPlayerS1_P17HudNotification_t" + "windows" "\x55\x8B\xEC\x53\x56\x8B\x75\x2A\x57\x85\xF6\x74\x2A" + } + "CTFGameRules::SendHudNotification" + { + "library" "server" + "linux" "@_ZN12CTFGameRules19SendHudNotificationER16IRecipientFilter17HudNotification_tb" + "windows" "\x55\x8B\xEC\x80\x7D\x2A\x00\x75\x2A\x80\xB9\x2A\x2A\x2A\x2A\x00" + } + "CTeamplayRoundBasedRules::State_Transition" + { + "library" "server" + "linux" "@_ZN24CTeamplayRoundBasedRules16State_TransitionE22gamerules_roundstate_t" + "windows" "\x55\x8B\xEC\x56\x8B\xF1\x8B\x8E\x2A\x2A\x2A\x2A\x8B\x86\x2A\x2A\x2A\x2A" + } + "CTFPlayer::CancelEurekaTeleport" + { + "library" "server" + "linux" "@_ZN9CTFPlayer20CancelEurekaTeleportEv" + "windows" "\xC6\x81\x2A\x2A\x2A\x2A\x00\xC7\x81\x2A\x2A\x2A\x2A\x00\x00\x80\xBF" + } + "CTFRobotDestructionLogic::m_sCTFRobotDestructionLogic" + { + "library" "server" + "linux" "@_ZN24CTFRobotDestructionLogic27m_sCTFRobotDestructionLogicE" + } + "cc_tf_rd_max_points_override" + { + "library" "server" + "windows" "\x55\x8B\xEC\x83\xEC\x0C\x8D\x4D\x2A\x56" + } + } + "Addresses" + { + "m_sCTFRobotDestructionLogic" + { + "linux" + { + "signature" "CTFRobotDestructionLogic::m_sCTFRobotDestructionLogic" + } + "windows" + { + "signature" "cc_tf_rd_max_points_override" + "read" "20" + } + } + } + "Functions" + { + "CTFGameRules::SetWinningTeam" + { + "offset" "CTFGameRules::SetWinningTeam" + "hooktype" "gamerules" + "return" "void" + "this" "ignore" + "arguments" + { + "team" + { + "type" "int" + } + "iWinReason" + { + "type" "int" + } + "bForceMapReset" + { + "type" "bool" + } + "bSwitchTeams" + { + "type" "bool" + } + "bDontAddScore" + { + "type" "bool" + } + "bFinal" + { + "type" "bool" + } + } + } + "CFilterTFTeam::PassesFilterImpl" + { + "offset" "CFilterTFTeam::PassesFilterImpl" + "hooktype" "entity" + "return" "bool" + "this" "ignore" + "arguments" + { + "pCaller" + { + "type" "cbaseentity" + } + "pEntity" + { + "type" "cbaseentity" + } + } + } + "CTFPlayer::IsAllowedToPickUpFlag" + { + "offset" "CTFPlayer::IsAllowedToPickUpFlag" + "hooktype" "entity" + "return" "bool" + "this" "entity" + } + "CTFPasstimeLogic::BCanPlayerPickUpBall" + { + "signature" "CTFPasstimeLogic::BCanPlayerPickUpBall" + "callconv" "thiscall" + "return" "bool" + "this" "ignore" + "arguments" + { + "pPlayer" + { + "type" "cbaseentity" + } + "pReason" + { + "type" "objectptr" + } + } + } + "CPasstimeGun::BValidPassTarget" + { + "signature" "CPasstimeGun::BValidPassTarget" + "callconv" "thiscall" + "return" "bool" + "this" "ignore" + "arguments" + { + "pSource" + { + "type" "cbaseentity" + } + "pTarget" + { + "type" "cbaseentity" + } + "pReason" + { + "type" "objectptr" + } + } + } + "CTFGameRules::SendHudNotification" + { + "signature" "CTFGameRules::SendHudNotification" + "callconv" "thiscall" + "return" "void" + "this" "ignore" + "arguments" + { + "filter" + { + "type" "objectptr" + } + "iType" + { + "type" "int" + } + "bForceShow" + { + "type" "bool" + } + } + } + } + } +} diff --git a/addons/sourcemod/scripting/misere.sp b/addons/sourcemod/scripting/misere.sp new file mode 100644 index 0000000..cd87f35 --- /dev/null +++ b/addons/sourcemod/scripting/misere.sp @@ -0,0 +1,651 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ + +//------------------------------------------------------------------------------ +#include +#include +#include +#include +#include +#include +#include + +#pragma semicolon 1 +#pragma newdecls required + +#define PLUGIN_VERSION "0.1.0" + +#define ROUND_TIME 300 +#define SETUP_TIME 10 +#define MAX_SCORES 3 + +#define ZONE_MODEL "models/misere/zone1" + +//------------------------------------------------------------------------------ +public Plugin myinfo = +{ + name = "[TF2] Misère PASS Time", + author = "ugng", + description = "Alternative PASS Time gamemode", + version = PLUGIN_VERSION, + url = "https://osyu.sh/" +}; + +//------------------------------------------------------------------------------ +// Virtual hooks +Handle g_hSetWinningTeam; +Handle g_hPassesFilterImpl; +Handle g_hIsAllowedToPickUpFlag; +// Detours +Handle g_hCanPlayerPickUpBall; +Handle g_hValidPassTarget; +Handle g_hSendHudNotification; +// SDK calls +Handle g_hStateTransition; +Handle g_hCancelEurekaTeleport; +// Addresses +Address g_pCTFRobotDestructionLogic; + +// ConVars +Handle g_hFriendlyFire; +Handle g_hMaxScores; +bool g_bPrevFriendlyFire; +int g_iPrevMaxScores; +bool g_bCVarReverted; + +// Hud/visual entities +int g_iPDLogic; +int g_iCapFlags[2]; +int g_iZoneProps[2]; + +// Map state +bool g_bMapInInit = false; +bool g_bInPassTime = false; + +// Game state +int g_iScores[2] = {0, 0}; +int g_iGoals[2] = {0, 0}; +float g_vCenter[3]; +int g_iBall = 0; +int g_iCarrier = 0; +int g_iCarrierTeam; + +//------------------------------------------------------------------------------ +public void OnPluginStart() +{ + CreateConVar("misere_version", PLUGIN_VERSION, "Misère PASS Time version", FCVAR_NOTIFY | FCVAR_DONTRECORD); + + g_hFriendlyFire = FindConVar("mp_friendlyfire"); + g_hMaxScores = FindConVar("tf_passtime_scores_per_round"); + + LoadTranslations("misere.phrases"); + + Handle hGameConf = LoadGameConfigFile("misere"); + + g_hSetWinningTeam = DHookCreateFromConf(hGameConf, "CTFGameRules::SetWinningTeam"); + g_hPassesFilterImpl = DHookCreateFromConf(hGameConf, "CFilterTFTeam::PassesFilterImpl"); + g_hIsAllowedToPickUpFlag = DHookCreateFromConf(hGameConf, "CTFPlayer::IsAllowedToPickUpFlag"); + g_hCanPlayerPickUpBall = DHookCreateFromConf(hGameConf, "CTFPasstimeLogic::BCanPlayerPickUpBall"); + g_hValidPassTarget = DHookCreateFromConf(hGameConf, "CPasstimeGun::BValidPassTarget"); + g_hSendHudNotification = DHookCreateFromConf(hGameConf, "CTFGameRules::SendHudNotification"); + + StartPrepSDKCall(SDKCall_GameRules); + PrepSDKCall_SetFromConf(hGameConf, SDKConf_Signature, "CTeamplayRoundBasedRules::State_Transition"); + PrepSDKCall_AddParameter(SDKType_PlainOldData, SDKPass_Plain); + g_hStateTransition = EndPrepSDKCall(); + + StartPrepSDKCall(SDKCall_Player); + PrepSDKCall_SetFromConf(hGameConf, SDKConf_Signature, "CTFPlayer::CancelEurekaTeleport"); + g_hCancelEurekaTeleport = EndPrepSDKCall(); + + g_pCTFRobotDestructionLogic = GameConfGetAddress(hGameConf, "m_sCTFRobotDestructionLogic"); + + CloseHandle(hGameConf); + + DHookEnableDetour(g_hCanPlayerPickUpBall, false, CanPlayerPickUpBall_Pre); + DHookEnableDetour(g_hCanPlayerPickUpBall, true, CanPlayerPickUpBall_Post); + DHookEnableDetour(g_hValidPassTarget, false, ValidPassTarget_Pre); + + HookEvent("pass_get", Event_PassGet); + HookEvent("pass_pass_caught", Event_PassCaught); + HookEvent("pass_ball_stolen", Event_PassStolen); + HookEvent("pass_free", Event_PassFree); + HookEvent("pass_score", Event_PassScore); +} + +//------------------------------------------------------------------------------ +public void OnPluginEnd() +{ + if (g_bInPassTime) + { + OnMapEnd(); + RestartRound(); + } +} + +//------------------------------------------------------------------------------ +public void OnMapInit() +{ + g_bMapInInit = true; +} + +//------------------------------------------------------------------------------ +public void OnMapStart() +{ + g_bInPassTime = GameRules_GetProp("m_nGameType") == 7; + + if (g_bInPassTime) + { + // Make clients think we're in PD rather than PASS Time so the PD hud is shown + SendProxy_HookGameRules("m_nGameType", Prop_Int, GameTypeProxy); + SendProxy_HookGameRules("m_bPlayingRobotDestructionMode", Prop_Int, GameTypeProxy); + + DHookGamerules(g_hSetWinningTeam, false, _, SetWinningTeam_Pre); + DHookEnableDetour(g_hSendHudNotification, false, SendHudNotification_Pre); + + for (int i = 1; i <= MaxClients; i++) + { + if (IsClientInGame(i)) + { + OnClientPutInServer(i); + } + } + + HookEvent("teamplay_round_start", Event_TeamplayRoundStart); + /* We have to do this since OnPassFree isn't called if someone is holding the + * ball when the round ends (no overtime). */ + HookEvent("teamplay_round_win", Event_PassFree); + HookEvent("player_spawn", Event_PlayerSpawn); + + AddCommandListener(Command_Taunt, "taunt"); + AddCommandListener(Command_Suicide, "kill"); + AddCommandListener(Command_Suicide, "explode"); + AddCommandListener(Command_Suicide, "joinclass"); + + g_bPrevFriendlyFire = GetConVarBool(g_hFriendlyFire); + SetConVarBool(g_hFriendlyFire, true); + + g_iPrevMaxScores = GetConVarInt(g_hMaxScores); + SetConVarInt(g_hMaxScores, MAX_SCORES); + + HookConVarChange(g_hFriendlyFire, OnConVarChanged); + HookConVarChange(g_hMaxScores, OnConVarChanged); + + PrecacheModel(ZONE_MODEL ... ".mdl"); + AddFileToDownloadsTable(ZONE_MODEL ... ".mdl"); + AddFileToDownloadsTable(ZONE_MODEL ... ".dx80.vtx"); + AddFileToDownloadsTable(ZONE_MODEL ... ".dx90.vtx"); + AddFileToDownloadsTable(ZONE_MODEL ... ".sw.vtx"); + AddFileToDownloadsTable(ZONE_MODEL ... ".vvd"); + + int iBallSpawn = FindEntityByClassname(-1, "info_passtime_ball_spawn"); + + float vBallSpawn[3]; + GetEntPropVector(iBallSpawn, Prop_Send, "m_vecOrigin", vBallSpawn); + + TR_TraceRayFilter(vBallSpawn, {90.0, 0.0, 0.0}, MASK_SOLID_BRUSHONLY, RayType_Infinite, TraceFilter); + TR_GetEndPosition(g_vCenter); + + if (g_bMapInInit) + { + // Call this so the PD hud & others are shown during the first pregame + Event_TeamplayRoundStart(INVALID_HANDLE, "", false); + } + RestartRound(); + } + + g_bMapInInit = false; +} + +//------------------------------------------------------------------------------ +public void OnMapEnd() +{ + if (g_bInPassTime) + { + DHookDisableDetour(g_hSendHudNotification, false, SendHudNotification_Pre); + + UnhookEvent("teamplay_round_start", Event_TeamplayRoundStart); + UnhookEvent("teamplay_round_win", Event_PassFree); + UnhookEvent("player_spawn", Event_PlayerSpawn); + + RemoveCommandListener(Command_Taunt, "taunt"); + RemoveCommandListener(Command_Suicide, "kill"); + RemoveCommandListener(Command_Suicide, "explode"); + RemoveCommandListener(Command_Suicide, "joinclass"); + + UnhookConVarChange(g_hFriendlyFire, OnConVarChanged); + UnhookConVarChange(g_hMaxScores, OnConVarChanged); + + SetConVarBool(g_hFriendlyFire, g_bPrevFriendlyFire); + SetConVarInt(g_hMaxScores, g_iPrevMaxScores); + + g_bInPassTime = false; + } +} + +//------------------------------------------------------------------------------ +public void OnClientPutInServer(int iClient) +{ + if (g_bInPassTime) + { + DHookEntity(g_hIsAllowedToPickUpFlag, false, iClient, _, IsAllowedToPickUpFlag_Pre); + } +} + +//------------------------------------------------------------------------------ +// Handle zone scoring and model scale. +public void OnGameFrame() +{ + if (g_bInPassTime && g_iCarrier) + { + float vCarrier[3]; + GetEntPropVector(g_iCarrier, Prop_Send, "m_vecOrigin", vCarrier); + + int iDistance = RoundFloat(GetVectorDistance(vCarrier, g_vCenter)); + + if (iDistance > g_iScores[g_iCarrierTeam]) + { + g_iScores[g_iCarrierTeam] = iDistance; + + ShowTFHudText(g_iCarrier, _, 0, "%t", "Leaving zone"); + + SetEntPropFloat(g_iZoneProps[g_iCarrierTeam], Prop_Send, "m_flModelScale", iDistance * 2.0); + + SetEntProp(g_iPDLogic, Prop_Send, g_iCarrierTeam ? "m_nBlueScore" : "m_nRedScore", iDistance); + SendRDPointsChange(g_iCarrierTeam + 2, false); + } + } +} + +//------------------------------------------------------------------------------ +public void OnEntityCreated(int iEnt, const char[] sClassName) +{ + if (g_bInPassTime && !g_iBall && StrEqual(sClassName, "passtime_ball")) + { + g_iBall = iEnt; + } +} + +//------------------------------------------------------------------------------ +/* Remove the fading uber condition when medigun uber is removed. The game never + * removes this condition on its own when uber is depleted, and when checking if + * players can pick up the ball the game also considers it as invulnerability. + * This causes any player who has been ubered in their current life to be unable + * to pick up the ball, which we don't want to happen. */ +public void TF2_OnConditionRemoved(int iClient, TFCond iCondition) +{ + if (g_bInPassTime && iCondition == TFCond_Ubercharged) + { + TF2_RemoveCondition(iClient, TFCond_UberchargeFading); + } +} + +//------------------------------------------------------------------------------ +// Prevent ConVars that we changed from getting messed with. +void OnConVarChanged(Handle hConVar, const char[] sOld, const char[] sNew) +{ + if (!g_bCVarReverted) + { + g_bCVarReverted = true; + SetConVarString(hConVar, sOld); + } + else + { + g_bCVarReverted = false; + } +} + +//------------------------------------------------------------------------------ +// Prevent the carrier from starting a taunt, and show them a hud notification. +Action Command_Taunt(int iClient, const char[] iCommand, int iArgc) +{ + if (iClient == g_iCarrier) + { + ShowTFHudText(g_iCarrier, _, 0, "#TF_Passtime_No_Taunt"); + return Plugin_Handled; + } + + return Plugin_Continue; +} + +//------------------------------------------------------------------------------ +/* Prevent players from suiciding or changing class if they are the carrier or + * near the ball, and show them a suitable hud notification. */ +Action Command_Suicide(int iClient, const char[] iCommand, int iArgc) +{ + bool bJoinClass = StrEqual(iCommand, "joinclass"); + + if (iClient == g_iCarrier) + { + ShowTFHudText(iClient, _, 0, "%t", bJoinClass ? "No class carry" : "No suicide carry"); + return Plugin_Handled; + } + else if (IsPlayerAlive(iClient)) + { + int iTarget = GetEntityMoveType(g_iBall) ? g_iBall : g_iCarrier; + + if (iTarget) + { + float vClient[3]; + float vTarget[3]; + GetClientAbsOrigin(iClient, vClient); + GetEntPropVector(iTarget, Prop_Send, "m_vecOrigin", vTarget); + + int iDistance = RoundFloat(GetVectorDistance(vClient, vTarget)); + + if (iDistance < 800) + { + ShowTFHudText(iClient, _, 0, "%t", bJoinClass ? "No class" : "No suicide"); + return Plugin_Handled; + } + } + } + + return Plugin_Continue; +} + +//------------------------------------------------------------------------------ +void Event_TeamplayRoundStart(Handle hEvent, const char[] sName, bool bDontBroadcast) +{ + g_iBall = 0; + g_iCarrier = 0; + g_iScores = {0, 0}; + g_iGoals = {0, 0}; + + g_iZoneProps[0] = CreateZoneProp(0); + g_iZoneProps[1] = CreateZoneProp(1); + + g_iPDLogic = CreateEntityByName("tf_logic_player_destruction"); + /* Null out RD logic global. Prevents various PD logic from running + * (e.g. players dropping flags when killed). */ + StoreToAddress(g_pCTFRobotDestructionLogic, 0, NumberType_Int32); + /* We need to set the .res file here because PD logic inherits from RD logic, + * and as a result the default .res file is for RD and won't work. */ + SetEntPropString(g_iPDLogic, Prop_Send, "m_szResFile", "resource/UI/HudObjectivePlayerDestruction.res"); + SetEntProp(g_iPDLogic, Prop_Send, "m_nMaxPoints", MAX_SCORES); + SDKHook(g_iPDLogic, SDKHook_Think, PDLogicThink_Pre); + + /* PD "escrow" is counted by the client hud code by iterating over all stolen + * CCaptureFlags in the world, adding up their point values and attributing + * them to the previous owner's team. We create two teamed dummy flags here + * (which have themselves set as the prev. owner) to show goals on the hud. */ + for (int i = 0; i < 2; i++) + { + g_iCapFlags[i] = CreateEntityByName("item_teamflag"); + SetEntProp(g_iCapFlags[i], Prop_Send, "m_iTeamNum", i + 2); + SetEntProp(g_iCapFlags[i], Prop_Send, "m_nFlagStatus", 1); + SetEntPropEnt(g_iCapFlags[i], Prop_Send, "m_hPrevOwner", g_iCapFlags[i]); + // Needs a model to prevent client console spam + SetEntityModel(g_iCapFlags[i], "models/empty.mdl"); + } + + int iRoundTimer = FindEntityByClassname(-1, "team_round_timer"); + SetVariantInt(ROUND_TIME); + AcceptEntityInput(iRoundTimer, "SetMaxTime"); + SetVariantInt(SETUP_TIME); + AcceptEntityInput(iRoundTimer, "SetSetupTime"); + + int iFilterTeam = -1; + while ((iFilterTeam = FindEntityByClassname(iFilterTeam, "filter_activator_tfteam")) != INVALID_ENT_REFERENCE) + { + DHookEntity(g_hPassesFilterImpl, false, iFilterTeam, _, PassesFilterImpl_Pre); + } + + int iBarrier = -1; + while ((iBarrier = FindEntityByClassname(iBarrier, "func_respawnroomvisualizer")) != INVALID_ENT_REFERENCE) + { + if (GetEntProp(iBarrier, Prop_Data, "m_bSolid")) + { + RemoveEntity(iBarrier); + } + } + + int iNoBall = -1; + while ((iNoBall = FindEntityByClassname(iNoBall, "func_passtime_no_ball_zone")) != INVALID_ENT_REFERENCE) + { + if (!GetEntProp(iNoBall, Prop_Data, "m_bDisabled")) + { + RemoveEntity(iNoBall); + } + } +} + +//------------------------------------------------------------------------------ +// Apply spawn protection (a la Mannpower). +void Event_PlayerSpawn(Handle hEvent, const char[] sName, bool bDontBroadcast) +{ + TF2_AddCondition(GetClientOfUserId(GetEventInt(hEvent, "userid")), TFCond_UberchargedCanteen, 8.0); +} + +//------------------------------------------------------------------------------ +void Event_PassGet(Handle hEvent, const char[] sName, bool bDontBroadcast) +{ + OnPassCarried(GetEventInt(hEvent, "owner")); +} +void Event_PassCaught(Handle hEvent, const char[] sName, bool bDontBroadcast) +{ + OnPassCarried(GetEventInt(hEvent, "catcher")); +} +void Event_PassStolen(Handle hEvent, const char[] sName, bool bDontBroadcast) +{ + OnPassCarried(GetEventInt(hEvent, "attacker")); +} + +//------------------------------------------------------------------------------ +void OnPassCarried(int iClient) +{ + g_iCarrier = iClient; + g_iCarrierTeam = GetClientTeam(g_iCarrier) - 2; + SetEntProp(g_iPDLogic, Prop_Send, g_iCarrierTeam ? "m_nBlueTargetPoints" : "m_nRedTargetPoints", MAX_SCORES); +} + +//------------------------------------------------------------------------------ +void Event_PassFree(Handle hEvent, const char[] sName, bool bDontBroadcast) +{ + g_iCarrier = 0; + SetEntProp(g_iPDLogic, Prop_Send, g_iCarrierTeam ? "m_nBlueTargetPoints" : "m_nRedTargetPoints", 0); +} + +//------------------------------------------------------------------------------ +void Event_PassScore(Handle hEvent, const char[] sName, bool bDontBroadcast) +{ + g_iGoals[g_iCarrierTeam] += GetEventInt(hEvent, "points"); + SetEntProp(g_iCapFlags[g_iCarrierTeam], Prop_Send, "m_nPointValue", g_iGoals[g_iCarrierTeam]); +} + +//------------------------------------------------------------------------------ +// Prevent the PD logic entity from thinking (it wreaks havoc with game state). +Action PDLogicThink_Pre(int iEnt) +{ + return Plugin_Handled; +} + +//------------------------------------------------------------------------------ +// When the round ends, set the winning team based on our scores. +MRESReturn SetWinningTeam_Pre(Handle hParams) +{ + TFTeam iWinningTeam = TFTeam_Unassigned; + + if (g_iScores[0] < g_iScores[1]) + { + iWinningTeam = TFTeam_Red; + } + else if (g_iScores[0] > g_iScores[1]) + { + iWinningTeam = TFTeam_Blue; + } + + DHookSetParam(hParams, 1, iWinningTeam); + return MRES_Handled; +} + +//------------------------------------------------------------------------------ +// Return true for all team filters so players can activate enemy doors. +MRESReturn PassesFilterImpl_Pre(Handle hReturn) +{ + DHookSetReturn(hReturn, true); + return MRES_Supercede; +} + +//------------------------------------------------------------------------------ +/* Normally this function checks if the player has a weapon equipped with the + * cannot_pick_up_intelligence attribute (jumper weapons), but we want those + * players to be able to pick up the ball here. We also want players to be + * immune to the ball based on our own criteria, so by superceding this with + * IsClientImmune's value we kill two birds with one stone. */ +MRESReturn IsAllowedToPickUpFlag_Pre(int iClient, Handle hReturn) +{ + DHookSetReturn(hReturn, !IsClientImmune(iClient)); + return MRES_Supercede; +} + +//------------------------------------------------------------------------------ +/* Stop non-immune players from taunting before the game checks if they can + * pick up the ball (the carrier cannot taunt). */ +MRESReturn CanPlayerPickUpBall_Pre(Handle hReturn, Handle hParams) +{ + int iClient = DHookGetParam(hParams, 1); + if (TF2_IsPlayerInCondition(iClient, TFCond_Taunting) && !IsClientImmune(iClient)) + { + TF2_RemoveCondition(iClient, TFCond_Taunting); + SDKCall(g_hCancelEurekaTeleport, iClient); + } + + return MRES_Handled; +} + +//------------------------------------------------------------------------------ +/* Prevent stock cannot-pick-up-ball hud notifications from being sent, since + * not being able to hold the ball is an advantage. */ +MRESReturn CanPlayerPickUpBall_Post(Handle hReturn, Handle hParams) +{ + if (DHookGetParamAddress(hParams, 2)) + { + DHookSetParamObjectPtrVar(hParams, 2, 0, ObjectValueType_Int, 0); + return MRES_Handled; + } + + return MRES_Ignored; +} + +//------------------------------------------------------------------------------ +// Disable pass targeting (we don't want the ball to chase teammates). +MRESReturn ValidPassTarget_Pre(Handle hReturn, Handle hParams) +{ + if (DHookGetParamAddress(hParams, 3)) + { + // We need to set this to 0 so we don't get random hud notifications + DHookSetParamObjectPtrVar(hParams, 3, 0, ObjectValueType_Int, 0); + } + DHookSetReturn(hReturn, false); + return MRES_Supercede; +} + +//------------------------------------------------------------------------------ +/* Prevent PASS Time how-to hud notifications from being sent, since they + * explain how to play the original gamemode and we don't want confusion. */ +MRESReturn SendHudNotification_Pre(Handle hParams) +{ + if (DHookGetParam(hParams, 2) == 16) + { + return MRES_Supercede; + } + + return MRES_Ignored; +} + +//------------------------------------------------------------------------------ +// Heresy! Witchcraft! More words! +int CreateZoneProp(int iSkin) +{ + int iPropParent = CreateEntityByName("prop_dynamic"); + SetEntityModel(iPropParent, ZONE_MODEL ... ".mdl"); + SetEntPropFloat(iPropParent, Prop_Send, "m_flModelScale", 0.0); + AddEntityEffects(iPropParent, 8 | 32); // EF_NOINTERP | EF_NODRAW + TeleportEntity(iPropParent, g_vCenter, NULL_VECTOR, NULL_VECTOR); + + int iPropChild = CreateEntityByName("prop_dynamic"); + SetEntityModel(iPropChild, ZONE_MODEL ... ".mdl"); + SetEntProp(iPropChild, Prop_Send, "m_nSkin", iSkin); + AddEntityEffects(iPropChild, 1 | 16); // EF_BONEMERGE | EF_NOSHADOW + TeleportEntity(iPropChild, g_vCenter, NULL_VECTOR, NULL_VECTOR); + + SetVariantString("!activator"); + AcceptEntityInput(iPropChild, "SetParent", iPropParent); + + return iPropParent; +} + +//------------------------------------------------------------------------------ +// Send message to all clients to play the score change animation on the PD hud. +void SendRDPointsChange(int iTeam, bool bPositive) +{ + Handle hMessage = StartMessageAll("RDTeamPointsChanged", USERMSG_RELIABLE); + BfWriteShort(hMessage, bPositive); + BfWriteByte(hMessage, iTeam); + BfWriteByte(hMessage, 0); + EndMessage(); +} + +//------------------------------------------------------------------------------ +void ShowTFHudText(int iClient, char[] sIcon = "ico_notify_flag_moving_alt", int iTeam, char[] sFmt, any ...) +{ + char sMessage[128]; + SetGlobalTransTarget(iClient); + VFormat(sMessage, sizeof(sMessage), sFmt, 5); + + Handle hMessage = StartMessageOne("HudNotifyCustom", iClient, USERMSG_RELIABLE); + BfWriteString(hMessage, sMessage); + BfWriteString(hMessage, sIcon); + BfWriteByte(hMessage, iTeam); + EndMessage(); +} + +//------------------------------------------------------------------------------ +/* Restart the round (if the map is not initializing). Used to clean entities + * when the plugin starts or ends. */ +void RestartRound() +{ + if (!g_bMapInInit) + { + RoundState iPrevState = GameRules_GetRoundState(); + SDKCall(g_hStateTransition, RoundState_Preround); + + // If we were in pregame, go back to prevent redundant state transitions + if (iPrevState == RoundState_Pregame) + { + SDKCall(g_hStateTransition, iPrevState); + } + } +} + +//------------------------------------------------------------------------------ +/* Our own criteria for whether players should be allowed to pick up the ball. + * For some reason the game doesn't already check for canteen uber, which is + * used by the Phlogistinator taunt (and our spawn protection). */ +bool IsClientImmune(int iClient) +{ + return (TF2_IsPlayerInCondition(iClient, TFCond_Ubercharged) || + TF2_IsPlayerInCondition(iClient, TFCond_UberchargedCanteen)); +} + +//------------------------------------------------------------------------------ +void AddEntityEffects(int iEnt, int iToAdd) +{ + int iEffects = GetEntProp(iEnt, Prop_Send, "m_fEffects"); + SetEntProp(iEnt, Prop_Send, "m_fEffects", iEffects | iToAdd); +} + +//------------------------------------------------------------------------------ +bool TraceFilter(int iEnt, int iContentsMask) +{ + return GetEntityMoveType(iEnt) == MOVETYPE_NONE; +} + +//------------------------------------------------------------------------------ +Action GameTypeProxy(const char[] sProp, int &iValue, int iElement, int iClient) +{ + iValue = StrEqual(sProp, "m_nGameType") ? 0 : 1; + return Plugin_Changed; +} diff --git a/addons/sourcemod/translations/misere.phrases.txt b/addons/sourcemod/translations/misere.phrases.txt new file mode 100644 index 0000000..0321c2d --- /dev/null +++ b/addons/sourcemod/translations/misere.phrases.txt @@ -0,0 +1,74 @@ +"Phrases" +{ + "Translator credits" + { + "bg" "ugng " + "chi" "Karasuneth " + "de" "Wirelex.exe " + "es" "darako " + "fr" "Nutshinou " + "it" "svp " + "pl" "ciasteczkowy potwór " + "ru" "ugng's mom " + } + "Leaving zone" + { + "bg" "Напускате зоната!" + "chi" "你是离开了这区!" + "de" "Sie verlassen die Zone!" + "en" "You are leaving the zone!" + "es" "¡Estás saliendo de la zona!" + "fr" "Vous abandonnez la zone !" + "it" "Stai uscendo dalla zona!" + "pl" "Opuszczasz strefę!" + "ru" "Вы покидаете зону!" + } + "No suicide" + { + "bg" "Не можете да се САМОУБИЕТЕ, докато сте близо до ПОДЕМНОТО У-ВО!" + "chi" "近球时不能自杀!" + "de" "Sie können nicht SELBSTMORD begehen, während in der Nähe des JACK!" + "en" "You cannot SUICIDE while near the JACK!" + "es" "¡No puedes SUICIDARTE mientras estés cerca del BALÓN!" + "fr" "Vous ne pouvez pas vous SUICIDER quand vous êtes près de la BALLE !" + "it" "Non puoi SUICIDARTI se sei vicino alla PALLA!" + "pl" "Nie możesz się POPEŁNIĆ SAMOBÓJSTWA, gdy jesteś przy PIŁCE!" + "ru" "Вы не можете УБИТЬ СЕБЯ, находясь рядом с МЯЧОМ!" + } + "No suicide carry" + { + "bg" "Не можете да се САМОУБИЕТЕ, докато носите ПОДЕМНОТО У-ВО!" + "chi" "持球时不能自杀!" + "de" "Sie können nicht SELBSTMORD begehen, während Sie den JACK tragen!" + "en" "You cannot SUICIDE while carrying the JACK!" + "es" "¡No puedes SUICIDARTE mientras lleves el BALÓN!" + "fr" "Vous ne pouvez pas vous SUICIDER quand vous avez la BALLE !" + "it" "Non puoi SUICIDARTI se hai la PALLA!" + "pl" "Nie możesz się POPEŁNIĆ SAMOBÓJSTWA, gdy niesiesz PIŁKĘ!" + "ru" "Вы не можете УБИТЬ СЕБЯ, когда у вас в руках МЯЧ!" + } + "No class" + { + "bg" "Не можете да СМЕНИТЕ КЛАСА, докато сте близо до ПОДЕМНОТО У-ВО!" + "chi" "近球时不能更改兵种!" + "de" "Sie können nicht die KLASSE WECHSELN, während in der Nähe des JACK!" + "en" "You cannot CHANGE CLASS while near the JACK!" + "es" "¡No puedes CAMBIAR DE CLASE mientras estés cerca del BALÓN!" + "fr" "Vous ne pouvez pas CHANGER DE CLASSE quand vous êtes près de la BALLE !" + "it" "Non puoi CAMBIARE CLASSE se sei vicino alla PALLA!" + "pl" "Nie możesz ZMIENIĆ KLASY, gdy jesteś przy PIŁCE!" + "ru" "Вы не можете СМЕНИТЬ КЛАСС, находясь рядом с МЯЧОМ!" + } + "No class carry" + { + "bg" "Не можете да СМЕНИТЕ КЛАСА, докато носите ПОДЕМНОТО У-ВО!" + "chi" "持球时不能更改兵种!" + "de" "Sie können nicht die KLASSE WECHSELN, während Sie den JACK tragen!" + "en" "You cannot CHANGE CLASS while carrying the JACK!" + "es" "¡No puedes CAMBIAR DE CLASE mientras lleves el BALÓN!" + "fr" "Vous ne pouvez pas CHANGER DE CLASSE quand vous avez la BALLE !" + "it" "Non puoi CAMBIARE CLASSE se hai la PALLA!" + "pl" "Nie możesz ZMIENIĆ KLASY, gdy niesiesz PIŁKĘ!" + "ru" "Вы не можете СМЕНИТЬ КЛАСС, когда у вас в руках МЯЧ!" + } +} diff --git a/models/misere/zone1.dx80.vtx b/models/misere/zone1.dx80.vtx new file mode 100644 index 0000000..67d4b8c Binary files /dev/null and b/models/misere/zone1.dx80.vtx differ diff --git a/models/misere/zone1.dx90.vtx b/models/misere/zone1.dx90.vtx new file mode 100644 index 0000000..4d77293 Binary files /dev/null and b/models/misere/zone1.dx90.vtx differ diff --git a/models/misere/zone1.mdl b/models/misere/zone1.mdl new file mode 100644 index 0000000..63374a8 Binary files /dev/null and b/models/misere/zone1.mdl differ diff --git a/models/misere/zone1.sw.vtx b/models/misere/zone1.sw.vtx new file mode 100644 index 0000000..a372837 Binary files /dev/null and b/models/misere/zone1.sw.vtx differ diff --git a/models/misere/zone1.vvd b/models/misere/zone1.vvd new file mode 100644 index 0000000..764990a Binary files /dev/null and b/models/misere/zone1.vvd differ