Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Daved27hundred committed May 1, 2023
2 parents 1e8588b + bbfa357 commit af9ebe5
Show file tree
Hide file tree
Showing 173 changed files with 2,562 additions and 2,636 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ jobs:
# uses a compiled language

- run: |
make RELEASE=1 RUNTESTS=0
make RELEASE=1 TESTS=0
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
35 changes: 26 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,10 @@
# make ASTYLE=0
# Disable format check of whitelisted json files.
# make LINTJSON=0
# Disable building and running tests.
# make RUNTESTS=0
# Disable building tests.
# make TESTS=0
# Enable running tests.
# make RUNTESTS=1
# Build source files in order of how often the matching header is included
# make HEADERPOPULARITY=1

Expand Down Expand Up @@ -172,9 +174,28 @@ ifndef LINTJSON
LINTJSON = 1
endif

# Enable running tests by default
# Enable building tests by default
ifndef TESTS
TESTS = 1
endif

# Disable running tests by default
ifndef RUNTESTS
RUNTESTS = 1
RUNTESTS = 0
endif

# Can't run tests if we aren't going to build them
ifeq ($(TESTS), 0)
RUNTESTS = 0
endif

ifeq ($(RUNTESTS), 1)
TESTS = 1
RUNTESTSTARGET = check
endif

ifeq ($(TESTS), 1)
TESTSTARGET = tests
endif

ifndef PCH
Expand Down Expand Up @@ -247,10 +268,6 @@ ifeq ($(BACKTRACE), 1)
endif
endif

ifeq ($(RUNTESTS), 1)
TESTS = tests
endif

# tiles object directories are because gcc gets confused
# Appears that the default value of $LD is unsuitable on most systems

Expand Down Expand Up @@ -910,7 +927,7 @@ endif

LDFLAGS += -lz

all: version prefix $(CHECKS) $(TARGET) $(L10N) $(TESTS)
all: version prefix $(CHECKS) $(TARGET) $(L10N) $(TESTSTARGET) $(RUNTESTSTARGET)
@

