Commit Graph

110 Commits

Author SHA1 Message Date
Jordie
a28de54405 Ban system and interface update (#41176)
Spiritual successor and extension to #17798, an almost entire rebuild of the SQL ban system backend and interface.
Bantypes are removed per #8584 and #6174. All bans are now 'role bans', server bans are when a ban's role is server. Admin bans are a column, meaning it's possible to ban admins from jobs.
Bans now have only an expiry datetime, duration is calculated from this when queried.
unbanned column is removed as it's superfluous, checking unban status is now done through checking unban_datetime. unban_round_id column added. Each ip and computerid columns rearranged so ip is always first, like in other tables. Bans now permit a null ckey, ip and computerid.

Ban checking is split into two procs now is_banned_from() does a check if a ckey is banned from one or more roles and returns true or false. This effectively replaces jobban_isbanned() used in simple if() statements. If connected a client's ban cache is checked rather than querying the DB. This makes it possible for a client connected to two or more servers to ignore any bans made on one server until their ban cache is rebuilt on the others. Could be avoided with cross-server calls to update ban caches or just the removal of the ban cache but as is I've done neither since I think it's enough of an edge case to not be worth it.
The second proc is is_banned_from_with_details(), this queries the DB for a role ban on a player's ckey, ip or CID and returns the details. This replaces direct queries in IsBanned.dm and the preferences menu.

The legacy ban system is removed.

The interfaces for banning, unbanning and editing bans have been remade to require less clicking and easier simultaneous operations. The banning and jobban panel are combined. They also store player connection details when opened so a client disconnecting no longer stops a ban being placed.

New banning panel:
Key, IP and CID can all be toggled to allow excluding them from a ban.
Checking Use IP and CID from last connection lets you enter only a ckey and have the DB fill these fields in for you, if possible.
Temporary bans have a drop-menu which lets you select between seconds, minutes, hours, days, weeks, months and years so you don't need to calculate how many minutes a long ban would be. The ban is still converted into minutes on the DB however.
Checking any of the head roles will check both of the boxes for you.
The red role box indicates there is already a ban on that role for this ckey. You can apply additional role bans to stack them.

New unbanning panel:
Unbanning panel is now separate from the banning panel but otherwise functionally the same.

Ban editing panel:
Actually just a modified banning panel, all the features from it work the same here.
You can now edit almost all parameters of a ban instead of just the reason.
You can't edit severity as it's not really part of the ban.
The panels have been tested but I've not been able to get my local server to be accessible so ban functionality isn't properly confirmed. Plenty of testing will be required as I'd rather not break bans.

cl
admin: Ban interface rework. The banning and unbanning panels have received a new design which is easier to use and allows multiple role bans to be made at once.
prefix: Ban search and unbanning moved to unbanning panel, which is now a separate panel to the old banning panel.
/cl
2018-12-04 20:48:17 +01:00
81Denton
6877c7a609 Adds separate MMI/borg messages for damaged brains (#41306)
* Adds separate MMI/borg messages for damaged brains

* better switch toggle msg, M.brain?.damaged_brain

* ree

* thanks helen

* I hate Mondays

* Update code/modules/mob/living/brain/MMI.dm

Co-Authored-By: 81Denton <32391752+81Denton@users.noreply.github.com>

* condenses vars
2018-11-10 01:33:21 +01:00
AnturK
9d7e25f9b7 Adds old name tracking to player panel, cleans up some name assignments. 2018-10-28 19:16:13 +01:00
Jordan Brown
01938b081f Merge pull request #40953 from ShizCalev/mannitol-ghetto-surgery
Ghetto surgery can now damage brains. Mannitol can heal damaged brains.
2018-10-17 21:21:06 +01:00
ShizCalev
deeef5d59c Removes tactical suicide borging (#40754)
* Removes tactical suicide borging

* correction
2018-10-15 20:49:56 +01:00
kevinz000
1f7a76ade0 Combat/Stun (slip) overhaul staging, mobility flags, adds crawling (#39967)
Aiming to implement the framework oranges has detailed in https://tgstation13.org/phpBB/viewtopic.php?f=10&t=19102
Moves canmove to a bitflag in a new variable called mobility_flags, that will allow finer grain control of what someone can do codewise, for example, letting them move but not stand up, or stand up but not move.

Adds Immobilize()d status effect that freezes movement but does not prevent anything else.
Adds Paralyze()d which is oldstun "You can't do anything at all and knock down).
Stun() will now prevent any item/UI usage and movement (which is similar to before).
Knockdown() will now only knockdown without preventing item usage/movement.
People knocked down will be able to crawl at softcrit-speeds
Refactors some /mob variables and procs to /mob/living.
update_canmove() refactored to update_mobility() and will handle mobility_flags instead of the removed canmove

cl
rscadd: Crawling is now possible if you are down but not stunned. Obviously, you will be slower.
/cl
Refactors are done. I'd rather get this merged faster than try to fine tune stuff like slips. The most obvious gameplay effect this pr has will be crawling, and I believe I made tiny tweaks but I can't find it Anything I missed or weird behavior should be reported.
2018-10-10 23:21:27 +01:00
ShizCalev
5a29dc43e3 Replaces istypes with the proper tool_behaviour checks. (#40414) 2018-10-01 01:10:45 +01:00
Garen Crownguard
f2cd8a131d screwdriver_act signal (#39877) 2018-08-27 10:56:40 +01:00
zxaber
9ee01bacb2 Allows empty borg shells to be disassembled. (#38639)
* Adds the ability to deconstruct empty cyborg shells.

* Update robot_parts.dm

* Able to directly swap cells

Added ability to change out power cells with a screwdriver.

* Update robot_parts.dm

* Removing unnecessary `src` prefixes from code.

* Update robot_parts.dm

* Moved to wrench_act and screwdriver_act overrides

I think I did this right

* Replaced screwdriver code

* Swapping out qdeleted for an if-not

* Adds a check for cell-less shells when MMI is added.

* Update robot_parts.dm

* Adds the ability to just remove the cell

Re-organized the screwdriver section as well, and added the ability to add a cell to a shell with no cell.

* Whoops

Copypaste error

* Changed the screwdriver section from nested if statements to use a function

Also removed the line that forced the naked endoskeleton out of your hand in the wrench section.
2018-07-03 18:16:25 +01:00
Jordan Brown
1f0b362b18 Qdels queries, adds sleep safety checks, DBcore checks for leaks (#38363)
* Qdels all queries, adds sleep handling

* DB Core messages admins about undeleted queries

* Compile fixes. Adds missing set waitfor

* Remove world/New shennanigans. Add DBQuery/BlockingExecute()

* Less spammy notifications to admins about undeleted queries

* Increase dbcore fire time to 1 minute

* Upgrade undeleted query warning

* Better place of death

* Fix build

* Remove BlockingExecute, see BSQL PR for why

* Yep, missed that one.

* Psyche, that's the WRONG QUERY!!
2018-06-18 20:49:09 +01:00
ShizCalev
725aefce3e Fixes missing augmentation hands (#37373) 2018-04-27 08:42:57 +01:00
Fox McCloud
d42a67da02 Kills off /obj/item/device (#37297)
* Kills off /obj/item/device

* whoops

* whoops

* Fix
2018-04-23 14:01:33 +01:00
ShizCalev
c4496dbd72 Consolidates bot assemblies under one parent 2018-01-07 13:43:46 -05:00
vuonojenmustaturska
5233ec1f6a Finishes the forceMove port (#33519)
* a thing

* thingy 2: electric boogaloo

* Obligatory webeditor commit
2017-12-15 10:39:34 +13:00
Jordie
8b19b490d1 JSON feedback (#32188)
* wip

* wip2

* makes code actually compile on 511 + fixes

* versioning

* s

* adds python conversion script, schema change and removes 'force ' from item_used_for_combat

* fix to compile

* forgot to actually commit this
2017-11-17 02:43:12 -05:00
Emmett Gaines
825ab4def4 [512] The great \ref purge (#31824)
* The great \ref purge

* cleanup
2017-10-28 17:20:04 -04:00
Jordan Brown
b6d349e1d4 Remove drop_item, drop_item_v, put_in_hands_or_del (#31386) 2017-10-07 13:36:33 -04:00
Jordan Brown
af4d9a85c9 Repaths /obj/item/weapon to /obj/item (#29929) 2017-08-16 10:38:51 -03:00
ShizCalev
45d3d52af7 Made some object lists less terrible to read (#29304)
* spaces

* more spaces

* last ones
2017-07-18 10:44:29 -04:00
ShizCalev
59ef81245b Changes some 1s and 0s to TRUE and FALSE (#29144) 2017-07-10 10:31:34 -04:00
Cyberboss
729010bbb2 Unorphans the blackbox (#26129)
Moved sql_poll_population from server_maint to this new SS. Moved few remaining server_maint tasks to SSping and deleted it.
2017-04-27 10:04:57 +12:00
Cyberboss
5646c736c8 Merge upstream 2017-03-30 19:18:59 -04:00
KorPhaeron
37325ccbe9 Robot Overlays 2017-03-27 19:52:10 -05:00
Cyberboss
05e1ef69e1 Merge upstream 2017-03-27 09:32:08 -04:00
GunHog
ac4d69254b Revival of "Allows AIs to deploy to borgs" by Shadowlight213 (#25184)
The AI may now deploy to cyborgs prepared as AI shells. The module to do this may be research in the exosuit fabricator. Simply slot the module into a completed cyborg frame as with an MMI, or into a playerless (with no ckey) cyborg.
2017-03-24 21:42:48 -03:00
Cyberboss
d0bfbc3e13 Rename ticker to SSticker 2017-03-22 10:48:25 -04:00
Lzimann
5a618297ce Replaces the default output with the to_chat wrapper. 2017-03-10 01:32:05 -03:00
Cyberboss
3f7f5d4000 Removes/Refactors /mob/unEquip (#22918)
* Part1

* IT COMPILES!!!!

* Fuck wait this was missing from that last

* Update handlabeler.dm

* Update handlabeler.dm

* Fixes n shit

* Fix this

* Fixes #23310

* Fucking @RemieRichards was right

* Fixes devil unEquip

* WTF ARE BITFLAGS?

* THERES THE FUCKING PROBLEM

* Fixes
2017-01-31 09:28:31 +13:00
Joan Lung
21d01c3669 Fixes a bug 2016-12-26 14:30:13 -05:00
Joan Lung
95af0534f6 MMI'd clockcultists put in AI cores will properly lose clockcult status (#22369)
* MMI'd clockcultists put in AI cores will properly lose clockcult

* uuuuugh

* fix the core while we're at it

* "

* mrrp

* this will also follow you around

* hmm
2016-12-25 16:18:55 +13:00
coiax
243fd295b4 Cyborg upgrade board tweaks (#22211)
* Cyborg upgrade board tweaks

🆑 coiax
add: Cyborg renaming boards cannot be used if no name has been entered.
del: Cyborg rename and emergency reboot modules are destroyed upon use,
and not stored inside the cyborg to be ejected if modules are reset.
/🆑

Reasons: Because being renamed "default name" isn't fun, and it means
you have to hang around to be renamed AGAIN. And for lore/balance/sanity
reasons, you don't get to get the reboot board back after you used it;
try dying less.

* Naming changes, and transformer tweak

- A new unnamed cyborg will copy the user's prefered cyborg name if
possible, defaulting to the old format if there's no preference.
- A rename board with no setting will apply the cyborg's default name,
if one exists, see above.
- Cyborg transformers (from the traitor AI) will no longer destroy all
items.

* Made behaviour more consistent

* Fix spelling
2016-12-23 09:31:03 +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
Joan Lung
3ec7e81131 "A Working Datum Antagonist" 2016-09-19 13:03:22 -04: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
Remie Richards
00738bd2a3 More than 2 hands!? WHAAAAAAT 2016-09-02 16:10:16 +01:00
Joan Lung
75106bb789 Hopefully fixes THAT ONE BUG (#18926) 2016-06-26 17:56:55 -04:00
Cruix
ac0bad5d61 Added priority overlay system. (#18225)
Added priority overlays to atoms, which will not be removed when overlays are cut and will always remain on top when new overlays are added. This requires everyone to use add_overlay() and cut_overlays() instead of overlays += and overlays.Cut(). These procs are found in __HELPERS/icons.dm, and the priority overlay list is found in game/atoms.dm. Everything else is replacing deprecated overlay manipulation.
2016-06-17 10:11:53 +12:00
Joan Lung
8d2da45e8c duh 2016-06-09 08:39:16 -04:00
Joan Lung
c5ee14a0e3 gotta emag the borg 2016-06-09 08:21:24 -04:00
Joan Lung
16fa622e56 this is all butts 2016-06-08 23:18:23 -04:00
Joan Lung
0765173ee2 hudupdate 2016-06-08 15:59:12 -04:00
Joan Lung
4f8133c3d1 unfucks ratvar conversion 2016-06-08 15:50:06 -04:00
MMMiracles
7c8603a0a8 important features (#18195) 2016-06-03 14:48:12 -05:00
Xhuis
b93957e6ca Pre-testmerge polish 2016-05-15 13:15:27 -04:00
Xhuis
10f9e64666 Conflicts VII 2016-05-15 01:19:57 -04:00
Xhuis
23073619a2 Conflicts III 2016-05-15 00:59:44 -04:00
Xhuis
45ef8a5e00 Ratvar, the Clockwork Justiciar 2016-05-15 00:59:28 -04:00
phil235
68da092009 Dismemberment port from Hippie code, based on RemieRichard's work. Big thanks to RemieRichards and crystalwarrior. 2016-05-05 18:17:51 +02:00
phil235
0480790b0a Same things but with structures now. 2016-04-24 20:38:33 +02:00
phil235
74e8bbf029 Fixes defibbed corpse not getting blind overlay despite being in crit.
Brain mobs that are beaten to death can still be inserted inside a brainless human corpse but defibbing the corpse cannot work (the brain is too damaged). On the other hand cloning that corpse will still work.
Deffibing a brainless corpse no longer gives "further attempts may be successful".
Fixes brain mob's container var not being nullified on Destroy().
2016-02-12 21:47:22 +01:00