Please login or register.

Login with username, password and session length
Advanced search  


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

Author Topic: Put an inventory icon on the screen  (Read 5606 times)

0 Members and 1 Guest are viewing this topic.


  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 22
  • mmmmm...
    • View Profile
    • ModelArt Software
Put an inventory icon on the screen
« on: February 06, 2003, 02:05:25 AM »


I've already programmed the interface of my game but I've got a problem. I'm trying to put an inventory icon on the screen (like Sam'n'Max), then I've created a global entity which is my icon. In the scenes without scroll, this entity is seen without problem but in the scenes with scroll it's fixed in a point (it doesn't move with the scroll)

I put this code in the main loop of the game daemon script.

Code: [Select]
global invIcon = Game.LoadEntity("interface\system\inv\inv.entity");




Can anybody(Mnemonic) help me?




  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re:Put an inventory icon on the screen
« Reply #1 on: February 06, 2003, 11:26:47 AM »

I don't think the entity is the right solution here, because the entities are part of the scene. A "window" would be much more suitable for this. Just create a transparent window, covering the whole screen, and the window will containt one button (-> your inventory icon).

Something like this:

Code: [Select]
  X = 0
  Y = 0
  WIDTH = 800
  HEIGHT = 600
    NAME = "Inventory"
    X = 20
    Y = 20
    IMAGE = "inventory_icon.bmp"
    SCRIPT = "blah.script"

You will then load the window in game.script using

Code: [Select]
var WinInventoryIcon = Game.LoadWindow("blahblah.window");
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

Page created in 0.014 seconds with 19 queries.