Fixes some other potential issues coming from changing a few del() to qdel().
Fixes not being able to shoot mob on same tile as the shooter.
Fixes being able to shoot oneself by simply clicking our mob.
Fixes not being able to shoot non human mobs right next to us.
Fixes throw_at() to look nicely for xeno leap by adding the diagonals_first argument.
Removes useless gateway/Crossed and gateway/Bumped().
Changes throw_at() to use diagonal directions.
I replaced the atom variable "throwpass" with the LETPASSTHROW pass_flags
I readded hit_check proc to catch things getting on the thrown thing's tile during its sleep(1) (especially needed for mobs running towards the thing), the only other possibility would've been to add throwing checks in atom/movable/Crossed() (called after every move) and I don't think it'd be worth it.
I added the item var "thrownby" to be able to continue to log the thrower of the item when it hits a mob. It removes the need for a thrower argument in throw_impact() and hitby().
Moved last_bumped var from movable to living.
Renamed /obj/machinery/field/proc/bump to bump_field() to avoid confusion with Bump(). Same thing with /obj/effect/mine/Bumped() -> triggermine().
Fixes sprite when hunter leaps into a wall. 10428
Removed some commented code here and there.
Remove allow_spin var, throw_at now uses a spin argument for that.
Throwpass atom var is no longer used to check whether thrown stuff can pass stuff (now using CanPass() proc like everything else), the var is still used for some adjacency click check.
A thrown mob hitting another mob now produces a sound; also thrown mob and target one no longer swap places even on help intent.
A thrown mob now is lightly hurt (and weakened) if he hits a wall/mob/dense object. Nerf the damage when thrown mob hit wall.(20 -> 10)
Thrown obj/mob no longer bounces off wall unless it's no grav. Heavy thrown items now push an unanchored obj/mob target.
Fixes losing all momentum when getting out of a thrown closet. 6569
A lot of work on throw_at, throw_impact, and hitby to make the code more OOP. Thrown items no longer collide with border items on the side. 10479
Fixes the killer crusher. 10507
Fixes lack of attack animation, sound and attack cooldown when the human mob attacks the hallucinated attacker.
Removes some commented code and some duplicated checks.
Reorganized the hallucination procs a bit.
Replacing some fo mob in viewers() show_message() with visible message().
Simplifying some message code in a couple places, fixing typos and span classes.
Replaces for(mob in oviewers) show_message() with visible_message() when possible.
Fixes the absolute pathing in Ninja code.
Fixes facehugger attack messages being bold red for third party (only the first leap message will stay bold red for third party, for better visibility)
Standardizes vomiting message
Fixes mech occupant not receiving any attack messages when the mech is attacked.
You can only use sabers to create a dualsword and to archieve the funky colours with the multitool.
Dualswords now will be eqipped on hand once created instead of staying on the floor.
Fixes issue #4050
Hopefully nothing went wrong but you never know.
Conflicts:
code/FEA/FEA_fire.dm
code/controllers/supply_shuttle.dm
code/game/gamemodes/changeling/changeling_powers.dm
code/game/machinery/autolathe.dm
code/game/machinery/drying_rack.dm
code/modules/hydroponics/hydroponics.dm
code/modules/projectiles/projectile/magic.dm
code/modules/reagents/Chemistry-Recipes.dm
code/modules/reagents/reagent_dispenser.dm
Replaces Holodamage with Stamina damage, if your stamina damage exceeds your current health, you get weaken(5)'d. Stamina heals itself slowly over time.
Makes the hallucination enemies deal more stamina damage than they did holodamage, but stamina damage heals now so it's mostly for just seeming threatening at the moment.
Adds the Disabler, a gun that does stamina damage. It has a range of your screen, but no more. Adds a disabler crate to cargo (security lock)
Fixes Lasertag ED209's because they were busted as shit
Reduces ED209's view range to 9 from 12, which was several times longer than your screen view, now is only a little bit more
Lastertag now does stamina damage instead of an instant stun for that GRITTY LASERTAG EXPERIENCE
Works pretty well. If it can't GC something, it'll just del() it and be done.
Speed is amazing, holy shit.
New procs you should be aware of:
qdel(atom/movable) - sets up an object for garbage collection. Call this rather than del(atom/movable).
atom/movable/Destroy() - called right before the object is GC'd, so it still has a loc. Also called if the object is del()'d.
new controller - garbage.dm has all the details on this. Basically it nulls all references on GC'd objects and force del() them if necessary.
Generally speaking, objects should use Destroy() for behavior prior to deletion rather than Del(). You should also always call the parent so the object gets the right gc_destroyed var set.
ISSUES:
Tries to GC mobs atm. This actually works for new players, not so much for humans/monkies/simple_animals/anything. I'm guessing it needs to clear out their mind and HUD and maybe other things.
Gibbing is really bugged. It works, but the overlays just sit there for awhile and ugh. I'm very tempted just to del() mob/living and mob/camera and call it a day.
qdel() equipment doesn't unequip the item.
Pipes don't generally GC correctly. Debugging suggests they get referenced in many pipenets and that isn't cleared properly. However some do work fine. Need assistance here.
Bots don't GC, probably in the radio controller.
Lots of other shit doesn't GC but it's hard to find them because of the pipe spam.
I think I'm calling Destroy() twice by accident.