$(TARGET): $(OBJS)
Expand Down
6 changes: 3 additions & 3 deletions data/help/texts.json
Original file line number Diff line number Diff line change
Expand Up @@ -222,9 +222,9 @@
"messages": [
"You control vehicles using the numpad, or vikeys. Note, however, that you control the vehicle's controls, rather than controlling the vehicle directly.",
"<HELP_DRAW_DIRECTIONS>",
"In order to assume control of a vehicle, get to a location with working \"vehicle controls\" and a \"seat,\" then press <press_control_vehicle>. Once you are in control, <press_UP> accelerates, <press_DOWN> slows or reverses, & <press_LEFT> & <press_RIGHT> turn left or right. Diagonals adjust course and speed. You default to cruise control, so the gas/brake adjust the speed which the vehicle will attempt to maintain.",
"In order to assume control of a vehicle, get to a location with working \"vehicle controls\" and a \"seat,\" then press <press_control_vehicle>. Once you are in control, <press_UP> accelerates, <press_DOWN> slows or reverses, & <press_LEFT> & <press_RIGHT> turn left or right. Diagonals adjust course and speed. The gas/brake adjust the speed which the vehicle will attempt to maintain.",
"10-30 MPH, or 16-48 KPH, is a good speed for beginning drivers, who tend to fumble the controls. As your Driving skill improves, you will fumble less and less. To simply maintain course and speed, hit <press_pause>.",
"It's a good idea to pull the handbrake - \"s\" - when parking, just to be safe. If you want to get out, hit the lights, toggle cruise control, turn the engine on or off, or otherwise use the vehicle controls, press <press_control_vehicle> to bring up the \"Vehicle controls\" menu, which has options for things you'd do from the driver's seat.",
"It's a good idea to pull the handbrake - \"s\" - when parking, just to be safe. If you want to get out, hit the lights, turn the engine on or off, or otherwise use the vehicle controls, press <press_control_vehicle> to bring up the \"Vehicle controls\" menu, which has options for things you'd do from the driver's seat.",
"Examining (<press_examine>) a vehicle brings up the vehicle interaction window. The left pane shows a top-down view of your vehicle and each part of it. The middle pane shows a summary of the vehicle's engines, batteries, storage tanks, weapons, and seating. The right panel is context-sensitive, but normally has descriptions of the vehicle parts in the tile highlighted in the vehicle view on the left.",
"Across the bottom is a summary of the most important parameters of your vehicle. \"Safe speed\" is how fast you can drive without damaging the engine, and \"Top speed\" is how fast you can drive at the engine's maximum output. \"Acceleration\" is how fast your vehicle can increase speed each turn. \"Cargo volume\" is how much cargo you can store and how much stuff you have in your vehicle, \"Mass\" is how much the vehicle weighs, and the \"Status\" and \"Wheels\" readouts give a summary of the vehicle condition and wheel condition. There are also fuel indicators on the lower right that give an estimate of how quickly your fuel will run out.",
"Air drag, water drag, rolling drag, and static drag are all values that influence your vehicle's safe and maximum speed. The interaction of drag and engine power is complicated, but generally speaking, more powerful engines will make your vehicle go faster but also consume fuel faster.",
Expand All @@ -239,7 +239,7 @@
"Each boat hull you add to your vehicle increases the height of the vehicle's watertight hull. If the height of the watertight hull is less than the vehicle's draft, then water will flow into your vehicle, and it will sink and be destroyed if it goes into deep water. If your vehicle's draft is less than the height of the watertight hull, your vehicle will not take on water and will not sink in deep water.",
"Draft is determined by the length and width of your vehicle, the mass of your vehicle, and the percentage of the vehicle's underbody covered in boat hulls. In general, a vehicle should be able to float if its mass in tons is less than a quarter of the product of its length and width, provided that the watertight hull is high enough. A boat that is 5 tiles wide and 9 tiles long has a good chance of floating if its entire underbody is covered in boat boards and it weighs less than 10 tons.",
"Increased draft increases water drag, and water drag reduces a vehicle's speed in water. If you want your boat to go fast, make it as light as possible.",
"Amphibious vehicles have both wheels and boat hulls. As long as your amphibious vehicle has enough wheels on land and enough boat hulls to not sink in deep water, you can freely transition from land to water. However, most amphibious vehicles are much slower in water than they are on land, so be careful when entering water to not leave your cruise control speed above your vehicle's safe water speed or you can burn out your engine!"
"Amphibious vehicles have both wheels and boat hulls. As long as your amphibious vehicle has enough wheels on land and enough boat hulls to not sink in deep water, you can freely transition from land to water. However, most amphibious vehicles are much slower in water than they are on land, so be careful when entering water to not leave your speed above your vehicle's safe water speed or you can burn out your engine!"
]
},
{
Expand Down
36 changes: 32 additions & 4 deletions data/json/achievements.json
Original file line number Diff line number Diff line change
Expand Up @@ -2071,11 +2071,11 @@
"name": "Eureka!",
"requirements": [
{
"event_statistic": "last_overmap_special_avatar_entered",
"is": "==",
"target": [ "overmap_special_id", "Lab_CORE_2x1x2" ],
"event_statistic": "num_avatar_enters_trans_lab",
"is": ">=",
"target": 1,
"visible": "when_achievement_completed",
"description": "Reach Trans Coastal Lab"
"description": "Reach a Trans Coastal Facility"
}
]
},
Expand Down Expand Up @@ -2107,6 +2107,20 @@
}
]
},
{
"id": "achievement_reach_military_bunker",
"type": "achievement",
"name": "Zombie Forces",
"requirements": [
{
"event_statistic": "last_overmap_special_avatar_entered",
"is": "==",
"target": [ "overmap_special_id", "military_bunker_1" ],
"visible": "when_achievement_completed",
"description": "Reach a Military Bunker"
}
]
},
{
"id": "achievement_reach_triffid_grove",
"type": "achievement",
Expand Down Expand Up @@ -2202,5 +2216,19 @@
"description": "Reach a Mine"
}
]
},
{
"id": "achievement_reach_police_station",
"type": "achievement",
"name": "Zombie PD, to protect and zombify!",
"requirements": [
{
"event_statistic": "num_avatar_enters_police_station",
"is": ">=",
"target": 1,
"visible": "when_achievement_completed",
"description": "Reach a Police Station"
}
]
}
]
20 changes: 0 additions & 20 deletions data/json/bionics.json
Original file line number Diff line number Diff line change
Expand Up @@ -1289,26 +1289,6 @@
"encumbrance": [ [ "eyes", 10 ] ],
"flags": [ "BIONIC_FAULTY" ]
},
{
"id": "bio_power_armor_interface",
"type": "bionic",
"name": { "str": "Power Armor Interface" },
"description": "Interfaces your power system with the internal charging port on suits of power armor, allowing them to draw from your bionic power banks.",
"occupied_bodyparts": [ [ "torso", 4 ], [ "head", 1 ] ],
"flags": [ "BIONIC_ARMOR_INTERFACE", "BIONIC_TOGGLED" ],
"react_cost": 1,
"time": "1 s"
},
{
"id": "bio_power_armor_interface_mkII",
"type": "bionic",
"name": { "str": "Power Armor Interface Mk. II" },
"description": "Interfaces your power system with the internal charging port on suits of power armor, allowing them to draw from your bionic power banks. Twice as efficient as the Mk. I model.",
"occupied_bodyparts": [ [ "torso", 3 ], [ "head", 2 ] ],
"flags": [ "BIONIC_ARMOR_INTERFACE", "BIONIC_TOGGLED" ],
"react_cost": 1,
"time": "2 s"
},
{
"id": "bio_power_storage",
"type": "bionic",
Expand Down
36 changes: 17 additions & 19 deletions data/json/effect_on_condition.json
Original file line number Diff line number Diff line change
Expand Up @@ -505,128 +505,126 @@
{
"type": "effect_on_condition",
"id": "EOC_GIVE_RANDOM_MISSION",
"recurrence": 1,
"global": false,
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": [
{
"weighted_list_eocs": [
[
{
"id": "give_MISSION_GET_RELIC",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_GET_RELIC" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_GET_RECORD_ACCOUNTING",
"condition": { "npc_has_trait": "GETS_RANDOM_MISSION" },
"condition": { "u_has_trait": "GETS_RANDOM_MISSION" },
"effect": { "offer_mission": "MISSION_GET_RECORD_ACCOUNTING" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_GET_INHALER",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_GET_INHALER" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_GET_ANTIBIOTICS",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_GET_ANTIBIOTICS" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_GET_FLAG",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_GET_FLAG" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_GET_RECORD_WEATHER",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_GET_RECORD_WEATHER" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_GET_SOFTWARE",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_GET_SOFTWARE" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_GET_RECORD_PATIENT",
"condition": { "npc_has_trait": "GETS_RANDOM_MISSION" },
"condition": { "u_has_trait": "GETS_RANDOM_MISSION" },
"effect": { "offer_mission": "MISSION_GET_RECORD_PATIENT" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_KILL_JABBERWOCK",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_KILL_JABBERWOCK" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_KILL_ZOMBIE_MOM",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_KILL_ZOMBIE_MOM" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_RESCUE_DOG",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_RESCUE_DOG" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_PROVE_YOU_ARE_A_SURVIVOR",
"condition": { "npc_has_trait": "GETS_RANDOM_MISSION" },
"condition": { "u_has_trait": "GETS_RANDOM_MISSION" },
"effect": { "offer_mission": "MISSION_PROVE_YOU_ARE_A_SURVIVOR" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_LEARN_ABOUT_CATTAIL_JELLY",
"condition": { "or": [ { "npc_has_trait": "GETS_RANDOM_MISSION" }, { "npc_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"condition": { "or": [ { "u_has_trait": "GETS_RANDOM_MISSION" }, { "u_has_trait": "GETS_RANDOM_MISSION_NOMOVE" } ] },
"effect": { "offer_mission": "MISSION_LEARN_ABOUT_CATTAIL_JELLY" }
},
{ "const": 1 }
],
[
{
"id": "give_MISSION_PYROMANIAC",
"condition": { "npc_has_trait": "GETS_RANDOM_MISSION" },
"condition": { "u_has_trait": "GETS_RANDOM_MISSION" },
"effect": { "offer_mission": "MISSION_PYROMANIAC" }
},
{ "const": 1 }
]
]
},
{ "npc_lose_trait": "GETS_RANDOM_MISSION" },
{ "npc_lose_trait": "GETS_RANDOM_MISSION_NOMOVE" }
{ "u_lose_trait": "GETS_RANDOM_MISSION" },
{ "u_lose_trait": "GETS_RANDOM_MISSION_NOMOVE" }
]
},
{
Expand Down
6 changes: 3 additions & 3 deletions data/json/furniture_and_terrain/furniture-terrains.json
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,7 @@
"name": "small boulder",
"description": "A big rock. Should be easy to roll around, but too heavy to carry with you. It can be used as a primitive anvil, or broken into a bunch of smaller rocks.",
"symbol": "o",
"color": "dark_gray",
"color": "light_gray",
"move_cost_mod": 3,
"coverage": 30,
"required_str": 10,
Expand All @@ -813,7 +813,7 @@
"name": "medium boulder",
"description": "A pretty big boulder, but still small enough to see and climb over. It would be a struggle to move it. It can be used as a primitive anvil, or broken into a bunch of smaller rocks.",
"symbol": "0",
"color": "dark_gray",
"color": "light_gray",
"move_cost_mod": 6,
"coverage": 45,
"required_str": 16,
Expand All @@ -833,7 +833,7 @@
"name": "large boulder",
"description": "A boulder that's taller than you. Now how are you going to move this?",
"symbol": "O",
"color": "dark_gray",
"color": "light_gray",
"move_cost_mod": -1,
"coverage": 65,
"required_str": 32,
Expand Down
10 changes: 10 additions & 0 deletions data/json/hobbies.json
Original file line number Diff line number Diff line change
Expand Up @@ -627,6 +627,16 @@
"skills": [ { "level": 3, "name": "fabrication" } ],
"proficiencies": [ "prof_carving", "prof_carpentry_basic" ]
},
{
"type": "profession",
"subtype": "hobby",
"id": "home_improvement",
"name": "Home Improvement",
"points": 2,
"description": "You'd fix up any holes and appliances in your own home with nothing but your two hands and some elbow grease. You did it to save money on repairmen, but now it seems you'll do it to save your life.",
"skills": [ { "level": 2, "name": "fabrication" }, { "level": 1, "name": "mechanics" }, { "level": 1, "name": "electronics" } ],
"proficiencies": [ "prof_carpentry_basic", "prof_appliance_repair" ]
},
{
"type": "profession",
"id": "fishing",
Expand Down
1 change: 1 addition & 0 deletions data/json/itemgroups/Weapons_Mods_Ammo/gunmod.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"id": "gunmod_common",
"//": "Common gunmods typically owned by citizens and found in many locations.",
"items": [
[ "belt_clip", 5 ],
[ "brass_catcher", 100 ],
[ "improve_sights", 60 ],
[ "muzzle_brake", 20 ],
Expand Down
Loading

0 comments on commit af9ebe5

Please sign in to comment.