Player::initPersistFields not exposed on client
by Ian Omroth Hardingham · in Torque Game Engine · 07/17/2008 (2:25 am) · 4 replies
Hey guys.
In my Player::initPersistFields I have a load of exposed members, but none of them are available on the client. Is there a switch I can throw to allow it? I'm bored of having to write set/get consoleMethods.
Ian
In my Player::initPersistFields I have a load of exposed members, but none of them are available on the client. Is there a switch I can throw to allow it? I'm bored of having to write set/get consoleMethods.
Ian
About the author
Designer and lead programmer on Frozen Synapse, Frozen Endzone, and Determinance. Co-owner of Mode 7 Games.
#2
That's not the problem - the values are fine on the client. But if I reference:
%serverObject.field
it works fine, but on the client:
%clientObject.field
is null. It's not a reference problem, %clientObject.method() works fine.
Ian
07/17/2008 (3:16 am)
Hey Peter.That's not the problem - the values are fine on the client. But if I reference:
%serverObject.field
it works fine, but on the client:
%clientObject.field
is null. It's not a reference problem, %clientObject.method() works fine.
Ian
#3
%clientObject.field
is returning null? Sounds like you are not sending the values to the client, are you using packUpdate/unpackUpdate on the variables?
07/17/2008 (3:57 am)
I'm a little confused, you say the values are fine on the client, but %clientObject.field
is returning null? Sounds like you are not sending the values to the client, are you using packUpdate/unpackUpdate on the variables?
#4
I've checked again, and I think this is a transmission problem, but not the kind I thought.
I've been trying to set field values on the client, and they haven't been being set. Your questioning led me to realise that that is of course because they're getting overwritten by the update from the server. I actually thought that they weren't exposed on the client at all.
Thanks again ;)
Ian
07/17/2008 (4:10 am)
Hey Peter.I've checked again, and I think this is a transmission problem, but not the kind I thought.
I've been trying to set field values on the client, and they haven't been being set. Your questioning led me to realise that that is of course because they're getting overwritten by the update from the server. I actually thought that they weren't exposed on the client at all.
Thanks again ;)
Ian
Torque 3D Owner Peter Simard
Default Studio Name