--
[ Picked text/plain from multipart/alternative ]
I have a couple of issues arrising with our weapons using the From Scratch
SDK. The structure of the weapons is similar to the HL2 ones in that they
are taken from the SDK Base weapon, into sub classes then the acctual
weapons are derived from these. One of the issues I am having is that the
Predicted information will not appear in cl_pdump, which makes it tougher to
debug visually. Has anyone one run accross this or has knowledge of how to
add something to the cl_pdump display? Secondally, I've added another class
derived from our derived classes, it runs fine, but it the predicted
variables seem to get out of sync and this ends up creating massive issues.
It seems to be setup properly, it's in the send table, in the prediction
table, just as every other weapon has it set up, ie. BaseCombat weapon all
the way down to our own classes. Then in the weapons code it is handled by
the item post from, pretty much like this
if( !m_bInSpecial )
{
//Shooting and stuff is handled here
}
if( pPlayer->m_afButtonPressed & IN_SPECIAL )
{
if( m_flNextPrimaryAttack <= gpGlobals->curtime )
{
m_bInSpecial = !m_bInSpecial;
//Handles animations and such
m_flNextPrimaryAttack = m_flNextSecondaryAttack = gpGlobals.curtime +
animationLength;
}
}
It seems simple enough, and follows the structure of all other weapon calls,
shooting, reloading etc, but at some point the server and client fall out of
sync, and m_bInSpecial will be true on one side and false on the other. For
some reason they won't sync up with each other either, even if you keep
switching in and out of special it will always be the opposite, it's as
though the server isn't even sending the value to the client, or the client
thinks that being the exact logical opposite falls inside tollerances. A
situation where cl_pdump would be handy.
If anyone has any insights that might help out I'd greatly appreciate it.
Thanks
--
_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders