Skip to content

Commit

Permalink
npc pass
Browse files Browse the repository at this point in the history
  • Loading branch information
GuardianDll committed Aug 29, 2024
1 parent 79e2897 commit af3b644
Show file tree
Hide file tree
Showing 102 changed files with 606 additions and 561 deletions.
12 changes: 6 additions & 6 deletions data/json/effects_on_condition/computer_eocs.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,19 +50,19 @@
"//": "todo: make it not reveal fungal towers and such? would require edits in reveal_map code, to accept blacklist of locations?",
"condition": {
"or": [
{ "npc_has_var": "map_cache", "value": "has" },
{ "npc_has_var": "map_cache", "value": "lack" },
{ "npc_has_var": "map_cache", "value": "read" }
{ "compare_string": [ "has", { "npc_val": "map_cache" } ] },
{ "compare_string": [ "lack", { "npc_val": "map_cache" } ] },
{ "compare_string": [ "read", { "npc_val": "map_cache" } ] }
]
},
"false_effect": [ { "npc_add_var": "map_cache", "possible_values": [ "has", "lack" ] }, { "run_eocs": "EOC_CHECK_MAP_CACHE" } ],
"effect": [
{
"if": { "npc_has_var": "map_cache", "value": "read" },
"if": { "compare_string": [ "read", { "npc_val": "map_cache" } ] },
"then": [ { "u_message": "You already noted everything map application on this phone can offer." } ]
},
{
"if": { "npc_has_var": "map_cache", "value": "has" },
"if": { "compare_string": [ "has", { "npc_val": "map_cache" } ] },
"then": [
{ "location_variable_adjust": { "npc_val": "spawn_location_omt" }, "z_adjust": 0, "z_override": true },
{ "reveal_map": { "npc_val": "spawn_location_omt" }, "radius": { "math": [ "rng(11, 36)" ] } },
Expand All @@ -71,7 +71,7 @@
]
},
{
"if": { "npc_has_var": "map_cache", "value": "lack" },
"if": { "compare_string": [ "lack", { "npc_val": "map_cache" } ] },
"then": [ { "u_message": "Whoever used this phone didn't ever open their map application. Worthless." } ]
}
]
Expand Down
4 changes: 2 additions & 2 deletions data/json/effects_on_condition/npc_eocs/godco_npc_eocs.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@
"condition": {
"and": [
{ "math": [ "godco_has_canningpots", "==", "1" ] },
{ "not": { "npc_has_var": "dialogue_missions_got_mission", "value": "yes" } }
{ "not": { "compare_string": [ "yes", { "npc_val": "dialogue_missions_got_mission" } ] } }
]
},
"deactivate_condition": { "npc_has_var": "dialogue_missions_got_mission", "value": "yes" },
"deactivate_condition": { "compare_string": [ "yes", { "npc_val": "dialogue_missions_got_mission" } ] },
"effect": [
{ "offer_mission": "MISSION_GODCO_FOOD_GUARD_CANNING_STARTUP" },
{ "npc_add_var": "dialogue_missions_got_mission", "value": "yes" }
Expand Down
10 changes: 5 additions & 5 deletions data/json/items/tool/science.json
Original file line number Diff line number Diff line change
Expand Up @@ -1372,15 +1372,15 @@
},
{
"id": "EOC_MIGO_BIO_TECH_SETUP",
"condition": { "not": { "npc_has_var": "mbt_f_function_set", "value": "yes" } },
"condition": { "not": { "compare_string": [ "yes", { "npc_val": "mbt_f_function_set" } ] } },
"effect": [
{ "npc_add_var": "mbt_f_function_set", "value": "yes" },
{ "npc_add_var": "mbt_f_function", "possible_values": [ "morale", "focus", "pain", "sleepiness" ] }
]
},
{
"id": "EOC_MIGO_BIO_TECH_MORALE",
"condition": { "npc_has_var": "mbt_f_function", "value": "morale" },
"condition": { "compare_string": [ "morale", { "npc_val": "mbt_f_function" } ] },
"effect": [
{ "u_message": "You feel amazing!" },
{
Expand All @@ -1394,20 +1394,20 @@
},
{
"id": "EOC_MIGO_BIO_TECH_FOCUS",
"condition": { "npc_has_var": "mbt_f_function", "value": "focus" },
"condition": { "compare_string": [ "focus", { "npc_val": "mbt_f_function" } ] },
"effect": [
{ "u_message": "You feel incredibly focused!" },
{ "math": [ "u_val('focus')", "+=", "min( u_val('focus') + 30, 130)" ] }
]
},
{
"id": "EOC_MIGO_BIO_TECH_PAIN",
"condition": { "npc_has_var": "mbt_f_function", "value": "pain" },
"condition": { "compare_string": [ "pain", { "npc_val": "mbt_f_function" } ] },
"effect": [ { "u_message": "You feel your aches and pains fade away!" }, { "math": [ "u_pain()", "-=", "30" ] } ]
},
{
"id": "EOC_MIGO_BIO_TECH_SLEEPINESS",
"condition": { "npc_has_var": "mbt_f_function", "value": "sleepiness" },
"condition": { "compare_string": [ "sleepiness", { "npc_val": "mbt_f_function" } ] },
"effect": [ { "u_message": "You instantly feel more awake!" }, { "math": [ "u_val('sleepiness')", "-=", "30" ] } ]
}
]
Expand Down
18 changes: 9 additions & 9 deletions data/json/npcs/Lighthouse_Family/NPC_lighthouse_man.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,13 @@
{
"text": "How are you doing?",
"topic": "TALK_lighthouse_man_hay",
"condition": { "npc_has_var": "flag_help_helped_lighthouse_man", "value": "yes" }
"condition": { "compare_string": [ "yes", { "npc_val": "flag_help_helped_lighthouse_man" } ] }
},
{ "text": "Do you need any help?", "topic": "TALK_MISSION_LIST" },
{
"text": "Care to trade?",
"topic": "TALK_lighthouse_man_1",
"condition": { "npc_has_var": "flag_help_helped_lighthouse_man", "value": "yes" },
"condition": { "compare_string": [ "yes", { "npc_val": "flag_help_helped_lighthouse_man" } ] },
"effect": "start_trade"
},
{
Expand Down Expand Up @@ -141,7 +141,7 @@
"topic": "TALK_lighthouse_man_cleaned",
"condition": {
"and": [
{ "npc_has_var": "count_cleaning_lighthouse_man", "value": "1" },
{ "compare_string": [ "1", { "npc_val": "count_cleaning_lighthouse_man" } ] },
"at_safe_space",
{ "npc_at_om_location": "lighthouse_z1" }
]
Expand All @@ -153,7 +153,7 @@
"topic": "TALK_lighthouse_man_cleaned",
"condition": {
"and": [
{ "npc_has_var": "count_cleaning_lighthouse_man", "value": "2" },
{ "compare_string": [ "2", { "npc_val": "count_cleaning_lighthouse_man" } ] },
"at_safe_space",
{ "npc_at_om_location": "lighthouse_z2" }
]
Expand All @@ -165,7 +165,7 @@
"topic": "TALK_lighthouse_man_cleaned",
"condition": {
"and": [
{ "npc_has_var": "count_cleaning_lighthouse_man", "value": "3" },
{ "compare_string": [ "3", { "npc_val": "count_cleaning_lighthouse_man" } ] },
"at_safe_space",
{ "npc_at_om_location": "lighthouse_z3" }
]
Expand All @@ -177,7 +177,7 @@
"topic": "TALK_lighthouse_man_cleaned",
"condition": {
"and": [
{ "npc_has_var": "count_cleaning_lighthouse_man", "value": "4" },
{ "compare_string": [ "4", { "npc_val": "count_cleaning_lighthouse_man" } ] },
"at_safe_space",
{ "npc_at_om_location": "lighthouse_z4" }
]
Expand All @@ -188,7 +188,7 @@
"text": "Yes. Top floor is clear.",
"condition": {
"and": [
{ "npc_has_var": "count_cleaning_lighthouse_man", "value": "5" },
{ "compare_string": [ "5", { "npc_val": "count_cleaning_lighthouse_man" } ] },
"at_safe_space",
{ "npc_at_om_location": "lighthouse_z5" }
]
Expand All @@ -200,7 +200,7 @@
"text": "Looks like that's over.",
"condition": {
"and": [
{ "npc_has_var": "count_cleaning_lighthouse_man", "value": "6" },
{ "compare_string": [ "6", { "npc_val": "count_cleaning_lighthouse_man" } ] },
"at_safe_space",
{ "npc_at_om_location": "lighthouse_ground" }
]
Expand Down Expand Up @@ -346,7 +346,7 @@
"name": { "str": "House cleaning" },
"description": "Clean lighthouse from <zombies> with Mikhail.",
"goal": "MGOAL_CONDITION",
"goal_condition": { "npc_has_var": "count_cleaning_lighthouse_man", "value": "7" },
"goal_condition": { "compare_string": [ "7", { "npc_val": "count_cleaning_lighthouse_man" } ] },
"difficulty": 0,
"value": 5000,
"start": {
Expand Down
5 changes: 2 additions & 3 deletions data/json/npcs/TALK_CYBORG_1.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
"id": "TALK_CYBORG_1",
"type": "talk_topic",
"dynamic_line": {
"npc_has_var": "dialogue_cyborg_cyborg_has_talked",
"value": "yes",
"compare_string": [ "yes", { "npc_val": "dialogue_cyborg_cyborg_has_talked" } ],
"no": {
"gendered_line": "I… I'm free. *Zzzt* I'm actually free! *bzzz* Look, you're the first person I've seen in a long time.",
"relevant_genders": [ "npc" ]
Expand All @@ -15,7 +14,7 @@
"responses": [
{
"switch": true,
"condition": { "npc_has_var": "dialogue_cyborg_cyborg_has_talked", "value": "yes" },
"condition": { "compare_string": [ "yes", { "npc_val": "dialogue_cyborg_cyborg_has_talked" } ] },
"text": "Hey. Let's chat for a second.",
"topic": "TALK_STRANGER_NEUTRAL"
},
Expand Down
2 changes: 1 addition & 1 deletion data/json/npcs/TALK_TEST.json
Original file line number Diff line number Diff line change
Expand Up @@ -645,7 +645,7 @@
{
"text": "This is a npc_has_var, npc_remove_var test response.",
"topic": "TALK_DONE",
"condition": { "npc_has_var": "test_var_test_test", "value": "reeb" },
"condition": { "compare_string": [ "reeb", { "npc_val": "test_var_test_test" } ] },
"effect": { "npc_lose_var": "test_var_test_test" }
}
]
Expand Down
Loading

0 comments on commit af3b644

Please sign in to comment.