Commit Graph

332 Commits

Author SHA1 Message Date
Atermonera
131636b1d2 Capitalizes initialize() to Initialize() because Destroy() is capitalized and this is pretty nerve-grinding 2019-03-26 13:21:08 -04:00
Spades
80de5331f0 Merge pull request #4296 from VOREStation/phoron-scrubbing
Restores phoron scrubbing to vents
2018-10-01 09:20:05 -04:00
Spades
c2ac5bc3b9 Restores phoron scrubbing to vents
I still say the changes were silly for Polaris, but for Virgo, they're
downright suicidal, so naturally we won't have this change.
2018-10-01 08:42:23 -04:00
Arokha Sieyes
b099ac6e4c Merge branch 'master' of https://github.com/VOREStation/Polaris into sync-09272018
# Conflicts:
#	code/__defines/holomap.dm
#	code/__defines/mobs.dm
#	code/_helpers/icons.dm
#	code/_helpers/unsorted.dm
#	code/_onclick/hud/hud.dm
#	code/_onclick/item_attack.dm
#	code/controllers/Processes/supply.dm
#	code/controllers/subsystems/planets.dm
#	code/datums/supplypacks/munitions.dm
#	code/datums/supplypacks/science.dm
#	code/datums/supplypacks/security.dm
#	code/datums/supplypacks/supply.dm
#	code/game/area/Space Station 13 areas.dm
#	code/game/atoms_movable.dm
#	code/game/machinery/autolathe.dm
#	code/game/machinery/doors/door.dm
#	code/game/machinery/jukebox.dm
#	code/game/machinery/recharger.dm
#	code/game/machinery/vending.dm
#	code/game/mecha/equipment/tools/medical_tools.dm
#	code/game/mecha/equipment/weapons/weapons.dm
#	code/game/objects/items/devices/PDA/PDA.dm
#	code/game/objects/items/devices/megaphone.dm
#	code/game/objects/items/poi_items.dm
#	code/game/objects/items/weapons/implants/implantlanguage.dm
#	code/game/objects/items/weapons/storage/firstaid.dm
#	code/game/objects/items/weapons/tools/weldingtool.dm
#	code/game/objects/structures/flora/trees.dm
#	code/game/objects/structures/plasticflaps.dm
#	code/game/supplyshuttle.dm
#	code/game/turfs/simulated/wall_attacks.dm
#	code/modules/admin/admin_verbs.dm
#	code/modules/assembly/infrared.dm
#	code/modules/client/client procs.dm
#	code/modules/client/preference_setup/loadout/loadout_utility.dm
#	code/modules/client/preferences.dm
#	code/modules/clothing/suits/miscellaneous.dm
#	code/modules/holomap/holomap_datum.dm
#	code/modules/holomap/station_holomap.dm
#	code/modules/integrated_electronics/core/printer.dm
#	code/modules/mining/machine_processing.dm
#	code/modules/mob/living/carbon/human/human_defense.dm
#	code/modules/mob/living/carbon/human/species/virtual_reality/avatar.dm
#	code/modules/mob/living/death.dm
#	code/modules/mob/living/silicon/ai/ai.dm
#	code/modules/mob/living/silicon/pai/pai.dm
#	code/modules/mob/living/silicon/robot/robot.dm
#	code/modules/mob/living/simple_animal/animals/parrot.dm
#	code/modules/mob/mob_movement.dm
#	code/modules/organs/organ_external.dm
#	code/modules/organs/organ_icon.dm
#	code/modules/organs/subtypes/standard.dm
#	code/modules/planet/weather.dm
#	code/modules/power/cable.dm
#	code/modules/power/fusion/core/core_control.dm
#	code/modules/power/fusion/fuel_assembly/fuel_control.dm
#	code/modules/power/fusion/gyrotron/gyrotron_control.dm
#	code/modules/projectiles/gun.dm
#	code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm
#	config/names/first_name_skrell.txt
#	config/names/last_name_skrell.txt
#	icons/mob/head.dmi
#	icons/mob/robots.dmi
#	icons/mob/species/tajaran/helmet.dmi
#	icons/obj/ammo.dmi
#	icons/obj/gun.dmi
#	icons/obj/mining.dmi
#	icons/obj/projectiles.dmi
#	icons/obj/rig_modules.dmi
#	icons/obj/surgery.dmi
#	icons/turf/walls.dmi
#	maps/southern_cross/southern_cross-1.dmm
#	maps/southern_cross/southern_cross-3.dmm
#	maps/southern_cross/southern_cross-6.dmm
#	maps/southern_cross/southern_cross-8.dmm
#	maps/submaps/surface_submaps/mountains/backup/IceCave1.dmm
#	maps/submaps/surface_submaps/mountains/backup/IceCave1A.dmm
#	maps/submaps/surface_submaps/mountains/backup/IceCave1B.dmm
#	maps/submaps/surface_submaps/mountains/backup/IceCave1C.dmm
#	maps/submaps/surface_submaps/mountains/crashedcontainmentshuttle.dmm
#	maps/submaps/surface_submaps/mountains/deadspy.dmm
#	maps/submaps/surface_submaps/mountains/mountains_areas.dm
#	maps/submaps/surface_submaps/plains/Thiefc.dmm
#	maps/~map_system/maps.dm
#	vorestation.dme
2018-09-27 18:01:09 -04:00
Anewbe
f452e66934 Scrubbers no longer automatically scrub phoron (#5512) 2018-09-06 15:51:58 -07:00
Atermonera
de65c3c643 NanoUI now processes again 2018-08-25 21:13:16 -07:00
Anewbe
729ce71aa0 Converts most istype(thing,tool) procs into an appropriate thing.is_tool() format 2018-08-02 21:45:15 -05:00
Leshana
6756c5a483 Merge branch 'master' of https://github.com/PolarisSS13/Polaris into polaris-sync-2018-03-30
# Conflicts:
#	.travis.yml
#	code/ATMOSPHERICS/components/unary/outlet_injector.dm
#	code/__defines/_planes+layers.dm
#	code/__defines/chemistry.dm
#	code/__defines/mobs.dm
#	code/_helpers/mobs.dm
#	code/_onclick/hud/robot.dm
#	code/game/area/areas.dm
#	code/game/machinery/computer/supply.dm
#	code/game/machinery/cryopod.dm
#	code/game/machinery/doors/airlock.dm
#	code/game/objects/items/devices/communicator/UI.dm
#	code/game/objects/items/devices/communicator/messaging.dm
#	code/game/sound.dm
#	code/game/supplyshuttle.dm
#	code/game/turfs/flooring/flooring_decals.dm
#	code/modules/admin/admin.dm
#	code/modules/client/preference_setup/occupation/occupation.dm
#	code/modules/events/event_container.dm
#	code/modules/mob/dead/observer/observer.dm
#	code/modules/mob/language/language.dm
#	code/modules/mob/living/carbon/human/human.dm
#	code/modules/mob/living/carbon/human/human_powers.dm
#	code/modules/mob/living/carbon/human/life.dm
#	code/modules/mob/living/carbon/human/species/species_shapeshift.dm
#	code/modules/mob/living/living.dm
#	code/modules/mob/living/living_powers.dm
#	code/modules/mob/living/say.dm
#	code/modules/mob/living/simple_animal/animals/bear.dm
#	code/modules/mob/living/simple_animal/animals/cat.dm
#	code/modules/mob/living/simple_animal/animals/parrot.dm
#	code/modules/mob/logout.dm
#	code/modules/mob/mob_helpers.dm
#	code/modules/organs/organ.dm
#	code/modules/organs/organ_icon.dm
#	code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Medicine.dm
#	code/modules/reagents/reagent_containers/syringes.dm
#	code/modules/shuttles/shuttle.dm
#	html/changelogs/.all_changelog.yml
#	maps/RandomZLevels/wildwest.dm
#	maps/southern_cross/items/clothing/sc_head.dm
#	maps/southern_cross/southern_cross-1.dmm
#	vorestation.dme
2018-03-31 09:20:59 -04:00
Leshana
1ae7f45f1f Merge branch 'master' into vplk-port-pipeland-theta 2018-03-28 17:47:21 -04:00
Aronai Sieyes
7d3aec96fd Arranges lots of things into planes (#5072)
* Rearranges a billion things into planes

* Make cryotubes fancy

* Update Travis

* Fix hiding logic
2018-03-28 12:59:12 -07:00
Leshana
131636c6b5 Fix pipe construction conflicting with existing pipes too much.
Bug in the init_dirs_cache was not setting direction of pipes, making all cached dirs be for south.
Because mapped in pipes didn't have piping layer set, mapped in pipes conflicted.
The full-tile check for unary machines forgot to exclude *itself*
2018-03-20 23:30:05 -04:00
Leshana
776b221828 Rewrite pipe construction
- Moved pipe construction defines into __defines/construction.dm
- Unified pipe *unwrenching* by creating a standard proc along with the `construction_type` var.
- Eliminated the pipe fitting name & icon_state lookup tables by adding `pipe_state` var on atmos machinery and referencing that.
    - Each pipe which can be made from a fitting object should override `pipe_state` with the icon state to be used on the pipe fitting object.
- Eliminated the giant switch statement of doom in pipe construction by delegating that work to `on_construction` proc.
    - To make this work, every pipe must implement `get_neighbor_nodes_for_init` which returns a list of nodes which should be re-initialized on that pipe's construction.
- Combined the SCRUBBERS, SUPPLY and REGULAR pipe fitting classes together by storing the `piping_layer` variable and using the `setPipingLayer` procs
- Standardized the code for searching for node neighbors into the `can_be_node` proc.
    - This proc is also improved in that is a mutual check, `check_connectable` is called on BOTH objects, so they have to mutually agree to connect as nodes. Eliminates lots of special edge case logic.
    - Updated all the `amos_init` procs to use `can_be_node`.  In the most common cases, even that boilerplate code is consolidated into the `STANDARD_ATMOS_CHOOSE_NODE` macro.
- Implemented `pipe_flags` which lets pipes declare (or override) certain requirements.
- Adds a "pipe_recipe" datum to help out things that construct pipes.  By taking it out of the dispenser, we open the road for multiple dispenser types.  No, no RPD yet.  Soon.
    - Enhances the pipe dispenser to operate on pipe recipe datums instead of hard coded lists of pipes it can construct.   These datums are also (partially) initialized from the pipe machine types themselves, reducing having to define stuff in multiple places.
    - Switched pipe dispenser UI to use browse().   Not a NanoUI, but makes it a bit prettier with low effort.
    - Changed pipe dispenser to use a button selector to switch between Regular/Scrubbers/Supply instead of having separate list items.
- Added icon states to HE pipes to support the "connected on neither side" state.
2018-03-20 23:29:27 -04:00
Leshana
d8938a4e5b Fix pipe construction conflicting with existing pipes too much.
Bug in the init_dirs_cache was not setting direction of pipes, making all cached dirs be for south.
Because mapped in pipes didn't have piping layer set, mapped in pipes conflicted.
The full-tile check for unary machines forgot to exclude *itself*
2018-03-09 12:36:43 -05:00
Leshana
63a1dd0143 - Moved pipe construction defines into __defines/construction.dm
- Unified pipe *unwrenching* by creating a standard proc along with the `construction_type` var.
- Eliminated the pipe fitting name & icon_state lookup tables by adding `pipe_state` var on atmos machinery and referencing that.
    - Each pipe which can be made from a fitting object should override `pipe_state` with the icon state to be used on the pipe fitting object.
- Eliminated the giant switch statement of doom in pipe construction by delegating that work to `on_construction` proc.
    - To make this work, every pipe must implement `get_neighbor_nodes_for_init` which returns a list of nodes which should be re-initialized on that pipe's construction.
- Combined the SCRUBBERS, SUPPLY and REGULAR pipe fitting classes together by storing the `piping_layer` variable and using the `setPipingLayer` procs
- Standardized the code for searching for node neighbors into the `can_be_node` proc.
    - This proc is also improved in that is a mutual check, `check_connectable` is called on BOTH objects, so they have to mutually agree to connect as nodes. Eliminates lots of special edge case logic.
    - Updated all the `amos_init` procs to use `can_be_node`.  In the most common cases, even that boilerplate code is consolidated into the `STANDARD_ATMOS_CHOOSE_NODE` macro.
- Implemented `pipe_flags` which lets pipes declare (or override) certain requirements.
- Adds a "pipe_recipe" datum to help out things that construct pipes.  By taking it out of the dispenser, we open the road for multiple dispenser types.  No, no RPD yet.  Soon.
    - Enhances the pipe dispenser to operate on pipe recipe datums instead of hard coded lists of pipes it can construct.   These datums are also (partially) initialized from the pipe machine types themselves, reducing having to define stuff in multiple places.
    - Switched pipe dispenser UI to use browse().   Not a NanoUI, but makes it a bit prettier with low effort.
    - Changed pipe dispenser to use a button selector to switch between Regular/Scrubbers/Supply instead of having separate list items.
- Added icon states to HE pipes to support the "connected on neither side" state.
2018-03-04 14:49:33 -05:00
Leshana
ba36595263 Consolidated digital t-valves type paths.
- Because mirroring is now *much* easier to setup than digital remote control, we reverse the order of inheritance to de-duplicate all the radio code from digital t-valves!
- This requires changing the following type paths:
    /obj/machinery/atmospherics/tvalve/mirrored/digital  -> /obj/machinery/atmospherics/tvalve/digital/mirrored
    /obj/machinery/atmospherics/tvalve/mirrored/digital/bypass -> /obj/machinery/atmospherics/tvalve/digital/mirrored/bypass
- Change made on all maps.

- We can eliminate any overriden methods at all on flipped trinary devices by making a `mirrored` and `tee` variable!  This allows us to do things like flip them without delete/spawning.
- T-Valves are also basically trinary.  Sadly they are not a subtype, so to share code with them I have to put it into an outside proc.  But still worth it.
2018-02-22 15:11:55 -05:00
Leshana
1d3697c68a Went even farther in consolidation of trinary atmospherics.
- We can eliminate any overridden methods at all on flipped trinary devices by making a `mirrored` and `tee` variable!  This allows us to do things like flip them without delete/spawning.
- T-Valves are also basically trinary.  Sadly they are not a subtype, so to share code with them I have to put it into an outside proc.  But still worth it.
2018-02-22 15:10:43 -05:00
Leshana
b70451cda6 Eliminated duplicate code in trinary components.
- Consolidate common functions into trinary_base
- The only real difference in atmos_init was which direction each node would connect in.  Delegated that to an overridable proc, and the rest can be consolidated. Same story for update_underlays()
- Used similar patterns on tvalves which also are trinary even tho they are not subtyes of trinary (for some reason)
2018-02-22 15:10:29 -05:00
Leshana
086d7f9d3e Consolidated digital t-valves type paths.
- Because mirroring is now *much* easier to setup than digital remote control, we reverse the order of inheritance to de-duplicate all the radio code from digital t-valves!
- This requires changing the following type paths:
    /obj/machinery/atmospherics/tvalve/mirrored/digital  -> /obj/machinery/atmospherics/tvalve/digital/mirrored
    /obj/machinery/atmospherics/tvalve/mirrored/digital/bypass -> /obj/machinery/atmospherics/tvalve/digital/mirrored/bypass
- Change made on all maps.

- We can eliminate any overriden methods at all on flipped trinary devices by making a `mirrored` and `tee` variable!  This allows us to do things like flip them without delete/spawning.
- T-Valves are also basically trinary.  Sadly they are not a subtype, so to share code with them I have to put it into an outside proc.  But still worth it.
2018-02-22 15:00:32 -05:00
Leshana
fefbcf6ba2 Went even farther in consolidation of trinary atmospherics.
- We can eliminate any overridden methods at all on flipped trinary devices by making a `mirrored` and `tee` variable!  This allows us to do things like flip them without delete/spawning.
- T-Valves are also basically trinary.  Sadly they are not a subtype, so to share code with them I have to put it into an outside proc.  But still worth it.
2018-02-22 14:58:28 -05:00
Leshana
edd1cfd316 Eliminated duplicate code in trinary components.
- Consolidate common functions into trinary_base
- The only real difference in atmos_init was which direction each node would connect in.  Delegated that to an overridable proc, and the rest can be consolidated. Same story for update_underlays()
- Used similar patterns on tvalves which also are trinary even tho they are not subtyes of trinary (for some reason)
2018-02-21 20:43:40 -05:00
Leshana
5847319443 Update every initialize() proc to return an initialize hint.
* Yes, all of them.
* Also did a few corrections to redundant New() and broken Destroy() along the way
* Renamed the turf_initializer.initialize() proc to InitializeTurf to avoid confusion.
* Subsumed /area/proc/initialize into /atom/proc/initialize() - Made /area's LateInitialize to get same behavior as before.
2018-02-05 15:50:13 -05:00
Leshana
17cfeaa518 Add "shuttle" vent pump.
Adds an exterior vent pump that pumps air to/from the turf *front* of it, so it can be mounted on a shuttle but exchange air outside the shuttle.
2018-02-04 18:54:19 -05:00
Leshana
cef001bf2a Update every initialize() proc to return an initialize hint.
* Yes, all of them.
* Also did a few corrections to redundant New() and broken Destroy() along the way
* Renamed the turf_initializer.initialize() proc to InitializeTurf to avoid confusion.
* Subsumed /area/proc/initialize into /atom/proc/initialize() - Made /area's LateInitialize to get same behavior as before.
2018-02-03 01:00:57 -05:00
Leshana
27c3272821 Merge remote-tracking branch 'upstream-polaris/master' into polaris-sync-2018-01-27
# Conflicts:
#	code/ZAS/_docs.dm
#	code/__defines/mobs.dm
#	code/game/turfs/flooring/flooring_decals.dm
#	code/game/turfs/simulated/walls.dm
#	code/modules/client/preference_setup/loadout/loadout_utility.dm
#	code/modules/lore_codex/codex.dm
#	code/modules/mob/living/life.dm
#	code/modules/mob/living/living_defines.dm
#	maps/southern_cross/southern_cross-1.dmm
#	maps/southern_cross/southern_cross-3.dmm
#	maps/southern_cross/southern_cross-6.dmm
#	maps/southern_cross/southern_cross-7.dmm
#	maps/southern_cross/southern_cross_jobs.dm
#	vorestation.dme
2018-01-27 23:08:53 -05:00
Leshana
972acdaf2c Even more GC fixes
* Fixes /obj/machinery/atmospherics/omni mixer and filter's being GC-able
* Fixes /obj/machinery/power/sensor being GC-able
2018-01-23 13:24:31 -05:00
Leshana
440141c054 Fixes #2820 - Vent pumps shutting down after some template loads
Specific situation happens when power_change() is called before atmos_init is called for the first time()
update_icons has no business modifying variables like use_power.  Just update the icon!
2018-01-23 13:24:31 -05:00
Leshana
cba712992a Fixes #2820 - Vent pumps shutting down after some template loads
Specific situation happens when power_change() is called before atmos_init is called for the first time()
update_icons has no business modifying variables like use_power.  Just update the icon!
2018-01-22 19:21:56 -05:00
Leshana
ab87edeae9 Fix construction of HE pipes, Vents, and Scrubbers Plus qdel issues.
The initialize() routines of HE pipes, vents an scrubbers need to be atmos_init() after all.
If you register yourself with radio controller you need to de-register yourself too.
2018-01-19 23:45:40 -05:00
Leshana
e49d87bc2a Fix construction of HE pipes, Vents, and Scrubbers Plus qdel issues.
The initialize() routines of HE pipes, vents an scrubbers need to be atmos_init() after all.
If you register yourself with radio controller you need to de-register yourself too.
2018-01-19 23:21:55 -05:00
Leshana
807f1c7b4b Merge remote-tracking branch 'polaris-upstream/master' into polaris-sync-2018-01-09
# Conflicts:
#	code/game/objects/items/devices/communicator/UI.dm
#	code/game/objects/structures/flora.dm
#
2018-01-09 14:40:09 -05:00
Leshana
224fe42e77 Prepare Atmospherics Machinery for SSatoms (#4501)
* to_chat() replacement.

* Revert calling target.init_dir() before connecting.

* This change was added in https://github.com/PolarisSS13/Polaris/pull/3775 to counteract `dir` not being set prior to New() for dynamically loaded maps.  The root cause was /atom/New() not calling _preloader.load().  Undoing the change now that /atom/New() is fixed.
* The addition of the init_dir() proc itself however, is useful, because there ARE other times some atmos machinery will want to re-initialize its dir, specifically whenever it is rotated.
* init_dir() must be called in the constructor of all atmospherics machines capable of connecting to another.   Since it has to happen for ALL machines, lets move that call to /obj/machinery/atmospherics/New()

* Rename /obj/machinery/atmospherics initialize() to atmos_init()

* These days `initialize()` is used to handle general object initialization that is moved outside of New().  The node connection discovery of atmos machinery needs to happen after all that, and so needs to be in a separate proc.
* Make sure to actually call atmos_init during system startup.
2018-01-06 10:52:56 -06:00
Leshana
28c193cbdb Merge remote-tracking branch 'refs/remotes/polaris-upstream/master' into polaris-sync-2018-01-04
# Conflicts:
#       code/game/objects/items/devices/communicator/communicator.dm
#       code/modules/client/preference_setup/occupation/occupation.dm
#       code/modules/mob/living/simple_animal/animals/cat.dm
#       code/modules/mob/mob_helpers.dm
#       code/unit_tests/zas_tests.dm
#       maps/southern_cross/southern_cross-1.dmm
#       maps/southern_cross/southern_cross-3.dmm
#       maps/southern_cross/southern_cross-6.dmm
#       vorestation.dme
2018-01-04 22:44:04 -05:00
Leshana
a97a574278 Transformed the machinery processor into an StonedMC subsystem
* This is PHASE 1 of a multi-phase conversion.  In this first phase we implement the subsystem, but leave it processing the existing global list variables.  In the next phase we will switch to use datum variables in the subsystem.  The main reason for splitting into two phases is ease of code review; change the meaningful code without the hundreds of machines -> SSmachines.machinery substitutions.
* We did declare macros for adding/removing things to the processing lists, and convert everywhere to use the macros.
* Added var/is_processing to /datum to keep track of whether an instance is already in a processing list (prevents it being in the list twice!) and also debugging, making sure its not in two lists etc.
* NOTE: The global machines list is **no longer sorted** for performance reasons.  As far as I know, the only module that actually ever cared was cameras.   Our camera system already handles its own sorting in the cameranets anyway, so it should no longer be needed.
2017-12-29 15:31:59 -05:00
Cyantime
6e24c453eb Merge branch 'master' into algaegen 2017-12-01 19:14:56 -05:00
Cyantime
ee435ef63f Unfix 2017-11-29 01:13:18 -05:00
Cyantime
9147613dbb Just the fixes 2017-11-29 01:09:01 -05:00
Cyantime
1dad838505 Build farms are unfilled by default 2017-11-28 22:51:43 -05:00
Cyantime
2c31da4064 Oxygen Generator improvements 2017-11-28 22:05:28 -05:00
killer653
1bb71ef429 Polaris Sync 2017-10-16 22:16:24 -04:00
killer653
fb8ba69ada Fixes all the other stuff 2017-10-15 20:56:13 -04:00
killer653
0080539924 More fixes 2017-10-15 19:54:50 -04:00
killer653
0f20177c5f Some more fixes 2017-10-15 19:02:26 -04:00
killer653
3cd3054811 Fixes filter being used, which prevented compiling 2017-10-15 19:01:55 -04:00
Cyantime
ede7f79dfe Forgot this. 2017-09-30 00:28:33 -04:00
Cyantime
36e78b48f1 Adds plasma research outpost. 2017-09-29 02:28:43 -04:00
Cyantime
56afe20d39 Fixes some trinary device direction initializations 2017-09-28 17:39:46 -04:00
killer653
bddfa16f82 Polaris sync 2017-09-15 21:17:34 -04:00
Anewbe
f3b989f33e Merge pull request #3809 from Cyantime/unwrench
Fixes pipe caps to always be removable
2017-09-11 17:21:10 -04:00
Cyantime
82626c6936 Removes pipe pressure check copypaste. Fixes pipe caps to always be removable. 2017-09-09 21:24:52 -04:00
Neerti
1bc28c07c0 Port's TG's Maploader 2017-09-08 12:49:26 -04:00