Brent,
Thank you… really appreciate your help on this one Brent… The code is below
Config file
application =
{
content =
{
width = 1024,
height = 768,
scale = "zoomEven", -- zoom to fill screen, possibly cropping edges
imageSuffix =
{
["@2x"] = 2
},
},
}
main.lua
display.setStatusBar( display.HiddenStatusBar )
require "sprite"
local definitions = require ('data')
local imageSheet = graphics.newImageSheet("dog\_sleeping.png", definitions.options )
local character = display.newSprite( imageSheet, definitions.sequenceData )
character.x = display.contentWidth/2
character.y = display.contentHeight/2
character:setSequence( "left")
character:play()
data.lua
[code]
local zombie_data = {
options =
{
frames =
{
{
x = 0, y = 0, width = 200, height = 83
},
{
x = 200, y = 0, width = 200, height = 83
},
{
x = 0, y = 166, width = 200, height = 84
},
{
x = 200, y = 166, width = 200, height = 84
},
{
x = 400, y = 334, width = 200, height = 85
},
{
x = 0, y = 419, width = 200, height = 85
},
{
x = 400, y = 589, width = 200, height = 86
},
{
x = 200, y = 419, width = 200, height = 85
},
{
x = 400, y = 419, width = 200, height = 85
},
{
x = 400, y = 166, width = 200, height = 84
},
{
x = 0, y = 250, width = 200, height = 84
},
{
x = 400, y = 0, width = 200, height = 83
},
{
x = 0, y = 83, width = 200, height = 83
},
{
x = 200, y = 83, width = 200, height = 83
},
{
x = 200, y = 250, width = 200, height = 84
},
{
x = 400, y = 250, width = 200, height = 84
},
{
x = 0, y = 504, width = 200, height = 85
},
{
x = 200, y = 504, width = 200, height = 85
},
{
x = 0, y = 675, width = 200, height = 86
},
{
x = 400, y = 504, width = 200, height = 85
},
{
x = 0, y = 589, width = 200, height = 85
},
{
x = 200, y = 589, width = 200, height = 85
},
{
x = 0, y = 334, width = 200, height = 84
},
{
x = 200, y = 334, width = 200, height = 84
},
{
x = 400, y = 83, width = 200, height = 83
},
},
– The params below are optional; used for dynamic resolution support
sheetContentWidth = 782, – width of original 1x size of entire sheet
sheetContentHeight = 782 – height of original 1x size of entire sheet
},
sequenceData = {
{ name=“idle”, frames = {1}, time = 1000, loopCount = 1 },
{ name=“left”, start=1, count=25, time = 2000, loopCount = 0 },
}
}
return zombie_data
[/code] [import]uid: 67619 topic_id: 34423 reply_id: 136830[/import]