Files
Bubberstation/code/__DEFINES/visual_helpers.dm
Krysonism 17006b220f NT researchers make shocking breakthrough in flux anomalogics! Tesla Cannon Resprite / Resound (#92031)
## About The Pull Request

![tesla_card](https://github.com/user-attachments/assets/27d0777b-3014-4785-b06e-f5e7fe0d5a36)

Resprites:

Tesla Cannon 
Tesla Cannon crafting kit

### New SFX / VFX

The tesla cannon now uses a new type of beam effect that randomly picks
sprite variants for each segment instead of a tracer.

This makes the arc look more dynamic and less distorted. 

Autofire guns can now choose to use a looping sound datum when firing.


![image](https://github.com/user-attachments/assets/b9c0c494-fce6-48bc-9d09-ea2e6257c86c)

#### Balance changes

The tesla cannon must now have its stock unfolded before firing, this
takes 1.5 seconds and makes the gun bulky.

It is still normal sized when folded, and folding it is instant.

### Bug fixes

Fixed a bug where looping_sound.stop() would fail to stop sounds.

The tesla cannon is an incredibly powerfu 

## Why It's Good For The Game

### My reasons for respriting

The old sprite was not bad, by all means but I had a few gripes with it.

* The old sprite does not incorporate the flux anomaly yellow colour.

* The old sprite looks a bit much like a real, professionally produced
sci-fi weapon,

* The old sprite looks pretty small for such a ultra high dps full auto
weapon.

* The old inhand is quite indistinct for something that can game end you
in like one second.

### My design

I think that anomaly items should be very mad science coded and, since
anomaly science is by definition a poorly studied field, they should
look more like prototypes created by a scientist rather than something
professionally made in a factory.

## Changelog

🆑
image: The tesla cannon has new sprites.
image: The tesla parts kit has new sprites.
image: The tesla cannon has a new shocking beam effect when firing.
sound: The tesla cannon has new sounds.
balance: The tesla cannon must now be unfolded to fire.
fix: looping sounds now stop playing sounds when commaned to do so.
/🆑
2025-08-19 22:35:58 -04:00

26 lines
839 B
Plaintext

/// Use this to set the base and ACTUAL pixel offsets of an object at the same time
/// You should always use this for pixel setting in typepaths, unless you want the map display to look different from in game
#define SET_BASE_PIXEL(x, y) \
pixel_x = x; \
base_pixel_x = x; \
pixel_y = y; \
base_pixel_y = y;
/// Helper define, sets JUST base pixel offsets
#define _SET_BASE_PIXEL_NO_OFFSET(x, y) \
base_pixel_x = x; \
base_pixel_y = y;
#define SET_BASE_VISUAL_PIXEL(w, z) \
pixel_w = w; \
base_pixel_w = w; \
pixel_z = z; \
base_pixel_z = z;
#define _SET_BASE_PIXEL_VISUAL_NO_OFFSET(w, z) \
base_pixel_w = w; \
base_pixel_z = z;
/// Much like [SET_BASE_PIXEL], except it will not effect pixel offsets in mapping programs
#define SET_BASE_PIXEL_NOMAP(x, y) MAP_SWITCH(SET_BASE_PIXEL(x, y), _SET_BASE_PIXEL_NO_OFFSET(x, y))