Commit Graph

10065 Commits

Author SHA1 Message Date
elly1989@rocketmail.com 3941c9b86c Standardised the handle_regular_status_updates() procs for alien hunter, queen and sentinel. They were just copypasta so I fixed the updatehealth() procs and removed the unneeded code.
Removed the invisibility verb for hunters. They now cloak when using stalk intent instead. :3 rawr

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3935 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-28 17:37:42 +00:00
johnsonmt88@gmail.com 80b15df54b ** Mob Define Cleanup: Part 1 **
I'm currently working on moving all of the vars in mob_defines.dm and some procs in mob.dm into more fitting places. For example, ghosts and simple animals can not be cloned, so they do not need a cloneloss var. Cloneloss would be better fitting to /mob/living or even /mob/living/carbon. 

By moving these defines into proper children of /mob we lower the amount of resources that must be set aside every time a mob is created and we lower the amount of data that gets transfered between mobs when we combine, transfer or transform them. In theory, this should help free up some resources and combat lag.

Due to how integrated some of these defines are in the rest of the code, I'm going to be committing this cleanup in small batches. Doing it this way instead of one massive commit means that bugs will be easier to locate and identify. It is also less likely to overwhelm players with bugs, and if it still does, it will make it easier for us to revert only the section that is causing problems. Smaller commits also means merging with existing code will be less of a nightmare and has less potential for merging mistakes.

One of my goals in this cleanup is to add a description to every single variable in mob defines. While some of them are self explanatory, there are some there that are used in horribly obscure ways on top of having no comment to describe their use.

-----------------------

Mob defines moved to living:
- last_special*
- bruteloss
- oxyloss
- toxloss
- fireloss
- cloneloss
- brainloss
- halloss
- hallucination
- hallucinations(list)

*Note: I believe this variable is not needed, but the code it is used in (the resist verb) is cluttered and messy. That chunk of code probably use a re-write. I'll put it on my TODO list and if I survive mob_defines I'll try to get around to it but if anyone wants to do it for me, that would certainly help!

-----------------------

Mob procs moved to living:
- getBruteLoss()
- adjustBruteLoss()
- getOxyLoss()
- adjustOxyLoss()
- setOxyLoss()
- getToxLoss()
- adjustToxLoss()
- setToxLoss()
- getFireLoss()
- adjustFireLoss()
- getCloneLoss()
- adjustCloneLoss()
- setCloneLoss()
- getHalLoss()
- adjustHalLoss()
- setHalLoss()
- getBrainLoss()
- adjustBrainLoss()
- setBrainLoss

Mob procs moved to carbon:
getDNA()
setDNA()

-----------------------

Mob verbs moved to carbon:
- Sleep
- Lay down / Get up

-----------------------

The : operator...

The thing that has been killing me through this whole cleanup is people using or copy/pasting the : operator everywhere. 


*** Please use obj.var_or_procname. Do not use obj:var_or_procname ***


Using obj:procname will not throw a compiler error if obj does not have that specific var or proc. This means that the coder making changes will NOT be informed of an error which will result in a proc failing, potentially being completely unusable and definatly causing a runtime error.

With that said, I fully anticipate that most bugs (if any) caused by this mob define cleanup to be the result of : operators.

I've been replacing many : operators in favour of the . operator as I've been going, most noteably I went out of my way to remove almost every : operator from the 4000+ line Chemistry-Regents.dm
Exceptions:
- Water: Turf and Atmos related vars. I'm not familiar with the members and methods in those class' hierarchy.
- Silicate: because it's commented out and I honestly dont see it returning.
- Thermite: Turf and Atmos related vars.
- Corn Oil: Turf and Atmos related vars.

Final note: While this may be the source of some mob-related bugs, there are two other revisions that have been committed between now and the last time either of the the two tgstation servers have been updated. These revisions both touch mob-related files. I'm not blaming these other revisions for anything, especially since one of them is mine anyway, I'm just listing them here for refrence to help quickly identify any problems.
- My human/life() changes in r3925 
- Carn's life() standardizations in r3933

