I'm having trouble understanding the flow of state information between
client and server in general, and to and from pm_shared in particular.

There seem to be a number of routines that copy state from one place
to another.

On the server side (in client.cpp):

void UpdateClientData ( const struct edict_s *ent, int sendweapons,
struct clientdata_s *cd )

int AddToFullPack( struct entity_state_s *state, int e, edict_t *ent,
edict_t *host, int hostflags, int player, unsigned char *pSet )

(as well as obviously related routines like CreateBaseline)

And on the client (in entity.cpp):

HUD_ProcessPlayerState( struct entity_state_s *dst, const struct
entity_state_s *src )

void DLLEXPORT HUD_TxferPredictionData ( struct entity_state_s *ps,
const struct entity_state_s *pps, struct clientdata_s *pcd, const
struct clientdata_s *ppcd, struct weapon_data_s *wd, const struct
weapon_data_s *pwd )

In addition there are the entries in delta.lst for clientdata_t,
entity_state_t, and entity_state_player_t. Of course there also might
be others I have missed.

I need some idea of the relationship between these routines, and
between the fields of thier arguments and the fields of the
playermove_s structure that is passed to PM_Move. None of the routines
access a playermove_s structure directly, but several have arguments
with the some fields with the same names. Some have SEVERAL (in/out)
pairs of arguments with such fields. Which ones come from, or go to
the playermove_s?

Because PM_Move runs on both client and server, its persistant state
needs to be common between them. Which routine(s) is responsible for
copying persistant state on the client from one timestep to the next?
Which are required to for the server state to override the client
state when they don't agree? (It appears the the whole structure is
automatically persistant on the server.)

How should other parts of the dlls access values computed by PM_Move?
On the server, what fields get copied (or can be copied) to other
places? If the client needs to use a value computed by PM_Move, where
should this be read from to always use the latest value? To always use
the difinitive (server) value? The last value computed may not be the
latest in game time, because when a server update arives, the clock
can get set back.

I don't really expect ansewers to ALL these questions, but any hints
(in addition to the rather vague hints in the source coments) or
references would certianly help, both me and anyone else who needs to
make substatial changes to game physics.

Ralph Hartley

_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders

Reply via email to