General > Developers Corner

"Rock the guards" command for Jailbreak?

<< < (2/2)

JamminR:
Heck, I just realized you may not even need that loop... Gmod has a new team.GetPlayers command you're using that I've never seen before.
(It's been too long since I really looked into latest Gmod lua)
It seems to expect a number parameter though..not sure TEAM_GUARD returns a number. Likely does.
I also wouldn't call it outside the function. It would have old data (=nothing, when server starts, which is when it's run)

As for your question, I don't know.
I unfortunately don't have the time to refresh myself on what those two functions do in our code, nor the time to review your code.
There's no need to go adding variables to functions though. If those 2 commands only had 3 parameters in the original functions you copied, adding one more without knowing what you're doing won't magically make it do what you want.
Yes, in our original, we needed a target to perforum a vote function on. In yours, you don't need a target called from the ULX command, you only need it later if 'vote' = 'passed'.

I'd focus on what happens when the vote passes...that's where the magic takes place.

rocco1233:
I actually just removed line 60 and did what you said, and it worked! Thanks for your help. Locking topic.

JamminR:
Glad you got it working.
Update your original post with the code you're using, if you haven't already.
Might be helpful for someone else in the future.

Navigation

[0] Message Index

[*] Previous page

Go to full version