So I know you can’t use PData clientside, so what I need to do is find a way to use my functions on the client. So here’s a function I created, ( and this is also the function I want to call on the client, through derma. )
local data = tostring( self:GetPData(“Username”) );
if ( data == nil ) then
ErrorNoHalt( "SOVIET - PMeta:GetUsername was called, but failed due to the field being nil.
And basically I need a way to call that function through a derma button, but I’m pretty sure I can’t call it directly because it has something to do with PData inside of it, how can I call it through my menu? A quick response would be great, thanks!
Here’s how I would need to call it,
if ( !GetUsername() == nil ) then – How would I call getusername here?
Initial_Menu = vgui.Create( “DFrame” )
Initial_Menu:SetPos( 50,50 )
Initial_Menu:SetSize( 1000, 900 )
Initial_Menu:SetTitle( “Soviet: Initial Creation” )
Initial_Menu:SetVisible( true )
Initial_Menu::SetBackgroundBlur( true )
Initial_Menu:SetDraggable( true )
Initial_Menu:ShowCloseButton( true )