Commit Graph

189 Commits

Author SHA1 Message Date
vuonojenmustaturska
6406896df1 Replaces a bunch of obj vars (and emagged on machinery/items) with obj_flags (#34078)
* It works, but is it worth it?

* bitfield helpers take 1

* Would this work?

* remove dangling debug code

* rebase & fixes

* vv bitfield stuff, reading

* DNM oceans of shitcode DNM

* honk

* honk2

* plonk

* rebase & fix
2018-01-22 20:19:46 +01:00
Jordan Brown
e13f2eef2a Removes usage of set background 2018-01-09 10:21:36 -05:00
Firecage
afd8bb7be5 Code Consistency: luminosity --> light_range (#31355)
* Code Consistency: luminosity --> light_range

* Finally-remembers-to-update-PR is best lizard.

* Update singularity.dm
2017-10-22 01:06:07 -04:00
Emmett Gaines
d17d09cb1b Radiation makes you vomit blood and more balance changes (#31753) 2017-10-18 10:24:09 -04:00
kevinz000
2a43a4f657 Fixes a bunch of bugs (#31687)
Fixes #13784 by forcing all orbits to update if the lowest stacked one updates
Fixes #21573 by making singularity try to move if it can't expand
Fixes #23306 by making simple bots that are off not able to move
Fixes #28274, fixes #26515 by actually making snipers zoom out
2017-10-16 21:12:32 +13:00
Emmett Gaines
9d17e9c102 Fixes camera mobs becoming contaminated and other tweaks (#31731) 2017-10-14 19:39:51 -03:00
Emmett Gaines
456cd10d94 Radiation rework and subsystem (#30909)
* radiation rework and subsystem

* moves a few things to initialize and adds radiation insulation

* adds a radiation contamination mechanic and makes requested changes

I'm terrified by the possibilities from this

* radiated objects give off light

and hopefuly contamination is balanced

* fixes runtimes and an mc crash kek

removed the lighting part of contaminated objects
attempted some more balancing

* Collectors output power in process() gradualy

And some more balancing tweaks

* Excludes a bunch of things from becoming radioactive

* Ready for testmerge balancing

* Inverse square law was swapped

* testmerge balancing

fixes the geiger counter
buffs collector power gen
nerfs sm radiation
slightly buffs rad insulation
nerfs rad damage (and its burn)
raised the minimum radiation

* disabling the radiation subsystem won't build up rad wave datums forever

* rewrites how mobs handle radiation

upgrades geiger counter functionality
and more balance tweaks

* cleans up stuff and removes debug message

* Slight contamination buff

* Major rad wave performance boost

Also improves rad insulation
Buffs contamination, again

* Fixes insulation runtime

More balance and performance tweaks

* fixes rad collectors not receiving power

* The final balance commit

Fixes a major bug causing radiation to underperform
More geiger counter changes that will be changed more to add sounds

* Monkey business

* Geiger counter sounds

* cleanup and move components to their own initialize

* Some code cleanup

And forgotten changes

* Cleans up some trailing returns

* Mapping changes
2017-10-13 10:22:00 -04:00
Jordan Brown
af4d9a85c9 Repaths /obj/item/weapon to /obj/item (#29929) 2017-08-16 10:38:51 -03:00
shizcalev
bfa0ab7234 Freon singuloth fix 2017-08-13 23:16:30 -04:00
oranges
e04fd83b9d Rename Bumped to CollidedWith
In light of the change of Bump to Collide, this should also be done
as it will make it less confusing for devs in the future

I also ended up changing a bunch of the code in the CollidedWith procs,
things that were assuming types, doing bad loc changes and so forth
2017-07-15 00:25:22 +00:00
oranges
5494f5328a Rename Bump to Collide (#29207)
This reduces confusion arising from the fact byond already has a built
in byond proc also named Bump.

We used an argument called yes to distinguish our Bump from byond's
builtin bump, but then we failed to make sure everyone of our bumps
properly override it, so a bunch of things have been double bumping

This resolves that issue permanently

I've also removed the second argument as it no longer has a purpose

I also cleaned up the recycler bump as it didn't do anything the
parent procs didn't already do
2017-07-14 13:47:22 +02:00
ShizCalev
59ef81245b Changes some 1s and 0s to TRUE and FALSE (#29144) 2017-07-10 10:31:34 -04:00
nicbn
77a2d3f5cd Replaces "istype"s with is_helpers macros (#28676) 2017-06-22 15:03:19 -03:00
Joan Lung
2672d88800 Renames stun effects and changes stun input values as preliminary work for changing stuns to status effects (#28524) 2017-06-18 23:03:51 -03:00
Leo
7d91e3143d Changes investigate logs to use a define (#27503) 2017-05-23 15:45:09 +12:00
Cyberboss
d8629afef5 Tesla light (#26899)
*  Ports sings to Initialize

* Tesla's now give off light
2017-05-05 12:27:10 -03:00
Cyberboss
9e1ef0ffe2 Global variable wrappers (#25325)
* Add the system for managed global variables

* Travis ban old globals

* So you CAN inline proccall, that's neat

* Fix that

* master.dm

* Remove the hack procs

* Move InitGlobals to the proper spot

* configuration.dm

* Fix the missing pre-slash

* clockcult.dm

* This is probably for the best

* Doy

* Fix shit

* Rest of the DEFINES tree

* Fix

* Use global. for access

* Update find_references_in_globals

Always hated that proc

Whoever made it must've bee a r e a l idiot...

* __HELPERS tree

* Move global initialization to master.

Fix the declaration

* database.dm

* Dat newline

* I said DECLARATIVE order!

* Here's something you can chew on @Iamgoofball

* game_modes.dm

* Fix this

* genetics.dm

* flavor_misc.dm

* More stuff

* Do it mso's way. Keep the controllers as global

* Make master actually see it

* Fix

* Finish _globalvars/lists

* Finish the rest of the _globalvars tree

* This is weird

* Migrate the controllers

* SLOTH -> GLOB

* Lighting globals

* round_start_time -> ticker

* PAI card list -> pai SS

* record_id_num -> static

* Diseases list -> SSdisease

* More disease globals to the SS

* More disease stuff

* Emote list

* Better and better

* Bluh

* So much stuff

* Ahh

* Wires

* dview

* station_areas

* Teleportlocs

* blood_splatter_icons

* Stuff and such

* More stuff

* RAD IO

* More stuff and such

* Blob shit

* Changeling stuff

* Add "Balance" to changelogs

* Balance for changelog compiler + Auto Tagging

* Update the PR template

* hivemind_bank

* Bip

* sacrificed

* Good shit

* Better define

* More cult shit

* Devil shit

* Gang shit

* > borers

Fix shit

* Rename the define

* Nuke

* Objectives

* Sandbox

* Multiverse sword

* Announce systems

* Stuff and such

* TC con

* Airlock

* doppllllerrrrrr

* holopads

* Shut up byond you inconsistent fuck

* Sneaky fuck

* Burp

* Bip

* Fixnshit

* Port without regard

* askdlfjs;

* asdfjasoidojfi

* Protected globals and more

* SO MANY

* ajsimkvahsaoisd

* akfdsiaopwimfeoiwafaw

* gsdfigjosidjfgiosdg

* AHHHHHHHHHHHHHHHHHHHHHHH!!!!!

* facerolll

* ASDFASDFASDF

* Removes the unused parts of dmm_suite

* WIP

* Fix quote

* asdfjauwfnkjs

* afwlunhskjfda

* asfjlaiwuefhaf

* SO CLOSE

* wwwweeeeeewwwww

* agdgmoewranwg

* HOLY MOTHER OF FUCK AND THATS JUST HALF THE JOB?!?

* Fix syntax errors

* 100 errors

* Another 100

* So many...

* Ugh

* More shit

* kilme

* Stuuuuuufffff

* ajrgmrlshio;djfa;sdkl

* jkbhkhjbmjvjmh

* soi soi soi

* butt

* TODAY WE LEARNED THAT GLOBAL AND STATIC ARE THE EXACT SAME FUCKING THING

* lllllllllllllllllllllllllllllllllllllllllll

* afsdijfiawhnflnjhnwsdfs

* yugykihlugk,kj

* time to go

* STUFFF!!!

* AAAAAAAAAAAAAAAAAHHHHHHHHHHHHHHHHHHHHHHHHHHH!!!!!!!!!!!!!!!!!!!!!!!

* ngoaijdjlfkamsdlkf

* Break time

* aufjsdklfalsjfi

* CONTROL KAY AND PRAY

* IT COMPILEELEELELAKLJFKLDAFJLKFDJLADKJHFLJKAJGAHIEJALDFJ!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

* Goteem

* Fix testing mode

* This does not belong in this PR

* Convert it to a controller

* Eh, fuck this option

* Revert controllerization Ill do it some other time

* Fix

* Working controllerization

* FOR THE LOVE OF CHRIST PROTECT THE LOGS

* Protect admins and deadmins

* Use the inbuilt proc
2017-04-06 23:26:13 -06:00
kevinz000
6ed5e98bcf Makes Ratvar more powerful than the admins (#25440)
* Update possess.dm

* Update possess.dm

* Update objs.dm

* Update ratvar_the_clockwork_justicar.dm

* Update singularity.dm

* Update possess.dm

* Update objs.dm

* Update objs.dm

* Update objs.dm

* Update possess.dm
2017-03-26 21:35:24 +02:00
Lzimann
5a618297ce Replaces the default output with the to_chat wrapper. 2017-03-10 01:32:05 -03:00
oranges
83c7390bb8 Track singularities in a global list (#24609)
This replaces a few operations on either the poi_list (still quite
large) or the world
2017-03-03 09:57:01 +01:00
Mervill
417c50efa2 These comments where removed by me.exe, just now 2016-12-08 01:48:46 -08: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
Joan Lung
dff4db726a Replaces a bunch of istypes with their proper macros (#20739)
* Replaces a bunch of istypes with their proper macros

* i'm not sure doing a 100+ file changed pr on a whim is something you do when bored
especially if you do it by hand because you never actually learned the regex that would let you automate it

* i'm just... gonna do this, because that check was true a lot and it shouldn't matter
2016-09-30 20:21:08 +02:00
phil235
194398cbbd Merge branch 'master' of https://github.com/tgstation/-tg-station into PreliminaryDamageRefactor
# Conflicts:
#	code/game/gamemodes/miniantags/bot_swarm/swarmer.dm
#	code/game/objects/effects/portals.dm
2016-09-29 01:44:27 +02:00
phil235
2d2975f783 Some preliminary changes before the damage refactor PR. The changes here do absolutely nothing gamewise.
This just adds some vars that the refactor will use. Putting this in a separate PR prevent the damage refactor PR from becoming too big (number of files changed) and hard to read and review.

Introduces the resistance_flags bitflag that replaces unacidable and burn_state.
Moves the armor var from item to /obj level and gives specific armor values to many objects, the armor list also gets two new armor types: fire and acid, which will be used in the refactor. the new fire and acid armor values are given to plenty of items.
2016-09-27 22:33:08 +02:00
phil235
6809603669 Changes obj/effect/blob,spider,swarmer,energy_net,spacevines to be ob/structures instead, since you can hit and destroy them.
Adds a large ash and large molten item decal (for future use)
simplifies decal/cleanable/replace_decal() code a bit.
Changes construction() proc to on_construction() for consistency, same for deconstruction().
Made a deconstruct() proc for machinery and computer (also for future use).
2016-09-27 19:58:27 +02:00
phil235
443a4501ec Carbon Dismemberment , second attempt. (#20461)
* - I rearranged X_defense.dm mob files, more damage_procs.dm.Here's what's inside:
* X_defense.dm: is for the procs of attacks onto the mob, all the XXX_act() proc (things happening to the mob), as well as protection check and get procs (armor, ear prot, projectile dismemberment)
* damage_procs.dm: actual damage procs like adjustBruteLoss() getfireloss, any proc that handles damaging.

- some bugfixes with gibspawner effects.
- monkey's bodyparts can be dismembered and are used to create its icon.
- brains are no longer carbons.
- all carbon have bodyparts that can be dropped when the mob is gibbed.
- adminspawned bodyparts now have a default icon.
- robotic parts are now a child of bodyparts.
- health analyzer on alien/monkey shows damage on each limb
- added admin option to add/remove bodyparts for all carbon (instead of just remove on humans)
- Fixes keycheck message spam for janicart and all when trying to move.
- Fixes bug with buckling to a scooter while limbless.
- removed arg "hit_zone" in proj's on_hit() because we can already use the def_zone var (where hit_zone got its value)
- Fixes mob not getting any damage when hit by a projectile on their missing limb, despite a hit message shown). carbon/apply_damage() now when we specify a def_zone and the corresponding BP is missing we default to the chest instead of stopping the proc. Consistently with how human/attacked_by() default to its attack to chest if missing limb.
- Fixes mini uzi icon when empty and no mag (typo).
- I renamed and changed a bit check_eye_prot and ear prot
- renamed flash_eyes to flash_act()
- I made a soundbang_act() similar to flash_act but for loud bangs.
- added a gib and dust animation to larva.
- husked monkeys
- no damage overlay for husk or skeleton.
- damage overlay for robotic limb now.
- no damage overlay when organic bodypart husked.
- one handed human with a bloody hand still get a bloody single hand overlay.
- fix admin heal being unable to heal robotic bodyparts.
- slightly touched robotic bodypart sprites (head one pixel too high)
- Fixes 18532 "beheaded husk has hair".
- Fixes 18584 "Ling stasis appearance bug"
- no more eyes or lipstick on husks.
- can remove flashes/wires/cells from robot chest and head with crowbar.
- Fixes not being able to surgically amputate robotic arm/leg.

* More merge conflict fixes and adding the new files I forgot to add.

* of course I forgot birdstation

* More typos and stuff I forgot to undo.

* Fixing a typo in examine.dm
Removing an unnecessary check.
Making admin heal regenerate limbs on all carbons.
Monkey-human transformation now transfer missing limbs info and presence of a cavity implant.
NODISMEMBER species can still lack a limb if the mob lacked a limb and changed into that new species.
Changeling Regenerate ability now also regenerate limbs when in monkey form. (and remove some cryptic useless code)

* Fixing more conflicts with remie's multihands PR.

* Fixes runtime with hud when calling build_hand_slots().
Fixes lightgeist healing not working.
Fixes null.handle_fall() runtimes with pirate mobs.
Fixes typo in has_left_hadn() and has_right_hand().

* Derp, forgot to remove debug message.
2016-09-12 19:33:50 +02:00
Joan Lung
6863867b0e The supermatter will no longer irradiate mobs on other zlevels when it explodes. (#20356)
* The supermatter will no longer irradiate mobs on other zlevels when it explodes.
Not if, when.

* ENTIRE OTHER ZLEVELS

* not like it fails
2016-09-08 11:35:16 +02:00
Joan Lung
992c0debbd Megafauna now have some innate light (#19632)
* Megafauna now have some innate light

* is the byond ref on this correct with it saying the default value is 0
let's find out
2016-08-02 17:08:51 -05:00
Joan Lung
1299758f4a Fixes the singularity every potentially eating itself (#19424) 2016-07-23 14:27:59 +12:00
Kyle Spier-Swenson
0d6bbbb412 stop the pills (#18703)
* RedPills Processing

Now you have to use START_PROCESSING(SSname, thing) (and STOP_PROCESSING)

* Fixes a minor bug.
2016-06-20 12:07:44 +02:00
Nerd Lord
f3fa0c3f38 is this a turf 2016-06-04 21:56:10 -04:00
Nerd Lord
9405446e08 important check 2016-06-04 11:20:59 -04:00
hornygranny
8ee1975b1b fixes singularity expanding and eating containment 2016-05-30 19:51:30 -07:00
Joan Lung
2cfb2d8eed Layers are now defines (#17949)
* Layers are now defines

* this looks better

* GAS_phil_LAYER

* no message

* remove the three unneeded defines

* no message
2016-05-27 22:16:21 +02:00
Joan Lung
6fc1d4fde4 Blobs can no longer eat the supermatter (#17205)
* Blobs can no longer eat the supermatter

* phil'd

* phil'd
2016-04-29 20:29:20 +02:00
MrStonedOne
958d9dacfb Fixes the singularity not eating/pulling turfs. 2016-03-15 04:06:34 -07:00
MrStonedOne
b601033c76 Singulo processes by tile, not atom, to avoid pulling something that's moved. 2016-03-15 03:39:46 -07:00
MrStonedOne
09fb8c2b10 Explosions and singulo use spiral range (and other changes) 2016-03-15 03:39:41 -07:00
MrStonedOne
2887dc7ce0 Removes lag.
This setup allows subsystems to pause themselves until next mc fire if they are about to go over a tick, and resume on the next mc tick
It also makes it so we prioritize running subsystems we skipped because there wasn't enough time in the current tick to run them based on their avg tick usage. (as well as subsystems paused mid way thru)

Adds a macro for adding this to non-mc procs. just drop it in the loop. There is a define version as well for if checks if you want to know if you just slept to avoid lag.

This is all inside #if DM_VERSION defines, so once i test that 509 still works to compile/test this should be good to merge
2016-03-15 03:39:39 -07:00
xxalpha
9154e6cbf2 ultra range again 2016-02-03 07:58:41 +00:00
Firecage
754491ce4c Changes relatives paths into absolute paths and makes some if()'s better 2016-01-17 01:36:56 +02:00
KorPhaeron
d564e1e2f3 Lava proofing 2015-12-17 01:48:11 -06:00
oranges
134a76cc8f Line ending apocalypse 2015-12-17 14:12:37 +13:00
Tkdrg
8ead3e8628 Cult Overhaul
Cult is awful, so let's try to improve it. Idea by KorPhaeron. I also
took some inspiration from adrix89's sacrifice cult, so credits to him.
Also thanks a lot specially to MrPerson and Iamgoofball for helping
me brainstorm this, and Joan for the sprites for the summoning orb,
the large nar-sie shell, and the new cult antag hud.

Basically, we remove conversion, and turn cult into a magic version of
nuke, with a small team of stealth elite cultists that have to build a
base in the station and sacrifice people in order to build an army of
constructs and get materials to eventually summon Nar-Sie.

Stun talismans and conversion are gone. Nar-Sie is now the only
objective. Sacrifice runes now provide summoning orbs, which you can use
to drop a large shell. Insert enough orbs in the shell and you trigger a
Delta. Defend the shell for 3 minutes and Nar-sie will arise. This shell
is bombproof and singularityproof. It may be summoned up to three times
if destroyed, but you will have to start from the beginning sac-wise.

Runes are now RNG. Each cultist only gets 50% of the runes. Inspiration
is basically The Binding of Isaac here (thank you MrPerson for this!).
Furthermore, many old runes were merged/removed and other new ones were
added. Almost all were massively rebalanced. Cult now also has a
stealthy ritual dagger with high bleeding and throw effects.
2015-12-15 04:59:31 -03:00
AnturK
a7334f95b6 Adds POI List, makes orbit use it. 2015-10-31 20:02:06 +01:00
Incoming5643
9d32d5b5ce Don't code with the web interface, kids 2015-10-27 19:43:45 -04:00
Incoming5643
2352d34036 Don't code while sleep deprived kids 2015-10-27 11:41:23 -04:00
Incoming
2825d2a6f2 apparently you have to give switch() some personal space 2015-10-27 02:24:34 -04:00
Incoming
11ae42e9cf Fixes icon blinking on level five singularities
What had happened: when stage six was added stage five's survivability took a stealth nerf, because any time the singularity reached enough energy to go six but hadn't eaten a supermatter shard (read: almost ever time) it would be force set to 2000 energy.

The problem: 2000 energy is the verge of stage four, so every time this hard set was hit (and for a hungry singulo this could be every consume check) the energy would be set to 2000. Then, at the same time, the singulo would suffer a little energy loss, momentarily become level four. Then, still all the same breath here, any new items would be eaten, pushing it back into level five.

Thus the singulo blinked.

As far as I can tell this was an unreported issue.
2015-10-27 02:11:25 -04:00