Join Date: Aug 2006
Location: In the Game [ro]
Just Capture the Flag
Mod version: 1.32c
Gameplay is simple, two teams, RED (Terrorists) and BLUE (CTs), each having a flag near their base.
The goal of each team is to capture the enemy flag while defending their own because in order to capture the enemy flag, you must bring it to your base and your flag must be there.
Enemy flags are stolen and team flags are returned by a simple touch.
Typical CTF gameplay... HOWEVER, it's got alot of features to enhance and balance the gameplay.
- Respawn, spawn protection and a team balance system
- Adrenaline points that give players temporary benefits when adrenaline reaches 100.
- Rewards (frags, adrenaline, money) for getting, capturing, killing carrier and returning flags.
- Assist rewards for assisting teammates on flag capturing and returning.
- Custom buy menu which allows all players to buy all weapons, including C4 (plantable anywhere, kills everything in range).
- Free ammo ! You get full free ammo whenever you buy a gun or you press the buy ammo keys.
- Killed enemies drop bonus items like medkits, adrenaline shots and ammo boxes.
- Mod has an API, see the API section for more details.
- You can disable individual features!
- And more, discover them yourself!
Follow these instructions carefully:
- Download and extract orpheu_base.zip into your amxmodx folder (Orpheu module thread)
- Download and extract jctf_resources.zip in your server's cstrike folder.
- Download jctf.txt and place it in your amxmodx/data/lang folder.
- Download jctf.sma and place it in your amxmodx/scripting folder then compile it (How to compile)
- Install plugin (move it from compiled to plugins) and write it's name in your plugins.ini file.
- Read the sections below on how to manage the mod.
NOTE: If you *really* can't get orpheu modeule to work, you can just disable it's usage: edit jctf.sma, change FEATURE_ORPHEU to false and recompile... howver, infinite round and flag capture round end will not work!
NOTE: Reset cvars need to be set on map-based configs (amxmodx/configs/maps/<mapname>.cfg) in order to be changed!
ctf_respawntime (reset to 10) - players respawn time
ctf_protection (reset to 5) - players spawn protection time
ctf_weaponstay (default 30) - how long do weapons and items stay on ground
ctf_spawnmoney (default 1000) - money bonus when spawning (unless it's a suicide)
ctf_infiniteround (default 1) - round doesn't end if all players form one team die (requires FEATURE_ORPHEU) changing this restarts game!
ctf_flagheal (default 1) - toggles if flag bases heal teammates
ctf_flagreturn (default 120) - flag auto-return time
ctf_flagendround (default 0) - if a flag is captured, round is ended (requires FEATURE_ORPHEU)
ctf_flagcaptureslay (default 0) - if a flag is captured, loosing team is slain (requires ctf_flagendround 1 OR FEATURE_ORPHEU false)
ctf_itempercent (default 30) - chance that items spawn when a player is killed, 0-100
ctf_nospam_flash (default 20) - delay of rebuying two flashbangs in a life
ctf_nospam_he (default 20) - delay of rebuying a HE grenade in a life
ctf_nospam_smoke (default 20) - delay of rebuying a smoke grenade in a life
ctf_spawn_prim (reset to "m3") - player's primary spawn weapon - use "" to disable (see list of weapon names in sma)
ctf_spawn_sec (reset to "glock") - player's secondary spawn weapon - use "" to disable (see list of weapon names in sma)
ctf_spawn_knife (reset to 1) - toggles if player receives a knife or not upon spawn
ctf_sound_taken (default 1) - toggles if the "flag taken" sounds can be heard
ctf_sound_dropped (default 1) - toggles if the "flag dropped" sounds can be heard
ctf_sound_returned (default 1) - toggles if the "flag returned" sounds can be heard
ctf_sound_score (default 1) - toggles if the "X team scores" sounds can be heard
ctf_dynamiclights (default 1) - set the default dynamic lights setting, players will still be able to toggle individually using /lights
ctf_glows (default 1) - set if entities can glow, like when players have flag or an adrenaline combo, weapons start to fade, etc.
Game cvars used by this mod:
mp_c4timer (recommended 20) - time before the C4 devices explode
mp_winlimit - when a team reaches this number of flag captures the map ends
mp_timelimit - map time limit (displayed as round timer)
mp_startmoney (recommended 3000) - starting money AND minimunm amount of money a player can have (unless it's a suicide)
mp_forcecamera - (0/1 - spectate enemies or not) mod fades to black if this is on and player is in free look (no teammates alive)
mp_forcechasecam - (0/1/2 - force chase cammera all/team/firstperson) same as above
mp_autoteambalance - enable/disable plugin's simple auto-team balance (checks at every player death)
You can customize the mod even more, you can find settings that I didn't made as CVars inside the source file (jctf.sma), there you can edit serval stuff, like disabling individual features, changing default settings for reset cvars, tweaking costs and rewards and many more.
Remember to re-compile and replace the compiled plugin in your plugins folder after you make any modifications to the jctf.sma file.
Recomandations and Issues:
ctf_return red/blue - return the specified flag if it was dropped for at least 15 seconds (configurable)
Can be used in: s = say, t = teamsay, c = console (note, console commands don't have the / in front!)
(s) /lights - enables/disables dynamic flag lights for that player
(s) /sounds 1-10 or test - sets the announcer volume, scale from 1 to 10, or plays an announcer sound for testing the volume (the test param)
(s,t) /help - shows the help text in console - includes server's mod settings of cvars and features
(s,t) /buy - shows the buy menu (not required, just use the normal buy key, default B)
(s,t) /spawn - buy an instant spawn for 50 adrenaline (configurable)
(s,t,c) /dropflag - drops the flag if you have it (WARNING: you will lose all rewards got for getting the flag!)
(s,t,c) /adrenaline - adrenaline combo pick menu once you got 100 adrenaline.
Once you load a map, both flags will spawn at the first player's spawn point.
As an RCON access admin you can move the flag bases to more suitable and ballanced places, you can do that using these commands in-game:
ctf_moveflag red/blue - move flag's base to your position, works even if you're dead or spectating
ctf_save - saves the flag base positions (as cstrike/maps/<mapname>.ctf)
Optionally, you can also download the jctf_mapflags.zip for some flag positions made by me, extract in server's cstrike/maps folder.
Translate this plugin to your language!
Servers running jCTF
Get addon plugins:
The "ED_Alloc: no free edicts" problem may occur when too many items (entities) exist at once in the map, to fix this, you could:
- Add "-num_edicts 4096" to server's run parameters
- Decrease "ctf_itempercent" and "ctf_weaponstay" cvars, the less items on ground, the better.
Players using VGUI menus won't be able to buy weapons that aren't listed there (like C4 and enemy weapons) and the mod can't disable VGUI on players without altering their config, therefore they're notified when spawning that they must use /buy or disable VGUI menu themseleves.
- Base-vs-base maps work best with this mod, most GunGame maps are like that.
- Do not use plugins related to buying, buy menu or C4 events.
Some addon plugins made by other members that uses jCTF:
Making addon plugins (API):
To install any of these plugins, you must first download jctf_api.zip, extract it into your amxmodx folder, also add the include required for the other mod (if any) and compile !
Send me a PM if you made some addon plugins if you want me to add them here.
You can also request addon plugins.
Since v1.2, this mod has an API that can be used from other plugins to get or control stuff on this plugin.
To use it, you need to download the jctf_api.zip and include it in your addon-plugin.
In the archive you'll find the required include, jctf.inc and an example plugin, jctf_addon_example.sma.
You can request more forwards or natives to be added to the API for further control of this mod.
- The players that participated on my boring testing sessions
- Arkshine for his Infinite Round and Round Terminator plugins, because I don't know anything about Orpheu
- Some plugin developers from which I got a few ideeas/codes... but I don't remember who exacly :/
- And the people that made good suggestions :}
You don't need all files from below, so don't just download them all, read the installation instructions !
* Changed files: jctf.sma
- Added ctf_dynamiclights cvar to enable server operators to disable dynamic lights by default, players can still re-enable them individually using /lights
- Added ctf_glows cvar to enable server operators to disable glows on entities for performance, however it will degrade gameplay due to lack of visual information
* Changed files: jctf.sma
- Fixed rewards beeing default to 0 for steal and capturing flags (my bad).
* Changes files: jctf.sma
- Removed forcing of CVars - if you depended on that, use amxx.cfg to store default values of cvars.
- Added posibility to disable respawn using ctf_respawntime 0.
- Added posibility to disable spawn protection using ctf_protection 0.
- Added posibility to disable dropped weapons fading out using ctf_weaponstay 0.
- Added posibility to disable flag auto-return using ctf_flagreturn 0.
- Fixed GameName printing CS 1.6 for CZ too, now it detects game name, if's unknown it doesn't write anything.
- Fixed player rewards still printing if all rewards are 0.
- Fixed MP3 files printing WAV error messages due to incorrect precaching method.
* Changed files: jctf.sma, jctf_resources.zip
- Fixed issue where plugin wouldn't trigger "Round_End" on ctf_flagendround 1 that caused issues with other plugins.
- Added new orpheu signatures: functions/EndRoundMessage and functions/CHalfLifeMultiplay/UpdateTeamScores.
- Changed "TeamScore" message to emessage, that way it can be hooked by other plugins.
- Added updating team scores internally too.
- Some other minor changes.
* Changed files: jctf.sma, lang/jctf.txt, jctf_resources.zip
- Added CVars: ctf_flagendround, ctf_flagcaptureslay and ctf_infiniteround (see thread for descriptions)
- Changed /help command, it now prints most mod settings and features (which are enabled/disabled)
- Added new orpheu signatures: functions/InstallGameRules and memory/CGameRulesOffsets (they're in jctf_resources.zip)
- Changed feature define FEATURE_INFROUND to FEATURE_ORPHEU because it also disables flag capture ending round
- Changed contents of lang keys: JOIN_NOFEATURES
- Renamed lang keys: HELP_3_* to HELP_4_* and DEAH_NOFREELOOK to DEATH_NOFREELOOK
- Added lang keys: DEATH_FLAGCAPTURED, STARTING_NEWROUND, and HELP_3_*
- Added so that on new round, flags are returned to base (no matter what the reason of new round)
* Changed files: jctf.sma
- Fixed if you reload map with the plugin disabled the rounds will end normally.
* Changed files: jctf.sma
- Fixed a compile error when switching FEATURE_ADRENALINE to false.
* Changed files: jctf.sma, jctf.txt
- Fixed buying VGUI issues, plugin now closes buy VGUI and opens custom buy menu without client changes.
- Removed VGUI related ML keys from jctf.txt.
* Changed files: jctf.sma, jctf.txt
- Added FEATURE disabling, you can now toggle individual features from the sma file.
- Added ctf_flagheal cvar which toggles if flag bases heal teammates.
- Changed HUD message to Director HUD messages, nicer and have no channel limit
- Increased char limit for "Freelook mode blocked" ML text from 32 to 48 chars.
- Rearranged sma configuration variables, you can find them easier on top of the file.
- Added hints and adrenaline menu to the ML support.
- Decreased chance that flag gets stuck in a wall (dramatically decreased collision box and added proximity check for pickup)
- Decreased C4's price from $15000 to $12000 and adrenaline cost from 100 to 80
- Some minor optimizations
* Changed files: jctf.sma, jctf.inc(jctf_api.zip), lang/jctf.txt
- Fixed "ED_Alloc: No free edicts" crashes (hopefully).
- Added Multilingual support, natives support it too.
- Added printing of admin commands in chat that obey amx_show_activity.
- Added a check of players spawning HP and Armor so Booster and flags know how much to heal.
- Added configurable extra HP the booster heals.
- Changed armor regeneration from Booster so it no longer sets armor to kevlar+helm if you have kevlar only.
- Added option to ignore bots from taking flags, default OFF
- Added checking of player's team range when touching flag in case it's a spawned spectator.
- Fixed bots not buying weapons, but be warned, they buy at default prices and without adrenaline.
- Changed default mp_buytime from 0 to 99999999 so bots can always buy, this doesn't affect players.
- Added API natives: jctf_get_flagcarrier(id) and jctf_get_team(id)
- Added FLAG_ADMINRETURN for the jctf_flag() forward, it triggers when an admin returns the flag using command
- Fixed ctf_moveflag command not showing Y axis in the log
- Changed ctf_moveflag to support red and blue inputs.
- Fade to black no longer affects spectators
- Added "ctf_returnflag <red/blue>" admin command that returns the specified flag if it was dropped for at least 15 seconds (configurable)
- Optimized some minor stuff
- Changed ctf_weaponstay's default value from 30 to 15 (seconds)
- Changed ctf_itempercent's default value from 30 to 25 (percent)
- Added Scout and G3SG1 as special weapons.
- Added the "configurable" flag in the source for weapon money and adrenaline costs
- Added configurable weapon and zoom-in running speeds
- Added cvars for controling sounds: ctf_sound_taken/dropped/returned/score
- Added how much money/adrenaline you need in the "Not enough money/adrenaline" message
- plugin no longer disables VGUI menu automatically but it notifies VGUI menu users upon spawn
- added new in-source configuration: CHAT_SHOW_COMMANDS
- fixed a bug where you'd get twice the adrenaline when using the jctf_add_adrenaline() native while using a reason
- fixed adrenaline HUD not updating when using jctf_add_adrenaline()
- added FLAG_MANUALDROP for jctf_flag() events
- fixed some example issues in jctf_addon_example.sma
- updated version check to 1.21 since jctf.inc was altered
- added a console print upon plugin load with plugin name and version
- forced to reset jctf_version to the current version if mod is updated while server is running
- added forwards and natives that other plugins could use
- added configurable spawning weapons using CVars, they're also forced to reset to prevent unwanted usage between maps
- minor adjustments in the code to fit the latest modifications
- fixed some issues with the autoteambalance
- fixed spawn protection countdown not stop when prematurely disabling protection
- fixed game name displaying version as number instead of string
- added mod version in quick help and help console message
- added checking of mp_forcechasecam too for the fade to black feature
- fixed the possiblity of not beeing blinded while in freelook after a respawn
- fixed a bug where transfered people (autoteambalance) would actually block the team they left from beeing joined, the "there are too many CTs/Ts" thing.
- added fade to black when mp_fadetoblack is disabled and mp_forcecamera is enabled while player is on free view (no teammates alive)
- fixed a rare bug where players won't respawn after beeing killed
- some optimizations in code
- removed previous round-end blocking and added new round blocking method via Orpheu module
- fixed various possible crashes caused by previous round-end blocking methods
- changed buy menu text so that items you can't afford are in red text
- fixed various speed issues with player zooming, shield and flag taking
- re-done player rendering system and altered some colors and values
- unforced most mod cvars, only two cvars remain forced
- fixed round-blocking player deaths's animations
- changed the sounds of medkit and adrenaline item pickup
- and of course, other small adjustments
- other small adjustments here and there
- removed the spectating bots, now players' deaths are blocked if they'll trigger round end, they wouldn't even notice
- altered C4 plant radio message to a be compatible with client modifications and other hooks
- added /help
- minor adjustments and code moved around
- fixed items not fading out
- fixed the simple auto-team balance
- fixed various possible errors
- minor fixes of typos and checks
NOTE: "Get plugin" does not work for this plugin, follow the instructions !
Last edited by Hunter-Digital; 06-28-2012 at 00:10.