Commit Graph

669 Commits

Author SHA1 Message Date
Aronai Sieyes
78d7ef1d72 Port Bay-style attack animations (#4827)
* POLARIS: Attack animations

* POLARIS: Overlay flick system

You can't do this in Byond, unfortunately, so here's some code from /tg/

* Make attack anims a preference
2018-02-15 22:02:04 -06:00
Leshana
676efe73e5 Move Xenoarcheology globals and initialization into a subsystem
* Move the global spawning_turfs lists from master_controller into SSxenoarch.  Rename all references.
* Move the call to SetupXenoarch from master_controller.setup() to SSxenoarch.Initialize()  Put SSxenoarch init order near the end to match current behavior.
2018-02-06 01:08:10 -05:00
Anewbe
f56597efed Merge pull request #4727 from VOREStation/vplk-bitfields
Code fix for stat_entry on NO_FIRE subsystems
2018-02-05 22:46:25 -06:00
Leshana
2c90995dcc Let objects register to be informed when shuttles have been setup.
* Switch /obj/shuttle_connector to use it instead of the icky process hack.
2018-02-05 15:50:15 -05:00
Leshana
8bec38ee00 Implement SSshuttles subsystem
* Replaces the shuttle_controller and shuttle process with the shuttles subsystem.  Instead of docking ports being initialized by the game ticker, its part of the StonedMC Master init order.
* The main advantage of this is control over the initialization order, as well as letting Master be aware of CPU we're using up with shuttle processing.
* By being part of the Master init order, we reduce the uncertainty about "are objects initialized yet?" which is nice, since shuttle docks break if machines aren't finished initializing!
2018-02-05 15:50:14 -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
44dc4b7286 Implement SSatoms
* Moves proc/initialize() from being on /atom/movable, /are and /turf/simulated to being on /atom - Now turfs can initialize too
* Added the SSatoms subsystem which controls initialization of atoms at roundstart and during normal conditions.
* Disabled the old auto_init = 0 behavior, ALL atoms should get initialized() called on them now.
* Refactored the way initialize() is called during /New() to utilize SSatoms instead of SScreation
* Removed SScreation, as it was only a stop-gap until SSatoms could be ported.
* Updated the maploader to inform SSatoms when it is loading maps instead of SScreation.
* Updated the template map loader to use SSatoms to perform initTemplateBounds
* Renamed 'initialized' var in seed_storage to deconflict.
* Removed usage of auto_init = 0, replaced with a no-op initialize() proc for atoms that don't need initialization.
2018-02-05 15:50:06 -05:00
Leshana
63a1806b41 Bitfields do not work that way.
Fix attempt to use `in` on a non-list.
2018-02-05 13:13:37 -05:00
Arokha Sieyes
13bfcf6bd3 Improve admin idlekick capability/awareness 2018-02-04 01:05:03 -05:00
Leshana
8c09d39ef1 Convert ZAS "Airflow" into a subsystem plus fixes
* Port of the "Airflow" portions of Yonaguni/EuropaStation#618
* The "airflow" part of ZAS used to be handled by a sleep'd loop.   This has the potential to bunch up and lag.  Switching to a StonedMC managed subsystem improves it.
* Fixed to ensure that zshadow mobs cannot be blown around by the wind no matter how fierce.
* Added a message to mobs informing them when their boots save them from being wind-thwapped.
* Check w_class on non-item objects if they have it defined (might as well since var/w_class is on /obj)
* Tiny optimization of c_airblock
2018-01-30 12:28:45 -05:00
Leshana
8e22707e24 Merge air_master into SSair, now its all one type 2018-01-30 12:28:45 -05:00
Leshana
5a2162a264 Preliminary implementation of ZAS as a StonedMC subsystem.
* Creates the SSair subsystem which replaces the Setup, Start(), and Tick() procs of air_master.
* It may be best to have SSair completely replace air_master, but for now we are having them work together.   It does completely replace the old processScheduer air ticker however.
* Remove the obsolete Setup and Tick procs.
* Adjust admin and debug verbs that dealt with some ZAS internals to work with the new implementation.
2018-01-30 12:28:45 -05:00
Leshana
9d700f5946 Fix writing [date] on paper and printout of ref in garbage collector error message. 2018-01-23 13:24:32 -05:00
Leshana
db0ba60f64 Implements the Tesla engine and supporting features (#4539)
* Adds "typecache" utility functions. A fast way to filter lists by type.

Ported from TG

* Ports the "orbit" feature and subsystem from TG

* Adds a feature that allows mobs and objs to "orbit" around some atom.  They literally are moved around in circles.  See the `orbit` proc in orbit.dm.
* Adds a subsystem that processes the actual movement of orbiting items.

* Adds utility methods for common machinery behavior.

* Adds default_unfasten_wrench which handles the standard anchor/unanchor behavior of wrenches being used on machines.  Together with the other default_x_tool machinery procs we can eliminate having that code duplicated in dozens of places!
* Adds is_wire_tool proc to easily detect when a machine is hit with a tool that should open its wires UI (if it has one).

Based on ideas from Paradise, with improvements for us.

* Implements the Tesla Engine

Ported from a mixture of TG and Paradise code and assets: Edison's Bane

Includes the tesla energy ball itself, the generator that makes it, tesla coils, grounding rods, the circuits and frames to build them.

* Switch dusting to zapping on impact and spin better

Ported /tg SpinAnimation which supports more than triangles.
2018-01-19 14:56:08 -06:00
Leshana
6bc422ff5e Ported VOREStation/VOREStation#461 - Allow greater customisation of wiki links 2018-01-17 16:46:48 -05:00
Anewbe
829cd092c8 Merge pull request #4534 from Neerti/1/14/2018_autopilot_and_other_shuttle_stuff
Web Shuttle Update
2018-01-15 11:15:02 -06:00
PrismaticGynoid
10b2cc7eef Multiple loadout slots (#4530)
* Multiple loadout slots

Ported from Bay. Each character can have 3 (number can be overridden by config) loadout slots. This way, you can have different outfits for different situations without needing to have a separate character slot or edit your loadout every time.

Tested here, works as intended. The current loadout is set as slot 1, so you don't need to worry about remaking it. This also ports the to_file and from_file macros to make it work, I'm assuming they could later be used elsewhere as well.

* Log of Changing
2018-01-14 14:47:47 -06:00
Neerti
d0d6689263 Web Shuttle Update
Adds autopilot functionality for shuttle one and shuttle two. It can be enabled and disabled by the flight computer.
Autopilot is active by default on both shuttles. The shuttle waits for two minutes when it reaches the outpost or station, except for the first flight, where it waits for about ten minutes, which should be plenty of time for people to get on and for the pilot to turn it off if one exists.
Adds renaming feature to all shuttles.
Ports /tg/'s 'shuttle warning' effect, which adds a bunch of blue circles where a ship is about to land, which should prevent surprise shuttle crushes if paying attention.
Flight times for all routes are cut in half to act as the bonus for flying manually. Automatic flight takes twice as long, and so it will take the current amount of time.
Makes Ninja shuttle faster because Nippen steal.
Does some cleanup with temporary effects.
2018-01-14 14:03:58 -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
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
Leshana
66e9d9cfdf Unify datum var definitions
Inspired by https://github.com/tgstation/tgstation/pull/29636
Also consolidated some sideways overridden /datum/Delete() here to reduce proc-call overhead.
2017-12-29 14:23:13 -05:00
Leshana
5ebcc92645 Port /tg garbage collection tweaks and statistics improvements
https://github.com/tgstation/tgstation/pull/30118 - Garbage collection tweaks and refactors.
https://github.com/tgstation/tgstation/pull/32022 - Find references fix.
2017-12-27 21:45:37 -05:00
Leshana
a435d73450 Ports /tg controller optimizations
https://github.com/tgstation/tgstation/pull/31092 - Fixes subsystems not returning a qdel hint
https://github.com/tgstation/tgstation/pull/31494 - In which the stoner one gets stoned and tries to address tick contention... again
https://github.com/tgstation/tgstation/pull/31950 - Removes an empty New()
https://github.com/tgstation/tgstation/pull/31951 - Logs subsystem shutdowns
2017-12-27 21:19:55 -05:00
Leshana
c6e8184b58 Ports https://github.com/tgstation/tgstation/pull/30184
* Adds defines for world.tick_usage
* This provides no useful benefit whatsoever, but /tg and Baystation12 have done it, so it will make porting future code easier if we do too.  No real harm done either.
2017-12-27 19:10:15 -05:00
Leshana
032d26010b Merging changes from /tg
https://github.com/tgstation/tgstation/pull/29637 Fixes subsystem MC crash tracking
https://github.com/tgstation/tgstation/pull/30092 Subsystem PreInit() now respects init_order
2017-12-27 18:58:51 -05:00
Woodratt
ed9395e58f SC Stupid Sized Map Update
Or how Woodrat spent too long on something that was supposed to be simple.

- Addition of a Explorer Radio Channel and headsets.
- Explorers and Search and Rescue job slots added
- Adjustments to the pilot job including getting rid of the flatcap
- Map fixes, adjustments, (including signs pointing to cryo) planetside side map additions splitting up of the wilderness into two area sections
- Disabled lighting on the arrivals shuttle area once it is docked with the station, should help with the whole issue of lighting bugging out and having dark space
- Fixed EMS jacket missing icons
- Fixed Research signs being missing for some reason, addition of directional signs for cryo
- Addition of a Search and Rescue Winter coat
- Probably a dozen other small bug fixes I forgot, and bug additions

Tested, seems fine. At least in short tests.
2017-12-24 07:04:34 -08:00
Neerti
fe33977812 Adds Submap (PoI) Seeding Procedure
Mostly ports /tg/'s method of seeding submaps into specific z-levels.
Due to the low number of submaps present, all of the PoIs are guaranteed to spawn. As more are added, this should fix itself.
2017-11-21 19:21:39 -05:00
Anewbe
cad5ef12e7 Does work on the event manager role again 2017-10-18 20:00:01 -05: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
Anewbe
4459d7087a Revert "Does more prep for the Event Manager role" 2017-10-04 18:33:34 -05:00
Anewbe
c2c6b5949a Does more prep for the Event Manager role 2017-10-02 21:51:48 -05:00
Neerti
aa454c0e1d Adds Farm PoI
Also fixes various bugs with surface tiles, hopefully.
Adds some documentation to the map file system.
Adds a new 'plane' map, ideal for testing PoIs by loading them manually.
Makes space heaters glow orange.
Adds a new grille type for fancy surface windows.
Adds self planting hydro trays/dirts if a seed is on top of them when the map is loaded.
2017-09-26 01:44:06 -04:00
Neerti
e703d629c6 Fixes the Sun/Weather and Ports Vore's Lighting SS
New lighting system is needed to handle updating literally 14k+ tiles whenever the sun moves.  The straight port seems to have had no adverse effects from what I could see.  Don't know if it's more performant but it doesn't seem to be less.

I didn't expect the latter would be needed for the former.
2017-09-22 12:16:21 -04:00
Anewbe
6ffebcef6e Merge pull request #3775 from Neerti/9/8/2017_tg_maploader_port
Port's TG's Maploader
2017-09-11 17:17:23 -04:00
Neerti
1bc28c07c0 Port's TG's Maploader 2017-09-08 12:49:26 -04:00
Neerti
8f00965cc2 Merge branch 'master' of https://github.com/PolarisSS13/Polaris into 8/10/2017_make_xenobio_old_again
# Conflicts fixed:
#	code/modules/admin/topic.dm
#	code/modules/admin/verbs/debug.dm
#	code/modules/admin/view_variables/helpers.dm
#	code/modules/mob/living/simple_animal/simple_animal.dm
#	code/modules/mob/transform_procs.dm
#	maps/northern_star/polaris-1.dmm
#	polaris.dme
2017-09-05 00:58:27 -04:00
Neerti
4bfcec55f2 work 2017-09-04 21:52:47 -04:00
Woodratt
10c8586db0 Rough port of
a8c9bb786a

Unsure if I even did it correctly, but seems to function in the brief tests done, no compile errors.

In preparation of porting the massive number of floor decals for the new map.
2017-08-21 14:44:25 -07:00
Neerti
9d98406833 Makes Arrivals Shuttle Great
Arrivals shuttle now moves automatically to and from the station.  People still spawn onboard if they join the round with arrivals selected in preferences.
The shuttle is completely automated and will go to the station if someone boards it, and leave if nobody is onboard.
Changes some tape code so it can be mapped in.
Sadly the mapmerger is broken so the map file diff is massive.
2017-08-05 15:18:55 -04:00
Spades
7e4417d31f It's CentCOM not CentCOMM
I swear to god I have fixed this like three times already and somehow it
keeps coming back.
2017-07-21 04:29:39 -04:00
Neerti
7bd7e83250 Removes staff exemption for AFK kicking.
As requested by a few staff members, this serves to keep the staffwho list more representative of who is actually available to help.
The current inactivity timer is rather generous so hopefully this won't impede admins who are actually there.
2017-06-24 15:15:11 -04:00
Anewbe
3997a1510a Merge pull request #3526 from VOREStation/stonedmc-update
StonedMC Update & Hookup
2017-06-16 16:22:26 -05:00
Leshana
2cd91c8bfc Fix /datum/scheduled_task was unable to be GC'd and was deleted.
In addition to fixing the problem, it makes sense.  The observer pattern is overkill for an object type we own; doing it directly in Destroy() is more efficient.
2017-06-14 01:07:35 -04:00
Neerti
18012fa1d1 Port's Bay's Shuttle Cleanup
Shuttles now set themselves up upon being instantiated instead of relying on a monolithic proc in the shuttle controller.
Shuttles can now be defined more cleanly on a per-map basis, as well.
Accidentally fixes a broken admin shuttle.
2017-06-11 11:45:31 -04:00
Leshana
82e6049821 Actually hooks up the StonedMC to run its subsystems in Polaris
* Hooks up informing Master the gameticker actually starts and stops the round subsystems will actually fire! What ho!
* We should convert the gameticker as an MC subsystem someday, and probably completely rewrite it while we are at it becuase it is crazy.  But this should bridge the gap until then.
2017-06-10 19:01:58 -04:00
Leshana
fb92653ac9 Ports "Makes global master vars static"
* https://github.com/tgstation/tgstation/pull/27523
2017-06-10 19:01:58 -04:00
Leshana
6a8abd4f80 Ports tg improvements in StonedMC subsystem
* Ports /tg StonedMC Enhancement - Runlevels - Lets services more precicely define when they want to fire - in the lobby, during game, only after, etc. Includes bugfixes from:
  * https://github.com/tgstation/tgstation/pull/27132
  * https://github.com/tgstation/tgstation/pull/27338
  * https://github.com/tgstation/tgstation/pull/27576
  * https://github.com/tgstation/tgstation/pull/27519
* Ports Standardizes subsystem Shutdown order - https://github.com/tgstation/tgstation/pull/26228
2017-06-10 19:01:58 -04:00
Leshana
82e90a206c Ports "Better repeated MC crash handling"
* From https://github.com/tgstation/tgstation/pull/25813
* If the MC crashes: The problem subsystem will be rebooted on its 2nd strike and disabled on its third.
2017-06-10 19:01:58 -04:00
Leshana
60ffe4b00f Ports garbage collector improvements and bugfixes from tg
* Writes a log of qdel() problems in a condensed format at the end of each round - tgstation/tgstation/pull/26135
* Moves hard dels into their own proc so that it can be profiled more easily, and uses it for the various types.  Includes bugfixes too
  * https://github.com/tgstation/tgstation/pull/26210
  * https://github.com/tgstation/tgstation/pull/26570
* Fix a bug with qdeling non-datums - https://github.com/tgstation/tgstation/pull/27434
* Fix typo - https://github.com/tgstation/tgstation/pull/27730
2017-06-08 00:11:59 -04:00