'SetSchedule' (a nil value)

	if (CLEINT) then
    if what:IsNPC( ) then
        what:SetSchedule( SCHED_WAIT_FOR_SCRIPT )

Is the code

And this is the error

[ERROR] addons/spyciclenew/lua/weapons/tf2_spy-cicle/shared.lua:322: attempt to call method 'SetSchedule' (a nil value)
  1. MakeIce - addons/spyciclenew/lua/weapons/tf2_spy-cicle/shared.lua:322
   2. unknown - addons/spyciclenew/lua/weapons/tf2_spy-cicle/shared.lua:151

I only get this error when attacking on a server, and not singplayer, any advin

[lua]if (CLEINT) then[/lua]


show us all of the code, NPC:SetSchedule is a serverside only function, so I don’t know why you’re only trying to do it in the client state?

Lol Liam, you are still trying to run serverside functions clientside?
You should really test your stuff on srcds/multiplayer instead of singleplayer otherwise you’ll be having troubles like this and the ents.Create

Silly me, I set it to Server and it worked.
Now I get this error