Commit Graph

11 Commits

Author SHA1 Message Date
SkyratBot
dc7d9a81a1 [MIRROR] Fix Map JSON loading errors (#1460)
* Fix Map JSON loading errors (#54563)

Also fixes that one runtime everyone runs into when they first load in

* Fix Map JSON loading errors

Co-authored-by: Jordan Brown <Cyberboss@users.noreply.github.com>
2020-10-25 11:11:00 +01:00
MrPerson
f7eb2c905b Unicode awareness Part 2 -- copytext() (#48512)
* Unicode support Part 2 -- copytext()

This is the transition of all copytext() calls to be unicode aware and also some nearby calls in the same functions. Most things are just replacing copytext() with copytext_char() as a terrible character limiter but a few others were slightly more involved.

I replaced a ton of
````
var/something = sanitize(input())
something = copytext(something, 1, MAX_MESSAGE_LEN)
````

with a single stripped_input() call. stripped_input() already calls html_encode(), trim(), and some other sanitization so there shouldn't be any major issues there.

This is still VERY rough btw; DNA is a mess, the status displays are complete ass, there's a copytext() in code\datums\shuttles.dm that I'm not sure what to do with, and I didn't touch anything in the tools folder. I haven't tested this much at all yet, I only got it to compile earlier this morning. There's also likely to be weird bugs until I get around to fixing length(), findtext(), and the rest of the string procs.

* Makes the code functional

* Assume color hex strings are always # followed by ascii.
Properly encodes and decodes the stuff in mob_helpers.dm which fixes some issues there.

* Removes ninjaspeak since it's unused
2020-01-18 13:07:22 +13:00
skoglol
8206b1e1cb Map rotation touchup, automatic map votes (#48602)
* Map rotation touchup, automatic map votes

* votes already running

* Pre-init vote restrictions

* No rotation for rounds less than 10 minutes.

* Splits voting preferred map check

* Fixed comment
2020-01-07 09:46:49 -05:00
TheChosenEvilOne
a414d76718 Custom (station) map loading for admin use. (#47778)
* Custom Map Loading

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* hh

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* Use load_map_config instead of just setting next_map_config

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* Some small changes.

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* Checks if map is correct and don't return on empty shuttle.

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* Thank you VSCode, very cool

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* Added a map bounds check.

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* Moved the config reset and file removal to the end of loadWorld()

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>

* Actually set the next map to default.

Signed-off-by: TheChosenEvilOne <tceo-email@protonmail.com>
2019-11-16 19:56:01 +01:00
skoglol
938e66f62c Adds sorting to most input() lists (#47117)
* Adds sorting to most input() lists.

* Sorted some global lists, added more input sorting

* Should now use correct sort everywhere.

* compiles

* Last fixes.
2019-10-22 04:28:42 -07:00
Cyberboss
d0bfbc3e13 Rename ticker to SSticker 2017-03-22 10:48:25 -04:00
Cyberboss
1bbc640afe Runtime Dynamic Station Loading (#24171)
* Dynamic map loading prototype

* Get the title screen working

* Fixes the random pod bugs

* map configs

* Add back the asteroid

* Ignore the rotate file

* Fix some shit

* More shit fixes

* Babby's first json

* Cyberboss confirmed shitcoder

* Makes map rotation great again

* Moves the map defines

* Delete tgstation2.dm

* Convert runtimestation

* Convert PubbyStation

* Convert OmegaStation

* Convert Metastation

* Convert Delta Station

* Lol file extensions

* Reee line endings

* Take out the trash

* Fix loadallmaps.dm

* Deltaassssssstation?

* Fix travis

* Did I ASK you to change the line endings?

* Remove votable maps

* Cleanup

* Previous config. Load configs in New. Fix splash

* Fix this

* More generic minetype

* STOP TOUCHING THE LINE ENDINGS!!!

* Add some flexibility to /obj/screen/splash

* Fix the shit

* Update gitignore

* Smooth transition from last map

* Better check

* Missed this map rotate check

* Remove these checks too

* Prep for a future request by @kevinz000

* Fix z2 line endings

* Solution for custom .dms

* Rename some things, trim some fat

* Fixes default map_config

* Remove stale comment

* Delete the previous config after loading

* Don't try to open a non-existent file

* Delete the old rotator script

* And references to it

* Line endings

* More line endings

* Del checks from when m-config may have not existed

* LINE ENDINGS

* Update the default map config

* Map load error checking for what it's worth

* Small cleanup

* For case sensitive

* File systems

* Strip maprotate stuff from build script

* Spruce up the _maps tree. Compile some empty space

* Make travis simpler

* LINEARU ENDARU!!!

* tgstation TWO!!!

* Lowercase mine type

* Dummy dm's for testmerging

* Fixes job ordering

* If ghosts wanna watch the map load so be it

* Let them know what's going on

* Fixes z-transitions

* Optimize z expansion further

* Remove this old var

* Fix wiznerd teleportation

* Rmove butt

* Does the thing

* Moved temp configs to the data dir

* Un-touch gitignore

* Forgot templates.dm

* Forgot to include the includer

* Fair enough

* SILENCE IMBECILE!

* @Cyberboss still a fuckboi

* Speed things up a bit

* Fix a potential bug with the error message

* Whatever
2017-03-07 10:45:31 +13:00
MrStonedOne
701e966f8f choosen -> chosen 2015-10-06 21:50:19 -07:00
MrStonedOne
1f7234d3bb adds prompt and logging to trigger map rotation verb 2015-10-06 21:20:35 -07:00
MrStonedOne
e27e9e8371 Map rotation fixes:
Fixes mutiple rotate operations from breaking the server, map rotation will properly detect rotation operations as well as update operations and abort.
Fixes max pop being treated as minpop
Adds more feedback to admin verbs.
2015-10-06 21:12:00 -07:00
MrStonedOne
29cf9bd265 Some map rotation tweaks.
Adds a config option for the map rotation chance.
Ups default rotation chance from 50% of round length to 75% of round length.
Moves the procs around.
Adds two new admin verbs:
Force map rotation.
Change map.
2015-10-02 10:48:09 -07:00