def testGetmaxplayers(self): j = es.getmaxplayercount() self.failUnless(j) # in CS:S we know the max players is cs_team_manager index -1 if es.getgame() == "Counter-Strike: Source": q = es.getentityindex('cs_team_manager') - 1 if q: self.failUnless(q==j)
def testGetmaxplayers(self): j = es.getmaxplayercount() self.failUnless(j) # in CS:S we know the max players is cs_team_manager index -1 if es.getgame() == "Counter-Strike: Source": q = es.getentityindex('cs_team_manager') - 1 if q: self.failUnless(q == j)
def siteCheck(): bombsitesNum.clear() managerindex = es.getentityindex('cs_player_manager') if managerindex > 0: index = getSiteIndex(vecmath.vector(es.getindexprop(managerindex, 'CCSPlayerResource.m_bombsiteCenterA'))) if index: bombsitesNum['A'] = index index = getSiteIndex(vecmath.vector(es.getindexprop(managerindex, 'CCSPlayerResource.m_bombsiteCenterB'))) if index: bombsitesNum['B'] = index
def siteCheck(): bombsitesNum.clear() managerindex = es.getentityindex('cs_player_manager') if managerindex > 0: index = getSiteIndex( vecmath.vector( es.getindexprop(managerindex, 'CCSPlayerResource.m_bombsiteCenterA'))) if index: bombsitesNum['A'] = index index = getSiteIndex( vecmath.vector( es.getindexprop(managerindex, 'CCSPlayerResource.m_bombsiteCenterB'))) if index: bombsitesNum['B'] = index
def getentityindex(argv): sv[argv[0]] = es.getentityindex(*argv[1:])
def func_entityindex(args): temp = '0' temp = str(es.getentityindex(args[0])) return temp