Shop System

jakarecosta

New Member
Reaction score
0
I want Help with a shop system i want to make

i want when a unit uses a skill gives a specific iten and i tried to use speelbooks to gather all the itens "skills"
but i had problems with the triggers and actions can anyone give me a light ?
 

Accname

2D-Graphics enthusiast
Reaction score
1,463
I have no idea what you are trying to say. Could you try to explain your situation in more detail? And with a little bit more structure?
 

jakarecosta

New Member
Reaction score
0
i have a spell book full with skills when the unit uses X skill it gives Y iten and deduces the gold cost
after this you have a iten that have spellbook skill when you use that iten you can choose the upgrade for that iten
you use a X skill and removes the source of the skill in this case the iten and you get a upgrade for that iten


unit skill(shop)>+iten -gold cost
iten skill> -iten -gold +upgrade(a better iten of same sort)

all that skills inside a spellbook so you can have multiple choices for buying/upgrading X iten

srry i'm brasilian mi english its a shame
 

Accname

2D-Graphics enthusiast
Reaction score
1,463
Okay, what exactly is your problem? Which part of these are you unable to do?

I would suggest looking into the Charge Gold / Lumber ability. It is an ability which can cost you mana, gold and/or lumber. You can set the cost within the editor. Put these inside a spellbook ability and then detect a cast with the event "Unit - Unit starts the effect of an ability".
 

jakarecosta

New Member
Reaction score
0
Okay, what exactly is your problem? Which part of these are you unable to do?

I would suggest looking into the Charge Gold / Lumber ability. It is an ability which can cost you mana, gold and/or lumber. You can set the cost within the editor.

but can i use multiples copyes of that skill i won't cause problems ? i was thinking in use channel skill on every iten the problem is i tryed to script that but i was unable to give the iten to the caster for some reason

i was making like a database of skills and itens like

set skill[1] skillX
set iten[1] itenX
set maxarray maxarray + 1
set skill[2] skillY
set iten[2] itenY
set maxarray maxarray + 1

and using loop A on the array to determine if the skill used is the same Nº of the iten then giving the iten to the caster

Event
unit start casting skill
Condition
unit is a hero
Actions
loop A 0 to [maxarray] do actions
if skill casted is skill[A] then
give iten[A] to caster
 
Last edited:

Accname

2D-Graphics enthusiast
Reaction score
1,463
The trigger you described should work. However, you need to make sure that each copy of the Channel ability has a different value set as its "Base Order ID". If two copies of Channel use the same Base Order ID and are given to the same unit then you wont be able to tell which abiliy was used.

If your trigger is still not working I would recommend adding some debug outputs to your trigger to see if it is run at all or where it stops. You can also copy the entire trigger as text if you right click on top. You can then paste the text on this forum within [ code] tags.
 

jakarecosta

New Member
Reaction score
0
i'm having problems to put the channel skill in the spell book don't know why

i did it once is not working now i add the skill in the spell list and add the spellbook in my unit but the channel skill its not showing in-game

any other skill that i put in the spellbook works but the one based on the channel skill are not showing

also i tryied to use the charge gold but i was unable to make te skill trigger the trigger what event should i use ?
 

Accname

2D-Graphics enthusiast
Reaction score
1,463
The Channel ability has a data field which makes it visible / invisible. This field is, by default, set to invisible. You have to change that to visible in order to see the spell.

For the "Charge Gold and Lumber" ability you NEED to use the "Unit Starts Effect of Ability" trigger as I said earlier. You should generally use that trigger for all your spells.
 

jakarecosta

New Member
Reaction score
0
ok now the problem is i'm giving the Charge Gold and Lumber to a iten making it a iten skill but wont work as i want

the iten i put the Charge Gold and Lumber skill is giving the skill to the unit not being a usable iten even if i put perishable and activly used on it when the unit get the iten it appears on the actions panel

wc3scrnshot_091516_134536_01-jpg.18836


The Itens that have the Charge Gold and Lumber and the skill showing on the action panel
 

Attachments

  • WC3ScrnShot_091516_134536_01.jpg
    WC3ScrnShot_091516_134536_01.jpg
    74.2 KB · Views: 617

Accname

2D-Graphics enthusiast
Reaction score
1,463
Okay, that is strange but it appears that is actually what it does. Didnt know that myself to be honest.

Well, I guess you need to use the Channel ability then and trigger the gold cost yourself.
 

jakarecosta

New Member
Reaction score
0
I have been giving my mind a break for a while
i resume the map modding today
i changed the way i wanted to do the shop now my idea is to use kinda like this
i have base materials that have values

and there is the recipe itens to trigger the thing

now the final iten has a cost
example:
Mana shard = 1
Mana Crystal = 2
Mana Relic = 5

Magic Orb = 5 (cost)

now you can either buy 2x Mana Crystal 1x Mana Shard And the Recipe or 1x Mana Relic and The Recipe so in both cases you get the final iten plus the bonuses from the materials too

i just need a trigger to check all the itens from the inv to get a match x.x
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though
  • Ghan Ghan:
    Heard Houston got hit pretty bad by storms last night. Hope all is well with TH.
  • The Helper The Helper:
    Power back on finally - all is good here no damage
    +2
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    New recipe is another summer dessert Berry and Peach Cheesecake - https://www.thehelper.net/threads/recipe-berry-and-peach-cheesecake.194169/
  • The Helper The Helper:
    I think we need to add something to the bottom of the front page that shows the Headline News forum that has a link to go to the News Forum Index so people can see there is more news. Do you guys see what I am saying, lets say you read all the articles on the front page and you get to the end and it just ends, no kind of link for MOAR!

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top