Jump to content

Edu Csak

  • Content Count

  • Joined

  • Last visited

Community Reputation

1 Neutral

About Edu Csak

  • Rank
  1. OML! Thanks for opening my mind for this possibility. Thank you very much!
  2. Hi! I'm trying to make a script where a item code is given and it grabs its respective menu list, but I can't find on wiki what command I should use to transform the value I've got into a variable of the menu that should be shown. Example: the item 48 is given. So, the tint48 menu list should be prompted. I came up with this idea of putting on a list (tintableItems) which contains the item (48), the menu that should prompt (tint48) and then the values that should go on (faces48). But I'm stucked on how to transform the value I get (tint48) into the list values of it. I don't even know if it's possible, but I'm searching wiki for this answer but I cannot find. I'm trying to simplify the coding Based on the item given, a menu should popup with the values provided. I don't want to make N lists, one for each item neither nesting neverending IFs to check if item 48 integer CHAN= -999; key old_owner; integer item=48; list tintableItems = [ 48,"tint48","faces48" ]; // where 48 is the item / tint48 its menu / faces48 the values list tint48 = ["TEETH","ALL","CLOSE","COLLAR","PULL TAB", "BODY"]; list faces48 = ["3","ALL_SIDES","","1","2","0"]; default { state_entry() { old_owner = llGetOwner(); if (item == (integer)llList2String(tintableItems, (integer) llListFindList(tintableItems, (list)item))) { //integer position = (integer) llListFindList(tintableItems, (list)item)+1; // gets the next position in List string value = llList2String(tintableItems, (integer) llListFindList(tintableItems, (list)item)+1); // grabs the value // now I want to use this value as parameter which menu list to use but don't know what command to get it done llDialog(old_owner, "Choose: ", (list)value , CHAN); llListen(CHAN, "", NULL_KEY, ""); } } } My problem lies here: llDialog(old_owner, "Choose: ", (list)value , CHAN); I know it's wrong. I just don't know what to do TY!
  3. Finally, I made it work. Once the channel value was set on state_entry, I found out that there's no way to have it changed. So I made other variable to be used and resetted within llListen with the value I got from the listen and got it working on touch_start Thank you all for your help
  4. OK, but my issue is how to change the llsay to start saying on channel 9 and not on 2. Initially, the hud uses the channel 2. Then the item says to hud to use channel 9. But I cannot have it saying channel 9. keeps on llSay(ing) on channel 2 state_entry() { chan=2; }listen(integer chan, string name, key id, string msg) { chan=(integer)msg; // msg = 9 - script now must llSay on channel 9... not on 2 anymore } But the variable chan receives the new value on listen, but keeps on reapplying the 2 above
  5. I've got an item and a HUD The item says the HUD which channel to use, but I"m stucked on how it changes. It's keep on using the old channel setted. The HUD uses channel 2 (for example) Then the item says to HUD to use channel 9 It listens, but keeps on using channel 2, not 9 state_entry() { chan=2; } listen(integer CHAN, string name, key id, string msg) { chan=(integer)msg; } // msg = 9 What I'm missing?
  6. I made a HUD to tint a vest mesh.I do have it working, but it tints ALL_SIDES. My question is: how to select on HUD which face to tint and send it with the color to apply? Thanks!
  • Create New...