Some more tests.
git-svn-id: svn://svn.code.sf.net/p/crossfire/code/maps/trunk@6057 282e977c-c81d-0410-88c4-b93c2d0d6712master
parent
0d98319f8e
commit
d136b2427b
|
@ -33,6 +33,8 @@ def do_help():
|
|||
whoami.Say(' - directory')
|
||||
whoami.Say(' - event')
|
||||
whoami.Say(' - light')
|
||||
whoami.Say(' - attacktype')
|
||||
whoami.Say(' - players')
|
||||
|
||||
def do_arch():
|
||||
archs = Crossfire.GetArchetypes()
|
||||
|
@ -320,6 +322,19 @@ def do_light():
|
|||
whoami.Map.ChangeLight(chg)
|
||||
whoami.Say('new light: %d'%whoami.Map.Light)
|
||||
|
||||
def do_attacktype():
|
||||
att = [ Crossfire.AttackType.FIRE, Crossfire.AttackType.COLD, Crossfire.AttackType.ELECTRICITY ]
|
||||
whoami.Say('Your attacktype are:')
|
||||
for at in att:
|
||||
if ( at & Crossfire.WhoIsActivator().AttackType == at):
|
||||
whoami.Say(Crossfire.AttackTypeName[ at ])
|
||||
|
||||
def do_players():
|
||||
players = Crossfire.GetPlayers()
|
||||
whoami.Say('Players logged in:')
|
||||
for pl in players:
|
||||
whoami.Say(' - %s'%pl.Name)
|
||||
|
||||
topic = Crossfire.WhatIsMessage().split()
|
||||
#whoami.Say('topic = %s'%topic)
|
||||
#whoami.Say('topic[0] = %s'%topic[0])
|
||||
|
@ -377,5 +392,9 @@ elif topic[0] == 'event':
|
|||
do_event()
|
||||
elif topic[0] == 'light':
|
||||
do_light()
|
||||
elif topic[0] == 'attacktype':
|
||||
do_attacktype()
|
||||
elif topic[0] == 'players':
|
||||
do_players()
|
||||
else:
|
||||
do_help()
|
||||
|
|
Loading…
Reference in New Issue