mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-15 01:54:52 +01:00
mayfools
390 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
e0bdfc3f5f |
Dynamic Rework (#91290)
Implements https://hackmd.io/@tgstation/SkeUS7lSp , rewriting Dynamic
from the ground-up
- Dynamic configuration is now vastly streamlined, making it far far far
easier to understand and edit
- Threat is gone entirely; round chaos is now determined by dynamic
tiers
- There's 5 dynamic tiers, 0 to 4.
- 0 is a pure greenshift.
- Tiers are just picked via weight - "16% chance of getting a high chaos
round".
- Tiers have min pop ranges. "Tier 4 (high chaos) requires 25 pop to be
selected".
- Tier determines how much of every ruleset is picked. "Tier 4 (High
Chaos) will pick 3-4 roundstart[1], 1-2 light, 1-2 heavy, and 2-3
latejoins".
- The number of rulesets picked depends on how many people are in the
server - this is also configurable[2]. As an example, a tier that
demands "1-3" rulesets will not spawn 3 rulesets if population <= 40 and
will not spawn 2 rulesets if population <= 25.
- Tiers also determine time before light, heavy, and latejoin rulesets
are picked, as well as the cooldown range between spawns. More chaotic
tiers may send midrounds sooner or wait less time between sending them.
- On the ruleset side of things, "requirements", "scaling", and
"enemies" is gone.
- You can configure a ruleset's min pop and weight flat, or per tier.
- For example a ruleset like Obsession is weighted higher for tiers 1-2
and lower for tiers 3-4.
- Rather than scaling up, roundstart rulesets can just be selected
multiple times.
- Rulesets also have `min_antag_cap` and `max_antag_cap`.
`min_antag_cap` determines how many candidates are needed for it to run,
and `max_antag_cap` determines how many candidates are selected.
- Rulesets attempt to run every 2.5 minutes. [3]
- Light rulesets will ALWAYS be picked before heavy rulesets. [4]
- Light injection chance is no longer 100%, heavy injection chance
formula has been simplified.
- Chance simply scales based on number of dead players / total number
off players, with a flag 50% chance if no antags exist. [5]
[1] This does not guarantee you will actually GET 3-4 roundstart
rulesets. If a roundstart ruleset is picked, and it ends up being unable
to execute (such as "not enough candidates", that slot is effectively a
wash.) This might be revisited.
[2] Currently, this is a hard limit - below X pop, you WILL get a
quarter or a half of the rulesets. This might be revisited to just be
weighted - you are just MORE LIKELY to get a quarter or a half.
[3] Little worried about accidentally frontloading everything so we'll
see about this
[4] This may be revisited but in most contexts it seems sensible.
[5] This may also be revisited, I'm not 100% sure what the best / most
simple way to tackle midround chances is.
Other implementation details
- The process of making rulesets has been streamlined as well. Many
rulesets only amount to a definition and `assign_role`.
- Dynamic.json -> Dynamic.toml
- Dynamic event hijacked was ripped out entirely.
- Most midround antag random events are now dynamic rulesets. Fugitives,
Morphs, Slaughter Demons, etc.
- The 1 weight slaughter demon event is gone. RIP in peace.
- There is now a hidden midround event that simply adds +1 latejoin, +1
light, or +1 heavy ruleset.
- `mind.special_role` is dead. Minds have a lazylist of special roles
now but it's essentially only used for traitor panel.
- Revs refactored almost entirely. Revs can now exist without a dynamic
ruleset.
- Cult refactored a tiny bit.
- Antag datums cleaned up.
- Pre round setup is less centralized on Dynamic.
- Admins have a whole panel for interfacing with dynamic. It's pretty
slapdash I'm sure someone could make a nicer looking one.