Stuff unrelated to mob defines:
- Fixed borgs and such being able to go into DNA modifiers.
- Changelog updated and I added Sieve to the list of coders.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3934 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-28 17:06:19 +00:00
caelaislinn 4a4d3b0614 Merge branch 'master' of https://github.com/Baystation12/Baystation12 2012-06-28 22:56:29 +10:00
Erthilo 5b13fbc6a7 Temp/quick/hotfix for evidence bags. 2012-06-27 23:36:55 +01:00
Erthilo 92b7eb534a Fixes sleeping resting message spam. 2012-06-27 22:34:55 +01:00
elly1989@rocketmail.com ea333ff216 Ugh another big 'Carn broke everything' commit.
Tried to standardise the (confusing as all hell) handle_regular_status_updates() procs for monkeys alien/humanoid, alien/larva, brains and humans.

Removed clamp_values as per Rockdtben's request.

Hopefully this should make those procs a lot easier to read and work with as well as reduce the number of calculations done every call.

Admin's rejuvinate verb cures disabilities, sdisabilities and sight/hearing.

Xenos can actually use their sleeping icon properly now.

If I've broken anything let me know directly and I'll have it fixed/reverted within 24 hours.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3933 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-27 19:47:17 +00:00
Erthilo 1e63e35ab4 Fixes double icons in examine, and random " on his head" " on his groin" messages. 2012-06-27 20:29:40 +01:00
elly1989@rocketmail.com 1cd5085a0f Fix for update_inv_l_hand() and update_inv_r_hand(). Forgot to uncomment these again after testing in a previous commit. :/
Thanks Nodrak

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3932 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-27 18:58:37 +00:00
Erthilo 4460bc2011 Simple animals can now use the Me verb. 2012-06-27 18:09:32 +01:00
johnsonmt88@gmail.com db89a2aefb Viruses no longer re-infect people who have been vaccinated or otherwise cured.
Chameleon projectors no longer let you move freely in space.
- I realize the way I fixed this is terrible, but the whole relaymove() proc in chameleon projectors is terrible. I was unable to rewrite it without breaking it completely so this fix will have to do.

