Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
153 commits
Select commit Hold shift + click to select a range
e2642f0
Merge pull request #875 from Custom-Roles-for-TTT/beta
Malivil Aug 9, 2025
f82f949
Fixed docs typo
Malivil Aug 11, 2025
a447786
Copied taskmaster progress to current dev branch
NoxxFlame Aug 12, 2025
c3183fe
Added the ability for tasks that require specific features to block o…
NoxxFlame Aug 12, 2025
b84a3a3
Added 'Kill Nearby Player' and 'Kill Faraway Player' tasks
NoxxFlame Aug 13, 2025
d4a31d7
Added new conversion constant
Malivil Aug 13, 2025
5efb1d2
Cleanup
Malivil Aug 13, 2025
2107739
Luacheck fixes
Malivil Aug 13, 2025
b1fc57c
Added Stay Near Target task (without progress bar)
Malivil Aug 13, 2025
88d654c
Added `state` parameter to `TTTTeamVoiceChatTargets` hook
Malivil Aug 14, 2025
143037a
Fixed illusionist not blocking traitor team voice chat
Malivil Aug 14, 2025
76fa64a
Added progress bar to Stay Near Target task
Malivil Aug 14, 2025
21b242c
Changed progress bar to fill rather than drain
Malivil Aug 14, 2025
4fcdedb
Cleanup
Malivil Aug 14, 2025
6ca9794
Changed task features to use constants
Malivil Aug 14, 2025
50d96ad
Disallow 0 for Stay Near Target convars
Malivil Aug 14, 2025
d698f31
Added 'Kill a Player From Behind' task
NoxxFlame Aug 14, 2025
a66db08
Added Crouch Near Body task
Malivil Aug 14, 2025
a8295a8
Merge remote-tracking branch 'origin/taskmaster' into taskmaster
NoxxFlame Aug 14, 2025
f1942b4
Added 'Kill an Airbourne Player' and 'Kill a Player While Midair' task
NoxxFlame Aug 14, 2025
c35dc60
Added `TTTDetectiveCalledToBody` hook which is called when a player c…
Malivil Aug 14, 2025
7e16191
Added Call Detective to Body task
Malivil Aug 14, 2025
504ef06
Added Pick Up Shop Item task
Malivil Aug 14, 2025
acf1447
Added Jump task
Malivil Aug 14, 2025
6c61a8f
Added Jump times convar to ULX
Malivil Aug 14, 2025
60b3d5f
Added Crouch task
Malivil Aug 14, 2025
600c488
Prefix task property names to ensure uniqueness
Malivil Aug 14, 2025
7a530a2
Added Fire Bullets task
Malivil Aug 14, 2025
81a0b48
Added Do Damage task
Malivil Aug 14, 2025
736481c
Removed test tasks
Malivil Aug 14, 2025
0d38608
Fixed Stay Near Target not handling the case where the target died
Malivil Aug 14, 2025
eb13a33
Fixed Stay Near Target task not handling target player disconnect
Malivil Aug 14, 2025
be296f8
Added Chat task
Malivil Aug 14, 2025
043bbcb
Added Health Under task
Malivil Aug 14, 2025
4bde7ad
Cleanup
Malivil Aug 14, 2025
5ab34b2
Added Holstered task
Malivil Aug 14, 2025
0b55bad
Fixed Holstered convar description
Malivil Aug 14, 2025
4add9c4
Added Crowbar task
Malivil Aug 14, 2025
dc628b5
Added Pick Up Weapons task
Malivil Aug 14, 2025
49dc4c3
Added Stand on Player task
Malivil Aug 14, 2025
a0b9803
Added Carry Corpse task
Malivil Aug 14, 2025
9a3b217
Changed `SYNC` methods to not clear values that are already `nil`
Malivil Aug 15, 2025
56eb3e8
Fixed some Taskmaster tasks being doable while dead
Malivil Aug 15, 2025
55ef53b
Added Stay Higher and Stay Lower tasks
Malivil Aug 15, 2025
c07323b
Added Damage Everyone task
Malivil Aug 15, 2025
420e615
Update names for consistency
Malivil Aug 15, 2025
c52e97c
More consistency
Malivil Aug 15, 2025
de8a77e
Cleanup
Malivil Aug 15, 2025
f4c7f46
Added "Stay in Area" task
Malivil Aug 15, 2025
568c136
Added Stay Away task
Malivil Aug 15, 2025
25eb6e7
Fixed Stay Near Target not cleaning up enough
Malivil Aug 15, 2025
299401c
Minor cleanup
Malivil Aug 15, 2025
b36ffad
Added Get Player Killed task
Malivil Aug 15, 2025
39a4427
Cleanup
Malivil Aug 15, 2025
a10cbaf
Added Get Player to Kill task
Malivil Aug 15, 2025
dcc5c15
Standardize
Malivil Aug 15, 2025
e833bff
Standardize more
Malivil Aug 15, 2025
7d7eb9e
Added Look at Player task
Malivil Aug 15, 2025
387cfdd
Changed Look at Player to work more like the Informant scan
Malivil Aug 15, 2025
5d76a23
Cleanup
Malivil Aug 15, 2025
db44664
Fixed comment
Malivil Aug 15, 2025
e95f5a1
Added Stay Hidden task
Malivil Aug 15, 2025
78b51ea
Added Take Damage task
Malivil Aug 15, 2025
cd1ffce
Added ability for tasks to be marked as not blocking the round from e…
Malivil Aug 15, 2025
8ca4c3c
Fixed promoted impersonator and deputy who are searched by a detectiv…
Malivil Aug 16, 2025
2ebc290
Added `table.GetFirstItemWithPropertyValue` static method
Malivil Aug 16, 2025
c75a505
Added ability to control whether the mercenary gets body armor as par…
Malivil Aug 16, 2025
fad5dd6
Added new method to luacheck
Malivil Aug 16, 2025
c1aa8b0
Added HTML docs for new mercenary convar
Malivil Aug 16, 2025
9ba6b0f
Added missing betaonly tag
Malivil Aug 16, 2025
6b85ea7
- Added ability to change vampire's fang drain overheal to overheal (…
Malivil Aug 16, 2025
341d581
Added new globals
Malivil Aug 16, 2025
6bb0696
Added ability to disable automatically confirming a players death whe…
Malivil Aug 16, 2025
bedc045
Added 'Kill Target' task
NoxxFlame Aug 17, 2025
39c7e9a
Added 'Kill Kill a Player With a Pistol' task
NoxxFlame Aug 17, 2025
1e0449c
Added 'Kill a Player While Aiming' task
NoxxFlame Aug 17, 2025
984f08f
Added 'Kill a Player With Your Last Bullet' task
NoxxFlame Aug 17, 2025
360e391
Added 'Kill a Player With a Crowbar' task
NoxxFlame Aug 17, 2025
2fe2830
Added 'Kill a Player With a Headshot' task
NoxxFlame Aug 17, 2025
4168b20
Added 'Kill a Player Who Attacked First' task
NoxxFlame Aug 17, 2025
04e0130
Added 'Kill a Player in One Hit' task
NoxxFlame Aug 17, 2025
5b22865
Added 'Get a Double Kill' task
NoxxFlame Aug 17, 2025
8b980be
Added 'Kill a Player After a 360' task and fixed progress bar colour …
NoxxFlame Aug 17, 2025
4a3a749
Added 'Kill a Player With a Specific Weapon' task (almost)
NoxxFlame Aug 17, 2025
d2b0432
Updated weapon switch and pickup HUD elements to use the same logic f…
Malivil Aug 17, 2025
40c5b16
Misc changes
NoxxFlame Aug 17, 2025
6f7be99
Cleanup
Malivil Aug 17, 2025
0d2ecc0
Luacheck fixes
Malivil Aug 17, 2025
128d863
Revert wrong luacheck fix
Malivil Aug 17, 2025
89052ec
Try a different fork of gluacheck
Malivil Aug 17, 2025
ae6aa98
Try the right rockspec
Malivil Aug 17, 2025
4a69303
Change to the actual right rockspec
Malivil Aug 17, 2025
bbebdca
I'll get this right eventually
Malivil Aug 17, 2025
6b78427
Fixed paths
Malivil Aug 17, 2025
2539bf9
Fixed another path
Malivil Aug 17, 2025
c25e078
Fixed load error
Malivil Aug 17, 2025
3f42e69
Change to my updated luacheck fork for better continue support
Malivil Aug 17, 2025
d57b23f
Revert overzealous luacheck changes
Malivil Aug 17, 2025
4773037
Fixed wrong variable usage
Malivil Aug 17, 2025
3b55777
Fixed error
Malivil Aug 17, 2025
042a94e
Added line pointing to the area in the Stay in Area task
Malivil Aug 17, 2025
51fee1f
Fixed descriptions being cut off in the reroll list if they were too …
Malivil Aug 17, 2025
3634495
Update to conform to updated gluacheck fork
Malivil Aug 18, 2025
77a33d1
Cleanup
Malivil Aug 18, 2025
e77d4ab
Fixed error rerolling when there are no available tasks remaining
Malivil Aug 18, 2025
d1c86e9
Added Task.Initialize optional method
Malivil Aug 18, 2025
c519767
Cleanup
Malivil Aug 18, 2025
62fa5db
Added tutorial, popup, and cheatsheet text
Malivil Aug 18, 2025
ce2320f
Changed Taskmaster to see jesters and MIA in case they need to kill e…
Malivil Aug 18, 2025
b6860f7
Expanded Taskmaster tutorial
Malivil Aug 18, 2025
ef75c38
Standardize naming on PascalCase
Malivil Aug 18, 2025
3c3876f
Fixed missing changes
Malivil Aug 18, 2025
b932682
Rework logic for events that complete on round end to fix winning if …
Malivil Aug 18, 2025
8647eb5
Changed taskmaster to allow rerolled tasks to show back up in future …
Malivil Aug 18, 2025
71699f0
Fixed error in Damage Everyone task when a non-player is shot
Malivil Aug 18, 2025
cc417f0
Implemented IsRoleAbilityDisabled logic
Malivil Aug 18, 2025
f547125
Added missing convars to ULX
Malivil Aug 20, 2025
307ae78
Added description and ranges to some auto-generated convars
Malivil Aug 20, 2025
ab362a0
Added markdown docs
Malivil Aug 20, 2025
84a4597
Added cr4ttt_role_cvars script
Malivil Aug 20, 2025
37bedfd
Fixed global bleed
Malivil Aug 20, 2025
d103ec7
Added support for non-numeric dropdowns to HTML docs generator
Malivil Aug 20, 2025
1d7000e
Added taskmaster HTML docs
Malivil Aug 20, 2025
2cc6e14
Error prevention and cleanup
Malivil Aug 20, 2025
c4848e5
Change create HTML tutorial to link to HTML convars page
Malivil Aug 24, 2025
2c0d786
Added task complete messages
Malivil Aug 24, 2025
cb8e2f9
Fixed missing param in docs
Malivil Aug 25, 2025
44bf3b6
Mixed duplicate hook name
NoxxFlame Aug 25, 2025
685b186
Added task complete sounds and reworked reroll logic to account for e…
NoxxFlame Aug 25, 2025
9558803
Small fix
NoxxFlame Aug 25, 2025
fb35f6e
Fixed broken doc header
Malivil Aug 25, 2025
09a281b
Added Taskmaster to release notes
Malivil Aug 25, 2025
277a1cb
Merge pull request #877 from Malivil/dev
Malivil Aug 28, 2025
0da2100
Merge branch 'dev' into taskmaster
Malivil Aug 28, 2025
9a38ded
Merge pull request #882 from NoxxFlame/taskmaster
Malivil Aug 28, 2025
24a6830
Moved role template into its own folder
Malivil Aug 28, 2025
6bbb5e4
Cleanup
Malivil Aug 28, 2025
a586fb7
Added HTML tutorial for creating Taskmaster tasks
Malivil Aug 28, 2025
64a9d3e
Cleanup
Malivil Aug 28, 2025
57d1be6
Added Markdown version of Taskmaster task tutorial
Malivil Aug 28, 2025
cdf9eef
Apply suggestions from code review
Malivil Aug 29, 2025
8a0cd57
Merge pull request #885 from Malivil/dev
Malivil Aug 29, 2025
e53a640
Added ability for the Tracker to be a special innocent instead of a s…
Malivil Aug 31, 2025
aad11f2
Merge branch 'dev' of https://github.com/Malivil/TTT-Custom-Roles int…
Malivil Aug 31, 2025
c4e487c
Merge pull request #886 from Malivil/dev
Malivil Aug 31, 2025
bf9fb6f
Added "signed" parameter to "util.BitsRequired" from base TTT
Malivil Aug 31, 2025
40a334e
Merge branch 'dev' into dev
Malivil Aug 31, 2025
13ad0b4
Fixed typo
Malivil Aug 31, 2025
ecdb853
Merge branch 'dev' of https://github.com/Malivil/TTT-Custom-Roles int…
Malivil Aug 31, 2025
f251464
Merge pull request #887 from Malivil/dev
Malivil Aug 31, 2025
13982d1
Ported "TTT: Add custom T Radio sound support and extra default sound…
Malivil Sep 4, 2025
60ff60e
Merge branch 'dev' into dev
Malivil Sep 4, 2025
923b92e
Merge pull request #888 from Malivil/dev
Malivil Sep 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/luacheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@ jobs:
uses: leafo/gh-actions-luarocks@v4

