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,462
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,462
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,462
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,462
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: 606

Accname

2D-Graphics enthusiast
Reaction score
1,462
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.
  • Varine Varine:
    How can you tell the difference between real traffic and indexing or AI generation bots?
  • The Helper The Helper:
    The bots will show up as users online in the forum software but they do not show up in my stats tracking. I am sure there are bots in the stats but the way alot of the bots treat the site do not show up on the stats
  • Varine Varine:
    I want to build a filtration system for my 3d printer, and that shit is so much more complicated than I thought it would be
  • Varine Varine:
    Apparently ABS emits styrene particulates which can be like .2 micrometers, which idk if the VOC detectors I have can even catch that
  • Varine Varine:
    Anyway I need to get some of those sensors and two air pressure sensors installed before an after the filters, which I need to figure out how to calculate the necessary pressure for and I have yet to find anything that tells me how to actually do that, just the cfm ratings
  • Varine Varine:
    And then I have to set up an arduino board to read those sensors, which I also don't know very much about but I have a whole bunch of crash course things for that
  • Varine Varine:
    These sensors are also a lot more than I thought they would be. Like 5 to 10 each, idk why but I assumed they would be like 2 dollars
  • Varine Varine:
    Another issue I'm learning is that a lot of the air quality sensors don't work at very high ambient temperatures. I'm planning on heating this enclosure to like 60C or so, and that's the upper limit of their functionality
  • Varine Varine:
    Although I don't know if I need to actually actively heat it or just let the plate and hotend bring the ambient temp to whatever it will, but even then I need to figure out an exfiltration for hot air. I think I kind of know what to do but it's still fucking confusing
  • The Helper The Helper:
    Maybe you could find some of that information from AC tech - like how they detect freon and such
  • Varine Varine:
    That's mostly what I've been looking at
  • Varine Varine:
    I don't think I'm dealing with quite the same pressures though, at the very least its a significantly smaller system. For the time being I'm just going to put together a quick scrubby box though and hope it works good enough to not make my house toxic
  • Varine Varine:
    I mean I don't use this enough to pose any significant danger I don't think, but I would still rather not be throwing styrene all over the air
  • The Helper The Helper:
    New dessert added to recipes Southern Pecan Praline Cake https://www.thehelper.net/threads/recipe-southern-pecan-praline-cake.193555/
  • The Helper The Helper:
    Another bot invasion 493 members online most of them bots that do not show up on stats
  • Varine Varine:
    I'm looking at a solid 378 guests, but 3 members. Of which two are me and VSNES. The third is unlisted, which makes me think its a ghost.
    +1
  • The Helper The Helper:
    Some members choose invisibility mode
    +1
  • The Helper The Helper:
    I bitch about Xenforo sometimes but it really is full featured you just have to really know what you are doing to get the most out of it.
  • The Helper The Helper:
    It is just not easy to fix styles and customize but it definitely can be done
  • The Helper The Helper:
    I do know this - xenforo dropped the ball by not keeping the vbulletin reputation comments as a feature. The loss of the Reputation comments data when we switched to Xenforo really was the death knell for the site when it came to all the users that left. I know I missed it so much and I got way less interested in the site when that feature was gone and I run the site.
  • Blackveiled Blackveiled:
    People love rep, lol
    +1
  • The Helper The Helper:
    The recipe today is Sloppy Joe Casserole - one of my faves LOL https://www.thehelper.net/threads/sloppy-joe-casserole-with-manwich.193585/
  • The Helper The Helper:
    Decided to put up a healthier type recipe to mix it up - Honey Garlic Shrimp Stir-Fry https://www.thehelper.net/threads/recipe-honey-garlic-shrimp-stir-fry.193595/

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top