You can check their exact licensing policy. This website provides high-quality graphics for devs to use in prototyping their games and is well worth a visit. Note: I pieced together the graphics for Uber Jump using the amazing artwork provided by. You can learn more about texture atlases in Sprite Kit in this tutorial. The game assets are stored in a texture atlas for efficiency. The game assets are all of the sprites, such as the player character, platforms and stars: I’ve split the artwork into background tiles and game assets.īackground tiles are large tiles that scroll up and down the screen as the player moves: Make sure that “Destination: Copy items if needed” is checked and that your UberJump target is selected. Importing the Artīefore you get down to adding Sprite Kit nodes to your game, you need some art.ĭownload the graphics resources for this project, drag the contents into your Xcode project. Now you are ready to start adding your game’s components. Ensure that the only available device orientation is Portrait. With your project selected in the Project Navigator in Xcode, select the UberJump target, go to the General settings tab and look in the Deployment Info section. Since your game is going to use the accelerometer, you need to make sure that tilting the device doesn’t flip the game into landscape mode. You’ll be replacing what’s in the GameScene.swift file in just a moment, but first you have one last thing to setup. Let scene = GameScene(size: )īuild and run to make sure everything is working so far.ĭon’t worry about the “Hello, World” text label clipping. Then replace viewDidLoad with the following: Now open GameViewController.swift and delete the unarchiveFromFile SKNode extension at the top of the file, as you won’t be needing this extraneous code. ![]() When the warning alert shows, choose Move to Trash. You won’t be using this, so select it and press the delete key. Locate the GameScene.sks file in the Project Navigator. Fire up Xcode, select File\New\Project, choose the iOS\Application\SpriteKit Game template and click Next.Įnter UberJump for the Product Name, set the Language to Swift, and iPhone for Devices and then click Next.Ĭhoose somewhere to save the project and click Create.īefore getting down to business, you’ll do some preliminary setup. To begin, you need a brand new Sprite Kit Xcode project. The result will be a complex, hybrid physics manipulation, as you both apply forces to the player node and also directly change its velocity. The accelerometer will handle the player’s left and right movement (x-axis). Collecting stars along the way will propel the player further on their journey upward, taking care of the up and down (y-axis) portion of the player’s movement (miss too many stars and you fall down though!). ![]() Uber Jump will take the same model, initially thrusting your player character upward and continuously applying gravity to pull them down. ![]() ![]() Collecting coins boosts the player upward while platforms provide temporary respite along the way. The game hurls the player character up the screen and from that point the player must fight against gravity to get as high as they can. As everyone knows, “uber” is better than “mega,” so let’s call your game “Uber Jump.” ]Īt its heart, a game like Mega Jump is a physics game. Yours will obviously be a truly amazing game and so it needs a truly amazing title. You are going to create a game similar to Mega Jump. That means you’ll need a paid developer account and a device to test on to get the most out of this tutorial. Note: The game you’ll build will eventually use the accelerometer to control horizontal movement.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |