Looping many DraggedComntainers
  • I am creating an object.lua and layout for just creating every object in the game that can be put ino tht inventory etc. How can I put a for loop in xml so I can create about a thousand items and then 'for loop' through them in the lua script to add the real names etc. I am just learning XML as well. I do have some experience with Smarty Templates but this is a little different.
  • The way we want to do it is with a custom C++ class, an EntityIconManager. Instead of doing the record keeping and creation of it all in lua, this class will be responsible for taking care of all that. It should then have a very simple interface for the gui to use, such as
    EntityIconManager.getSingleton()::getIcon("settler", "medium")
    which would then return a CEGUI Texture ready to use.

    I haven't written this class yet though, but write your lua code as if there was such an class. I'm gonna get a new release out, and then I'll create it.
    I would really like to see your progress, one main reason being to make sure you go about it in the correct way, i.e. something that will work with the overall architecture of Ember.
  • So then that would then create a draggedcontainer with the image on it? Probably better then Lua so better tweaks can be made.

    Yes I was just fiddling and setting up the Inventory.layout of what I want to do. Anything major I will ask first.

    I am focussing on Inventory, A new Journal with a Tree List (clues added to keep track of minor clues like someone says I think he went that way) and beefing up the Entity creator a little for more interaction like maybe adding events easily without Lua code.

    Also just installed Mepis 6 and finally it is decently fast as well as the browser. Linux isn't that bad it takes some getting used of outside the registry on Windows which is more linear. I have started some Installer work with a distro but we haven't compiled it yet. It's pretty easy to dev so far as eveything is in packcages and you just have to compile per package. the installer is a little tricky though since there are some outside files.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Google Sign In with OpenID