I'm new to Unity and trying to figure out the best way to create animated backgrounds. To be clear, I'm not asking you to give me an exact solution or instructions, and I would be grateful if you just tell me which direction to look in, and I will figure it out by reading the documentation.
I'm interested in how animated backgrounds are created in 2D Unity (for example, as here: https://youtu.be/OxiGlmV6ByA?t=1075 flying leaves are visible on the background). I only thought of using particles or just creating standard animations in Unity. But, the second way seems too long and complex, and about the particles, I'm not sure how much it affects the performance in a mobile game. Google searches mostly give instructions on how to create parallax backgrounds or moving backgrounds in Unity.
In general, I will be grateful if you tell me which approach is the most optimal for creating an animated background in a mobile 2D game in Unity.
The particles system is well optimized, for what you want to do it will not affects the performance, even on mobile.
Related
In Unity is there a way to stop the camera rendering few objects or lets say far away objects so that it is more performant? I can achieve this with adjusting the far-clipping plane. But I also want the objects to be seen by camera. Such that the objects are visible in the scene but not rendered by the camera? This is specifically for VR purpose. Is there a way to achieve such an unusual thing?
If I understand correctly, you're asking for something to be visible but unrendered. This poses a conflicting problem, as rendering something is the process of making it visible.
Normally, you'd work with not rendering things outside of the viewport and LOD (level of detail).
LOD
Basically rendering things far away with low level of detail, making the game more performant. You can see how to set it up here: https://docs.unity3d.com/Manual/LevelOfDetail.html
Occlusion Culling
Culling is partly done by Unity, as can be read here: https://docs.unity3d.com/Manual/OcclusionCulling.html
There might be more answers than this, I'm not sure I fully understand what you wish and I am not a game designer by profession so my optimization skills are sub-par.
I am new to coding, so am unfamiliar with many techniques etc, so please bear with!
I was wondering how you would go about recreating the effect seen in 'God of light' (http://wpuploads.appadvice.com/wp-content/uploads/2014/02/IMG_5498.jpeg), specifically the animated beams of light, with the awesome 'energy' look to them. In my SpriteKit game, the player reflects a beam (of light) using mirrors they draw. I am currently creating the beam using a CGPath as this lets me change its length easily, and have finished the code for the game without textures and just using SKSpriteNodes and shapes etc but I am clueless as to how I would go about adding an animated texture to the beam, such as the one in God of Light. If anyone would be willing to share any ideas as to the basic plan they would use to go about creating this effect I would be very appreciative!
Sorry its a little vague, but I haven't begun giving the beam a texture yet, and literally have no idea how to go about it.
Thanks!
I would use a separate animation program such as After Effects to create the the animation effect you want and export a series of keyframes. Then I would place the keyframes into an atlas and use SKAction animateWithTextures to animate them. Here is an excellent tutorial on it: Sprite Kit Tutorial: Animations and Texture Atlases: http://www.raywenderlich.com/45152/sprite-kit-tutorial-animations-and-texture-atlases
I am new to iPhone development, and I am looking for someone with experience
to simply tell me whether I am on the right path or to perhaps point me to it
regarding what I am trying to acheive.
I am trying to develop a character animation that reacts to the volume of
the microphone input. Something like Talking Tomcat, except that instead of
having just a face react to the volume, an entire character´s body is involved.
The character has been created in illustrator and it is image based. So
this will be a 2D animation. I have created numerous frames for the different
kinds of reactions the character will have depending on the volume.
For my animation I am using UIViews using its Animation resources and adding
UIImageViews as subviews. I am also using CGAffineTransforms for rotating
images.
I am also relying on Timers to control the different stages of the
animation.
To allow for a more flexible animation, I have created UIViews for the head,
arms, torso and legs of the character. These have been severed into their own
images and I am manipulating these images individually through UIViews.
I can go over my code in more detail if necessary, although any help will be greatly appreciated even if it is something off the bat.
Seeing that you're not an advanced ios developer I would suggest starting with cocos2d.
It has everything you need to start with animation.
Web page and forums has plenty of information on how to do it and... what's most important [to me at least], you've got gurus like Ray Wenderlich writing excellent tutorials like:
http://www.raywenderlich.com/1271/how-to-use-animations-and-sprite-sheets-in-cocos2d
I have been messing around with Cocos2d for a while but decided that, due to my lack of graphic design skills, I would be better off creating a game with Geo wars style graphics. I.e. geometric shapes etc.
Can anyone point me in the right direction on how to get started with this? I know I can create rudimentary shapes but how do I go about getting glowing shapes, particle effects etc.
Any advice or pointers in the right direction would be greatly appreciated, I have thus far been unable to find much information on creating graphics in the style that I want!
With Cocos2d the best way to get the glow would to probably be to bake them into the sprites themselves and animate between different levels of glow.
Particle effects is well covered in the programming guide, the particle designer program they mention makes it pretty painless as well
http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:particles
I went through all my resources but I am not getting the scattering effect of an image smoothly. However, I am able to zoom it and I had scattered it but it is not as smooth as I want. I just want to click on a button and it should zoom and the other image should get scatter
I want the image to be scattered as the link given below is it possible in iPhone?
http://www.touchmagix.com/templates/diamond.htm
this is hell lot of graphics. If you intend to achieve this with iPhone sdk, start learning details about CALayer and then try to manipulate the movements of different objects. Which will require lot of coding logic.
My suggestion would be going for Cocos2D and try with the different classes and api's present there. In Cocos2D you can create an image which will act as an actual physical object and you can apply all laws of physics to it. Say if you create a ball, and you push it, the ball will go in the direction of the push and bounce back if it gets hit by any other physical object and you don't require to do any coding for this. Cocos2D takes care of all these things.
Try it.