GUI movie clips, anyone?

How I did it:
As an experiment, I tried fiddling around with spritesheets to see if I could create movies in Roblox.

Programs I used: TexturePacker and a program to convert a mp4 to individual JPG files.

Used the mp4 to jpg program to break the movie into individual frames.

I then imported the jpg images into TexturePacker, and formed a giant sprite sheet with them. Once I resized it accordingly to be under 10K pixels in width, I exported it as a PNG (The original PNG can be found here, warning: Big image)

https://i.imgbomb.com/7ffsj.png

I then looked at one of the chunks in TexturePacker, and figured out that each chunk was about 142x80 pixels - accounting for the padding, I calculated that each in-game image would be about 144x82 pixels. Using the ImageRectOffset and ImageRectSize properties of an ImageLabel, I wrote a script that would play through the sprite sheet like a film strip (Right to left, ascending).

Script:

[code]local x = 10800
local y = 330
local img = script.Parent.ImageLabel

local r = game:GetService(“RunService”)

repeat
wait(1/20)
if y <= 2 then
y = 330
x = x - 144
else
y = y - 82
end
img.ImageRectOffset = Vector2.new(x,y)
until x <= 0[/code]

Currently, the image is stored in the local texture folder, due to the fact that Roblox has a limit on how big images can be. In the near future, I can split the movies into chunks of 1000x1000px, and play them in order.

1 Like

“In the near future, I can split the movies into chunks of 1000x1000px” I’ve never heard anything about ROBLOX planning to increase the max resolution for uploaded images – if they do, that’s amazing o.o

Last time I checked, the limit was around 1000x1000px, but I could be mistaken.

What? Decals are 420x420 and shirts are 585x559 IIRC. I’ve hear nothinggggg about 1000x1000

I thought decals used to be 256x256 and the site resized them to 420x420 for viewing to give some layer of protection against deliberate stealing

I believe they bumped it up to 420x420 for better textures.

The decal max size is 1024x1024 - AFAIK - and rendered on-site is 420x420

I can test it right now, to make sure that’s correct, but I’m pretty sure it’s correct.

[quote] The decal max size is 1024x1024 - AFAIK - and rendered on-site is 420x420

I can test it right now, to make sure that’s correct, but I’m pretty sure it’s correct. [/quote]

This is correct.

[quote] The decal max size is 1024x1024 - AFAIK - and rendered on-site is 420x420

I can test it right now, to make sure that’s correct, but I’m pretty sure it’s correct. [/quote]

Holy crap that makes life so much easier. Why did I hear of this earlier q.q

If only I still had my other computer, I would totally use this for to show off how un-lucky-luck me professionalnoobingflyingcrashingdodging skills are in Planetside 2 while this song is playing in the background :

This is an amazing idea, thanks for the code!

Pretty cool!
I made a short one

Clip:

Spritesheet (uploaded to Roblox)