Yogstation icon indicating copy to clipboard operation
Yogstation copied to clipboard

Adds a new wizard spell, Mimicry

Open Lichton opened this issue 2 years ago • 8 comments

My first PR!

Hello, I'm Photoshoot, and I've taken up the frankly absurd task of making a complicated new ability for a common antagonist as my first EVER code in Byond. However, I've spent like 5 days testing the balance, getting opinions on it, and fixing bugs/testing. I hope this is a sufficiently interesting feature for you all to consider merging it (AFTER the big bug I can't figure out is fixed). My intent with posting it here is just to show you all the code so you can understand my issue clearly, and help me figure out how to solve

The new spell.

disguise

Mimicry is a 1 spell point cost wizard spell in the Assistance category. When cast, it disguises the user as a random crewmember on the station. This completely alters your appearance and voice, but examination can still reveal you. However, this does not hide in hand items, so holding a staff or a gun will reveal you as a threat. It lasts for 15 seconds, with every level (Maximum upgrades is 2) giving it an extra 3 seconds.

After much bugfixing:

I believe I've idiot-proofed this spell as much as I can, all that's needed it to check that it functions normally for you guys off my computer. :cl:
rscadd: Added new wizard spell, Mimicry imageadd: Added icon for Mimicry spell /:cl:

Lichton avatar Aug 25 '22 01:08 Lichton

psst, put the icon here in the PR

VaelophisNyx avatar Aug 25 '22 01:08 VaelophisNyx

When the disguise is cast, it relies on you being a normal humanoid species, and prevents you from using the spell while you are not. HOWEVER, if you transform into anything other then a carbon during the spell (Shapechange spell included) your sprite can't be undisguised properly. I'm honestly not sure how I can fix this, but it'd have to be inside of revert_cast because that triggers whenever you become a carbon. Or, maybe doing it when your shape changes.

My advice would be to create TRAIT_NOWABBAJACK in code/__DEFINES/traits.dm and then apply that on cloak via ADD_TRAIT(L, TRAIT_NOWABBAJACK, MAGIC_TRAIT) where L is the mob, then removing it on decloak via REMOVE_TRAIT(L, TRAIT_NOWABBAJACK, MAGIC_TRAIT).

Then check for TRAIT_NOWABBAJACK via HAS_TRAIT(M, TRAIT_NOWABBAJACK) in code\modules\projectiles\projectile\magic.dm on /proc/wabbajack(mob/living/M, randomize).

ynot01 avatar Aug 25 '22 01:08 ynot01

psst, put the icon here in the PR

I actually did, extremely confused

When the disguise is cast, it relies on you being a normal humanoid species, and prevents you from using the spell while you are not. HOWEVER, if you transform into anything other then a carbon during the spell (Shapechange spell included) your sprite can't be undisguised properly. I'm honestly not sure how I can fix this, but it'd have to be inside of revert_cast because that triggers whenever you become a carbon. Or, maybe doing it when your shape changes.

My advice would be to create TRAIT_NOWABBAJACK in code/__DEFINES/traits.dm and then apply that on cloak via ADD_TRAIT(L, TRAIT_NOWABBAJACK, MAGIC_TRAIT) where L is the mob, then removing it on decloak via REMOVE_TRAIT(L, TRAIT_NOWABBAJACK, MAGIC_TRAIT).

Then check for TRAIT_NOWABBAJACK via HAS_TRAIT(M, TRAIT_NOWABBAJACK) in code\modules\projectiles\projectile\magic.dm on /proc/wabbajack(mob/living/M, randomize).

Luckily there is a notransform for living creatures.

Lichton avatar Aug 25 '22 02:08 Lichton

no no I mean put like, an exported GIF of it in the actual PR reason stuff, not just in the DMI file; so it's easier to see

VaelophisNyx avatar Aug 25 '22 05:08 VaelophisNyx

Check bloodsuckers veil spell and try reusing it's code instead of doing such horrific things like user.icon = target.icon

ghost avatar Aug 25 '22 06:08 ghost

no no I mean put like, an exported GIF of it in the actual PR reason stuff, not just in the DMI file; so it's easier to see

No I mean I did put that in the PR, right under the spell icon area, for some reason it didn't show up.

Check bloodsuckers veil spell and try reusing it's code instead of doing such horrific things like user.icon = target.icon

Bloodsuckers veil literally just doesn't do the thing I want it to do? This is the exact same code as the abductor code, which is already in the game, and has the same effect. I really don't understand your complaint here.

Lichton avatar Aug 25 '22 15:08 Lichton

Bloodsuckers veil literally just doesn't do the thing I want it to do? This is the exact same code as the abductor code, which is already in the game, and has the same effect. I really don't understand your complaint here.

I mean not the randomising part, i mean that it would be better to copy special apearance things rather then copying the icon

ghost avatar Aug 25 '22 19:08 ghost

Try to still put the sprite in the PR post so it's more easy to see, but being that this is your first pr and stuff i will let that slide being that it's only 1 sprite added, the icon is acceptable, so basically tldr keep trying to put the icon on the post but how it's your first pr it will still get the art approval, still try to fix it

Ye I will, I put it in the original post but for some reason didn't come through, and I forgot to ever put it in later

Lichton avatar Aug 27 '22 16:08 Lichton

This is 100% ready by the way to merge

Lichton avatar Sep 03 '22 01:09 Lichton