Commit Graph

54 Commits

Author SHA1 Message Date
CPTANT
801ae39391 makes disposals construction faster 2017-02-18 13:20:18 +01:00
Joan Lung
eb9a1009d3 Perpetual 2017-02-12 15:55:35 -05:00
Joan Lung
ca4b081e26 Fixes RPDs (#23985) 2017-02-11 17:51:34 -06:00
Joan Lung
e8b8e27789 Fixes being unable to place RPDs into storage items 2017-02-09 15:41:45 -05:00
Cyberboss
ff1b515b77 Fixes RPD aggression (#23724) 2017-02-06 18:25:50 +13:00
bgobandit
fbf5c902f6 spelling issues too how quaint 2017-01-07 12:53:27 -05:00
Mervill
417c50efa2 These comments where removed by me.exe, just now 2016-12-08 01:48:46 -08:00
Kyle Spier-Swenson
dedb16826e Speeds up world init. (93s -> 49s) (#21992)
* Speeds up world init.

* Armor is now new inited for obj and the first level of subpaths.
* Actions is now lazyinited and deleted with empty.
* Actiontypes is now only inited when actually used and deleted once it pre-fills actions with the action buttons.
* Pipes now prefill their node list(s) in new() using new /list/ (count) syntax to speed up the list initaliztions and remove the init proc.
* Pipes no longer store their item version, instead creating it on the fly when deconned
* Walls no longer store their metal stacks, instead creating it on the fly when deconned.
* obj, walls, floor, plating, item, machinery, structure, pipe, pipenet, atom, and movable no longer have an (init) proc. (along with a few other smaller examples)
* Atmos can pass checking is now a var with the ability to have a proc be call in advance cases.
  * (as a side effect, I had to fix a few things that were calling atmosCanPass rather then using the pre-calculated list, this should speed up chemfoam and flame effects greatly)

* Reverts upload limit
(remind me one day to defuck this, it could easily be a config thats not editable by vv to make changes easier)

* Makes apc update icon a bit faster.
APC new is some what high on the profile of world init, still not sure why, but this stood out as a waste of cpu so i fixed it.

* Fixes runtime with atmos backpack water tanks.

* Makes smoothing faster (and fixes turfs smoothing twice at init)

* Makes apcs init faster by replacing some spawns with addtimer

* fix transit turfs.
2016-12-08 21:50:15 +13:00
Mervill
09ea5ad2e5 w_class now uses defines 2016-12-01 21:33:14 -08:00
phil235
029bc65b93 Merge branch 'master' of https://github.com/tgstation/-tg-station into Color_washing
# Conflicts:
#	code/game/atoms.dm
#	code/game/gamemodes/nuclear/nuclearbomb.dm
2016-10-19 01:56:02 +02:00
phil235
240f3a4c49 Adding var/list/atom_colours to /atom .
The var will be used to store the various coloring that happen for the atom so that we can separate paint coloring from color that must be inherent to the atom (an initial color for example), or from certain coloring effect like revenant's blight, mob electrocution's black color, admin edit of the color var, green color from holding the greentext item, etc.
The list has four elements, used for four categories:
ADMIN_COLOUR_PRIORITY for admin varedits and very rate color effect like holding the greentext item (and other effects that should prime over any other potential source of coloring even temporary effects).
TEMPORARY_COLOUR_PRIORITY for short color effects like revenant blight on mob, mob electrocution making you all black for a couple seconds, effects that should be appearing above paint coloring.
WASHABLE_COLOUR_PRIORITY for pretty much all paint coloring like colorful reagent on mobs, coloring turfs with paint, etc.
FIXED_COLOUR_PRIORITY for color inherent to the atom, like a blob's color, any object with a color value given in its definition.

Fixes electocution animation on mob not making the mob all black (with the skeleton overlay blinking over it)
Spray cleaner and soap can now wash paint off mobs, turfs and objects.
2016-10-19 01:51:30 +02:00
Joan Lung
4cddd81120 Suicide now uses the pronoun helpers (#20973)
* This doesn't actually matter, because you're dead forever once it happens...

* is this entire pr chaff for something else

* you'll do it? nah, fuck that I'll do it
2016-10-18 14:36:38 +13:00
Joan Lung
ce13143d9d Replaces yet more istypes with helpers (#20806)
* uses more istype helpers

* oranges is inefficient
2016-10-10 17:48:35 +13:00
phil235
5f835bfc26 Obj damaging system, acid damage, and fire damage refactor (WIP) (#20793)
Please refer to #20867 and #20870 for a easier view of the changes. Those two PRs show all meaningful changes (hopefully) and doesn't show the files changed with just 3 lines changed.

This PR does three things:

    It makes all children of /obj/ use the same damage system.
    Previously to make your new machine/structure be destroyable you needed to give it a var/health, and its own version of many damage related proc such as bullet_act(), take_damage(), attacked_by(), attack_animal(), attack_hulk(), ex_act(), etc... But now, all /obj/ use the same version of those procs at the /obj/ level in code/game/obj_defense.dm. All these obj share the same necessary vars: obj_integrity (health), max_integrity, integrity_failure (optional, below that health level failure happens), and the armor list var which was previously only for items, as well as the resistance_flags bitfield. When you want your new object to be destroyable, you only have to give it a value for those vars and maybe override one proc if you want a special behavior but that's it. This reorganization removes a lot of copypasta (most bullet_act() version for each obj were nearly identical). Two new elements are added to the armor list var: fire and acid armor values.
    How much damage an obj take depends on the armor value for each damage category. But some objects are INDESTRUCTIBLE and simply never take any damage no matter the type.
    The armor categories are:
    -melee(punches, item attacks, xeno/animal/hulk attacks, blob attacks, thrown weapons)
    -bullet
    -laser
    -energy (used by projectiles like ionrifle, taser, and also by EMPs)
    -bio (unused for this, only here because clothes use them when worn)
    -rad (same)
    -bomb (self-explanatory)
    -fire (for fire damage, not for heat damage though)
    -acid
    For machines and structures, when their health reaches zero the object is not just deleted but gets somewhat forcedeconstructed (the proc used is shared with the actual deconstruction system) which can drops things. To not frustrates players most of these objects drop most of the elements necessary to rebuild them (think window dropping shards). Machines drop a machine frame and all components for example (but the frame can then be itself smashed to pieces).
    For clothes, when they are damaged, they get a "damaged" overlay, which can also be seen when worn, similar to the "bloody" overlay.

    It refactors acid. See #20537.
    Some objects are ACID_PROOF and take no damage from acid, while others take varying amounts
    of damage depending on their acid armor value. Some objects are even UNACIDABLE, no acid effect can even land on them. Acid on objects can be washed off using water.

    It changes some aspect of damage from fires.
    All /obj/ can now take fire damage and be flammable, instead of just items. And instead of having just FLAMMABLE objs that become ON_FIRE as soon as some fire touch them (paper), we now have objects that are non flammable but do take damage from fire and become ashes if their health reaches zero (only for items). The damage taken varies depending on the obj's fire armor value and total health. There's also still obj and items that are FIRE_PROOF (although some might still be melted by lava if they're not LAVA_PROOF).
    When a mob is on fire, its clothes now take fire damage and can turn to ashes. Similarly, when a mob takes melee damages, its clothes gets damaged a bit and can turn to shreds. You can repair clothes with cloth that is produceable by botany's biogenerator.

    It also does many minor things:
        Clicking a structure/machine with an item on help intent never results in an attack (so you don't destroy a structure while trying to figure out which tool to use).
        I moved a lot of objects away from /obj/effect, it should only be used for visual effects, decals and stuff, not for things you can hit and destroy.
        I tweaked a bit how clothes shredding from bombs work.
        I made a machine or structure un/anchorable with the wrench, I don't remember which object...
        Since I changed the meaning of the FIRE_PROOF bitflag to actually mean fire immune, I'm buffing the slime extract that you apply on items to make them fire proof. well now they're really 100% fire proof!
        animals with environment_smash = 1 no longer one-hit destroy tables and stuff, we give them a decent obj_damage value so they can destroy most obj relatively fast depending on the animal.
        Probably a million things I forgot.

If you want to know how the damage system works all you need is the three obj vars "obj_integrity", "max_integrity", "integrity_failure", as well as the armor list var and the resistance_flags bitfield, and read the file obj_defense.dm
2016-10-10 11:14:59 +13:00
Remie Richards
b3b60b187b Manual repair of some edge cases. 2016-06-11 23:11:54 +01:00
Remie Richards
fda2c699fc Automatic conversion via Regex 2016-06-11 18:37:48 +01:00
c0
846d419b30 Moves tools from items.dmi to tools.dmi 2016-04-30 04:12:12 +03:00
phil235
43e98079f1 Removing some comments I had left in. 2016-04-24 21:12:04 +02:00
phil235
0caa59b21a First commit of this big PR
These are the files with just tiny tweaks. Mostly modify an object's attackby so it does "return ..()" instead of "..()".
If there are other things in this commit, the PR's description will explain them.
2016-04-24 20:26:24 +02:00
duncathan
a2a554c48a Merge branch 'master' of https://github.com/tgstation/-tg-station into turfs
Conflicts:
	code/game/objects/explosion.dm
	code/game/objects/items/stacks/sheets/mineral.dm
	code/game/objects/structures/girders.dm
	code/game/objects/structures/grille.dm
	code/game/turfs/turf.dm
	code/modules/events/spacevine.dm
	code/modules/events/wormholes.dm
	code/modules/mining/mine_items.dm
	code/modules/mob/living/silicon/robot/robot.dm
2016-04-03 18:22:20 -06:00
duncathan
e86cf0f280 praise the good lord, for the game finally compiles 2016-03-29 19:04:37 -06:00
c0
f71ab62e79 HUD item slots no longer show item placeholders when there are actual items inside 2016-03-22 08:00:38 +03:00
Menshin
8c41e37d3e * RPD now starts in pipe building mode
* Removed unused var
2016-02-25 13:51:11 +01:00
Firecage
7f96592b87 Merge Conflict Fix 2016-01-27 13:29:38 +02:00
Tkdrg
773f0f7c21 Fixes RPD/disposals exploits
Also removes a bit of copy-paste and speeds up a helper slightly.

Fixes #13473
Fixes #14654
2016-01-24 16:23:20 -03:00
Firecage
332bde0f4f Does the rest of the if()'s/ else's 2016-01-17 19:03:12 +02:00
phil235
d3ee910211 Makes effect system code more OOP.
obj/effect/effect is now renamed obj/effect/particle_effect for better usability.
datum/effect/system and /datum/effect/effect/system are now both /datum/effect_system.
Fixes a bug where wall mounted igniters (and other spark producing objects) didn't produce sparks sometimes.
Moved explosion_particles.dm into the effect_system folder, because it has effect_systems code.
2015-10-21 23:28:29 +02:00
Razharas
9d8cf0ffe9 Merge branch 'hemanifolds' of https://github.com/duncathan/-tg-station into duncathan-hemanifolds 2015-09-25 16:35:08 +03:00
Lijah99
884efcb308 adds a suicide message for the rpd 2015-09-20 20:30:28 -06:00
bear1ake
f697ae90f5 removes a bunch of .0 2015-09-10 20:57:30 +09:00
duncathan
3e4299105d adds heat exchanging manifolds, both 3-way and 4-way 2015-09-06 15:06:59 -06:00
xxalpha
3379cb8145 Fixed cyborg modules, cyborg parts and cyborgs not qdelling properly. 2015-08-29 19:24:36 +01:00
duncathan
0e78170041 fixes deconstruction and RPD 2015-08-16 14:55:33 -06:00
duncathan
d320c4c945 first pass of cleaning up construction.dm + merge from upstream 2015-08-14 20:55:09 -06:00
duncathan
50fb67ca65 how can one man be so bad at git 2015-07-16 16:07:22 -06:00
Firecage
4688c2c969 Fixes proc arguments 2015-07-15 23:52:35 +02:00
duncathan
c870469a39 speeds up RPD and pipe unwrenching 2015-07-10 18:03:43 -06:00
xxalpha
cfb5e724b6 Material container, all items can have materials, wake me up
cant wake up

go to sleep debug
2015-07-01 03:34:47 +01:00
Iamgoofball
a8ec1c76df Merge branch 'master' of https://github.com/tgstation/-tg-station into graphics
Conflicts:
	code/ATMOSPHERICS/atmospherics.dm
	code/game/machinery/computer/computer.dm
	code/game/objects/items/weapons/explosives.dm
	code/game/objects/structures/crates_lockers/closets/fireaxe.dm
	code/game/objects/structures/musician.dm
	code/game/objects/structures/tables_racks.dm
	code/game/objects/structures/window.dm
2015-06-23 12:54:26 -07:00
Iamgoofball
c2256d41fc BAR NOW SHOWS UP ON THE OBJECT YOU'RE INTERACTING WITH 2015-06-13 13:58:08 -07:00
duncathan
dab13732fe cleans up icon paths; modifies certain unary devices
updates icon paths in multiple files
removed insulated icon state in pipe_item.dmi (insulateds are deaaaad)
lays an icon framework so that o2 generators, cold sinks, heat sinks may eventually be made constructable
  they no longer override update_icon() but instead update like just about every other device
  eventually I'll give these real sprites but given that they're unused it can wait for now
  sprites and construction are outside the scope of this PR
makes heat exchangers update their color based on their node
  because heat exchangers are different sprite-wise they had to override update_icon entirely
makes heat exchanger, heat sinks, cold sinks, o2 generators non-dense
2015-06-13 02:43:17 -06:00
duncathan
f4f5ccae61 cleanup of various unused/useless things
removed unused pipe vars alert_pressure, fatique_pressure, maximum_pressure
moved pipe vars maximum_temperature_difference, thermal_conductivity to h/e pipes
removed insulated pipes, as they are identical to simple pipes in every way
removed insulated pipes from RPD.dm, pipe_dispenser.dm and construction.dm
removed red_pipe.dmi
changed instances of insulated pipes on box (whyyyy) to simple pipes
2015-05-27 18:12:12 -06:00
Boggart
e474a7b084 Fixes being unable to switch back to the previous pipe type without switching off it and back after using the delete or paint modes. 2015-04-27 13:48:36 -06:00
kingofkosmos
de280c72b5 Removed some more spans from visible messages. 2015-04-24 21:06:59 +03:00
kingofkosmos
1d14471d00 Ellipses to waiting messages. Warning-spanclasses to failing messages with an exclamation mark. 2015-04-24 20:50:50 +03:00
Boggart
ecebb594f9 Fixes being unable to construct disposal pipes on walls and fixes changing the RPD settings while already building affecting the currently building pipes.
Changes the RPD to use the newer datum/browser ui, makes it so that it show's what you have picked and doesn't let you endlessly repick it.

Fixes my wonky check for bins/outlets/chutes on walls, also adds a changelog.

Undefs the defines in RPD.dm at the end of the file.

Changes the "Type:" label to "Category:"
2015-04-23 11:53:27 -06:00
Menshin
a1a8555a45 * Fixes the air stored inside atmos machinery not updating on construction
* Fixes filters and mixers switching off on icon update
* Fixes the RPD not properly setting the flipped variable for flipped mixers/filters
* Fixes using the atmos analyzer on a pipe making you attack it
2015-02-04 21:56:07 +01:00
Menshin
b8230e024b * Cleaned the disposals code a bit (making it uses the defines !)
* Disposals constructs are now stored inside disposals instead of having them deleted and a copy created
* Bins, chutes and outlets will now properly clean any connected trunk on qdel()
* You can no longer change the RPD setting by keeping its window opened
* You can no longer use the RPD as a non-dextrous mob
* Reinforced floors will now be broken by ejected items/mobs, instead of stucking them in the void indefinitely
2015-01-19 01:53:19 +01:00
Menshin
8d1ebf3ad1 * Prevent stacking of dense disposal constructs (bin, outlet, chute)
* Some general code cleaning (less snowflaking)
2015-01-15 20:05:15 +01:00
tkdrg
4e84fb2eef Changes a missed del() to qdel() 2015-01-04 16:22:27 -03:00