affects
index
/home/thindil/Projekty/anaria/server/lib/pymodules/affects.py

affects.py
 
Items which give bonuses to stats or skills.

 
Modules
       
auxiliary
hooks
mudsys
olc
random
storage
utils

 
Classes
       
AffectData
AffectsData

 
class AffectData
    Data for affects for items.
 
  Methods defined here:
__init__(self, set=None)
Standard class constructor.
copy(self)
copyTo(self, to)
store(self)

Data and other attributes defined here:
__item_type__ = 'affect'

 
class AffectsData
    Data for affects for chars.
 
  Methods defined here:
__init__(self, set=None)
Standard class constructor.
copy(self)
copyTo(self, to)
store(self)

 
Functions
       
__unload__()
remove all hooks.
affect_desc_info(info)
appends informactions about bonuses from an object to the description
buffer when person looks at it.
affect_equip_hook(info)
add bonus to stats/skills when we wearing new equipment.
affect_unequip_hook(info)
remove bonus to stats/skills when we remove equipment.
affectolc_chooser(sock, data, option)
figure out what we want to edit and display a prompt.
affectolc_menu(sock, data)
display our menu interface.
affectolc_parser(sock, data, choice, arg)
parse out what we want to change a specified field to.
affectolc_to_proto(data)
return a script that will generate relevant info to create this item.
cmd_affects(ch, cmd, arg)
Usage: wplywy
 
Show informations about current affects on character.
generate_affect(self, afftype, maxval=5, onlyname=False, prefix=[], suffix=[])
Generate random affect on object. If onlyname is set on True, generate only
name of stat/skill on which item affect. Prefix and suffix must have that same
amount of elements and in this same order like affect type. At this moment, for
stats is 4.

 
Data
        __AFFECTOLC_NAME__ = 2
__AFFECTOLC_TYPE__ = 1
__AFFECTOLC_VALUE__ = 3
affect_types = {'cechy': ['Si\xc5\x82a', 'Zr\xc4\x99czno\xc5\x9b\xc4\x87', 'Inteligencja', 'Kondycja'], 'umiej\xc4\x99tno\xc5\x9bci': []}
affectolc_opt_map = {'1': (1, 'Wybierz typ: '), '2': (2, 'Wprowad\xc5\xba nazw\xc4\x99 cechy/umiej\xc4\x99tno\xc5\x9bci: '), '3': (3, 'Wprowad\xc5\xba wysoko\xc5\x9b\xc4\x87 premii: ')}