Re spawning help, (posted a video)
Kittyclaws390
Member Posts: 27
I know my animation is bad I'm going to fix my flaws but that aside lol my tree won't respawn, I original was going to do this a different way but I didn't like the idea. I have windows, i would love to get a mac later on because there are a whole lot more tutorials but I can't right now. Sorry off topic, If there is anything I left out tell me and Ill take a pic or video of it. If anyone can help it will be much appreciated
Comments
The rules are working correctly.
You have them set up to . . . destroy the current actor - then spawn a copy in the same location that is rotated 180° - so the project is doing exactly what you are asking it to do.
Q: What part of your code tells the spawn behaviour to spawn the actor over on the righthand side of the screen.
Q: Why do you have 180° in the rotation field in the spawner ?
P.S. looks nice !
First off you are destroying the tree actor before it can spawn the tree actor again.
The reason it inverts is because you are spawning it at 180 degrees.
Try spawning it in the direction of 0 and from position of 1000 and 100 relative to scene. (if on an iPad project, otherwise put a position so the tree is on the scene.)
Edit: Socks beat me to it.
Need Help? Email Me | Templates | Full Game Source Code
If you want the tree to re-spawn on the right edge of the screen (this is just a guess) you would delete the 180 you have now 'in the direction' and put value in the first 'from position' box instead, making it Relative to Scene. Use a value off the right side of the scene.
The first box in the 'from position' is for the X offset (side-to-side) of the spawn and the second box is for the Y offset (top-to-bottom).
http://jamie-cross.net/posts/ ✮ Udemy: Introduction to Mobile Games Development ✮ Learn Mobile Game Development in One Day Using Gamesalad ✮ My Patreon Page
lol, I got confused by the 180 when I put it into the move section sorry I thought it was suppose to make it move. I didn't put the position in so I could show what it was doing but that solves my problems but one and thats when I put another move code into the section the new tree won't move. I've tried it many ways and i think im doing something wrong. how would you move this newly spawned tree
It would move the same way the old one was. Make sure the prototype has the same rules as the instance you have on scene.
Need Help? Email Me | Templates | Full Game Source Code
What is it you want to happen exactly? You touch the first tree, then what?
http://jamie-cross.net/posts/ ✮ Udemy: Introduction to Mobile Games Development ✮ Learn Mobile Game Development in One Day Using Gamesalad ✮ My Patreon Page
She wants another one to spawn out of screen and have the elephant walk towards it as well, so that the elephant can destroy it, and continue to have trees spawn continuously.
Perfect! Thanks a lot! I had deleted the prototype Thanks for everyones help!