• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Shop with "dummy" items?

Status
Not open for further replies.
Level 2
Joined
Jan 20, 2008
Messages
7
So far I've made a shop which can sell items, and when hero aproaches it he can buy certain item from it - ie. normal item shop. But it can't be normal item shop - item can be only sold to hero that meet special requirements (various reasons, must have other item, some variable must be set, etc). I've made a trigger (A unit solds an item) which checks if that hero is able to buy that item. If he can buy it, then it's ok, but if he can't then I need to remove item from his backpack, give his money back, and refresh the cooldown on item in shop (and I don't know how to refresh the cooldown). Also I can't remove item from his inventory instantly, because it will vanish, but all bonuses will still be applied to hero :eek:.

It is possible to have a shop that sells nothing? I would like to attach trigger into each item and do everything manually by JASS. I mean - I have something that looks like a shop, that have 4x3 item-buttons and active only if hero is around, and if clicked then nothing happens - only trigger is being executed. Like dialogs, but in a shop form.
 
Level 12
Joined
Mar 23, 2008
Messages
942
I think it would be better instead of selling the real item, sell fake ones in shop, so if the correct hero bought the item, you remove it and give the real one.
So you will have no problems with the bonus.
 
Level 2
Joined
Jan 20, 2008
Messages
7
But still I would have to give money back for the item if hero isn't allowed to buy it and somehow refresh the cooldown.
 
Last edited:
Status
Not open for further replies.
Top