Raised This Month: $ Target: $400
 0% 

Cheat commands that require sv_cheats 1


Post New Thread Reply   
 
Thread Tools Display Modes
Author
EHG
Senior Member
Join Date: May 2009
Location: 127.0.0.1
Plugin ID:
1192
Plugin Version:
1.2
Plugin Category:
General Purpose
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    62 
    Plugin Description:
    Use commands that require sv_cheats 1 to be enabled server side
    Old 09-30-2009 , 12:02   Cheat commands that require sv_cheats 1
    Reply With Quote #1

    Description
    This plugin will allow admins with root access (feel free to edit the admin flag required) to use any command that requires sv_cheats including those commands that still don't work after removing their cheat flag.
    What this plugin does is quietly setting sv_cheats to 1, running the command, and then setting it back to 0 without ever sending sv_cheat activity to the client.
    However if a cheat command works by removing its cheat flag then that it is recommended to do so instead of using this.

    A nice plugin that removes the cheat flag for admins: http://forums.alliedmods.net/showthread.php?t=81101

    Certain commands like thirdperson will still not work using this method because they don't require server side cheats but instead require client side sv_cheats.
    For commands like thirdperson you can use the following plugin to send sv_cheats 1 to a client without altering server side sv_cheats:
    http://forums.alliedmods.net/showthread.php?t=92289


    Make a file called sm_cheat_cvars.cfg in your server's cfg folder. In L4D2 whenever sv_cheats is modified all cvars are reset. So if you have any custom values that you don't want to be reset after using this command then list them in that file. It is executed after running the command.
    note: you may have to use sm_cvar <cvar> for certain cvars, just like you would in server.cfg

    Something to keep in mind
    Changing the sv_cheats cvar resets cvars like sb_stop and sb_all_bot_team. Just something to keep in mind, it can mess with scripts that rely on certain cvars not being reset.
    A good example is the L4D2 Score/Team manager that relies on sb_all_bot_team being set to 1. Or my Round Start Bot Stop script relies on sb_stop being changed at certain times.
    Keep in mind that using this may have unwanted effects on scripts like that.

    Commands
    sm_cheat <command>

    Example
    sm_cheat ent_setname !picker sentry1


    Change log
    1.2
    Added a config to be executed after each usage of the command
    1.1 Altered code to allow usage for any command requiring sv_cheats
    1.0 First release
    Attached Files
    File Type: sp Get Plugin or Get Source (sm_cheat.sp - 8374 views - 1.2 KB)

    Last edited by EHG; 05-12-2010 at 15:30. Reason: Update
    EHG is offline
    Maxis010
    Senior Member
    Join Date: Jun 2009
    Old 09-30-2009 , 12:10   Re: ent_fire command without sv_cheats 1
    Reply With Quote #2

    Quote:
    Originally Posted by EHG View Post
    Description
    Allows admins with root access to use the ent_fire command without sv_cheats set to 1.

    Commands
    sm_ent_fire <command>


    Sourcemod moderators: Can you correct that Plugin Game: Counter-Strike: source to say Any
    Not knocking your work but this is already part of FuncommandsX

    P.S Edit your post, then click Go Advanced and you can change your plugin details including the Plugin Game
    Maxis010 is offline
    EHG
    Senior Member
    Join Date: May 2009
    Location: 127.0.0.1
    Old 09-30-2009 , 15:32   Re: ent_fire command without sv_cheats 1
    Reply With Quote #3

    FuncommandsX does not include usage of ent_fire without sv_cheats 1.
    Maybe you are thinking of an explode command or actual fire?
    ent_fire is a developer tool to set information on a specific entity ingame.
    EHG is offline
    Maxis010
    Senior Member
    Join Date: Jun 2009
    Old 09-30-2009 , 15:51   Re: ent_fire command without sv_cheats 1
    Reply With Quote #4

    Quote:
    Originally Posted by EHG View Post
    FuncommandsX does not include usage of ent_fire without sv_cheats 1.
    Maybe you are thinking of an explode command or actual fire?
    ent_fire is a developer tool to set information on a specific entity ingame.
    Your right, ignore me, went back and checked my scripting folder, found what I was thinking of and compared that code to your's
    Maxis010 is offline
    olj
    Veteran Member
    Join Date: Jun 2009
    Old 10-03-2009 , 05:59   Re: ent commands without sv_cheats 1
    Reply With Quote #5

    Can we use this for any commands? Like "boom" command for l4d? Stripping of cheats flag doesnt work there.
    __________________
    olj is offline
    noodleboy347
    AlliedModders Donor
    Join Date: Mar 2009
    Old 10-03-2009 , 16:15   Re: ent commands without sv_cheats 1
    Reply With Quote #6

    Can you do ent_remove that doesn't crash the server when a player is deleted?
    noodleboy347 is offline
    EHG
    Senior Member
    Join Date: May 2009
    Location: 127.0.0.1
    Old 10-05-2009 , 02:39   Re: Cheat commands without sv_cheats 1
    Reply With Quote #7

    I have updated the plugin to allow usage with any command.

    noodleboy347:
    search around for something called l4d build enabler, if I remember correctly it includes code that blocks the ent_remove command from being used on important objects like players and saferoom doors..etc
    EHG is offline
    Frus
    Senior Member
    Join Date: Aug 2009
    Old 10-05-2009 , 03:21   Re: Cheat commands without sv_cheats 1
    Reply With Quote #8

    Could you add a feature to allow you to specify which client executes the command? So an admin could force any client to execute a cheat command.
    Frus is offline
    Dragonshadow
    BANNED
    Join Date: Jun 2008
    Old 10-05-2009 , 13:32   Re: Cheat commands without sv_cheats 1
    Reply With Quote #9

    since it silently sets it to 1 you can't use this with KAC can you?
    Dragonshadow is offline
    EHG
    Senior Member
    Join Date: May 2009
    Location: 127.0.0.1
    Old 10-06-2009 , 00:39   Re: Cheat commands without sv_cheats 1
    Reply With Quote #10

    This plugin sets sv_cheats 1 server side.
    sv_cheats 1 is never sent to the client.
    Unless I am mistaken KAC only checks clients that modify their sv_cheats client side.
    EHG is offline
    Reply


    Thread Tools
    Display Modes

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 11:55.


    Powered by vBulletin®
    Copyright ©2000 - 2024, vBulletin Solutions, Inc.
    Theme made by Freecode