Problems respawning in Sandbox derived gamemode

I’m having problems after respawning in my gamemode.
The view seems to twitch up and down, and when walking around there is a noticeable delay.

You can sort of see it in this video, as I’m walking towards the door: http://www.xfire.com/video/12f34a/

Can anyone help?

do u use an custom camara?

Are there ANY errors when the game launches? How are you testing the game, locally, or on a dedicated server? Need more than that for info.

Sorry, only errors are about resource.addfile’s. This is on a srcds running on my local machine.

Spawn function is:

[lua]
function GM:PlayerSpawn(ply)
GAMEMODE:SetPlayer(ply, ply:Team())
end

The initial spawn is fine, no problems, this is only after you respawn.

That doesn’t appear to be a valid Gamemode Hook(SetPlayer). What were you planning to do with it?

I don’t know why… but that kind of looked like lag (maybe) to me. You said your not getting any errors right?

Huh? That has nothing to do with hooking, it could just be a gamemode function he wrote. It it didn’t exists he would get errors every spawn.

I did see ‘You are now in build model’ and ‘You are now in roleplay model’ spammed in the chat, could have something to do with it.

Yes, but seeing as he hasn’t added self.BaseClass:PlayerSpawn(ply), which means that the player will not spawn. If he spawns fine the first time, that’s probably because he’s spawning in PlayerInitialSpawn.

I’m curious what SetPlayer does, just to make sure he’s spawning properly.

This is because 2 brushes were to close to each other, sorted now.

SetPlayer just sets some vars like allowing noclipping and setting team, an extension of PlayerSpawn really.
self.BaseClass:PlayerSpawn(ply) sorted it, thanks very much.