Runtime fix for facehuggers having a null target (the mob they're attacking.)

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3930 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-27 17:05:27 +00:00
daniel.cf.hultgren@gmail.com 9ebb3271ff It now properly compiles.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3929 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-27 16:46:16 +00:00
daniel.cf.hultgren@gmail.com bcfa1cecf1 Added pizzaboxes. Stackable, Tagable, and awesome. Sprites by supercrayon (I slightly modified them, sorry)
Updated (and fixed) changelog.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3927 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-27 15:03:15 +00:00
baloh.matevz 9f3005255c - Renamed the obj/hud other_update() proc to hidden_inventory_update()
- Renamed the obj/hud show_otherinventory var to inventory_shown
- Added the F12 hotkey which hides most of the UI except for the intent switcher, hands, health indicator, damage indicators and the other pop-in indicators on the right. The proc is called /mob/verb/button_pressed_F12(), the verb abbreviation is "F12" and it's hidden, so it won't show in the info panel. This currently only works for human mobs.

Screenshot:
http://www.kamletos.si/minimal%20UI.png

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3926 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-27 08:13:23 +00:00
johnsonmt88@gmail.com da5bfd3b0f Setting people's criminal status via SecHUDs now require the user to be alive, and to actually be wearing the HUD.
Set the solar control computers to 'off' by default since you have to set them off then back on again to get them working properly anyway.

Fixed a typo in glass/attackby() causing lit-glass tiles to not be created. Fixes issue 593

Moved certain procs in human/life.dm() into an if(stat != DEAD). This means that certain procs will update only if the mob is alive.
Affected procs:
- handle_virus_updates()
- handle_changeling()
- handle_mutations_and_radiation()
- handle_chemicals_in_body()
- handle_disabilities()
- handle_random_events() 
- update_canmove() 
- - If dead, it forces mob.canmove to 0, meaning you don't get to be the walking dead.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3925 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-27 06:16:31 +00:00
Erthilo 5c87d02731 "Fixes" packages wrapping crates that are too large or too small. 2012-06-26 20:35:04 +01:00
caelaislinn fd5661de1f Merge branch 'master' of https://github.com/Baystation12/Baystation12 2012-06-27 00:02:01 +10:00
johnsonmt88@gmail.com 54b9fb7d88 Fix for pumpkin hats using improper sprites when they're lit up. Fixes issue 591.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3921 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-26 02:50:32 +00:00
elly1989@rocketmail.com 5d3c6a9259 Please stop committing all the #define FILE_DIR stuff every commit. Dreammaker updates it automatically anyway. Just remove that section prior to commit.
Added some WIP master controller alternatives. Located in code/WorkInProgress/carn They should stop the MC doubling up and smooth the lagspikes over a little bit (depending on how they are set up). They need a bit of work still, but are functional. Just untick code/game/master_controller.dm and tick the version you want to try out.

Committing Giacom's pai remote-signaller code.

Minor map fix for Travis (extra grille NE corner of atmos)

Added a debug tool that prints powernets into a text-based map.

Fixed a runtime that occurred everytime somebody cut a laid cable. It was updating the power networks twice each time >_>

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3920 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-26 01:47:40 +00:00
mport2004@gmail.com 88c867ea25 Fixed a supply shuttle runtime due to the stamping missing a null check.
Added a null check to cleanbots and new player preferences.
Did a bit of blob and antimatter work.


git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3919 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-26 01:20:19 +00:00
Erthilo c95a5a512c TG: - The adminhelp sound is now a character setup option for admins of any rank.
Revision: r3784
Author: 	 baloh.matevz
2012-06-26 01:00:06 +01:00
Erthilo 053ffb837e TG: -Wallets now have sprites for holding silver head IDs and red Centcom IDs.
-New spare ID box sprite. New pill-bottle box sprite.
-Added spades for botanists who want to play with dirt.
-A spade can be found in the hydroponics supply area, along with a couple spare
tools useful for the job.
Revision: r3782
Author: 	 d_h2...@yahoo.com
2012-06-26 00:26:41 +01:00
baloh.matevz ae6ab401e9 - Fixed chemical reactions stat tracking.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3918 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-25 13:58:46 +00:00
caelaislinn 564390774f fix for "Energy radiating from the /datum/artifact_effect"
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 22:49:47 +10:00
baloh.matevz 4fe200c4e1 (printing SQL to world is a bad idea...)
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3917 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-25 11:03:41 +00:00
baloh.matevz 0007122cff - Added basic ban logging for DB_Ban. First step for the cross-server ban system.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3916 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-25 11:02:52 +00:00
CIB d8a5824cbc Merge pull request #1392 from Erthilo/master
Medical System Updates + Bug fixes
2012-06-25 02:52:05 -07:00
caelaislinn c46d2920a6 Merge branch 'master' of https://github.com/Baystation12/Baystation12 2012-06-25 18:07:47 +10:00
CIB 47aca7ca44 Merge pull request #1393 from CIB/master
Fixed a derp
2012-06-24 19:30:27 -07:00
cib 7f5db7ab68 Fixed BE_CULTIST/BE_PAI derp. 2012-06-25 04:27:19 -07:00
Erthilo 390782f544 Merge branch 'master' of github.com:Baystation12/Baystation12 2012-06-25 01:20:08 +01:00
Erthilo bb8f21a431 Possible fix for everyone being referred to as "It". 2012-06-25 01:19:47 +01:00
Erthilo 67c5e8e3a8 Medical System Updates...
* Dragging someone while injured (brute) will have a small chance of injuring them further that increases depending on how damaged they are. This coincides with the blood spatters that are already generated.
* Blood is now actually lost from the person being dragged.

* Added splints that can be applied to broken arms and legs, and will reduce effects of broken limbs. These can be removed the same way as handcuffs. They show up on the mob and on examine.
* Added an autoinjector that can only hold five units, but acts like a hypospray.
* Added an advanced medical kit that Medical Doctors spawn with that has Advanced Trauma Kits, Advanced Burn Kits, autoinjectors, and splints.
* Health Scanners now show unsplinted fractures ONLY in arms or legs.

* People in critical (less than -50 health) from external trauma (100+ damage from brute and/or burn) bleeding, and with unsplinted limbs, will send a message to anyone trying to drag them, to warn them it would be a bad idea trying to move them. They will suffer a lot more damage if dragged while lying down.
* The correct procedure is therefore, A) Bring a roller bed, or B) Splint all limbs, stop all bleeding with gauze, and then drag them.

