0% found this document useful (0 votes)
9 views3 pages

Start

Eso

Uploaded by

josepharturo2009
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views3 pages

Start

Eso

Uploaded by

josepharturo2009
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 3

// ----------------------------------

// RSDK Project: Sonic 1/Sonic 2


// Script Description: Start Message Object
// Script Author: Christian Whitehead/Simon Thomley
// Unpacked by Rubberduckycooly's script unpacker
// ----------------------------------

//-------Aliases-------//
private alias 4 : TYPE_STARTMESSAGE

// Tables

event ObjectMain
switch object.state
case 0
CheckTouchRect(0, 0, screen.xsize, screen.ysize)
if inputPress.start == 1
checkResult = 1
end if
if inputPress.buttonA == 1
checkResult = 1
end if
if inputPress.buttonB == 1
checkResult = 1
end if
if inputPress.buttonC == 1
checkResult = 1
end if
if checkResult > -1
if options.stageSelectFlag == 1
if checkResult > 0
object.state = 2
else
object.state = 1
end if
else
object.state = 1
end if
PlaySfx(SfxName[Menu Select], 0)
StopMusic()
else
object.value4++
if object.value4 == 360
object.state = 4
end if
end if
break
case 1
object.value0 += 8
if object.value0 == 320
options.attractMode = 0
player.lives = 3
player.continues = 0
player.score = 0
player.scoreBonus = 0xC350
lampPostID = 0
specialStage.listPos = 0
specialStage.emeralds = 0
specialStage.nextZone = 0
stage.activeList = REGULAR_STAGE
stage.listPos = 0
LoadStage()
end if
SetScreenFade(0, 0, 0, object.value0)
break
case 2
object.value0 += 8
if object.value0 == 320
options.attractMode = 0
player.lives = 3
player.continues = 0
player.score = 0
player.scoreBonus = 0xC350
lampPostID = 0
specialStage.listPos = 0
specialStage.emeralds = 0
specialStage.nextZone = 0
stage.activeList = PRESENTATION_STAGE
stage.listPos = 5
LoadStage()
end if
SetScreenFade(0, 0, 0, object.value0)
break
case 3
object.value0 += 8
if object.value0 == 320
options.attractMode = 0
stage.listPos = 4
LoadStage()
end if
SetScreenFade(0, 0, 0, object.value0)
break
case 4
object.value0 += 8
if object.value0 == 320
player.lives = 3
player.continues = 0
player.score = 0
player.scoreBonus = 0xC350
lampPostID = 0
specialStage.listPos = 0
specialStage.emeralds = 0
specialStage.nextZone = 0
if attract.stage == 3
stage.activeList = SPECIAL_STAGE
stage.listPos = 0
else
stage.activeList = REGULAR_STAGE
stage.listPos = attract.stage
stage.listPos *= 3
end if
attract.stage++
attract.stage &= 3
options.attractMode = 1
credits.screen = 0
LoadStage()
end if
SetScreenFade(0, 0, 0, object.value0)
break
end switch
end event

event ObjectDraw
object.animationTimer++
if object.animationTimer > 59
object.animationTimer = 0
end if
if object.animationTimer > 29
DrawSpriteScreenXY(0, object.xpos, object.ypos)
end if
end event

event ObjectStartup
LoadSpriteSheet("Title/Title.gif")
switch engine.deviceType
case 0
SpriteFrame(-48, -4, 96, 8, 1, 283)
break
case 1
SpriteFrame(-56, -4, 112, 8, 1, 292)
break
end switch
end event

event RSDKDraw
DrawSprite(0)
end event

event RSDKLoad
LoadSpriteSheet("Global/Display.gif")
SpriteFrame(-16, -16, 32, 32, 1, 143)
end event

You might also like