Please login or register.

Login with username, password and session length
Advanced search  

News:

Forum rules - please read before posting, it can save you a lot of time.

Author Topic: Inventory "boxes" in window  (Read 2556 times)

0 Members and 1 Guest are viewing this topic.

Squinage

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 11
    • View Profile
    • Re:Gamed
Inventory "boxes" in window
« on: September 18, 2012, 01:42:36 PM »

Hello again, I have a new issue whilst working on the inventory in my game.

I have an inventory icon (window), which when clicked, displays another window which will be the inventory. This process works when I have a normal window as the inventory (although no items appear on it as the inventory item areas are not defined).

This issue I am having is that I don't understand how to code where the item should appear in the inventory window.

In the example project, there is an "inventory.def" file which is essentially a window with extra boxes to determine where the items go.

I found this post:

http://forum.dead-code.org/index.php?topic=5167.msg29296#msg29296

but I'm still not sure on this.

I have placed this code in my game.script and referenced it to be visible when you click on the icon:
Code: WME Script
  1. global WinInventoryOpen = Game.GetInventoryWindow("interface\inventory.def");

The above does not seem to work and nor does this as the file is not a window:
Code: WME Script
  1. global WinInventoryOpen = Game.LoadWindow("interface\inventory.def");

And I'm not sure how else you get the inventory boxes in a normal .window or how to reference the .def file in the game.script.

I hope the above makes sense!

Could anyone help me one this?

Squin
Logged

Squinage

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 11
    • View Profile
    • Re:Gamed
Re: Inventory "boxes" in window
« Reply #1 on: September 19, 2012, 03:39:28 PM »

Just in case anyone looks at this and wonders how it was solved, I found what I needed in the below documentation:

http://res.dead-code.org/doku.php/wmebook:ch6

I'll make sure I look harder next time :)

Squin
Logged
 

Page created in 0.045 seconds with 20 queries.