* Fixed CPR being performed at weird health levels.
2012-06-25 01:18:55 +01:00
caelaislinn 7bd5beeb17 anomlies now have an activated and non-activated sprite
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 09:26:50 +10:00
caelaislinn 00493873c0 artifacts have a disable message
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 09:03:39 +10:00
caelaislinn f131543fb7 fix for never closing bug
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 08:55:28 +10:00
caelaislinn beb863020b more tweaks and fixes
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 08:50:03 +10:00
caelaislinn ddda9f2ce3 fixes and tweaks for the harvester
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 08:35:19 +10:00
caelaislinn 137e15ef62 this should fix the power harvester bug
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 07:59:08 +10:00
Albert Iordache 156f1349c2 Fixed compilation error and moved acid_act() 2012-06-24 19:13:51 +03:00
caelaislinn a240dc71ba added acid_act() proc, works similarly to proc on luna code, fixed some anomaly bugs
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-25 01:48:55 +10:00
baloh.matevz 159ff955a6 - Fixed the old iconset's equip button fitting a million batons into your suit storage slot.
- Fixed aliens not being able to tell which hand they have selected

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3913 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-24 14:27:58 +00:00
caelaislinn 2237e3f658 talking crystal can be heard with ghost ears
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-24 19:58:21 +10:00
elly1989@rocketmail.com b21a3ed742 Fixes issue 586.
Culprit code:

/obj/item/clothing/gloves/latex/attackby(obj/item/weapon/cable_coil/O as obj, loc)
	if (istype(O) && O.amount==1)
		var/obj/item/latexballon/LB = new
		if (usr.get_inactive_hand()==src)
			usr.before_take_item(src)
			usr.put_in_inactive_hand(LB)
		else
			LB.loc = src.loc
		del(O)
		del(src)
	else
		return ..()

I was going to fix said code but after seeing that BALLOON is spelled incorrectly, that it uses amount == 1, balloons have no in-hand sprite AND don't even have  a desc I decided I shouldn't waste my time when the authorsimply couldn't be bothered. Commented it out.

Runtime fix for:
untime error: Cannot modify null.icon_state.
proc name: insert key pressed (/client/verb/insert_key_pressed)
  source file: mob_movement.dm,84
Cause: AIs don't have intents and stuff.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3911 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-24 09:54:36 +00:00
elly1989@rocketmail.com 65a84484cf Removed a debug message.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3909 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-24 09:01:17 +00:00
elly1989@rocketmail.com 4f910f122f Runtime fix for db_click when clicking the mask inventory slot with an empty hand. This proc will get rewritten anyway (when I've gathered enough courage and/or vodka :3)
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3907 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-24 07:28:42 +00:00
caelaislinn 021ddbde38 Merge branch 'master' of https://github.com/Baystation12/Baystation12 2012-06-24 16:36:47 +10:00
mport2004@gmail.com 1513e96439 Fixed some engrish in a desc.
Added more AM to the containment_jar
The shielding makes a bigger boom if it blows.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3905 316c924e-a436-60f5-8080-3fe189b3f50e
2012-06-24 05:00:44 +00:00
SkyMarshal 315e027b05 Merge pull request #1385 from SkyMarshal/BugFixes
Sanity for the "give" command, changelog.
2012-06-23 21:39:46 -07:00
SkyMarshal 484c01498d Sanity for the "give" command, changelog. 2012-06-23 21:38:39 -07:00
caelaislinn 37e76d7436 artifact machinery now uses power
Signed-off-by: caelaislinn <cael_aislinn@yahoo.com.au>
2012-06-24 11:57:32 +10:00