| 08-06-2004, 08:40 AM | #1 |
Is there anyway to give a hero an item in a specific slot or move an item to a specific slot? Any help would be awesome! Thanks! :god_help_us: |
| 08-06-2004, 10:18 AM | #2 |
I dont have WE open, so i cant be positive, but I'm fairly certain that there is a give item to slot trigger function. Moving items could be done my removing the item from a certain slot and creating it in another slot. |
| 08-06-2004, 12:41 PM | #3 |
I'm not certain that there is a function that gives item to a specific slot, but you can always count the empty item slots before the one you want to add the item to, and then first add that many dummy items to the hero. After adding the wanted item, you just remove all the dummy items and you have your item in the right spot. |
| 08-06-2004, 06:25 PM | #4 |
Interesting idea, will try that dummy item thing. Thanks! |
| 08-06-2004, 10:48 PM | #5 |
dummy items would help, but that's an untrustable solution, I think this function is better : http://www.wc3sear.ch/index.php?p=JASS&ID=234 |
| 08-06-2004, 11:11 PM | #6 |
I consider it a better resource to visit here: http://www.wc3campaigns.com/showthread.php?t=61667 Only because its links to the much better jassvault. |
| 08-06-2004, 11:16 PM | #7 | |
Quote:
or you/me could just link directly to the jass vault directly |
| 08-07-2004, 09:24 AM | #8 |
I don't see why dummy items would be untrustable, but I definitely won't argue that the JASS function doesn't get the job done much more easily and simply. But the dummy items way is the easiest way to do this in GUI only. :) |
| 08-07-2004, 11:23 AM | #9 |
Zuh? One line of custom text and your pretty much set. Let say you want the item he dropped to go back to slot 3. (i.e. he can't drop the item) I.e. call UnitAddItemToSlot(GetManipulatingUnit(),GetManipulatedItem(),2) Dummy items are annoying and without being smart about it you can over flow the amount you wanted and its alot more processor intensive to use them. |
| 08-07-2004, 01:41 PM | #10 |
Again, I do not claim that the method with this custom script line is inferior in any way. I just said that, not knowing the custom text, you could still use the dummy items way (and of course I mean being smart about it, because you could say for any method that if you are not smart about it, it won't work.) |
| 08-07-2004, 02:40 PM | #11 |
Weaaddar, you got the function I was trying to say but I guess its only a JASS function. Anitarf, dummy items would indeed work (I've done it before when I didnt know about the JASS function) but you save processor time by using the built in wc3 way. Of course, if you didnt know the custom script then dummy items would be the only way to go. |
| 08-07-2004, 09:08 PM | #12 |
ofcourse you didn't find the function before hand. I just wrote it like a week ago. |
