Hi there,
Been a while since I was active on here.. looking for some really small and simple plugin for Oxide 2, but no clue how to do it myself.
Basically what I want is a plugin that executes a specific console command after the server is completely started (can do this with a timer too..) and then another command after X seconds. That's all.
Would anyone be able to provide the required code for the plugin?
Thanks!
Solved Automatic commands
Discussion in 'Plugin Requests' started by iScripters, Jan 12, 2015.
-
Wulf Community Admin
As far as I know, there is no way to issue server commands from a plugin yet with Experimental.
-
-
Wulf Community Admin
-
-
Thanks for the replies! I've had this working on sauerkraut earlier (Yeah I know, not the same as Oxide) with a Python script, thought it might be possible with Lua too.
Thanks anyway -
-
Wulf Community Admin
-
Maybe BasePlayer:SendConsoleCommand("chat.say \"/command\" \"arg1\" \"arg2\" ")
I think it should work. I'm not sure this is something that should be...
And we can run the commands from the first player , who came to the serverLast edited by a moderator: Jan 12, 2015 -
Which commands would you want to execute?
-
-
Wulf Community Admin
Code:player:SendConsoleCommand("global.quit") global.ConsoleSystem.Run("global.quit", false) global.Application.Quit(nil) BasePlayer:SendConsoleCommand("global.quit")
-
-
Wulf Community Admin
-
Can't you run the commands by using ConsoleSystem.ClientRun(String command, bool sendToServer, bool WantsFeedback)
-
Wulf Community Admin
-
-
Wulf Community Admin
Edit: Nevermind... apparently server.stop and global.stop already exist, so they couldn't register.
[DOUBLEPOST=1421097801][/DOUBLEPOST]Looks like I'll be porting my Auto Commands plugin to Experimental now then. Thanks @Mughisi. -
SendConsoleCommands not working for me too :c
Need to use: arg.cmd.Call(arg)
But I do not know how to make it work in a Lua .-. (System.Action) -
Wulf Community Admin