mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 05:00:55 +01:00
Pixel adjustments to mobs are now sourced / Refactors riding (#89320)
Fixes #85980 - Pixel adjustments are now sourced When tweaking a mob's pixel w, x, y, z, is is now done via `add_offsets` and must have a source string associated - Refactors riding Refactors how riding component selects the offsets to use. It's now all done via the getter rather than a weird mix of a var, a cache, and a getter. - Moves a bunch of animations to use `pixel_w` / `pixel_z` Largely to prevent conflicts with adjustments to a mob's pixel position, but also as many animations are not actual movements, but visual movements. Floating is one such example. It just works 🆑 Melbert fix: Fixed grab offsets not showing for anything but passive grab fix: Fix jank with mob offsets when riding things refactor: Refactored riding component, particularly how it selects layer and offsets. Report any oddities refactor: Refactored pixel offsets of mobs. Report any oddities /🆑
This commit is contained in:
@@ -249,12 +249,10 @@
|
||||
owner.emote("twitch")
|
||||
if(2 to 3)
|
||||
owner.say("[prob(50) ? ";" : ""][pick("SHIT", "PISS", "FUCK", "CUNT", "COCKSUCKER", "MOTHERFUCKER", "TITS")]", forced=name)
|
||||
var/x_offset_old = owner.pixel_x
|
||||
var/y_offset_old = owner.pixel_y
|
||||
var/x_offset = owner.pixel_x + rand(-2,2)
|
||||
var/y_offset = owner.pixel_y + rand(-1,1)
|
||||
animate(owner, pixel_x = x_offset, pixel_y = y_offset, time = 1)
|
||||
animate(owner, pixel_x = x_offset_old, pixel_y = y_offset_old, time = 1)
|
||||
var/w_offset = rand(-2, 2)
|
||||
var/z_offset = rand(-1, 1)
|
||||
animate(owner, pixel_w = w_offset, pixel_z = z_offset, time = 0.1 SECONDS, flags = ANIMATION_RELATIVE|ANIMATION_PARALLEL)
|
||||
animate(owner, pixel_w = -w_offset, pixel_z = -z_offset, time = 0.1 SECONDS, flags = ANIMATION_RELATIVE)
|
||||
|
||||
|
||||
//Deafness makes you deaf.
|
||||
|
||||
Reference in New Issue
Block a user