Weapon sprites keep cutting off

Ask about editing graphics, sounds, models, music, etc here!
Shaders (GLSL) and SNDINFO questions also go here!

Moderators: GZDoom Developers, Raze Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
DoritoDustin
Posts: 9
Joined: Thu Nov 16, 2023 6:07 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 11

Weapon sprites keep cutting off

Post by DoritoDustin »

Hello all,

I'm making a custom weapon with a CQB gunfu attack and a custom reload animation. when I made them i made sure they were all 320x200. However when I import them into the game some of the frames, particularly around the edges, get cut off. I've got some video here:



Is there a way to just ignore the boxes built in and just have an image be bigger? I looked up Weaponsprite and maybe this is one way ?

Also what do modders typically use for their weapon sprites? Mine come out all blurry and filtered and I'm not sure what to do about it.
User avatar
Marrub
 
 
Posts: 1193
Joined: Tue Feb 26, 2013 2:48 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Arch Linux
Graphics Processor: ATI/AMD with Vulkan/Metal Support

Re: Weapon sprites keep cutting off

Post by Marrub »

320x200 is only one full 4:3 screen. The weapon is getting offset (by Hideous Destructor's bobbing,) and centered for wide-screen (by the engine.) So, it'll inevitably show the edges. You want to make sprites be the entire frame—everything that could possibly ever be visible, not just what a 4:3 screen would see. Then make sure it's cropped to the content of the image, and offset it with a tool like SLADE. SLADE also will show you the 4:3 screen bounds and the bobbing bounds.
Here's an example of a sprite that goes off the normal 4:3 screen on both axes, where the thick lines show the 320x200 area:
Image
Also, your sprites are likely blurry because you rotated and scaled them with an inadequate tool set up to use some kind of filtering. I don't really know what's best for pixel art in this case, I've just avoided ever doing those kinds of transformations.
DoritoDustin
Posts: 9
Joined: Thu Nov 16, 2023 6:07 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 11

Re: Weapon sprites keep cutting off

Post by DoritoDustin »

Thank you for the response. I believe you are right about the tools as they had anti-aliasing as a default when I used them. I'm going to look into the other information provided. Appreciate the assist.

Return to “Assets (and other stuff)”