- Maybe some other things.
See readme for more info.
Will you see a massive change in how rounds play out? My hunch says
rounds will spawn less rulesets on average, but it's ultimately to how
it's configured
🆑 Melbert
refactor: Dynamic rewritten entirely, report any strange rounds
config: Dynamic config reworked, it's now a TOML file
refactor: Refactored antag roles somewhat, report any oddities
refactor: Refactored Revolution entirely, report any oddities
del: Deleted most midround events that spawn antags - they use dynamic
rulesets now
add: Dynamic rulesets can now be false alarms
add: Adds a random event that gives dynamic the ability to run another
ruleset later
admin: Adds a panel for messing around with dynamic
admin: Adds a panel for chance for every dynamic ruleset to be selected
admin: You can spawn revs without using dynamic now
fix: Nuke team leaders get their fun title back
/🆑
(cherry picked from commit
|
||
|
|
75e7ef6def |
Mutation code cleanup, mutations now have sources to avoid concurrency problems. (#91346)
This PR aims to clean or bring up to date portions of code about dna, the dna console and mutations. This includes taking care of or removing some of the awful choices like the pratically useless `datum/mutation/human` pathing, or the class variable, in favor of using sources to avoid potential issues with extraneous sources of a mutation. The files changed are over a hundred just because I removed the `datum/mutation/human` path, but the actual bulk of the code is mainly shared between the datum/dna.dm, _mutations.dm and dna_console.dm. Mutation shitcode is hurting my future plans for infusions a little. Also it's a much needed refactor. Drafted 'till I'm sure it works without issues. 🆑 refactor: Refactored mutation code backend. Report any issue. /🆑 |
||
|
|
25da3e86a6 |
Ghost settings UI (#91370)
This is part of my ongoing project to remove the Stat panel which you can read/contribute to here: https://hackmd.io/443_dE5lRWeEAp9bjGcKYw Replaces the pAI button at the bottom of Ghost's HUD with a new button for Ghost settings Default look  With fun verbs (admin only, the 2 buttons at the top right), No body, and lag switches on (disables T-Ray and Zooming)  The ghost icon next to "re-enter body" is the DNR button, which requires double click. Extra view is now easier to understand, 0 is "default", anything more is extra vision you get. Goes to 3 for regular users, 7 for BYOND members. Removes the "Ghost" tab from the stat panel entirely, this replaces it. The Ghost tab of the stat panel is filled with barely functional stuff, like "Jump to Mob" which allows you to jump to "oranges ear" which teleports you to nullspace, or the 4 different jump to verbs for different things which is irrelevant from the Orbit menu and the many improvements it got over the years, and even the Notifications panel, which seems pretty useful, but because it's delegated to a small button filled with the rest of these it gets entirely drowned out. This puts all the important things in front of the user at the click of a button, meant to be easy to navigate and giving important information first. 🆑 add: Added a 'Ghost settings' button, taking the spot of the pAI candidate button and replacing the "Ghost" tab of the Stat panel. This button contains buttons pertinent to your time as an Observer. /🆑 |
||
|
|
bc2215667f |
Re-refactors batons / Refactors attack chain force modifiers (#90809)
Melee attack chain now has a list passed along with it, `attack_modifiers`, which you can stick force modifiers to change the resulting attack This is basically a soft implementation of damage packets until a more definitive pr, but one that only applies to item attack chain, and not unarmed attacks. This change was done to facilitate a baton refactor - batons no longer hack together their own attack chain, and are now integrated straight into the real attack chain. This refactor itself was done because batons don't send any attack signals, which has been annoying in the past (for swing combat). 🆑 Melbert refactor: Batons have been refactored again. Baton stuns now properly count as an attack, when before it was a nothing. Report any oddities, particularly in regards to harmbatonning vs normal batonning. refactor: The method of adjusting item damage mid-attack has been refactored - some affected items include the Nullblade and knives. Report any strange happenings with damage numbers. refactor: A few objects have been moved to the new interaction chain - records consoles, mawed crucible, alien weeds and space vines, hedges, restaurant portals, and some mobs - to name a few. fix: Spears only deal bonus damage against secure lockers, not all closet types (including crates) /🆑 |
||
|
|
9968f94721 |
Regal Rat cleanup & minor changes (#91012)
## About The Pull Request Since #90505 added another entry to it the Regal Rat Riot ability, which turns maintenance creatures into versions loyal to the rat, has become sort of unmanageable (and to be honest it was a bit gross to start with). Instead of having a big if/else list (which was making the same range check multiple times...) that sets stats on a bunch of mobs, I delegated it to the mobs themselves and instead of changing some stats of the existing mobs we just turn them into a new mob which can be spawned or placed separately by mappers or admins if they want. Other stuff I changed: Riot (the ability which transforms mobs into minions) no longer spawns a mouse if it fails to find anything. Instead you have a chance to fish mice out of disposals bins while digging out trash and items. Domain is now a toggle which activates itself every 6 seconds rather than a button you manually click every 6 seconds. Riot makes a visual effect when used. Rare Pepe randomisation is done via a random spawner instead of the mob modifying a bunch of its own properties in Initialise. A bunch of mobs now automatically follow you after being tamed. I wrote this assuming I was going to add it to the rioted mobs but then didn't end up doing that because you might want them to immediately attack someone. My rule of thumb is that if I think you'd want the mob to attack someone the moment it is befriended I didn't add this and if you wouldn't I did. I changed some of the regal rat minion names, and some of them can now spawn from gold slime which couldn't before. ## Why It's Good For The Game This proc sucked and now it's nicer. As for the other changes; - A tamed mob immediately following you is nice feedback and saves you a click as it's likely to be your first action. Also removes some admin panel shitcode I added. - I changed Domain to a toggle because you generally want to use it on cooldown and someone suggested it on this PR and it sounded like a good idea. - I saw someone in Discord complaining that the previous flow of recruiting rats by hitting Riot with nothing around to summon one, waiting, hitting it again to convert one rat, and waiting again was tedious and annoying which I agree with. This method improves the quality of life by separating these two actions but _also_ as a side effect reduces a regal rat's ability to secretly stockpile 50 rats in a hidden maintenance room because most disposal bins are in slightly more visible areas, they'll actually need to go and make a mess somewhere someone can see them. ## Changelog 🆑 balance: Regal Rats can now grab mice out of disposal bins, and no longer spawn them with the Riot ability. balance: The Riot ability no longer needs to be used once for each slightly different kind of mob in your radius. balance: The Regal Rat Domain ability is now toggled on and off. balance: Several kinds of mob will immediately start following you once tamed. balance: Rats, hostile frogs, and evil snails can be created via gold slime reaction. /🆑 |
||
|
|
11d82b7995 |
You can now interact with held mobs beside wearing them (feat: "minor" melee attack chain cleanup) (#90080)
People can now pet held mothroaches and pugs if they want to, or use items on them, hopefully without causing many issues. After all, it only took about a couple dozen lines of code to make... ...Oh, did the 527 files changed or the 850~ lines added/removed perhaps catch your eye? Made you wonder if I accidentally pushed the wrong branch? or skewed something up big time? Well, nuh uh. I just happen to be fed up with the melee attack chain still using stringized params instead of an array/list. It was frankly revolting to see how I'd have had to otherwise call `list2params` for what I'm trying to accomplish here, and make this PR another tessera to the immense stupidity of our attack chain procs calling `params2list` over and over and over instead of just using that one call instance from `ClickOn` as an argument. It's 2025, honey, wake up! I also tried to replace some of those single letter vars/args but there are just way too many of them. Improving old code. And I want to be able to pet mobroaches while holding them too. 🆑 qol: You can now interact with held mobs in more ways beside wearing them. /🆑 |
||
|
|
4c8e970db9 |
Wizard Event - Object Rain (#90502)
## About The Pull Request Port of a feature I coded for a downstream ages ago and never bothered PRing up here. This event simply selects a department and then makes objects of various types fall from the sky in that area. The types of things it can pick from are: - Fish - Small animals (cats and dogs) - Food - Small change Food is selected randomly from all foods and will get rapidly dirty if not collected within the bounds of the five second rule. Fish are selected randomly from all fish, and will be alive when they land but likely to die quite quickly (as most fish cannot breathe on land) causing additional emotional distress to people nearby. While they are few in number, some fish are actually quite dangerous items. The animals are a weighted pick from some curated lists of items. The puppies survive their contact with the floor and can be adopted or farmed for meat as desired. The coins are also picked from a weighted list which is basically just copied from one of our maintenance coin spawners. This event is only active during Summon Events or during the first couple of ritual circles a wizard might activate. As it's mostly a social motivator rather than being inherently particularly disruptive (although it can make a bit of a mess), it only appears around the same tier as similar effects like the Hallucinatory Anomaly after which it is replaced by more dangerous events. ## Why It's Good For The Game By dropping potentially desirable items inside a department and also telling people that there's (for example) cash just lying around on the floor in the cargo bay, it may divert people from what they are doing so that they will converge on that area of the station. This creates opportunities for people to interact with each other, compete over these resources, or take advantage of potential reduced oversight of unaffected parts of the station. Also the idea of a miraculous rain of animals (particularly fish, but cats and dogs have their own saying) has a cultural basis and is the kind of whimsical thing you can imagine happening as a side-effect of magical spells. ## Changelog 🆑 add: Occasionally when a Wizard is around, strange things may being falling from the sky. /🆑 |
||
|
|
e732a19949 |
Add wizard event - Magical Rain (#90495)
## About The Pull Request Adds a new wizard event - Magical Rain This selects a random reagent from a curtailed list that is rained down on the station. The only safe spaces are in maintenance and containers like lockers. Of course the wizard is not directly affected by the reagent, although side effects may still apply. For example, if it is raining lube, it will cause turfs to get slippery which can slip the wizard. You can also collect the rain in containers, which might be funny or useful depending on what it is. (Alcoholics love booze rain) I did have to trim down the list of reagents since there are over +700 and most of them do nothing to mobs/turfs when they `TOUCH`. The list is ~50 reagents that are: ```dm // most medicine do nothing when it comes into contact with turfs or mobs (via TOUCH) except for a few var/list/allowed_medicine = list( /datum/reagent/medicine/c2/synthflesh, /datum/reagent/medicine/adminordrazine, /datum/reagent/medicine/strange_reagent, // include a random medicine pick(subtypesof(/datum/reagent/medicine)), ) GLOB.wizard_rain_reagents |= allowed_medicine // One randomized type is allowed so the whitelist isn't spammed with subtypes GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/glitter)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/carpet)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/mutationtoxin)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/plantnutriment)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/uranium)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/luminescent_fluid)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/impurity)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent/drug)) GLOB.wizard_rain_reagents |= pick(typesof(/datum/reagent/water)) GLOB.wizard_rain_reagents |= pick(typesof(/datum/reagent/fuel)) GLOB.wizard_rain_reagents |= pick(typesof(/datum/reagent/colorful_reagent)) GLOB.wizard_rain_reagents |= pick(typesof(/datum/reagent/ants)) GLOB.wizard_rain_reagents |= pick(typesof(/datum/reagent/lube)) GLOB.wizard_rain_reagents |= pick(typesof(/datum/reagent/space_cleaner)) // lots of toxins do nothing so we need to be picky var/list/allowed_toxins = list( /datum/reagent/toxin/itching_powder, /datum/reagent/toxin/polonium, // radiation /datum/reagent/toxin/mutagen, // all the acids /datum/reagent/toxin/acid, /datum/reagent/toxin/acid/fluacid, /datum/reagent/toxin/acid/nitracid, // include a random toxin pick(subtypesof(/datum/reagent/toxin)), ) GLOB.wizard_rain_reagents |= allowed_toxins // too many food & drinks so blacklist most of them var/list/allowed_food_drinks = list( /datum/reagent/consumable/ethanol/wizz_fizz, /datum/reagent/consumable/condensedcapsaicin, /datum/reagent/consumable/frostoil, // include a random food or drink pick(subtypesof(/datum/reagent/consumable)), // include a random regular drink (vodka, wine, beer, etc.) pick(/obj/machinery/chem_dispenser/drinks/beer::beer_dispensable_reagents), ) GLOB.wizard_rain_reagents |= allowed_food_drinks var/list/allowed_exotic_reagents = list( // fire /datum/reagent/clf3, /datum/reagent/phlogiston, /datum/reagent/napalm, // cosmetic /datum/reagent/hair_dye, /datum/reagent/barbers_aid, /datum/reagent/baldium, /datum/reagent/mulligan, /datum/reagent/growthserum, // op shit /datum/reagent/romerol, /datum/reagent/gondola_mutation_toxin, /datum/reagent/metalgen, /datum/reagent/flightpotion, /datum/reagent/eigenstate, /datum/reagent/magillitis, /datum/reagent/pax, /datum/reagent/gluttonytoxin, /datum/reagent/aslimetoxin, // misc /datum/reagent/blood, /datum/reagent/hauntium, /datum/reagent/copper, ) GLOB.wizard_rain_reagents |= allowed_exotic_reagents // add a few randomized reagents not listed above so they at least have a chance GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent)) GLOB.wizard_rain_reagents |= pick(subtypesof(/datum/reagent)) ``` ## Why It's Good For The Game More interesting effects for weather. The wizard events are always supposed to be silly and wacky, so having stuff like raining ants or booze is hilarious. Several OP chems are included like napalm, strange reagent, and flight potion which can lead to some chaos. ## Changelog 🆑 add: Add wizard magical rain event. A random reagent is selected to rain down across the station. The only places to escape are in maintenance and inside containers such as lockers. The wizard is not directly affected by the reagent, but the side effects might still apply. (ie. raining lube, will make the floors slippery, which can slip the wizard) /🆑 --------- Co-authored-by: Jacquerel <hnevard@gmail.com> |
||
|
|
b9c803a9d8 |
Base implementation of /datum/persistent_client (#89449)
Converts `/datum/player_details` into `/datum/persistent_client`. Persistent Clients persist across connections. The only time a mob's persistent client will change is if the ckey it's bound to logs into a different mob, or the mob is deleted (duh). Also adds PossessByPlayer() so that transfering mob control is cleaner and makes more immediate sense if you don't know byond-fu. Clients are an abstract representation of a connection that can be dropped at almost any moment so putting things that should be stable to access at any time onto an undying object is ideal. This allows for future expansions like abstracting away client.screen and managing everything cleanly. |
||
|
|
b6b8306fda | Merge branch 'master' of https://github.com/tgstation/tgstation into upstream-25-02a | ||
|
|
940e2d31cf |
tgstation is back online and you are a horrible goose (#89204)
## About The Pull Request Converts geese to basic mobs. Nobody else did this one because two separate other developers have said they started and then examining what the goose does made them feel mildly ill, but I am stronger. I will admit though I wasn't 100% committed to making it work exactly the same way, I rewrote the entire system to use interfaces I like more (read: I put all this shit in a status effect which means any mob can be given the ability to vomit out everything in its contents) and if that means the behaviour is only "inspired by" that didn't bother me that much. **Geese:** - Wander randomly around. - Peck people who attack them. - Occasionally start pecking other nearby animals for absolutely no reason. - Eat any food they randomly wander within one tile of, but don't seek it out further than that. - Eat anything made of plastic that they randomly wander within one tile of. - Choke to death over 30 seconds if they eat anything made of plastic. - Vomit out whatever it was that they choked on when they die. - Honk (this is new). The more famous subtype of goose is Birdboat. Birdboat is a unique goose present on several maps with some additional behaviour. **Birdboat:** - Is chill and doesn't start pecking people for no reason. - Is occasionally possessed by ghosts. - Builds up an internal vomit-meter as he eats things. Moving around and just sort of generally hanging will start rolling dice to find out when Birdboat's tummy gets upset. - May start vomiting instead of choking to death on plastic, thereby saving his own life. - Vomits out everything that he just ate while running around, making a mess of the floor. - Starts eating everything he just vomited out again. Unlike regular geese who just eat your food and it's gone, Birdboat's miraculous digestion preserves all of the food he eats so if he consumes the entire kitchen counter it will eventually come back out again the way it went in. Although you might not want to eat it any more. The precise way in which this manifests may be slightly different, but largely this is also what these animals did before. Other stuff: I noticed a bunch of find/set behaviours were not setting a search range? I think that means they were never finding anything? I did not actually test any of them to see if they were broken, but it's possible that a bunch of broken AI behaviours like "climbing trees" may now actually start triggering because they have a search radius greater than an orange of 0. I added "keep this in contents instead of deleting it" as a parameter for generic eating and slapped it on the goldgrub, as it is used in two places and may end up being used in more. ## Why It's Good For The Game This kills off the last user of the `retaliate` subtype and makes our list so so much closer to finish. It's like... a couple of bots, a handful of oddballs (I'll probably handle these soon), and then just the mining bosses and minibosses to go. If you give a human the vomit goose ability (now that I made it work on any mob) they will eject all their organs and body parts via the mouth until they die, if you don't do the brain or heart first you can vomit your own head off. ## Changelog 🆑 refactor: Geese have been moved to the basic mob subsystem, please report any unusual behaviour. /🆑 --------- Co-authored-by: Ben10Omintrix <138636438+Ben10Omintrix@users.noreply.github.com> |
||
|
|
3499727a6d |
Implements datumized embedding handlers in place of element-component-datum triad (#88511)
## About The Pull Request This PR completely rewrites our embedding system in favor of embedding datum handlers which acts as containers for all embedding-related data and logic. Currently embedding logic relies on an element-component-datum triad, where elements on the items handle embedding logic, singleton datums store embedding data and components (which get assigned to ***mobs*** in whom the item embedded) handle pain and the item being ripped out. How do we access all the procs? By using comsigs as procs, which is really bad. This code was written back in 2020 when DCS was hot stuff but in hindsight this implementation was a mistake, as it heavily restricts custom embedding behaviors unless you're willing to constantly run GetComponent (bad, ugly, incarnation of evil) This PR rewrites all that logic to be handled by lazyloaded ``/datum/embedding``, which is stored similarly to current ``/datum/embed_data``. Upon being requested, it is initialized and assigned to a parent from whom all the logic is handled, from being embedded to pain and having the item ripped out. On projectiles this only handles one proc, after which it copies itself down to the shrapnel item instead and runs the chain further from there. Ideally, most embedding-related logic now should be handled purely datum-side - in most cases items should not be hooking up to themselves like they did before (unless said logic is for when the item is made sticky or smth) and instead the code should be handled by the embedding datum (see sholean grapes implementation in this PR). This should allow us to do fancy stuff like syringe guns embedding syringes into targets and injecting them that way, and fix some bugs along the way. Closes #88115 Closes #87946 Also fixed a bug with scars not displaying when examined closely from #86506 because i was in the area anyways |
||
|
|
e59d8ba64b | Merge commit '179a607a90ad7ec62bdaff4e6fe72af60ee56442' of https://github.com/tgstation/tgstation into upstream-24-10b | ||
|
|
bb70889f6e |
TG Upstream Part 1
3591 individual conflicts Update build.js Update install_node.sh Update byond.js oh my fucking god hat slow huh holy shit we all fall down 2 more I missed 2900 individual conflicts 2700 Individual conflicts replaces yarn file with tg version, bumping us down to 2200-ish Down to 2000 individual conflicts 140 down mmm aaaaaaaaaaaaaaaaaaa not yt 575 soon 900 individual conflicts 600 individual conflicts, 121 file conflicts im not okay 160 across 19 files 29 in 4 files 0 conflicts, compiletime fix time some minor incap stuff missed ticks weird dupe definition stuff missed ticks 2 incap fixes undefs and pie fix Radio update and some extra minor stuff returns a single override no more dupe definitions, 175 compiletime errors Unticked file fix sound and emote stuff honk and more radio stuff |
||
|
|
2cf34ec44e | Reduces volume of the nuke sound (#86888) | ||
|
|
6808a082eb |
Assorted changes to job assignment code and logging. Runtime free, guaranteed or your money back. Price: $£0. (#85947)
## About The Previous Pull Request #85308 reverted by #85929  ~~Causes the round to not start when a player isn't eligible for any jobs at a specific priority level due to runtimes trying to `pick()` from an empty list aborting the entire job assignment stack.~~ (Fixed???? by https://github.com/tgstation/tgstation/pull/85947/commits/e0e9f2f430079d4ab7097abe12e75f934131a638) Maybe we should test merge this for a mo just to make sure no more cheeky runtimes pop up before merging. ## About The Pull Request This PR does a couple of minor things: Makes the job debug logging a bit easier to follow. Minorly brings some SSjob code up to code standards, converting proc names to snake_case and doing some otherm is cleanup. Refactored some stuff into different procs, updated some comments. And some major things: Changes the job assignment logic. Old behaviour > Assign dynamic priority roles > Force one Head of Staff (if possible) > Assign all AIs > Assign overflow roles (bugged in 2 ways) > Shuffle the available jobs list once, at the start of the random job assignment loop > Pick and assign random jobs for random players from High prefs down, with a priority on Head of Staff roles > Handle everyone that couldn't be assigned a random job New behaviour > Assign dynamic priority roles > Assign all Head of Staff roles to players with High prefs > If no Head of Staff was made in the above way, force one Head of Staff (if possible) > Assign all AIs > Assign overflow roles (fixed) > Prioritise and fill unfilled head roles at each job priority pref level, from High prefs down. > Build a list of all jobs that each unassigned player could be eligible for at the above pref level. > Pick a job from that list at random and assign it to the player. > Handle everyone that couldn't be assigned a random job. In reality there should be little impact on overall job assignment, the code changes read more as semantics. For example, the priority check for filling Head slots will have the same candidate pool in both old and new versions, but in the new version we're more clearly saying that Heads are important and we want to prioritise filling them for the sake of round progression even though the outcome in new and old is the same. A key change will lead to an increase in assistants - Overflow fixes. Currently the code block to do early assignments to the Overflow role doesn't work - or works but not as you'd expect. The idea was is that because enabling the Overflow role in the prefs menu is an On/Off toggle that sets the job to High priority when enabled and prevents any other High priority pref, players that have the Overflow role enabled will **always** get it. It's their highest priority job with infinite slots. So we do a pass right at the start to give everyone with the Overflow role enabled that role and save us wasting time later on in random job code giving them that same role but with more work. The problem is the code for this only assigns the Overflow role to people with it set to Low priority in their prefs, resulting in log readouts like: ``` [2024-07-27 09:49:43.469] DEBUG-JOB: DO, Running Overflow Check 1 [2024-07-27 09:49:43.469] DEBUG-JOB: Running FOC, Job: /datum/job/assistant, Level: Low Priority [2024-07-27 09:49:43.472] DEBUG-JOB: FOC player job enabled at wrong level, Player: Radioprague, TheirLevel: Medium Priority, ReqLevel: Low Priority [2024-07-27 09:49:43.472] DEBUG-JOB: FOC player job enabled at wrong level, Player: Caluan, TheirLevel: High Priority, ReqLevel: Low Priority [2024-07-27 09:49:43.473] DEBUG-JOB: FOC player job enabled at wrong level, Player: Caractaser, TheirLevel: High Priority, ReqLevel: Low Priority [2024-07-27 09:49:43.473] DEBUG-JOB: FOC player job enabled at wrong level, Player: Apsua, TheirLevel: High Priority, ReqLevel: Low Priority [2024-07-27 09:49:43.475] DEBUG-JOB: FOC player job enabled at wrong level, Player: Bebrus2, TheirLevel: Medium Priority, ReqLevel: Low Priority [2024-07-27 09:49:43.475] DEBUG-JOB: AC1, Candidates: 0 ``` Where nobody gets pre-assigned the overflow role because their prefs are all set to the High priority from being toggled... Except wait a second, some people have it at Medium priority when it should just be a No Role/High Priority Role toggle? And herein we meet a problem. My hypothesis is that traits and stuff that change the overflow have allowed players to set the "ordinary" overflow role of Assistant to Medium and/or Low priority. This still shows as enabled in the prefs menu, but leads to an outcome where a player with assistant enabled is assigned Cook instead. ``` [2024-07-27 09:49:47.775] DEBUG-JOB: DO, Running Overflow Check 1 [2024-07-27 09:49:47.775] DEBUG-JOB: Running FOC, Job: /datum/job/assistant, Level: Low Priority ... [2024-07-27 09:49:43.475] DEBUG-JOB: FOC player job enabled at wrong level, Player: Bebrus2, TheirLevel: Medium Priority, ReqLevel: Low Priority ... [2024-07-27 09:49:47.987] DEBUG-JOB: Running AR, Player: Bebrus2, Job: /datum/job/cook, LateJoin: 0 ``` So players with the Overflow job pref set to Low (an unexpected state, should be disabled or High) would be guaranteed to get that role if none of the higher priority Head of Staff/AI/Dynamic roles took over via the bugged "force overflow for people with the pref enabled" proc. Players with the Overflow job pref set to High would be guaranteed to get that role if none of the higher priority Head of Staff/AI/Dynamic roles took over via the random job assignment code giving them their Highest priority role thanks to the infinite job slots of the Overflow. And players with the Overflow job pref set to Medium (an unexpected state, should be disabled or High) would get Assistant if the shuffle step of the available jobs list put Assisstant before any of the other jobs they had prefs enabled for at Medium that weren't already filled, otherwise they'd get another random job. This code is now changed to ignore the priority the player has set when looking for people to fill the overflow role. As long as it **is** enabled, the player will get it unless they're forced into a dynamic ruleset role (AI when malf rolls) or a Head of Staff role due to their other prefs (they have RD set to med or low, and no other player has a Head of Staff at high so they get randomly picked and miss the overflow role). This will increase the number of assistants in shifts where their pref state has Assisstant in the bugged Medium priority, but doesn't change it for bugged Low and not-bugged High/On priority. On the other side of the coin, we have how the random jobs are picked. They're kinda not random, and I noticed this reading the logs then reading the code. The list of available jobs to pick from is randomly shuffled - but only **once**. All players pull from a list of jobs in the same order. So you end up with a log block like this: ``` [2024-07-27 09:49:47.985] DEBUG-JOB: DO pass, Player: Pierow, Level:3, Job:Botanist [2024-07-27 09:49:47.985] DEBUG-JOB: Running AR, Player: Pierow, Job: /datum/job/botanist, LateJoin: 0 [2024-07-27 09:49:47.985] DEBUG-JOB: Player: Pierow is now Rank: Botanist, JCP:0, JPL:2 [2024-07-27 09:49:47.986] DEBUG-JOB: DO pass, Player: Daddos, Level:3, Job:Botanist [2024-07-27 09:49:47.986] DEBUG-JOB: Running AR, Player: Daddos, Job: /datum/job/botanist, LateJoin: 0 [2024-07-27 09:49:47.986] DEBUG-JOB: Player: Daddos is now Rank: Botanist, JCP:1, JPL:2 [2024-07-27 09:49:47.986] DEBUG-JOB: FOC job filled and not overflow, Player: Bebrus2, Job: /datum/job/botanist, Current: 2, Limit: 2 [2024-07-27 09:49:47.987] DEBUG-JOB: FOC player job not enabled, Player: Bebrus2 [2024-07-27 09:49:47.987] DEBUG-JOB: DO pass, Player: Bebrus2, Level:3, Job:Cook [2024-07-27 09:49:47.987] DEBUG-JOB: Running AR, Player: Bebrus2, Job: /datum/job/cook, LateJoin: 0 [2024-07-27 09:49:47.988] DEBUG-JOB: Player: Bebrus2 is now Rank: Cook, JCP:0, JPL:1 [2024-07-27 09:49:47.988] DEBUG-JOB: FOC player job not enabled, Player: Redwizz [2024-07-27 09:49:47.988] DEBUG-JOB: FOC job filled and not overflow, Player: Redwizz, Job: /datum/job/cook, Current: 1, Limit: 1 ``` The list is shuffled into an order of something like `list("Scientist", "Botanist", "Cook", "Sec Officer", ...)` then iterated over for each player. So every random job selection goes: > "Does Player1 have Scientist enabled and at the right priority? No? Okay, Botanist? Yes? You get botanist." > "Does Player2 have Scientist enabled and at the right priority? No? Okay, Botanist? Yes? You get botanist." > "Does Player3 have Scientist enabled and at the right priority? No? Okay, Botanist has no slots left so we'll remove it from the list. Okay, Cook? Yes? You get cook." > "Does Player4 have Scientist enabled and at the right priority? No? Okay, Cook has no slots left so we'll remove it from the list. Okay, Sec Officer? ..." This can lead to stacked individual departments if it gets randomly rolled to the start of the list in the shuffle, and completely empty departments if they end up at the end. On high pop shifts this is probably less of an issue. Player prefs add noise to this and as departments at the front fill up, those at the back pick up some of the lower pref players. But have you ever had a shift where there's just like... No fucking sec even though there's tons of players? The logging (before I made changes in this PR) was a bit ass, but my hypothesis there is that sec officer was shuffled right at the end of the random job list, so every other department was filled up before sec officers were picked. To mitigate this, I made the list shuffle every single time the game picks a random available job for the player. This should lead to a more balanced selection of available jobs by avoiding situations where the code is biased towards packing some departments by accident. ## Why It's Good For The Game Overflow fixes mean people who go to their prefs and see the Overflow Role is On will all have the same experience - They will be the Overflow role. More random random job selection should prevent individual departments having a jobs be stacked when it would have otherwise been possible for a more balanced selection but the code unintentially biased random departments to be overstaffed and understaffed each shift. ## Changelog 🆑 fix: Having the Overflow Role set to On will properly ensure you get that role at a High priority as intended by the game code. fix: Job selection is now a little bit more random. Fixes an unintentional bias in random job assignment that could lead to feast-or-famine for roles where everyone is assigned one job and nobody is assigned another job. /🆑 |
||
|
|
4c4930c71d | Merge branch 'master' of https://github.com/tgstation/tgstation into pulls-tg-to-fix-shit | ||
|
|
4d1639b04c |
Revert "Assorted changes to job assignment code and logging." (#85929)
Reverts tgstation/tgstation#85308  |
||
|
|
1eef540054 |
Assorted changes to job assignment code and logging. (#85308)
## About The Pull Request
This PR does a couple of minor things:
Makes the job debug logging a bit easier to follow.
Minorly brings some SSjob code up to code standards, converting proc
names to snake_case and doing some otherm is cleanup.
Refactored some stuff into different procs, updated some comments.
And some major things:
Changes the job assignment logic.
Old behaviour
> Assign dynamic priority roles
> Force one Head of Staff (if possible)
> Assign all AIs
> Assign overflow roles (bugged in 2 ways)
> Shuffle the available jobs list once, at the start of the random job
assignment loop
> Pick and assign random jobs for random players from High prefs down,
with a priority on Head of Staff roles
> Handle everyone that couldn't be assigned a random job
New behaviour
> Assign dynamic priority roles
> Assign all Head of Staff roles to players with High prefs
> If no Head of Staff was made in the above way, force one Head of Staff
(if possible)
> Assign all AIs
> Assign overflow roles (fixed)
> Prioritise and fill unfilled head roles at each job priority pref
level, from High prefs down.
> Build a list of all jobs that each unassigned player could be eligible
for at the above pref level.
> Pick a job from that list at random and assign it to the player.
> Handle everyone that couldn't be assigned a random job.
In reality there should be little impact on overall job assignment, the
code changes read more as semantics. For example, the priority check for
filling Head slots will have the same candidate pool in both old and new
versions, but in the new version we're more clearly saying that Heads
are important and we want to prioritise filling them for the sake of
round progression even though the outcome in new and old is the same.
A key change will lead to an increase in assistants - Overflow fixes.
Currently the code block to do early assignments to the Overflow role
doesn't work - or works but not as you'd expect. The idea was is that
because enabling the Overflow role in the prefs menu is an On/Off toggle
that sets the job to High priority when enabled and prevents any other
High priority pref, players that have the Overflow role enabled will
**always** get it. It's their highest priority job with infinite slots.
So we do a pass right at the start to give everyone with the Overflow
role enabled that role and save us wasting time later on in random job
code giving them that same role but with more work.
The problem is the code for this only assigns the Overflow role to
people with it set to Low priority in their prefs, resulting in log
readouts like:
```
[2024-07-27 09:49:43.469] DEBUG-JOB: DO, Running Overflow Check 1
[2024-07-27 09:49:43.469] DEBUG-JOB: Running FOC, Job: /datum/job/assistant, Level: Low Priority
[2024-07-27 09:49:43.472] DEBUG-JOB: FOC player job enabled at wrong level, Player: Radioprague, TheirLevel: Medium Priority, ReqLevel: Low Priority
[2024-07-27 09:49:43.472] DEBUG-JOB: FOC player job enabled at wrong level, Player: Caluan, TheirLevel: High Priority, ReqLevel: Low Priority
[2024-07-27 09:49:43.473] DEBUG-JOB: FOC player job enabled at wrong level, Player: Caractaser, TheirLevel: High Priority, ReqLevel: Low Priority
[2024-07-27 09:49:43.473] DEBUG-JOB: FOC player job enabled at wrong level, Player: Apsua, TheirLevel: High Priority, ReqLevel: Low Priority
[2024-07-27 09:49:43.475] DEBUG-JOB: FOC player job enabled at wrong level, Player: Bebrus2, TheirLevel: Medium Priority, ReqLevel: Low Priority
[2024-07-27 09:49:43.475] DEBUG-JOB: AC1, Candidates: 0
```
Where nobody gets pre-assigned the overflow role because their prefs are
all set to the High priority from being toggled... Except wait a second,
some people have it at Medium priority when it should just be a No
Role/High Priority Role toggle?
And herein we meet a problem. My hypothesis is that traits and stuff
that change the overflow have allowed players to set the "ordinary"
overflow role of Assistant to Medium and/or Low priority.
This still shows as enabled in the prefs menu, but leads to an outcome
where a player with assistant enabled is assigned Cook instead.
```
[2024-07-27 09:49:47.775] DEBUG-JOB: DO, Running Overflow Check 1
[2024-07-27 09:49:47.775] DEBUG-JOB: Running FOC, Job: /datum/job/assistant, Level: Low Priority
...
[2024-07-27 09:49:43.475] DEBUG-JOB: FOC player job enabled at wrong level, Player: Bebrus2, TheirLevel: Medium Priority, ReqLevel: Low Priority
...
[2024-07-27 09:49:47.987] DEBUG-JOB: Running AR, Player: Bebrus2, Job: /datum/job/cook, LateJoin: 0
```
So players with the Overflow job pref set to Low (an unexpected state,
should be disabled or High) would be guaranteed to get that role if none
of the higher priority Head of Staff/AI/Dynamic roles took over via the
bugged "force overflow for people with the pref enabled" proc.
Players with the Overflow job pref set to High would be guaranteed to
get that role if none of the higher priority Head of Staff/AI/Dynamic
roles took over via the random job assignment code giving them their
Highest priority role thanks to the infinite job slots of the Overflow.
And players with the Overflow job pref set to Medium (an unexpected
state, should be disabled or High) would get Assistant if the shuffle
step of the available jobs list put Assisstant before any of the other
jobs they had prefs enabled for at Medium that weren't already filled,
otherwise they'd get another random job.
This code is now changed to ignore the priority the player has set when
looking for people to fill the overflow role. As long as it **is**
enabled, the player will get it unless they're forced into a dynamic
ruleset role (AI when malf rolls) or a Head of Staff role due to their
other prefs (they have RD set to med or low, and no other player has a
Head of Staff at high so they get randomly picked and miss the overflow
role).
This will increase the number of assistants in shifts where their pref
state has Assisstant in the bugged Medium priority, but doesn't change
it for bugged Low and not-bugged High/On priority.
On the other side of the coin, we have how the random jobs are picked.
They're kinda not random, and I noticed this reading the logs then
reading the code.
The list of available jobs to pick from is randomly shuffled - but only
**once**. All players pull from a list of jobs in the same order. So you
end up with a log block like this:
```
[2024-07-27 09:49:47.985] DEBUG-JOB: DO pass, Player: Pierow, Level:3, Job:Botanist
[2024-07-27 09:49:47.985] DEBUG-JOB: Running AR, Player: Pierow, Job: /datum/job/botanist, LateJoin: 0
[2024-07-27 09:49:47.985] DEBUG-JOB: Player: Pierow is now Rank: Botanist, JCP:0, JPL:2
[2024-07-27 09:49:47.986] DEBUG-JOB: DO pass, Player: Daddos, Level:3, Job:Botanist
[2024-07-27 09:49:47.986] DEBUG-JOB: Running AR, Player: Daddos, Job: /datum/job/botanist, LateJoin: 0
[2024-07-27 09:49:47.986] DEBUG-JOB: Player: Daddos is now Rank: Botanist, JCP:1, JPL:2
[2024-07-27 09:49:47.986] DEBUG-JOB: FOC job filled and not overflow, Player: Bebrus2, Job: /datum/job/botanist, Current: 2, Limit: 2
[2024-07-27 09:49:47.987] DEBUG-JOB: FOC player job not enabled, Player: Bebrus2
[2024-07-27 09:49:47.987] DEBUG-JOB: DO pass, Player: Bebrus2, Level:3, Job:Cook
[2024-07-27 09:49:47.987] DEBUG-JOB: Running AR, Player: Bebrus2, Job: /datum/job/cook, LateJoin: 0
[2024-07-27 09:49:47.988] DEBUG-JOB: Player: Bebrus2 is now Rank: Cook, JCP:0, JPL:1
[2024-07-27 09:49:47.988] DEBUG-JOB: FOC player job not enabled, Player: Redwizz
[2024-07-27 09:49:47.988] DEBUG-JOB: FOC job filled and not overflow, Player: Redwizz, Job: /datum/job/cook, Current: 1, Limit: 1
```
The list is shuffled into an order of something like `list("Scientist",
"Botanist", "Cook", "Sec Officer", ...)` then iterated over for each
player. So every random job selection goes:
> "Does Player1 have Scientist enabled and at the right priority? No?
Okay, Botanist? Yes? You get botanist."
> "Does Player2 have Scientist enabled and at the right priority? No?
Okay, Botanist? Yes? You get botanist."
> "Does Player3 have Scientist enabled and at the right priority? No?
Okay, Botanist has no slots left so we'll remove it from the list. Okay,
Cook? Yes? You get cook."
> "Does Player4 have Scientist enabled and at the right priority? No?
Okay, Cook has no slots left so we'll remove it from the list. Okay, Sec
Officer? ..."
This can lead to stacked individual departments if it gets randomly
rolled to the start of the list in the shuffle, and completely empty
departments if they end up at the end.
On high pop shifts this is probably less of an issue. Player prefs add
noise to this and as departments at the front fill up, those at the back
pick up some of the lower pref players.
But have you ever had a shift where there's just like... No fucking sec
even though there's tons of players? The logging (before I made changes
in this PR) was a bit ass, but my hypothesis there is that sec officer
was shuffled right at the end of the random job list, so every other
department was filled up before sec officers were picked.
To mitigate this, I made the list shuffle every single time the game
picks a random available job for the player. This should lead to a more
balanced selection of available jobs by avoiding situations where the
code is biased towards packing some departments by accident.
## Why It's Good For The Game
Overflow fixes mean people who go to their prefs and see the Overflow
Role is On will all have the same experience - They will be the Overflow
role.
More random random job selection should prevent individual departments
having a jobs be stacked when it would have otherwise been possible for
a more balanced selection but the code unintentially biased random
departments to be overstaffed and understaffed each shift.
## Changelog
🆑
fix: Having the Overflow Role set to On will properly ensure you get
that role at a High priority as intended by the game code.
fix: Job selection is now a little bit more random. Fixes an
unintentional bias in random job assignment that could lead to
feast-or-famine for roles where everyone is assigned one job and nobody
is assigned another job.
/🆑
---------
Co-authored-by: san7890 <the@san7890.com>
|
||
|
|
f4e244fb49 |
[MIRROR] Refactors embedding to use datums instead of storing data in bespoke elements (#28699)
* Refactors embedding to use datums instead of storing data in bespoke elements (#84599) ## About The Pull Request This refactors embedding elements to make them use singleton datums (similarly to armor) instead being bespoke and creating a new element every time armor values are supposed to be adjusted. Default values have been removed from defines due to now being declared in base class itself. Additionally fixes vending machines and tackling gloves setting generated shards (which they instantly embed into their victim) embed properties to null after running the embedding code, despite said shards having non-null embedding values by default, making them not be able to embed into anyone else, also potentially breaking the pain/jostling code if they somehow get updated. ## Why It's Good For The Game Current embedding system is an unnecessarily complicated mess as bespoke elements are hard to work with, and creating a new element every time you change values is hacky at best. This change should make it easier to read and work with. ## Changelog 🆑 fix: Fixed glass shards generated from falling vending machines or tackling windows not being able to embed into anyone. refactor: Refactored embedding code to use datums instead of bespoke elements and ugly associated lists. /🆑 * Refactors embedding to use datums instead of storing data in bespoke elements * modular fixes * fix c14 * paint -> pain ugggh --------- Co-authored-by: SmArtKar <44720187+SmArtKar@users.noreply.github.com> Co-authored-by: SpaceLoveSs13 <68121607+SpaceLoveSs13@users.noreply.github.com> |
||
|
|
b6c84135c3 |
Refactors embedding to use datums instead of storing data in bespoke elements (#84599)
## About The Pull Request This refactors embedding elements to make them use singleton datums (similarly to armor) instead being bespoke and creating a new element every time armor values are supposed to be adjusted. Default values have been removed from defines due to now being declared in base class itself. Additionally fixes vending machines and tackling gloves setting generated shards (which they instantly embed into their victim) embed properties to null after running the embedding code, despite said shards having non-null embedding values by default, making them not be able to embed into anyone else, also potentially breaking the pain/jostling code if they somehow get updated. ## Why It's Good For The Game Current embedding system is an unnecessarily complicated mess as bespoke elements are hard to work with, and creating a new element every time you change values is hacky at best. This change should make it easier to read and work with. ## Changelog 🆑 fix: Fixed glass shards generated from falling vending machines or tackling windows not being able to embed into anyone. refactor: Refactored embedding code to use datums instead of bespoke elements and ugly associated lists. /🆑 |
||
|
|
1df0e42efb |
[MIRROR] Cigarettes and vapes are no longer subtypes of masks. (#28479)
* Cigarettes and vapes are no longer subtypes of masks. * clothing path * clothing misses * more * fix donator * more2 * more3 * Update prop_summoner.dm * Update prop_summoner.dm * fix --------- Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com> Co-authored-by: SpaceLoveSs13 <68121607+SpaceLoveSs13@users.noreply.github.com> |
||
|
|
35484728f1 |
Cigarettes and vapes are no longer subtypes of masks. (#82942)
## About The Pull Request Since non-clothing items can also be worn on several slots, there's no need for cigarettes/vapes to be subtypes of masks anymore, since that comes with a few oddities like #82870. ## Why It's Good For The Game This should fix #82870, with about no side-effect aside them no longer being edible by moths 🤢. |
||
|
|
f591dd3bd3 |
[MIRROR] Gondolas are now basic mobs (#27934)
* Gondolas are now basic mobs (#83451) ## About The Pull Request This PR turns gondolas into basic mobs and does some fiddling with gondola pods Their verbs are now action buttons which they lose upon delivering. If set to stay, they won't have their abilities afterwards (or wont get them in the first place if the delivery is already done). Lets them survive without a pod requirement in case admins want to spawn one for their own stuff, so I also removed it from the snowflake checks to exclude them from stuff. Also replaced the hardcoded "cant speak" with simply giving the mute trait, so admins can make gondolas speak if they want to for any reason. ## Why It's Good For The Game The pet level of simple animals can finally be killed off, also gives admins more control over gondola-related stuff if they so wish. ## Changelog 🆑 refactor: Gondolas (including gondola pods) are now basic mobs. /🆑 --------- Co-authored-by: san7890 <the@san7890.com> * Well then. Hope it works. * Ohhh. --------- Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com> Co-authored-by: san7890 <the@san7890.com> Co-authored-by: Useroth <37159550+Useroth@users.noreply.github.com> |
||
|
|
8442124bcd |
Gondolas are now basic mobs (#83451)
## About The Pull Request This PR turns gondolas into basic mobs and does some fiddling with gondola pods Their verbs are now action buttons which they lose upon delivering. If set to stay, they won't have their abilities afterwards (or wont get them in the first place if the delivery is already done). Lets them survive without a pod requirement in case admins want to spawn one for their own stuff, so I also removed it from the snowflake checks to exclude them from stuff. Also replaced the hardcoded "cant speak" with simply giving the mute trait, so admins can make gondolas speak if they want to for any reason. ## Why It's Good For The Game The pet level of simple animals can finally be killed off, also gives admins more control over gondola-related stuff if they so wish. ## Changelog 🆑 refactor: Gondolas (including gondola pods) are now basic mobs. /🆑 --------- Co-authored-by: san7890 <the@san7890.com> |
||
|
|
bcd232b21d |
Fixes Cursed Items wizard event (#83111)
Slot flags got changed from set 1 through 20 numbers to bitflags, this was runtiming since it was still trying to use the old hard-set slot numbers. ``` [2024-05-07 00:50:31.612] RUNTIME: runtime error: list index out of bounds - proc name: start (/datum/round_event/wizard/cursed_items/start) - source file: code/modules/events/wizard/curseditems.dm,44 - usr: null - src: /datum/round_event/wizard/curs... (/datum/round_event/wizard/cursed_items) - call stack: - /datum/round_event/wizard/curs... (/datum/round_event/wizard/cursed_items): start() - /datum/round_event/wizard/curs... (/datum/round_event/wizard/cursed_items): process(2) - Events (/datum/controller/subsystem/events): fire(0) - Events (/datum/controller/subsystem/events): ignite(0) - Master (/datum/controller/master): RunQueue() - Master (/datum/controller/master): Loop(2) - Master (/datum/controller/master): StartProcessing(0) - ``` 🆑 ShizCalev fix: Cursed Items wizard event actually works again. /🆑 |
||
|
|
d62a1d95ea |
Fixes Cursed Items wizard event (#83111)
Slot flags got changed from set 1 through 20 numbers to bitflags, this was runtiming since it was still trying to use the old hard-set slot numbers. ``` [2024-05-07 00:50:31.612] RUNTIME: runtime error: list index out of bounds - proc name: start (/datum/round_event/wizard/cursed_items/start) - source file: code/modules/events/wizard/curseditems.dm,44 - usr: null - src: /datum/round_event/wizard/curs... (/datum/round_event/wizard/cursed_items) - call stack: - /datum/round_event/wizard/curs... (/datum/round_event/wizard/cursed_items): start() - /datum/round_event/wizard/curs... (/datum/round_event/wizard/cursed_items): process(2) - Events (/datum/controller/subsystem/events): fire(0) - Events (/datum/controller/subsystem/events): ignite(0) - Master (/datum/controller/master): RunQueue() - Master (/datum/controller/master): Loop(2) - Master (/datum/controller/master): StartProcessing(0) - ``` 🆑 ShizCalev fix: Cursed Items wizard event actually works again. /🆑 |
||
|
|
227264f146 |
[MIRROR] Removes Orbit Polling Component, SSpolling improvement (#26769)
* Removes Orbit Polling Component, SSpolling improvement * a * Update effects.dmi * Update tgstation.dme * Revert "Update tgstation.dme" This reverts commit d4fdaf0abbfaacddb0cc0d175dad4e410fe57e44. --------- Co-authored-by: 13spacemen <46101244+13spacemen@users.noreply.github.com> Co-authored-by: Pinta <68373373+softcerv@users.noreply.github.com> |
||
|
|
357799c8a5 |
Removes Orbit Polling Component, SSpolling improvement (#81748)
When I made SSpolling, jlsnow gave me his blessing to delete the orbit polling component [where you orbit something for 20 seconds before it chooses a ghost from the orbiters] It's only used in a few places like soulstones replacing jobbanned/inactive players, etc. Also upgraded SSpolling; you can now place a little icon on the sides in the chat message, chat message looks a lot nicer, the alert pic and the jump target don't have to be the same anymore, and I made it be able to pre-pick candidates since 90% of the use cases would just want 1 candidate Also prints to chat who the chosen one was Also made slime intelligence potions ask the user for a reason, which will be displayed in the alert poll |
||
|
|
a4e243f638 |
[MIRROR] Fixes RPG titles alignment (#26230)
* Fixes RPG titles alignment (#81077) ## About The Pull Request Fixes https://github.com/tgstation/tgstation/issues/81013 RPG titles having incorrect alignment  ## Changelog 🆑 LT3 fix: Fixed alignment of RPG titles /🆑 * Fixes RPG titles alignment --------- Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com> |
||
|
|
afe30a4668 |
Fixes RPG titles alignment (#81077)
## About The Pull Request Fixes https://github.com/tgstation/tgstation/issues/81013 RPG titles having incorrect alignment  ## Changelog 🆑 LT3 fix: Fixed alignment of RPG titles /🆑 |
||
|
|
922ec66ee7 |
[MIRROR] Better Ghost Selection [MDB IGNORE] (#25789)
* Better Ghost Selection * yes * oldcode updates and compat --------- Co-authored-by: 13spacemen <46101244+13spacemen@users.noreply.github.com> Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com> |
||
|
|
908d6f1a2b |
Better Ghost Selection (#80283)
## About The Pull Request Revived my old PR https://github.com/tgstation/tgstation/pull/68901 Replaces the annoying tgui alert popup "Do you want to be X? | Yes | No | Never for this round" that is hard to read and steals window focus, with a nice clean alert in the top right that counts down. If it's the same event/mob they stack with 2x, 3x, etc. It also shows how many candidates/ghosts are signed up. The poll alerts have screentips too, they countdown and show if you're signed up, how many people are signed up, if you chose "never for this round" (which is cancelable) ## Why It's Good For The Game  Way easier to see what role is available, you get a nice pic of the role and get it's name in big text, you can cancel "never for this round", and you can cancel signing up for a role before the timer is up ## Changelog 🆑 refactor: Ghost roles now offer ghosts a clickable poll button. Ghosts can select a role, deselect it, alt-click it for "Never For This Round", can cancel "Never", can see the countdown, and can see how many other people are signed up for the role poll. /🆑 |
||
|
|
2fc93c632a |
[MIRROR] Improves Cursed Items Wizard Event [MDB IGNORE] (#25299)
* Improves Cursed Items Wizard Event * Update curseditems.dm * Update curseditems.dm --------- Co-authored-by: san7890 <the@san7890.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |
||
|
|
516e02d01a |
Improves Cursed Items Wizard Event (#79941)
## About The Pull Request I was bored and stumbled upon this and I remembered how pissed off I got that smoke would spawn on all humans during this event despite nothing *magical* happening to them. So, I fixed that (as well as saving us from iterating through `alive_mob_list` TWICE) and did some other code improvements while in the area. * We use define keys instead of raw strings (typo prevention) * No more single-letter variables (way more readable too) * Better indentation * Better list multilining * Some more documentation * Use legitimate boolean dichotomy yep it looks good ## Why It's Good For The Game you don't get smoke spawning on you for no reason at all when you didn't do anything ## Changelog 🆑 fix: During the "Cursed Items" wizard event, you should only have smoke spawn on you if you actually had a cursed item equipped to you. /🆑 --------- Co-authored-by: Fikou <23585223+Fikou@users.noreply.github.com> |
||
|
|
6627b1a9c1 |
[MIRROR] Refactors Parrots into Basic Mobs (ft. Ben10Omintrix/Kobsamobsa) [MDB IGNORE] (#25100)
* Refactors Parrots into Basic Mobs (ft. Ben10Omintrix/Kobsamobsa) * UpdatePaths * Modular, cleanup, porting parrot commands into the new system * makes poly slightly less of a dick * Update parrot.dm * Update parrot.dm * Update tgstation.dme * Revert "Update tgstation.dme" This reverts commit a8b40c4aba524c271db02c271089664649dea1eb. --------- Co-authored-by: san7890 <the@san7890.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |
||
|
|
b251b9dbb0 | Refactors Parrots into Basic Mobs (ft. Ben10Omintrix/Kobsamobsa) (#79762) | ||
|
|
365648698f |
[MIRROR] Prevents Mindswapping on Bitrunners [MDB IGNORE] (#24667)
* Prevents Mindswapping on Bitrunners (#79323) ## About The Pull Request Fixes #79310 Adds a new trait to prevent mindswaps (which is just useful for any future cases when we don't wanna rely on the blacklist typecache) while also accounting for bitrunners (who you can't mindswap because their mind is elsewhere) and their avatars (because that's not a real mind now is it). this does mean that bitrunners while bitrunning are immune to all mindswaps but i don't have a good answer on how to fix it. i don't even much like the idea of VR but I think that having these traits are useful enough for future utilization. ## Why It's Good For The Game prevent big breakage. ## Changelog 🆑 fix: Bitrunners can no longer get mass-mindswapped out of their avatar when the wizard does the event. Something about machinery and magic not going well together. /🆑 * Prevents Mindswapping on Bitrunners --------- Co-authored-by: san7890 <the@san7890.com> |
||
|
|
22de4d8b3b |
Prevents Mindswapping on Bitrunners (#79323)
## About The Pull Request Fixes #79310 Adds a new trait to prevent mindswaps (which is just useful for any future cases when we don't wanna rely on the blacklist typecache) while also accounting for bitrunners (who you can't mindswap because their mind is elsewhere) and their avatars (because that's not a real mind now is it). this does mean that bitrunners while bitrunning are immune to all mindswaps but i don't have a good answer on how to fix it. i don't even much like the idea of VR but I think that having these traits are useful enough for future utilization. ## Why It's Good For The Game prevent big breakage. ## Changelog 🆑 fix: Bitrunners can no longer get mass-mindswapped out of their avatar when the wizard does the event. Something about machinery and magic not going well together. /🆑 |
||
|
|
f6577ec049 |
[MIRROR] Refactors Sloths into Basic Mobs [MDB IGNORE] (#24171)
* Refactors Sloths into Basic Mobs (#78752) ## About The Pull Request Hey there, This just refactors sloths to the basic mob framework. Nothing new should be added beyond them seeming a bit more sluggish and being a bit smarter about the fights they pick/running away. ## Why It's Good For The Game Three more subtypes off the list, we are now sub-200 simple animals left to refactor. If people want to play catch with their sloth it should be much easier to fit that in now. ## Changelog 🆑 refactor: Sloths are now basic mobs, however their overall sluggish behavior shouldn't have changed much- let us know if anything is broken. /🆑 * Refactors Sloths into Basic Mobs * Modular path --------- Co-authored-by: san7890 <the@san7890.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |
||
|
|
3983623ac3 |
[MIRROR] Refactors Goats into Basic Mobs [MDB IGNORE] (#24142)
* Refactors Goats into Basic Mobs (#78759) ## About The Pull Request Refactors goats into basic mobs, pretty clean refactor. They're a bit smarter when it comes to retaliating mobs, and they're still just as good as ever when it comes to munching on good ol' plantlife. I also (finally) turned Pete into a goat subtype just in case people want to inject more behavior into him in the future. ## Why It's Good For The Game Cleaner implementation of code when it comes to doing stuff like eating kudzu or just lusting after flora. ## Changelog 🆑 refactor: Refactored goats into basic mobs! Not much should have changed beyond their endless desire to retaliate should you attack them, they're still just as good as chomping away plant life as ever. /🆑 * Refactors Goats into Basic Mobs * UpdatePaths --------- Co-authored-by: san7890 <the@san7890.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |
||
|
|
82904b766c |
Refactors Sloths into Basic Mobs (#78752)
## About The Pull Request Hey there, This just refactors sloths to the basic mob framework. Nothing new should be added beyond them seeming a bit more sluggish and being a bit smarter about the fights they pick/running away. ## Why It's Good For The Game Three more subtypes off the list, we are now sub-200 simple animals left to refactor. If people want to play catch with their sloth it should be much easier to fit that in now. ## Changelog 🆑 refactor: Sloths are now basic mobs, however their overall sluggish behavior shouldn't have changed much- let us know if anything is broken. /🆑 |
||
|
|
1b1fde4908 |
Refactors Goats into Basic Mobs (#78759)
## About The Pull Request Refactors goats into basic mobs, pretty clean refactor. They're a bit smarter when it comes to retaliating mobs, and they're still just as good as ever when it comes to munching on good ol' plantlife. I also (finally) turned Pete into a goat subtype just in case people want to inject more behavior into him in the future. ## Why It's Good For The Game Cleaner implementation of code when it comes to doing stuff like eating kudzu or just lusting after flora. ## Changelog 🆑 refactor: Refactored goats into basic mobs! Not much should have changed beyond their endless desire to retaliate should you attack them, they're still just as good as chomping away plant life as ever. /🆑 |
||
|
|
58c20a99fb |
[MIRROR] Basic blob mobs [MDB IGNORE] (#23938)
* Basic blob mobs * Update blackmesa.dmm * Modular update --------- Co-authored-by: Jacquerel <hnevard@gmail.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |
||
|
|
8cdc0fbe61 |
[MIRROR] Refactors Snakes into Basic Animals [MDB IGNORE] (#23972)
* Refactors Snakes into Basic Animals (#78612) * Refactors Snakes into Basic Animals * Modular paths --------- Co-authored-by: san7890 <the@san7890.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |
||
|
|
24ee1a4681 | Refactors Snakes into Basic Animals (#78612) | ||
|
|
517d33e6f0 |
Basic blob mobs (#78520)
## About The Pull Request I remembered today that blob code is ass, especially blob spores. There's still a lot to improve but I cleaned up _some_ of it by converting these mobs. Now they use a newer framework and more signal handling as compared to circular references. I _expect_ the behaviour here to largely be the same as it was or similar. I haven't added anything fancy or new. This is a reasonably big PR but at least all of the files are small? Everything here touched every other thing enough that it didnt make sense to split up sorry. Other things I did in code: - Experimented with replacing the `mob/blob` subtype with a component. Don't know if this is genius or stupid. - AI subtree which just walks somewhere. We've used this behaviour a lot but never given it its own subtree. - Blob Spores and Zombies are two different mobs now instead of being one mob which just changes every single one of its properties. - Made a few living defence procs call super, because the only thing super does was send a signal and we weren't doing that for no reason. Also added a couple extra signals for intercepts we did not have. ## Changelog 🆑 fix: Blob spores will respond to rallies more reliably (it won't runtime every time they try and pathfind). fix: Blobbernaut pain animation overlays should align with the direction the mob is facing instead of always facing South refactor: Blob spores, zombies, and blobbernauts now all use the basic mob framework. They should work the same, but please report any issues. /🆑 --------- Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com> Co-authored-by: san7890 <the@san7890.com> |
||
|
|
25fb2e098b |
[MIRROR] Adds error on qdeling callback, fixes errors this causes [MDB IGNORE] (#23271)
* Adds error on qdeling callback, fixes errors this causes (#77850) ## About The Pull Request You shouldn't ever qdel a callback. If you don't want to own it free your ref (remove it from a list/set it to null). When all refs are cleared it'll get cleaned up by byond itself * Adds error on qdeling callback, fixes errors this causes * Update cell_component.dm * Update acid.dm --------- Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |
||
|
|
ed0999e4ea |
Adds error on qdeling callback, fixes errors this causes (#77850)
## About The Pull Request You shouldn't ever qdel a callback. If you don't want to own it free your ref (remove it from a list/set it to null). When all refs are cleared it'll get cleaned up by byond itself |
||
|
|
d2b4b475cb |
[MIRROR] Spiders don't automatically grant an antag datum [MDB IGNORE] (#23029)
* Spiders don't automatically grant an antag datum (#77523) ## About The Pull Request Fixes #77501 Spider egg ghost role spawners grant the spider antag datum, rather than the act of being a spider. This means that gold core, mapstart, polymorph belt, and other spiders will not have an antagonist datum. While doing this I also made a new abstract `mob/living/basic/spider` type which all three kinds of spider life stage (`spiderling`, `young`, `giant`) extend from, because there was a gross amount of copied code. Now there isn't. Also the Flesh Spider and Event Midwife eggs now simply hatch adult spiders instead of child ones. This is because there is no reason for either of these to have a two minute wait time before they get going. Midwife spiders spawned by the event should just start spidering immediately, and Flesh Spiders are made by changelings and shouldn't be effected by measures introduced to balance the spider gamemode. Eggs which are laid during a round and _can_ hatch into midwife spiders still hatch baby spiders. Also I swapped some white pixels on the animation of the ambush spiderling for a different colour because they looked bad. ## Why It's Good For The Game While the policy is always "if you turn yourself into something, you're not an antagonist" the presence of the antag datum still confuses people. Plus that code was gross and I didn't like it. ## Changelog 🆑 fix: Giant Spiders only have an antag datum if created by the round event. balance: Flesh spider eggs hatch into adult spiders instead of baby spiders. balance: The eggs spawned by the start of the spider infestation event hatch into adult Midwife spiders instead of baby ones. /🆑 * Spiders don't automatically grant an antag datum * Modular paths * Modular paths --------- Co-authored-by: Jacquerel <hnevard@gmail.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com> |