Home | Trees | Index | Help |
---|
|
object
--+
|
Level
Method Summary | |
---|---|
__init__(self,
name)
| |
__getstate__(self)
| |
__setstate__(self,
state)
| |
Add a new body to the level. | |
Add a new entity to the level. | |
Add a new sprite to the level. | |
agents_in_rect(self,
rect)
| |
attach(self,
display_engine,
physics_engine)
| |
attach_display(self,
display_engine)
| |
attach_physics(self,
physics_engine)
| |
bodies(self)
| |
bodies_intersecting_point(self,
x,
y,
include_nonsolids)
| |
bodies_intersecting_rect(self,
rect,
include_nonsolids)
| |
detach(self)
| |
detach_display(self)
| |
detach_physics(self)
| |
Return a list of all entities in this level. | |
entities_in_rect(self,
rect)
| |
Record the fact that the player has explored the given area of the level (so fog should be removed from that area). | |
Return a list of rects, indicating what areas the player has explored. | |
find_walker_path(self,
walker,
endx,
endy)
| |
load(levelname,
dir)
(Static method) | |
Remove a body from the level. | |
remove_entity(self,
entity)
| |
Remove a sprite from the level. | |
save(self,
levelname,
dir)
| |
scripts(self)
| |
update_path_planners(self)
| |
_set_bg(self,
val)
| |
Inherited from object | |
x.__delattr__('name') <==> del x.name | |
x.__getattribute__('name') <==> x.name | |
Return hash(x)... | |
Return a new object with type S, a subtype of T... | |
helper for pickle | |
helper for pickle | |
Return repr(x)... | |
x.__setattr__('name', value) <==> x.name = value | |
Return str(x)... |
Property Summary | |
---|---|
background : The name of the level's background image file. |
Instance Variable Summary | |
---|---|
walker_path_planner : A path planner used by walkers to navigate the level. |
Class Variable Summary | |
---|---|
int |
EXPLORE_TILESIZE = 100 |
int |
PICKLE_PROTOCOL = -1 |
bool |
reset_scripts_to_default = True
|
Instance Method Details |
---|
__init__(self,
name=None)
|
__getstate__(self) |
__setstate__(self, state) |
add_body(self, body)Add a new body to the level. A new body should only be added by the entity that owns it.
|
add_entity(self, entity)Add a new entity to the level. |
add_sprite(self, owner, sprite)Add a new sprite to the level. A new sprite should only be added by the entity that owns it.
|
agents_in_rect(self, rect) |
attach(self, display_engine, physics_engine) |
attach_display(self, display_engine) |
attach_physics(self, physics_engine) |
bodies(self) |
bodies_intersecting_point(self, x, y, include_nonsolids=True) |
bodies_intersecting_rect(self, rect, include_nonsolids=True) |
detach(self) |
detach_display(self) |
detach_physics(self) |
entities(self)Return a list of all entities in this level. |
entities_in_rect(self, rect) |
explore(self, rect)Record the fact that the player has explored the given area of the level (so fog should be removed from that area). |
explored_areas(self)Return a list of rects, indicating what areas the player has explored. |
find_walker_path(self, walker, endx, endy) |
remove_body(self, body)Remove a body from the level. A Body should only be removed by the entity that owns it.
|
remove_entity(self, entity) |
remove_sprite(self, owner, sprite)Remove a sprite from the level. A Sprite should only be removed by the entity that owns it.
|
save(self, levelname, dir='levels') |
scripts(self) |
update_path_planners(self) |
_set_bg(self, val) |
Static Method Details |
---|
load(levelname, dir='levels') |
Property Details |
---|
backgroundThe name of the level's background image file.
|
Instance Variable Details |
---|
walker_path_plannerA path planner used by walkers to navigate the level. |
Class Variable Details |
---|
EXPLORE_TILESIZE
|
PICKLE_PROTOCOL
|
reset_scripts_to_default
|
Home | Trees | Index | Help |
---|
Generated by Epydoc 2.1 on Thu Sep 22 22:52:43 2005 | http://epydoc.sf.net |