movement
index
/Users/hollis/Desktop/nakedmud/lib/pymodules/movement.py

movement.py
 
all of the functions concerned with movement and position change

 
Modules
       
hooks
inform
mud
mudsys

 
Functions
       
chk_can_move(ch, cmd)
chk_land(ch, cmd)
chk_sit(ch, cmd)
chk_sleep(ch, cmd)
chk_stand(ch, cmd)
chk_wake(ch, cmd)
cmd_move(ch, cmd, arg)
A basic movement command, relocating you to another room in the
specified direction.
cmd_sit(ch, cmd, arg)
If standing, attempts to sit on the ground.
cmd_sleep(ch, cmd, arg)
If awake, attempts to lay down and sleep.
cmd_stand(ch, cmd, arg)
If sitting, attempts to stand. If flying, attempts to land.
cmd_wake(ch, cmd, arg)
If sleep, attempts to wake up and sit.
dir_index(dir)
returns the index of the direction name
dir_opposite(dir)
returns the opposite direction of the specified one, or None if none.
try_change_pos(ch, pos)
this function attempts to change the position of the person
try_move(ch, dir, mssg=False)
Handles all moving of characters from one room to another, through
commands. Attempts a move. If successful, returns the exit left
through.
try_move_mssg(ch, dir)
Handles all moving of characters from one room to another, through
commands. Attempts a move. If successful, returns the exit left through.
Informs people of our moving
try_use_furniture(ch, obj, pos)
attempts to resituate a person on the piece of furniture

 
Data
        cmd = 'se'
dir_abbr = ['n', 'e', 's', 'w', 'ne', 'nw', 'sw', 'se', 'u', 'd']
dir_name = ['north', 'east', 'south', 'west', 'northeast', 'northwest', 'southwest', 'southeast', 'up', 'down']
dir_opp = [2, 3, 0, 1, 6, 7, 4, 5, 9, 8]
pos_act = ['collapse', 'sleep', 'sit', 'stand', 'fly']
positions = ['unconscious', 'sleeping', 'sitting', 'standing', 'flying']