comparison src/parpg/components/container.py @ 41:74f09d6417f4

Backed out changeset: 799fc37fec6d
author KarstenBock@gmx.net
date Wed, 10 Aug 2011 21:08:14 +0200
parents 799fc37fec6d
children 1cc037593517
comparison
equal deleted inserted replaced
40:be9a0e9e3ac2 41:74f09d6417f4
18 Component that allows an entity to contain one or more child entities. 18 Component that allows an entity to contain one or more child entities.
19 """ 19 """
20 20
21 def __init__(self): 21 def __init__(self):
22 Component.__init__(children=list, max_bulk=int) 22 Component.__init__(children=list, max_bulk=int)
23
24 def get_bulk(container):
25 bulk = 0
26 for child in container.children:
27 bulk += child.bulk
28 return bulk