“type”: “encounter”,
“encounter_type”: “wait_for_event”,
…
“wait_for_event_info”:{
*and here i am stuck in how to check if the building event is finished"
and if that is not possible maybe a building is an item which can be checked by a “wait_for_requirements” encounter
Is there a difference in functionality between
"trigger"
“challenge” and
"climax"
?
EDIT:
Info and question to developement
Why is it impossible to have coins used in the “collection_encounter” ?
see “collection_quest_shakedown.lua”
–exempt money
if radiant.entities.is_material(entity, ‘gold’) or radiant.entities.is_material(entity, ‘money’) then
return false
end
It would be very nice if they could be used to pay tributes, recipes and so on.
It is logical to exempt food and trophies but why money ?
Next step:
Unlock recipes
Is it possible to unlock more than one recipe with a single encounter ?
The “unlock_recipe.lua” says "must be a string"
In the trader campaign there is always only one recipe which is unlocked.
@BrunoSupremo
you are right that there are 3 recipes which get unlocked by the monument campaign but they are all in seperate encounters .
See here:
i know that i could go the way to “trigger_many” and unlock every single recipe simultaneously in a bunch of encounters but i would prefer to do it more elegant.
i could do it with an array in an array but i dont know if that will work.
In the Archipelago, I actually did it using lua scripts, but only because I needed some extra things that would not be possible through the json encounters alone… I see no problem in calling multiple encounters though, I would say it is preferred, as it has less chances of breaking in the future.
My code:
local cook_job = stonehearth.job:get_job_info(ctx.player_id, "stonehearth:jobs:cook")
cook_job:manually_unlock_recipe("decoration:fruit_container")
local potter_job = stonehearth.job:get_job_info(ctx.player_id, "stonehearth:jobs:potter")
potter_job:manually_unlock_recipe("furniture:sand_castle")
If you want to organize it better, create a sub folder with all the unlocking encounters. This way, they don’t get mixed up with your other encounters.
Because money is tricky. Gold chests can hold up to 1000 coins. But if you request 1000 in your encounter, it will be requesting 1000 gold chests, regardless of the money each of them has. The request is made with the uris.
Wood, stone and food have stacks too, but that isn’t currently supported for collection encounters (just like when crafting, you spend 2 logs regardless of how many stacks they have).
thank you relyss i had a guess that it is that way so coins are just a counter not an entity…ok
For Information to anyone doing campaign:
If you “trigger_many” in an encounter pointing to multiple unlocks it is fully functional but
the messages of the unlocks overwrite each other so fast that you cant read them. For better displaying do a chain of unlocks so that every bulletin title can be read.
I figured that out but will use it later on when redoing my campaign.
If you play test a campaign:
The campaign is loaded at world creation, so a new campaign will only be started if you create a new map.
The encounters can be changed, added or deleted in play test as long as they have not been triggered.
item_requirements
if you want to check single items that must be crafted or just be, dont do it with
deny_if_less_than
value: 1.
That is not working. The check passes without the item
Do it like this:
“item”: “exists_in_world”
“uri”: “your_mod alias”
“type”: “deny_if_not”
“value”: true
I hope everyone creates new campaigns. That is a big big way to have more challenges more goals to achieve and an rpg like touch brought to stonehearth.
@Relyss
Please gelp me out again
(Yes i read all the encounters now…not fully understanding everything)
How to:
I need an encounter which counts items and out edges if a value number is reached.
I read the shakedown process but that is bound to an entity an to trigger events.
I tried “wait for requirement met” with “uri” and “deny if less than” value: 100
No errors but it just “out edges” ignoring value"
I tried to use “item threshold” but cant get it to work as i want.
What i try to do:
The encounter should check if 100 hunk of stones or more are stockpiled then out edge
Edited: for numbers in json the quotes are not needed. Edit #2: Aah, bug. I think there’s something wrong with the uris. You could try with this for the moment:
Ah ok i think i got my misunderstanding.
I havfnt thought about getting to it by mazerial tagging instead i tried to use a uri.
Thank you reliss i will try that tomorrow