// ----------------------------------
// RSDK Project: Sonic 2
// Script Description: Ship FG Object
// Script Author: Christian Whitehead/Simon Thomley
// Unpacked by Rubberduckycooly's script unpacker
// ----------------------------------


// ========================
// Events
// ========================

event ObjectDraw
	DrawSprite(object.propertyValue)
end event


event ObjectStartup
	LoadSpriteSheet("SCZ/Objects.gif")
	SpriteFrame(-32, -16, 64, 32, 153, 223)
	SpriteFrame(-40, -8, 80, 16, 344, 157)
	SpriteFrame(-8, -8, 16, 16, 344, 157)
	SpriteFrame(-40, -8, 64, 16, 344, 141)
	SpriteFrame(-16, -8, 32, 16, 392, 141)
	SpriteFrame(-16, -8, 32, 16, 392, 157)
	SpriteFrame(-32, -4, 64, 8, 153, 215)
	SpriteFrame(-8, -4, 16, 8, 344, 141)
	SpriteFrame(-40, -4, 80, 8, 72, 247)

	foreach (TypeName[Ship FG], arrayPos0, ALL_ENTITIES)
		object[arrayPos0].drawOrder = 5
	next
end event


// ========================
// Editor Events
// ========================

event RSDKDraw
	DrawSprite(object.propertyValue)
end event


event RSDKLoad
	LoadSpriteSheet("SCZ/Objects.gif")
	SpriteFrame(-32, -16, 64, 32, 153, 223)
	SpriteFrame(-40, -8, 80, 16, 344, 157)
	SpriteFrame(-8, -8, 16, 16, 344, 157)
	SpriteFrame(-40, -8, 64, 16, 344, 141)
	SpriteFrame(-16, -8, 32, 16, 392, 141)
	SpriteFrame(-16, -8, 32, 16, 392, 157)
	SpriteFrame(-32, -4, 64, 8, 153, 215)
	SpriteFrame(-8, -4, 16, 8, 344, 141)
	SpriteFrame(-40, -4, 80, 8, 72, 247)
	
	SetVariableAlias(ALIAS_VAR_PROPVAL, "frameID")
end event
