Path: blob/main/Scripts/R3/PaletteAni_C.txt
1319 views
//-------------Sonic CD Palette Animation Script--------------//1//--------Scripted by Christian Whitehead 'The Taxman'--------//2//-------Unpacked By Rubberduckycooly's Script Unpacker-------//34// Aliases5#alias Object.Value0 : Object.Timer6#alias Object.Value1 : Object.CurrentPalette78// Priority9#alias 1 : PRIORITY_ACTIVE101112sub ObjectMain13Object.Timer++14if Object.Timer == 315Object.Timer = 016Object.CurrentPalette++17Object.CurrentPalette %= 318SetActivePalette(Object.CurrentPalette, 0, 240)19end if20end sub212223sub ObjectStartup24Object[19].Type = TypeName[PaletteAnimation]25Object[19].Priority = PRIORITY_ACTIVE2627CopyPalette(0, 1)28CopyPalette(0, 2)2930// Bug Details:31// The TempValue2 here seems to cause the structs in R33C to use a black palette cycle when they are supposed to be green.32// This is because in "Palettes/R3C_PalCycle.act", idx-31 and idx-63 are black color slots.33// Could either imply that this is a coding oversight or a .pal file issue. Unsure of which it is.34TempValue0 = 035TempValue1 = 036TempValue2 = 3237while TempValue0 < 338LoadPalette("R3C_PalCycle.act", TempValue0, 160, TempValue1, TempValue2)39TempValue0++40TempValue1 += 3241TempValue2 += 3242loop43end sub444546// ========================47// Editor Subs48// ========================4950sub RSDKDraw51DrawSprite(0)52end sub535455sub RSDKLoad56LoadSpriteSheet("Global/Display.gif")57SpriteFrame(-16, -16, 32, 32, 1, 143) // #0 - "Script" Icon5859SetVariableAlias(ALIAS_VAR_PROPVAL, "unused")60end sub616263