Houses are one of the easiest things to add to the game. To add a house the image is added to
libs/otherlib/images/ --- as a standard please use the background folder but it is not required.
the xml is located at
libs/otherlib/xml/housing/house1.xml
More house files can be added but not much point since they are small xml blocks just add them to
libs/otherlib/xml/housing/housefiles.xml
Okay so that's the basics. Now lets look at the xml, remember that the greater then and less then tags are removed do to html concerns on the blog.
Tags are pretty straight forward
name = "Onsen House" --- Name of the house.
price = "500" --- Price of the house.
file = "background/houseonsen.jpg" --- Where the image for the house is located.
room = "6" --- Number of STARTING rooms.
roommax = "6" --- Max number of rooms after expansion.
master = "1" --- Number of STARTING master bedrooms.
mastermax = "2" --- Max number of master bedrooms.
description = "An inn converted into the house on the edge of the green. Has large baths." --- Flavor Text
defaultroom = "empty room" --- When they house is purchased the rooms are set to this as default. EXCEPT for the required room that will be in the first slot and so on depending on the number of required rooms.
The following can be used multiple times as necessary.
required name = "onsen" --- This room is required to the house it comes with it and can not be removed.
restricted name = "dark room" --- This room can never be added to the house.
That's it pretty simple, I think adding a house is fast and fun.
Daisy
Well done. I think you built an efficient system here.
ReplyDelete