Page 1 of 1

Health not an attribute

Posted: Sun Jan 18, 2015 7:00 pm
by arawra

Syntax: Select all

@Event        
def player_hurt(game_event):
attacker_userid = game_event.get_int('attacker')
victim_userid = game_event.get_int('userid')
damage = game_event.get_int('dmg_health')

attacker = dndPlayerDictionary[attacker_userid]
victim = dndPlayerDictionary[victim_userid]

tell(playerinfo_from_userid(attacker_userid), 'victim hp: %s'%victim.health)


Still not finding health as an attribute after updating from the Jan 17th release.

Top of \source-python\data\source-python\properties\player\csgo.ini

Code: Select all

[health]
prop = 'm_iHealth'
type = 'int'



E: Yeah looks like there were a lot of changes... doing a fresh install.
EE: After wiping csgo/addons/ and putting a fresh copy there, still same error. Windows x64

Posted: Sun Jan 18, 2015 7:21 pm
by satoon101
We don't use ../addons/source-python/data/source-python/properties/ anymore, and that directory has been removed. I thought I had added health to csgo, but I must not have committed that change. Just as in the ../entities/managers/engines/orangebox/CBaseEntity.ini, the same for the csgo engine should have health listed as a KeyValue. We will fix that up soon and add more to csgo's data files when we can get them tested.

Posted: Sun Jan 18, 2015 7:57 pm
by Hedgehog
I've also found that speed KeyValue in CS:S is always 0.0, so it would be better to overwrite it in property section of CBasePlayer.ini to

Syntax: Select all

localdata.m_flLaggedMovementValue = speed

Posted: Thu Feb 19, 2015 8:30 pm
by arawra
I think I'm seeing some updates for entities to include their data again. Not on my dev box. Anything missing that I should be aware of?

Posted: Thu Feb 19, 2015 8:40 pm
by satoon101
We haven't posted a new release since this topic was started. Those have been added, though, so the next release will include them.