Skip to content

Commit

Permalink
autodocing some stuff and starts a readme
Browse files Browse the repository at this point in the history
  • Loading branch information
FalloutFalcon committed Oct 23, 2024
1 parent 103e74b commit ec5f436
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 10 deletions.
5 changes: 4 additions & 1 deletion code/modules/missions/dynamic/_dynamic.dm
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
/datum/mission/dynamic
value = 2000
/// Which landmark we will search for in spawned_mission_pois of the planet
var/setpiece_poi = /obj/effect/landmark/mission_poi/main
/// Item that will be spawned at the setpiece_poi
var/setpiece_item
///Specific item uses an exact item, if false it will allow type or any subtype
/// Specific item uses an exact item, if false it will allow type or any subtype
var/specific_item = TRUE
/// The item that you can turn in to complete the mission. If specific_item is false it uses the type of the item.
var/atom/movable/required_item

/datum/mission/dynamic/generate_mission_details()
Expand Down
16 changes: 10 additions & 6 deletions code/modules/missions/mission.dm
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,20 @@
var/author = ""
var/desc = "Do something for me."
var/faction = /datum/faction/independent
var/value = 1000 /// The mission's payout.
/// The mission's payout.
var/value = 1000
/// Optional var to give an item upon completion along with value
var/mission_reward
var/duration /// The amount of time in which to complete the mission. Setting it to 0 will result in no time limit
var/weight = 0 /// The relative probability of this mission being selected. 0-weight missions are never selected.
/// The amount of time in which to complete the mission. Setting it to 0 will result in no time limit
var/duration
/// The relative probability of this mission being selected. 0-weight missions are never selected.
var/weight = 0

///Only needed if you have multipe missiosn that use the same poi's on the map. Set at new.
/// Only needed if you have multipe missiosn that use the same poi's on the map. Set at new.
var/mission_index

var/location_specific = TRUE
/// The outpost that issued this mission. Passed in New().
//var/datum/overmap/outpost/source_outpost
/// The location the mission is relient on, often pulling varibles from it or will delete itself if the mission_location is deleted. Passed in New().
var/datum/overmap/mission_location

/// Should mission value scale proportionally to the deviation from the mission's base duration?
Expand All @@ -23,6 +26,7 @@
/// The maximum deviation of the mission's true duration from the base value, as a proportion.
var/dur_mod_range = 0.1

/// Timestamp for when the mission was activated
var/time_issued
var/active = FALSE
var/failed = FALSE
Expand Down
4 changes: 1 addition & 3 deletions code/modules/missions/mission_board.dm
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/obj/machinery/computer/mission/LateInitialize()
. = ..()
if(istype(get_area(src.loc), /area/outpost))
var/obj/machinery/mission_pad/pad = locate() in range(4,src)
var/obj/machinery/mission_pad/pad = locate() in range(2,src)
pad_ref = WEAKREF(pad)
desc += "This one is not linked to any outpost."

Expand Down Expand Up @@ -69,8 +69,6 @@
var/obj/machinery/mission_pad/pad = pad_ref?.resolve()
if(!pad)
return
//if(!usr.can_perform_action(src) || (machine_stat & (NOPOWER|BROKEN)))
// return
switch(action)
if("recalc")
recalc()
Expand Down
7 changes: 7 additions & 0 deletions code/modules/missions/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Dynamic Missions

## About
A massive rework to missions with the core goal of making them more intresting and feeding into our existing loop better

## Variables

0 comments on commit ec5f436

Please sign in to comment.