Hi, ive heard some rumours that its possible to create a custom votes in silent mod without adding lua scripts or additional pk3 files, ive been searching a bit in wiki but coudnt find much info about it, anyone, I would need someone to assist me with making a +5 mins vote, thats the only 1 i need , anyone help? thanks
Posted 01 July 2014 - 05:16 PM
Posted 01 July 2014 - 05:30 PM
[customvote] name = The of the vote shown with the /callvote command. Maximum length 15 characters. exec = Command string to execute if the vote passes. Maximum length 1023 characters. description = Description of the vote shown with the /callvote command. Maximum length 1023 characters. votetext = The text that is show for voters. Maximum length 255 characters. passtext = Optionally, a text that is shown to players if the vote passes. levels = Optionally, admins can define the vote to be available to only specific levels. Same format that is used with the custom commands.
Goes in shrubbot.cfg just like you would do a command.
*Disclaimer I havent used yet so idk for sure.
Posted 01 July 2014 - 05:35 PM
name = +5mins
exec = ??
description = Add additional 5 minutes to current timelimit
votetext = Add 5 more minutes?
passtext = Vote passed
What should go in exec? And btw, is that vote then shown in when you click esc and go to votes, or you must call it in a diffrent way? thanks.
Posted 01 July 2014 - 10:46 PM
I havent really expieremented with this at all so I may have to be corrected.
But I dont think you could add just 5 minutes. You would need to set the timelimit to a specific number. (which obviously wouldnt be too handy)
I think if you want +5 mins on the clock you might want to make a lua console command to do so.
And to call this vote you would need to do /callvote addtime in the console or make a new menu pk3 with addtime in it.
The Vote in shrubbot:
[customvote] name = addtime exec = addtime description = Adds 5 minutes to the clock votetext = Add 5 minutes to the clock? passtext = 5 Minutes have been added to the clock levels =
You would need a lua file for this still (Which originally isnt what you wanted, But I dont think there is another way)
function et_ConsoleCommand( command ) if ( string.lower(command) == "addtime" ) then et.trap_Cvar_Set("timelimit",( et.trap_Cvar_Get("timelimit") + 5 ) ) end end
Not 100% that is correct lol. That is just how I interpreted it to be done.
Posted 02 July 2014 - 05:42 AM
Ok, thx for the effort zelly!
Posted 02 July 2014 - 09:06 AM
Yea I know about it, but I thought it could be done now without adding additional pk3s on server.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users