|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectvooga.engine.factory.LevelParser
vooga.examples.factory.LevelParserExample
public class LevelParserExample
This class provides full implementation for LevelParser. An example of how this could be used in a game is as follows: To understand the formatting of the XML file look at tutorialXML This ultimate purpose of the class is to turn an .xml file into a VoogaPlayField, which will contain all resources that constitute a level. This level, in the form of a VoogaPlayField, can be used to construct a GameState for the given level, which should handle rendering and updating of the level. In order to use your own specific sprites extend LevelParser and add a method named as the following process + Name of Specific Sprite and then define the fields in the xml file and use those attributes and create your sprite do what you need to the sprite and call the other methods needed for all sprites.
Nested Class Summary | |
---|---|
class |
LevelParserExample.MySprite
|
Field Summary |
---|
Fields inherited from class vooga.engine.factory.LevelParser |
---|
FIRST_IMAGE |
Constructor Summary | |
---|---|
LevelParserExample()
|
Method Summary | |
---|---|
LevelParserExample.MySprite |
processMySprite(org.w3c.dom.NamedNodeMap parameters)
|
Methods inherited from class vooga.engine.factory.LevelParser |
---|
getGame, getIncompletePlayfield, getOverlayTracker, getPlayfield, isElement, processBackgrounds, processSprite, processVisual |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LevelParserExample()
Method Detail |
---|
public LevelParserExample.MySprite processMySprite(org.w3c.dom.NamedNodeMap parameters)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |