Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-24-2006, 11:03 PM
Angel_Light Angel_Light is offline
Varia Developer
Angel_Light's Avatar
Join Date: Nov 2005
Location: Knoxville, TN
Posts: 1,684
Angel_Light is on a distinguished road
Send a message via AIM to Angel_Light Send a message via MSN to Angel_Light
custom qmenu

Okay, I'm creating a custom qmenu and I need to know how to display all of the players weapons and stuff. without doing it individually. I made sure ever weapon img is 32 by 32 so if that helps any. :/ Any thought?
__________________
Deep into the Darkness peering...
Reply With Quote
  #2  
Old 08-24-2006, 11:56 PM
excaliber7388 excaliber7388 is offline
Banned
excaliber7388's Avatar
Join Date: Jul 2005
Location: US
Posts: 5,229
excaliber7388 can only hope to improve
Send a message via AIM to excaliber7388
I've been thinking about doing this as well. You could have possitions saved with an index number, and a for loop that goes through all weapons, and puts them in their place acording to the index. Although this could be a bit sloppy, and there would have to be a limit on the number of items the player can have. I'm sure there has to a better way though.
Reply With Quote
  #3  
Old 08-25-2006, 12:07 AM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
PHP Code:
for (temp.weaponplayer.weapons)
{
  
// Code

temp.weapon.name will get the weapon name, and I think either temp.weapon.icon or temp.weapon.image or so will get the image (someone correct me if I am wrong).

I guess to draw all icons onto one panel, you could use a GuiDrawingPanel. Similarly you could spawn other GUI controls such as GuiBitmapButtonCtrls for each weapon.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 07:15 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.