My favorites
▼
|
Sign in
evolvemod
An advanced admin mod for Garry's Mod.
Project Home
Issues
Source
Export to GitHub
READ-ONLY: This project has been
archived
. For more information see
this post
.
Search
Search within:
All issues
Open issues
New issues
Issues to verify
for
Advanced search
Search tips
Subscriptions
Issue
23
attachment: sh_pw.lua
(1020 bytes)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/*-------------------------------------------------------------------------------------------------------------------------
Run a console command on the server
-------------------------------------------------------------------------------------------------------------------------*/
local PLUGIN = {}
PLUGIN.Title = "Password"
PLUGIN.Description = "Set the server password."
PLUGIN.Author = "Mr.Faul"
PLUGIN.ChatCommand = "pw"
PLUGIN.Usage = "<password>"
PLUGIN.Privileges = { "Password" }
function PLUGIN:Call( ply, args )
if ( ply:EV_HasPrivilege( "Password" ) ) then
if ( #args > 0 ) then
RunConsoleCommand( "sv_password",args[1] )
evolve:Notify( evolve.colors.blue, ply:Nick(), evolve.colors.white, " sets password to ", evolve.colors.red, args[1], evolve.colors.white, "." )
else
evolve:Notify( ply, evolve.colors.red, "No password specified." )
end
else
evolve:Notify( ply, evolve.colors.red, evolve.constants.notallowed )
end
end
evolve:RegisterPlugin( PLUGIN )
Powered by
Google Project Hosting