Its not so hard for me to take a object from a scene and move it to a point, scale it or something similar in lua. But how I can create an object and assign a graphic in lua?
local tmpObj = game.CurrentScene:create(VSceneObjects, "temp")
works, there is a new object, but I dont find a way to give it a graphic (sprite?).
Example of (diffent) things I want to do:
-Player clicks and a ball is thrown through the scene.
- Putting back an item by right clicking: A graphic of the object is shown near the cursor position and the item is moving to the inventory symbol. (generating an object as part of the scene is maybe not the best idear)
Some approach?