my game won’t load, I think it is cause I am using graphics compatibility v1.
I need to know how to display a sprite in game. I have the pictures .
here is my code
and my config.lua
my game won’t load, I think it is cause I am using graphics compatibility v1.
I need to know how to display a sprite in game. I have the pictures .
here is my code
and my config.lua
The old spite library, which has been deprecated for over a year has been removed. If you still need it, you can get it from our github repository at:
https://github.com/coronalabs/framework-sprite-legacy
Rob
I dont understand what this does for me?
You get sprite.lua and drop it into the folder with your main.lua, then at the top of any module that you are calling the sprite library, simply do:
local sprite = require(“sprite”)
Rob
I don’t understand. what is the main problem.
local jetSpriteSet = (jetSprites,“planesprite1.png”,525,135)
local jetSprites = sprite.newSpriteSet(jetSpriteSheet,1,5) – THIS DOES NOT WORK ANYMORE
…
You cannot call sprite.* methods. They do not exist anymore in the main distributed package. You can get the Sprite legacy module from github and include it into your project as local sprite = require(‘sprite’) and the code will function again as long as it can see the new require.
can you take my code and show me exactly what I need to do? sorry I am just very confused. I am also very frustrated.
> can you take my code and show me exactly what I need to do?
No. Your code will not function without an understanding of modules, functions, and git.
To resolve this issue you will need a developer and some developer tools.
You could probably fix some of the code by switching to the new APIs. If you can’t read documentation and code yourself, you cannot fix this.
I’m going to make this as simple as I can.
Go to this website: https://github.com/coronalabs/framework-sprite-legacy
Click on the link for sprite.lua
There is an icon that looks like a clipboard with a C on it. That will copy the source code to your clip board.
Create a new file in your editor, paste the code into it.
Save that file with the name sprite.lua in the same folder with your main.lua
In your main.lua at this line at the top:
sprite = require(“sprite”)
Leave the “local” off of the front of that line. I don’t like it being global, but in this case, it’s probably the safest thing for modules you don’t have control over.
That should get you going.
Rob
The old spite library, which has been deprecated for over a year has been removed. If you still need it, you can get it from our github repository at:
https://github.com/coronalabs/framework-sprite-legacy
Rob
I dont understand what this does for me?
You get sprite.lua and drop it into the folder with your main.lua, then at the top of any module that you are calling the sprite library, simply do:
local sprite = require(“sprite”)
Rob
I don’t understand. what is the main problem.
local jetSpriteSet = (jetSprites,“planesprite1.png”,525,135)
local jetSprites = sprite.newSpriteSet(jetSpriteSheet,1,5) – THIS DOES NOT WORK ANYMORE
…
You cannot call sprite.* methods. They do not exist anymore in the main distributed package. You can get the Sprite legacy module from github and include it into your project as local sprite = require(‘sprite’) and the code will function again as long as it can see the new require.
can you take my code and show me exactly what I need to do? sorry I am just very confused. I am also very frustrated.
> can you take my code and show me exactly what I need to do?
No. Your code will not function without an understanding of modules, functions, and git.
To resolve this issue you will need a developer and some developer tools.
You could probably fix some of the code by switching to the new APIs. If you can’t read documentation and code yourself, you cannot fix this.
I’m going to make this as simple as I can.
Go to this website: https://github.com/coronalabs/framework-sprite-legacy
Click on the link for sprite.lua
There is an icon that looks like a clipboard with a C on it. That will copy the source code to your clip board.
Create a new file in your editor, paste the code into it.
Save that file with the name sprite.lua in the same folder with your main.lua
In your main.lua at this line at the top:
sprite = require(“sprite”)
Leave the “local” off of the front of that line. I don’t like it being global, but in this case, it’s probably the safest thing for modules you don’t have control over.
That should get you going.
Rob