Commit Graph

147 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
XDTM
6b3be0f71b Bank Cards now only display messages to the owner if carried (#40459)
* Bank Cards now only display messages to the owner if carried

* Adds recursive loc check, sounds, better code

* leftover

* .

* review
2018-09-25 18:24:38 +01:00
Jordan Brown
0b6e1cb6d8 Merge pull request #39481 from AutomaticFrenzy/patch/syntax
Fix some weird syntax
2018-08-04 22:49:35 +02: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
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
AnturK
ad08f1e2dd Fixes some defines. (#37223) 2018-04-16 17:20:48 +01:00
Jalleo
2ead2633ba Removes a unused helper (#36811) 2018-03-31 03:47:09 +01:00
AsV9
d338cac150 Merge remote-tracking branch 'tgstation/master'
Not sure if this worked. Used a wonky special snowflake strat to merge.
2018-03-24 08:57:13 +01:00
Jordan Brown
8966681800 Fix a runtime if someone is deleted on the arrivals shuttle (#35459)
* Fix a runtime if someone is deleted on the arrivals shuttle

* Duh
2018-02-10 11:28:06 -05:00
AnturK
f7122af33b [s] Fixes get mob by key (#35377)
* Really now.

* Also this
2018-02-06 04:58:39 -05:00
Jordan Brown
71daca41c7 Makes flick_overlay use client time (#35271) 2018-02-05 02:09:30 -02:00
ShizCalev
ee18d6f8e2 Fixes clockwork sigil candidate runtime, cleans up some jobban checks with defines (#34907)
* Cleanup

* .

* Synced special_role & factions with role defines

* Revert

* more cleanup

* fix
2018-02-04 03:03:34 -06:00
ShizCalev
f46dcd7b92 honk 2018-01-21 02:55:19 -06:00
ShizCalev
3bf0f4dcf0 Fixes get_area_name runtime 2018-01-21 02:55:19 -06:00
ShizCalev
3d08996463 Replaces cached get_area vars for names (#34338) 2018-01-13 21:55:47 -05:00
Jordan Brown
e13f2eef2a Removes usage of set background 2018-01-09 10:21:36 -05:00
YPOQ
43e0d7a23e Fixes some broken random events (#33345) 2017-12-07 20:18:28 -05:00
vuonojenmustaturska
59f6cb1d80 Maybe fixes meson hearing exploit (#33005)
* Not all of wisdom brings joy

* Serves me right for making changes based on how i remember the code working
2017-11-25 20:24:38 +01:00
GupGup
ce82a2e614 Fixes hostile mobs attacking surrounding tiles when trying to attack someone: the stunning finale (#32699)
fix for issue #4237
replacement for #32593 and #32665
revises #30152 (useless)
2017-11-23 10:23:26 +13:00
vuonojenmustaturska
39375d5cc2 Replaces a bunch of mob loops with hopefully better ones (#32786)
* Free codebase churn

* fixes dviewmob

* a commit

* Partial revert "Free codebase churn"

This reverts commit 9dd41b3860c331637bbc85e694dd32dc59768ad5.

* better fix to dviewmob

* renames living_mob_list to alive_mob_list, adds mob_living_list and carbon_list

* make some use out of the shiny carbon list

* make some use out of the shiny new living list

* more things, also make the mobs subsystem (Life) use living list

* bonus

* domo arigato mr. roboto

* compile fixes, also made the drone code less dumb

* better?

* make admin message prettier

* honk

* fixes blobs

* rev fixes

* one small thing
2017-11-16 23:08:40 +01:00
vuonojenmustaturska
cb8cd5c508 Speeds up saycode by almost doubling get_hearers_in_view() performance (#32650)
* The sun is also a warrior

* Knowledge can also destroy

* nor can the kindest will preserve you from the kill
2017-11-16 06:08:53 -05:00
kevinz000
c0af783134 Update game.dm 2017-10-08 01:36:45 -07:00
ShizCalev
f82adb7238 Refactor quick create antag panel code, fixed AFK revs not properly ending the round. (#31103)
* Refactor quick create antag, fixed AFK revs not ending

* More cleanup

* Simplified one of the checks
The other half was covered by considered_alive already.

* Reordered check

Eliminate current antags sooner before running them through the rest of
the checks.

* removed switch
2017-10-02 09:48:42 +02:00
Jordan Brown
4178c209f1 Configuration datum refactor (#30763)
* Configuration datum refactor

* More WIP

* New easier on the eyes format

* More WIP

* Finished config.txt

* Fucktons more WIP

* The end of conversion draws near...

* Add all this shit

* Done converting entries finally

* Hunting down compile errors

* More WIP

* MORE CONVERSIONS

* More WIP

* More WIP

* Oh shit only 90 errors this time!

* IT COMPILES!!!

* Fixes world start runtimes
2017-09-29 15:36:51 +13:00
ShizCalev
74f5a8c904 DisplayTimeText mk2 (#30969)
* Adds new helper, DisplayTimeText

* Removed unused define

Thought it would've been nice to have for the future, but I guess it's
fine to go without it.

* CBB

* Revamp

* Early returns

* More cleanup

* Proc cleanup

* Makes fraction only show if seconds is < 1

* Last cleanup

* Revert

* Corrected incorrect round time.

Dunno how nobody ever caught that it was incorrect on live servers, gg.
2017-09-24 19:58:58 -04:00
Jordan Brown
c9eb2a81cc Fixes get_area not working on areas 2017-09-15 05:13:10 -05:00
Jordan Brown
0101efb94a Speeds up get_area (#30429) 2017-09-06 09:45:41 -05:00
Ian Turk
7460f2c5b8 Replaced flags with flags_1 2017-08-16 13:01:15 -06:00
Jordan Brown
d1ae0a0c95 Adds helpers to avoid << use (#29611) 2017-08-09 00:27:54 -03:00
Joan Lung
ec9439b915 Renames GLOB.cardinal to GLOB.cardinals to match GLOB.diagonals and GLOB.alldirs 2017-07-09 17:24:28 -04:00
Joan Lung
888b2e093e Makes the lavaland pressure check a proc (#28954)
* Makes the lavaland pressure check a proc

* code that probably did nothing tm

* sss

* 50 should be a define instead
2017-07-02 20:14:42 -04:00
Jordan Brown
d7ebd649ba Refactors the latejoin list (#26647) 2017-06-04 17:07:46 -03:00
AnturK
5791f418ba Fixes role polls 2017-05-13 18:15:51 +02:00
Joan Lung
8b912f84aa Fixes a bunch more cult bugs (#27034) 2017-05-08 13:17:40 -03:00
Joan Lung
74f00e629f Cult fixes (#26990)
* Cult fixes

* ha ha whoops

* whoooops

* whoops x3 combo
2017-05-07 00:51:40 -03:00
Robustin
ad19802a6d fucking hell im so done with this PR 2017-05-03 20:03:43 -04:00
Robustin
3423cbeba5 Finally working again 2017-05-02 19:25:49 -04:00
Robustin
4103871708 Merge branch 'master' of https://github.com/tgstation/tgstation into CMA4
# Conflicts:
#	code/datums/antagonists/datum_cult.dm
#	code/game/gamemodes/cult/cult.dm
#	code/modules/mob/living/simple_animal/constructs.dm
#	icons/mob/actions.dmi
2017-04-30 16:36:36 -04:00
Robustin
4a4c2a498c Big finalized update 2017-04-30 16:30:35 -04:00
Robustin
06c3116c2d Still debugging 2017-04-28 19:41:57 -04:00
Robustin
3ffaead7cf Cult Master 2017-04-26 20:14:42 -04:00
Cyberboss
6c6fc719ec Refactors roundstart checks slightly (#26131)
* Refactors roundstart checks slightly

* Fix
2017-04-27 10:05:40 +12:00
Cyberboss
944fd9463c Afk fixup (#26181)
* Fixes inactivity/afk semantics and config

* Fixes people in the lobby not getting afk kicked

* Bluh

* Fax

* Doy

* Yes
2017-04-15 13:11:03 -06:00
Joan Lung
a10ad0f4c4 Improves shield generator code (#25994) 2017-04-08 21:42:03 -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
Cyberboss
d0bfbc3e13 Rename ticker to SSticker 2017-03-22 10:48:25 -04:00
Lzimann
3dd6722c07 Fix conflict 2017-03-10 01:39:22 -03:00
Lzimann
5a618297ce Replaces the default output with the to_chat wrapper. 2017-03-10 01:32:05 -03:00
Cyberboss
e48564d941 Arrivals Ferry (#24694)
* Highlight docking ports in TESTING

* Buckle arrivals to their seats

* Fixes shuttle/Initialize not calling the base

* Arrivals docking

* Use forceMove so the shuttle effect starts

* Forgot this check

* Fixes

* Needful

* Fix this shit

* Line endings?

* Double check, fix sound

* Remove empty if

* Fucking lists

* Fix parallax and ghosts

* Ghost fix

* GHOST

* Fix shit

* Fix parallax + config

* I lied slightly

* Hyperspace sound refactor

* Finish fixing the maps + doors

* Fix the sound not playing

* Consoles + area fix

* Updates default config

* Fix line endings

* Safety checks

* Damage checks

* This should be down here

* Clean some stuff up

* Fix a few things on Delta and Omega

* Delete the useless air alarm on Pubby's shuttle

* Fixes #24727

* Always the fucking line endings

* Fix this negative check

* LINE ENDINGS!!!!!

* Revert to master

* Redo the changes

* Fix the sound not repeating

* Readds the shuttle door

* Fix people disabling latejoins
2017-03-10 14:19:34 +13:00
Pieter-Jan Briers
b5b93e51f7 Merge remote-tracking branch 'upstream/master' into rebase-to-vg 2017-02-18 16:52:07 +01:00