• Print

Author Topic: Trouble in Terrorist Town Commands for ULX  (Read 78682 times)

0 Members and 1 Guest are viewing this topic.

Offline bender180

  • Full Member
  • ***
  • Posts: 217
  • Karma: 42
    • Benders Villa
Trouble in Terrorist Town Commands for ULX
« on: July 16, 2014, 08:27:02 pm »
Trouble in Terrorist Town Commands for ULX

The Return
I'm back with more free time and a want to work on these again you can find the original thread here.

The Legacy
This addon WAS a joint effort from Bender180 and Skillz to bring you the best ulx commands for ttt possible, I do not believe skillz will be returning with me as i think he is still busy with other projects, but he still deserves credit for all the hard work he did here.

What I need:
I've been away from TTT for a while (just started getting back into it), I need suggestions. What do you want to see added to these commands, what will benefit your server?

Anyway here are the commands,

The Commands

Admin Commands
    Respawning Commands
    • ulx respawn <player> - Respawns target player while un-identifying the corpse and removing it, the command will also check for credits left of the body (if any) and respawn the player with them. has silent echos opposite
    • ulx respawntp <player> - Respawns the target player at the location the admin is looking.
    Role Forcing
    • ulx force <player> <pram> Prams: innocent, traitor detective - Changes target players role to the pram specified and gives the appropriate amount of credits. has silent echos opposite
    • ulx forcenr <player> <pram> Prams: traitor detective, unmark - carries out the action specified in the following round to next round force traitor/detective the group must have permission to ulx force. Echos silently
    AFK Players
    • ulx fspec <player> - forces the target player into the afk mode similar to how the gamemode would.
    • ulx unafk <player> - forces the target player back into player mode (opposite to the afk command.)
    Misc
    • ulx karma <player> <value> - changes target players karma to the specified value.
    • ulx slaynr <player> <amount> - carries out the set amount of slays at every round start
    • ulx identify/ ulx unidentify<player> - Identifies or identifies a players corpse (Thanks Neku)
    • ulx removebody <player> - Removes a players corpse (Thanks Neku)
    • ulx impairnr <player> <amount> - Impairs a players health by given amount the next round (Thanks Decicus)
    • ulx roundrestart - Restarts the current round.

    Fun Commands
    • ulx credits <player> <value> - gives specified value of credits to the target player.

    Voting Commands
    • ulx votenrs <player> - Triggers a vote to slay the player the following round.
    • ulx votefs <player> - Triggers a vote to force a player to spectator mode.

    Next Update
    • Any Ideas?

    Download
    Screenshots






    « Last Edit: September 17, 2014, 03:38:59 pm by bender180 »
    Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
    Also made the ttt ulx commands.

    Offline Neku

    • Hero Member
    • *****
    • Posts: 549
    • Karma: 27
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #1 on: July 16, 2014, 08:51:32 pm »
    Respaning Commands

    Just thought you should know that.
    But I remember seeing something within the code from the original post relating to identifying bodies.
    Out of the Garry's Mod business.

    Offline Neku

    • Hero Member
    • *****
    • Posts: 549
    • Karma: 27
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #2 on: July 18, 2014, 03:03:52 am »
    Code: Lua
    1. function ulx.identify( calling_ply, target_ply, unidentify )
    2.         body = corpse_find( target_ply )
    3.         if not body then ULib.tsayError( calling_ply, "This player's corpse does not exist!", true ) return end
    4.  
    5.         if not unidentify then
    6.                 ulx.fancyLogAdmin( calling_ply, "#A identified #T's body!", target_ply )
    7.                 corpse_identify( body )
    8.         else
    9.                 ulx.fancyLogAdmin( calling_ply, "#A unidentified #T's body!", target_ply )
    10.                 CORPSE.SetFound( body, false )
    11.         end
    12. end
    13. local identify = ulx.command( CATEGORY_NAME, "ulx identify", ulx.identify, "!identify")
    14. identify:addParam{ type=ULib.cmds.PlayerArg }
    15. identify:addParam{ type=ULib.cmds.BoolArg, invisible=true }
    16. identify:defaultAccess( ULib.ACCESS_SUPERADMIN )
    17. identify:setOpposite( "ulx unidentify", {_, _, true}, "!unidentify", true )
    18. identify:help( "Identifies a target's body." )
    19.  
    20. function ulx.removebody( calling_ply, target_ply )
    21.         body = corpse_find( target_ply )
    22.         if not body then ULib.tsayError( calling_ply, "This player's corpse does not exist!", true ) return end
    23.         ulx.fancyLogAdmin( calling_ply, "#A removed #T's body!", target_ply )
    24.         if string.find( body:GetModel(), "zm_", 6, true ) then
    25.                 body:Remove()
    26.         elseif body.player_ragdoll then
    27.                 body:Remove()
    28.         end
    29. end
    30. local removebody = ulx.command( CATEGORY_NAME, "ulx removebody", ulx.removebody, "!removebody")
    31. removebody:addParam{ type=ULib.cmds.PlayerArg }
    32. removebody:defaultAccess( ULib.ACCESS_SUPERADMIN )
    33. removebody:help( "Removes a target's body." )
    34.  

    I think this would be a nice addition to your addon, I made it specifically so it can just be pasted right onto ttt_admin.lua. Or at least the old one.

    Although, I haven't tested it, I was hoping you'd be able to.
    Out of the Garry's Mod business.

    Offline Decicus

    • Hero Member
    • *****
    • Posts: 552
    • Karma: 81
      • Alex Thomassen
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #3 on: July 18, 2014, 05:11:20 pm »
    "Slap Next Round" would be nice in this addon. I already have one in my command package, but having it in this would be a lot easier for other server owners.

    Feel free to use my code if you want, you have my full permission.
    Contact information:
    E-mail: alex@thomassen.xyz.
    You can also send a PM.

    Offline bender180

    • Full Member
    • ***
    • Posts: 217
    • Karma: 42
      • Benders Villa
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #4 on: July 18, 2014, 08:25:37 pm »
    Your slapnr is basicly just a way to impare their health for the next round is what I'm seeing, I could see that being useful I will use the idea seen as you offered so nicely :) I may change the code a little though. 

    One idea I've had for awhile is having a tab in xgui to change the ttt variables just like how it has the sbox server variables but I haven't ever touched derma and I have no clue how to tie into xgui maybe stickly man could point me in the right direction.
    Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
    Also made the ttt ulx commands.

    Offline Decicus

    • Hero Member
    • *****
    • Posts: 552
    • Karma: 81
      • Alex Thomassen
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #5 on: July 19, 2014, 05:43:23 am »
    Your slapnr is basicly just a way to impare their health for the next round is what I'm seeing, I could see that being useful I will use the idea seen as you offered so nicely :) I may change the code a little though.

    Do whatever you feel fits, it was just a suggestion.
    Contact information:
    E-mail: alex@thomassen.xyz.
    You can also send a PM.

    Offline bender180

    • Full Member
    • ***
    • Posts: 217
    • Karma: 42
      • Benders Villa
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #6 on: July 19, 2014, 07:04:17 am »
    Do whatever you feel fits, it was just a suggestion.

    Sorry if I came across rude, I wrote that half asleep last night, but yes i think slapnr would make a great addition thanks for the suggestion.
    Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
    Also made the ttt ulx commands.

    Offline bender180

    • Full Member
    • ***
    • Posts: 217
    • Karma: 42
      • Benders Villa
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #7 on: July 21, 2014, 06:16:07 pm »
    New update with some fixes

    Fixed typo with gamemode error

    Added gamemode error to commands missing it

    Fixed an issue with Tommynator's 's damage log

    Fixed Respawn Commands still showing player as a T after respawn

    Fix for identify command not showiung a player as a T in scoreboard (will throw server error for not having a "real" player id the corpse.)(fixed)
    « Last Edit: July 21, 2014, 08:00:37 pm by bender180 »
    Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
    Also made the ttt ulx commands.

    Offline Hollistupid

    • Newbie
    • *
    • Posts: 15
    • Karma: 0
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #8 on: July 25, 2014, 07:11:09 am »
    Hey bender, great to see you back and LOVE your addon. Anyways, when you were gone I had coder edit your ttt_admin to fix a bug where when a player was designated to be slain the next round and the map switched, they would be slain but still show up as alive on the scoreboard, however he created a workaround that works flawlessly and even added an optional reason for slaying.  I bought the rights completely so if you want to use this in your official release it would be great!

    slaynr command edited
    http://pastebin.com/HWsc1skT

    Offline Neku

    • Hero Member
    • *****
    • Posts: 549
    • Karma: 27
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #9 on: July 25, 2014, 12:41:47 pm »
    Hey bender, great to see you back and LOVE your addon. Anyways, when you were gone I had coder edit your ttt_admin to fix a bug where when a player was designated to be slain the next round and the map switched, they would be slain but still show up as alive on the scoreboard, however he created a workaround that works flawlessly and even added an optional reason for slaying.  I bought the rights completely so if you want to use this in your official release it would be great!

    slaynr command edited
    http://pastebin.com/HWsc1skT

    You bought the rights to something he didn't really make?


    Out of the Garry's Mod business.

    Offline bender180

    • Full Member
    • ***
    • Posts: 217
    • Karma: 42
      • Benders Villa
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #10 on: July 25, 2014, 04:58:45 pm »
    For the reason addition all the scripter did was uncomment a line i had written, I had bigger plans for the reason side of slaynr but nerver got around to finishing it. ;)

    As for the other issue that was fixed in an update earlier this week :) as well as an issue that effected tommnators damage log.

    Thanks for the support though its what made me start working on these again.  :-*
    Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
    Also made the ttt ulx commands.

    Offline Hollistupid

    • Newbie
    • *
    • Posts: 15
    • Karma: 0
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #11 on: July 25, 2014, 06:40:28 pm »
    You bought the rights to something he didn't really make?



    Hired someone to fix an annoying problem the original creator could not fix since he was not here.

    Offline bender180

    • Full Member
    • ***
    • Posts: 217
    • Karma: 42
      • Benders Villa
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #12 on: July 27, 2014, 12:21:15 pm »
    New update!

    Fixed the LOOOOONNNG standing bug with respawning a player where it would say "User is already alive!" when they were really just a spectator.
    Improvement to SlayNr
    Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
    Also made the ttt ulx commands.

    Offline Decicus

    • Hero Member
    • *****
    • Posts: 552
    • Karma: 81
      • Alex Thomassen
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #13 on: July 27, 2014, 12:41:45 pm »
    Love the new updates, Bender. Keep up the work!
    Contact information:
    E-mail: alex@thomassen.xyz.
    You can also send a PM.

    Offline bender180

    • Full Member
    • ***
    • Posts: 217
    • Karma: 42
      • Benders Villa
    Re: Trouble in Terrorist Town Commands for ULX
    « Reply #14 on: September 15, 2014, 07:26:28 pm »
    Just wanted to show what i've been working on this last little while, vgui/xgui has been a learning curve but after a few days and a 7 hour push today i'm finally at a point where I feel it's almost done.

    I've sorted out the cvars just like bad king has on his website.



    I'm hoping to release this in an update later this week, as always feedback is more then welcome.
    « Last Edit: September 15, 2014, 07:43:59 pm by bender180 »
    Made community pool and community bowling and for the life of me couldn't tell you why they are popular.
    Also made the ttt ulx commands.

    • Print