- name: Setup dependencies
run: luarocks install --deps-only gluacheck-dev-1.rockspec
run: luarocks install --deps-only luacheck-dev-1.rockspec

- name: Build ‘luacheck’ (bootstrap)
run: luarocks make gluacheck-dev-1.rockspec
run: luarocks make luacheck-dev-1.rockspec

- name: Run ‘luacheck’ (dogfood)
run: lua -e 'package.path="./gluacheck/src/?.lua;./gluacheck/src/?/init.lua;"..package.path' gluacheck/bin/luacheck.lua gamemodes scripts
12 changes: 12 additions & 0 deletions .luacheckrc
Original file line number Diff line number Diff line change
Expand Up @@ -897,6 +897,7 @@ globals = {
"EVENT_VINDICATORFAIL",
"EVENT_VINDICATORSUCCESS",
"EVENT_ZOMBIFIED",
"FEET_PER_METER",
"GLITCH_CHAT_NONE",
"GLITCH_CHAT_BLOCK_ALWAYS",
"GLITCH_CHAT_BLOCK_WHILE_ALIVE",
Expand Down Expand Up @@ -1052,6 +1053,10 @@ globals = {
"SPECIAL_DETECTIVE_HIDE_NONE",
"SPONGE_ALL_PLAYERS",
"SPONGE_ATTACKER_AND_VICTIM",
"TASKMASTER_TF_TARGETID_PLAYERICON",
"TASKMASTER_TF_TARGETID_PLAYERTEXT",
"TASKMASTER_TF_PROGRESSBAR",
"TASKMASTER_TF_PARTICLERADIUS",
"TRACKRADAR",
"TRAITOR_BUTTON_ROLES",
"TRAITOR_ROLES",
Expand All @@ -1078,6 +1083,7 @@ globals = {
"WIN_PLAGUEMASTER",
"WIN_SHADOW",
"WIN_SPONGE",
"WIN_TASKMASTER",
"WIN_TIMELIMIT",
"WIN_TRAITOR",
"WIN_VAMPIRE",
Expand All @@ -1089,6 +1095,9 @@ globals = {
"VAMPIRE_DEATH_NONE",
"VAMPIRE_DEATH_KILL_CONVERTED",
"VAMPIRE_DEATH_REVERT_CONVERTED",
"VAMPIRE_OVERHEAL_MODE_HEALTH",
"VAMPIRE_OVERHEAL_MODE_MAX_HEALTH",
"VAMPIRE_OVERHEAL_MODE_BOTH",
"VAMPIRE_THRALL_FF_MODE_NONE",
"VAMPIRE_THRALL_FF_MODE_REFLECT",
"VAMPIRE_THRALL_FF_MODE_IMMUNE",
Expand Down Expand Up @@ -1142,6 +1151,7 @@ globals = {
"ROLE_SPONGE",
"ROLE_SPY",
"ROLE_SWAPPER",
"ROLE_TASKMASTER",
"ROLE_TRACKER",
"ROLE_TRICKSTER",
"ROLE_TURNCOAT",
Expand Down Expand Up @@ -1210,6 +1220,7 @@ globals = {
"CRHUD",
"DEATHRADAR",
"SYNC",
"TASKMASTER",

-- TTTPAP Namespaces
"TTTPAP",
Expand Down Expand Up @@ -1250,6 +1261,7 @@ std = {
EqualValues = {},
ExcludedKeys = {},
GetKeys = {},
GetFirstItemWithPropertyValue = {},
HasItemWithPropertyValue = {},
HasTable = {},
HasValue = {},
Expand Down
15 changes: 13 additions & 2 deletions API/HOOKS.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,15 @@ Called before the name and role of a player's killer is shown to the victim. Use
- *killerName* - The new killerName value to use or the original passed into the hook
- *role* - The new role value to use or the original passed into the hook. Use `ROLE_NONE` to hide the attacker's role from the victim

### TTTDetectiveCalledToBody(ply, owner, rag)
Called when a player calls a detective to a player ragdoll.\
*Realm:* Server\
*Added in:* 2.3.5\
*Parameters:*
- *ply* - The player who is calling for a detective
- *owner* - The player who owns the corpse the detective is being called to
- *rag* - The ragdoll representing the corpse being called to

### TTTDetectiveLikePromoted(ply)
Called when a detective-like (deputy, impersonator, etc.) player is promoted.\
*Realm:* Server\
Expand Down Expand Up @@ -1263,13 +1272,14 @@ Called before a team chat message is sent. Used to modify the targets of the tea

*Return:* Whether or not this team chat message should be sent (Defaults to `true`)

### TTTTeamVoiceChatTargets(speaker, targets)
### TTTTeamVoiceChatTargets(speaker, targets, state)
Called before a team voice state message is sent. Used to modify the targets of the team voice state message.\
*Realm:* Server\
*Added in:* 2.0.7\
*Parameters:*
- *speaker* - The player trying to send their team voice state message
- *targets* - The table of players that this message will be sent to. Add or remove players from this table to change the message recipients
- *state* - Whether the speaker is speaking globally (`true`) or only to their team (`false`) *(Added in 2.3.5)*

*Return:* Whether or not this team voice state message should be sent (Defaults to `true`)

Expand Down Expand Up @@ -1340,7 +1350,7 @@ Called after globals are synced but but before role colors and strings are set.
*Realm:* Client and Server\
*Added in:* 1.2.7

### TTTVampireBodyEaten(ply, ent, living, healed)
### TTTVampireBodyEaten(ply, ent, living, healed, maxchange)
Called after a vampire eats a body.\
*Realm:* Server\
*Added in:* 1.6.16\
Expand All @@ -1349,6 +1359,7 @@ Called after a vampire eats a body.\
- *ent* - The target entity. Generally either a player or a ragdoll
- *living* - Whether the target entity was living at the time they were eaten
- *healed* - The amount of health the player gained from eating the body
- *maxchange* - The amount of maximum health the player gained from eating the body *(Added in 2.3.5)*

### TTTVampireInvisibilityChange(ply, invisible)
Called when a vampire starts or ends their invisibility.\
Expand Down
11 changes: 10 additions & 1 deletion API/METHODS_TABLE.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,17 @@ Returns new table that contains the keys not present as values in in the given e
- *tbl* - The table whose keys are being inspected
- *excludes* - Table of values to exclude

### table.GetFirstItemWithPropertyValue(tbl, key, val)
Returns the first item in the given table that has an item whose property specified by the provided `key` has a value that matches the given `val`.\
*Realm:* Client and Server\
*Added in:* 2.3.5\
*Parameters:*
- *tbl* - The table whose values are being inspected
- *key* - The property name whose value is being compared
- *val* - The value to find in the given property

### table.HasItemWithPropertyValue(tbl, key, val)
Returns whether the given table has an item whose property specified by the provided `key` has a value that makes the given `val`.\
Returns whether the given table has an item whose property specified by the provided `key` has a value that matches the given `val`.\
*Realm:* Client and Server\
*Added in:* 1.8.7\
*Parameters:*
Expand Down
3 changes: 2 additions & 1 deletion API/METHODS_UTIL.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# Utility Methods
Utility methods created to help with various common scenarios

### util.BitsRequired(num)
### util.BitsRequired(num, signed)
Returns how many bits are required to transmit the given number over the network.\
*Realm:* Client and Server\
*Added in:* 2.3.3\
*Parameters:*
- *num* - The number being transmitted
- *signed* - Whether the number being transmitted is signed *(Added in 2.3.5)*

### util.BurnRagdoll(rag, burn_time, scorch)
Burns a player ragdoll, shows scorch marks, and automatically destroys the ragdoll unless it's been extinguished by water.\
Expand Down
Loading
Loading