CSendProp pretty much broken - doesn't find any props.
Posted: Wed Aug 14, 2013 6:49 am
It seems CSendProp is broken. It doesn't find any property anymore, not even the most basic properties like
CBaseEntity.m_vecOrigin
CBasePlayer.m_iHealth
etc.
Btw, I suggest the message output function is changed somehow, right now it only shows the error messages if you put "developer 1" in console. Would be cool if it could throw an python exception instead, so you can actually tell where the error is coming from.
Edit: TestCase
CBaseEntity.m_vecOrigin
CBasePlayer.m_iHealth
etc.
Btw, I suggest the message output function is changed somehow, right now it only shows the error messages if you put "developer 1" in console. Would be cool if it could throw an python exception instead, so you can actually tell where the error is coming from.
Edit: TestCase
Syntax: Select all
def Test(av):
p = av['playerinfo']
e = p.get_edict()
prop = e.get_prop('CBasePlayer.m_iHealth')
print(prop.get_int())
import k2tools.cmdlib
def load():
k2tools.cmdlib.AdvancedCommandManager.register('test',
callback=(Test,),
log_pre_exec=True,
log_post_exec=True,
log_spam_protect=True,
server=True,
console=True,
)
def unload():
k2tools.cmdlib.AdvancedCommandManager.unregister('test')