Game Development Community

OnClientEnterGame

by David Wilson · in Torque Game Engine · 01/01/2005 (6:59 pm) · 2 replies

In /server/scripts/game.cs -

There's "function GameConnection::onClientEnterGame(%this);

Can someone tell me how this gets run? I can't find it in the source code or being called form the script.

I thought maybe anything with "GameConnection::" would be run when the client connects, but I made a function GameConnection::onMeEnterGame with just an echo for the console, and apparently it didn't get run.

So how's the other one run?

Thanks
David

#1
01/01/2005 (11:40 pm)
Take a look in missiondownload.cs - once the client has acknowledged that its successfully downloaded the mission then this function get's called. ( see the function serverCmdMissionStartPhase3Ack).

It's probably worth getting something that can search through .cs files to find a given string - I use Visual Studio but there are loads of other dev environments that do the same thing. It's very useful when you're trying to figure out what's going on...
#2
01/02/2005 (4:06 am)
AhHA!

Thanks!