mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-17 12:35:26 +00:00
<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may not be viewable. --> <!-- You can view Contributing.MD for a detailed description of the pull request process. --> ## About The Pull Request small tweaks for bitrunning - ability disks grant a huge power spike which should let me balance megafauna health more closely to the real thing - added a check for bit avatars to skip dynamic midround checks - more info for netpods mostly <!-- Describe The Pull Request. Please be sure every change is documented or this can delay review and even discourage maintainers from merging your PR! --> ## Why It's Good For The Game fixes #78513 fixes #78575 <!-- Argue for the merits of your changes and how they benefit the game, especially if they are controversial and/or far reaching. If you can't actually explain WHY what you are doing will improve the game, then it probably isn't good for the game in the first place. --> ## Changelog <!-- If your PR modifies aspects of the game that can be concretely observed by players or admins you should add a changelog. If your change does NOT meet this description, remove this section. Be sure to properly mark your PRs to prevent unnecessary GBP loss. You can read up on GBP and it's effects on PRs in the tgstation guides for contributors. Please note that maintainers freely reserve the right to remove and add tags should they deem it appropriate. You can attempt to finagle the system all you want, but it's best to shoot for clear communication right off the bat. --> 🆑 add: Netpods and quantum servers now have more examination info fix: You no longer lose antag status if you receive it in the vdom. fix: Beach bar shouldn't have visible atmos piping anymore. fix: Adds more lighting to the vaporwave vdom level. balance: Buffed vdom megafauna health to compensate for new ability disks. /🆑 <!-- Both 🆑's are required for the changelog to work! You can put your name to the right of the first 🆑 if you want to overwrite your GitHub username as author ingame. --> <!-- You can use multiple of the same prefix (they're only used for the icon ingame) and delete the unneeded ones. Despite some of the tags, changelogs should generally represent how a player might be affected by the changes rather than a summary of the PR's contents. -->
102 lines
2.7 KiB
Plaintext
102 lines
2.7 KiB
Plaintext
/// Generates a new avatar for the bitrunner.
|
|
/obj/machinery/quantum_server/proc/generate_avatar(obj/structure/hololadder/wayout, datum/outfit/netsuit)
|
|
var/mob/living/carbon/human/avatar = new(wayout.loc)
|
|
|
|
var/outfit_path = generated_domain.forced_outfit || netsuit
|
|
var/datum/outfit/to_wear = new outfit_path()
|
|
|
|
to_wear.belt = /obj/item/bitrunning_host_monitor
|
|
to_wear.glasses = null
|
|
to_wear.gloves = null
|
|
to_wear.l_hand = null
|
|
to_wear.l_pocket = null
|
|
to_wear.r_hand = null
|
|
to_wear.r_pocket = null
|
|
to_wear.suit = null
|
|
to_wear.suit_store = null
|
|
|
|
avatar.equipOutfit(to_wear, visualsOnly = TRUE)
|
|
|
|
var/thing = avatar.get_active_held_item()
|
|
if(!isnull(thing))
|
|
qdel(thing)
|
|
|
|
thing = avatar.get_inactive_held_item()
|
|
if(!isnull(thing))
|
|
qdel(thing)
|
|
|
|
var/obj/item/storage/backpack/bag = avatar.back
|
|
if(istype(bag))
|
|
QDEL_LIST(bag.contents)
|
|
|
|
bag.contents += list(
|
|
new /obj/item/storage/box/survival,
|
|
new /obj/item/storage/medkit/regular,
|
|
new /obj/item/flashlight,
|
|
)
|
|
|
|
var/obj/item/card/id/outfit_id = avatar.wear_id
|
|
if(outfit_id)
|
|
outfit_id.assignment = "Bit Avatar"
|
|
outfit_id.registered_name = avatar.real_name
|
|
|
|
outfit_id.registered_account = new()
|
|
outfit_id.registered_account.replaceable = FALSE
|
|
|
|
SSid_access.apply_trim_to_card(outfit_id, /datum/id_trim/bit_avatar)
|
|
|
|
return avatar
|
|
|
|
/// Generates a new hololadder for the bitrunner. Effectively a respawn attempt.
|
|
/obj/machinery/quantum_server/proc/generate_hololadder()
|
|
if(!length(exit_turfs))
|
|
return
|
|
|
|
if(retries_spent >= length(exit_turfs))
|
|
return
|
|
|
|
var/turf/destination
|
|
for(var/turf/dest_turf in exit_turfs)
|
|
if(!locate(/obj/structure/hololadder) in dest_turf)
|
|
destination = dest_turf
|
|
break
|
|
|
|
if(isnull(destination))
|
|
return
|
|
|
|
var/obj/structure/hololadder/wayout = new(destination)
|
|
if(isnull(wayout))
|
|
return
|
|
|
|
retries_spent += 1
|
|
|
|
return wayout
|
|
|
|
/// Scans over neo's contents for bitrunning tech disks. Loads the items or abilities onto the avatar.
|
|
/obj/machinery/quantum_server/proc/stock_gear(mob/living/carbon/human/avatar, mob/living/carbon/human/neo)
|
|
var/failed = FALSE
|
|
|
|
for(var/obj/item/bitrunning_disk/disk in neo.get_contents())
|
|
if(istype(disk, /obj/item/bitrunning_disk/ability))
|
|
var/obj/item/bitrunning_disk/ability/ability_disk = disk
|
|
|
|
if(isnull(ability_disk.granted_action))
|
|
failed = TRUE
|
|
continue
|
|
|
|
var/datum/action/our_action = new ability_disk.granted_action()
|
|
our_action.Grant(avatar)
|
|
continue
|
|
|
|
if(istype(disk, /obj/item/bitrunning_disk/item))
|
|
var/obj/item/bitrunning_disk/item/item_disk = disk
|
|
|
|
if(isnull(item_disk.granted_item))
|
|
failed = TRUE
|
|
continue
|
|
|
|
avatar.put_in_hands(new item_disk.granted_item())
|
|
|
|
if(failed)
|
|
to_chat(neo, span_warning("One of your disks failed to load. You must activate them to make a selection."))
|