• VGUI menu refuses to appear.
    4 replies, posted
My friend posted about this yesterday but because he didn't exactly give out the details and was boxed into oblivion, I thought I would post instead. Basically he wants me to create this voice menu by incorporating it into a seperate weapon (God knows why) because he broke the voice commands in DarkRP. The menu is fine, no lua errors, but it refuses to appear. The function I'm assuming doesn't run because vgui functions are clientside. However I'm not sure how to execute them from a weapon. [code]function SWEP:SecondaryAttack() if CLIENT then self:combineHelp() end end[/code] The function since it's too long for a post: [url]https://dl.dropboxusercontent.com/u/73775541/code2.txt[/url]
-snip- I'm dumb, sorry. But I think that it doesn't work because CombineHelp isn't clientsided. Just add if CLIENT then before making the function.
I believe you are testing it in singleplayer, and the thing is, most SWEP functions are not called clientside in singleplayer.
[QUOTE=Robotboy655;43886279]I believe you are testing it in singleplayer, and the thing is, most SWEP functions are not called clientside in singleplayer.[/QUOTE] this will end up being used on a multiplayer server
[QUOTE=Robotboy655;43886279]I believe you are testing it in singleplayer, and the thing is, most SWEP functions are not called clientside in singleplayer.[/QUOTE]That worked! I had no idea that would have some sort of effect. This'll help in the long run, thank you so much.
Sorry, you need to Log In to post a reply to this thread.