Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
8 changes: 8 additions & 0 deletions UIAnimation.xcodeproj/project.pbxproj
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
778CE9D7229BF77300F5483E /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 778CE9D5229BF77300F5483E /* Main.storyboard */; };
778CE9D9229BF77600F5483E /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 778CE9D8229BF77600F5483E /* Assets.xcassets */; };
778CE9DC229BF77600F5483E /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 778CE9DA229BF77600F5483E /* LaunchScreen.storyboard */; };
87C3DA92229C763600C4407B /* ViewControllerBronze.swift in Sources */ = {isa = PBXBuildFile; fileRef = 87C3DA91229C763600C4407B /* ViewControllerBronze.swift */; };
87C3DA96229DD9E800C4407B /* ViewControllerPrata.swift in Sources */ = {isa = PBXBuildFile; fileRef = 87C3DA95229DD9E800C4407B /* ViewControllerPrata.swift */; };
/* End PBXBuildFile section */

/* Begin PBXFileReference section */
Expand All @@ -22,6 +24,8 @@
778CE9D8229BF77600F5483E /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
778CE9DB229BF77600F5483E /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
778CE9DD229BF77600F5483E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
87C3DA91229C763600C4407B /* ViewControllerBronze.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewControllerBronze.swift; sourceTree = "<group>"; };
87C3DA95229DD9E800C4407B /* ViewControllerPrata.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewControllerPrata.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand Down Expand Up @@ -56,7 +60,9 @@
children = (
778CE9D1229BF77300F5483E /* AppDelegate.swift */,
778CE9D3229BF77300F5483E /* ViewController.swift */,
87C3DA91229C763600C4407B /* ViewControllerBronze.swift */,
778CE9D5229BF77300F5483E /* Main.storyboard */,
87C3DA95229DD9E800C4407B /* ViewControllerPrata.swift */,
778CE9D8229BF77600F5483E /* Assets.xcassets */,
778CE9DA229BF77600F5483E /* LaunchScreen.storyboard */,
778CE9DD229BF77600F5483E /* Info.plist */,
Expand Down Expand Up @@ -136,7 +142,9 @@
buildActionMask = 2147483647;
files = (
778CE9D4229BF77300F5483E /* ViewController.swift in Sources */,
87C3DA92229C763600C4407B /* ViewControllerBronze.swift in Sources */,
778CE9D2229BF77300F5483E /* AppDelegate.swift in Sources */,
87C3DA96229DD9E800C4407B /* ViewControllerPrata.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down
Empty file.
Empty file.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<Bucket
type = "1"
version = "2.0">
<Breakpoints>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "UIAnimation/ViewController.swift"
timestampString = "580770119.370442"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "41"
endingLineNumber = "41"
landmarkName = "viewDidAppear(_:)"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>UIAnimation.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
</dict>
</plist>
Empty file.
2 changes: 1 addition & 1 deletion UIAnimation/AppDelegate.swift
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import UIKit

@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
class AppDelegate: UIResponder, UIApplicationDelegate{

var window: UIWindow?

Expand Down
Empty file modified UIAnimation/Assets.xcassets/AppIcon.appiconset/Contents.json
100644 → 100755
Empty file.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/AppIcon.appiconset/icon-iPad20.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/AppIcon.appiconset/icon-iPad29.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/AppIcon.appiconset/icon-iPad40.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/AppIcon.appiconset/icon-iPad76.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/icon1.imageset/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/icon1.imageset/icon1.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/icon1.imageset/icon1@2x.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/icon1.imageset/icon1@3x.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/icon2.imageset/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/icon2.imageset/icon2@1x.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/icon2.imageset/icon2@2x.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/icon2.imageset/icon2@3x.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/icon3.imageset/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/icon3.imageset/icon3.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file modified UIAnimation/Assets.xcassets/icon3.imageset/icon3@2x.png
100644 → 100755
Empty file modified UIAnimation/Assets.xcassets/icon3.imageset/icon3@3x.png
100644 → 100755
Empty file modified UIAnimation/Assets.xcassets/icon4.imageset/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/icon4.imageset/icon4@1x.png
100644 → 100755
Empty file modified UIAnimation/Assets.xcassets/icon4.imageset/icon4@2x.png
100644 → 100755
Empty file modified UIAnimation/Assets.xcassets/icon4.imageset/icon4@3x.png
100644 → 100755
Empty file modified UIAnimation/Assets.xcassets/rocket.imageset/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/rocket.imageset/rocket.png
100644 → 100755
Empty file modified UIAnimation/Assets.xcassets/rocket2.imageset/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/rocket2.imageset/rocket2.png
100644 → 100755
Empty file modified UIAnimation/Assets.xcassets/world1.imageset/Contents.json
100644 → 100755
Empty file.
Empty file modified UIAnimation/Assets.xcassets/world1.imageset/world1.png
100644 → 100755
Empty file modified UIAnimation/Base.lproj/LaunchScreen.storyboard
100644 → 100755
Empty file.
79 changes: 73 additions & 6 deletions UIAnimation/Base.lproj/Main.storyboard
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -13,34 +13,97 @@
<!--Bronze-->
<scene sceneID="lHF-dN-ARc">
<objects>
<viewController id="LaB-eW-x7h" sceneMemberID="viewController">
<viewController id="LaB-eW-x7h" customClass="ViewControllerBronze" customModule="UIAnimation" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="8N2-mN-kSu">
<rect key="frame" x="0.0" y="0.0" width="414" height="813"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="world1" translatesAutoresizingMaskIntoConstraints="NO" id="v1Z-r5-7Sw">
<rect key="frame" x="0.0" y="217" width="414" height="414"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="rocket" translatesAutoresizingMaskIntoConstraints="NO" id="BWt-VZ-oo4">
<rect key="frame" x="159" y="360" width="96" height="128"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
</imageView>
<segmentedControl opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="top" segmentControlStyle="plain" selectedSegmentIndex="0" translatesAutoresizingMaskIntoConstraints="NO" id="DnY-yw-kqs">
<rect key="frame" x="139" y="75" width="137" height="29"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<segments>
<segment title="Cinza"/>
<segment title="Preto"/>
</segments>
<connections>
<action selector="funcaoDoBotao:" destination="LaB-eW-x7h" eventType="valueChanged" id="dnw-IL-Jg1"/>
</connections>
</segmentedControl>
</subviews>
<color key="backgroundColor" red="0.2627450980392157" green="0.2627450980392157" blue="0.2627450980392157" alpha="1" colorSpace="calibratedRGB"/>
<viewLayoutGuide key="safeArea" id="2nI-w7-VyP"/>
</view>
<tabBarItem key="tabBarItem" title="Bronze" image="icon4" id="VvG-JI-ieX"/>
<connections>
<outlet property="fundo" destination="8N2-mN-kSu" id="9jI-D9-CT9"/>
<outlet property="rocket" destination="BWt-VZ-oo4" id="a04-eO-h79"/>
<outlet property="segmentedControl" destination="DnY-yw-kqs" id="SV8-Yu-obT"/>
<outlet property="world" destination="v1Z-r5-7Sw" id="AN1-Sq-MUN"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="6ga-1z-lVg" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="-1372" y="1280"/>
<point key="canvasLocation" x="-1459.4202898550725" y="1263.6160714285713"/>
</scene>
<!--Prata-->
<scene sceneID="bJA-Hh-BCp">
<objects>
<viewController id="4ND-yu-RVr" sceneMemberID="viewController">
<viewController id="4ND-yu-RVr" customClass="ViewControllerPrata" customModule="UIAnimation" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="BK3-NW-hqi">
<rect key="frame" x="0.0" y="0.0" width="414" height="813"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="world1" translatesAutoresizingMaskIntoConstraints="NO" id="Ohe-Cu-rrF">
<rect key="frame" x="0.0" y="199" width="414" height="414"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="rocket" translatesAutoresizingMaskIntoConstraints="NO" id="aDq-qB-BNT">
<rect key="frame" x="159" y="685" width="96" height="128"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
</imageView>
<textField opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" text="nome" borderStyle="roundedRect" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="jTc-oz-TZj">
<rect key="frame" x="105" y="304" width="205" height="30"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<nil key="textColor"/>
<fontDescription key="fontDescription" type="system" pointSize="15"/>
<textInputTraits key="textInputTraits"/>
</textField>
<textField opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" text="senha" borderStyle="roundedRect" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="81Z-l0-vtQ">
<rect key="frame" x="105" y="363" width="205" height="30"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<nil key="textColor"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits"/>
</textField>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="NOMEDOJOGO" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0CP-6o-g69">
<rect key="frame" x="119" y="169" width="176" height="30"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="25"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="gWt-2z-ZOB">
<rect key="frame" x="87" y="401" width="240" height="128"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<state key="normal" title="LOGIN"/>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<viewLayoutGuide key="safeArea" id="6Ip-rs-mOl"/>
</view>
<tabBarItem key="tabBarItem" title="Prata" image="icon3" id="Cqx-qd-e1W"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="NFR-NQ-Iyx" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="-507" y="1280"/>
<point key="canvasLocation" x="-507.24637681159425" y="1279.6875"/>
</scene>
<!--Ouro-->
<scene sceneID="VPQ-z8-7lg">
Expand All @@ -61,7 +124,7 @@
<!--Base-->
<scene sceneID="F1L-Fx-mba">
<objects>
<viewController id="ann-cb-b2r" sceneMemberID="viewController">
<viewController id="ann-cb-b2r" customClass="ViewController" customModule="UIAnimation" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="JqL-BI-YnF">
<rect key="frame" x="0.0" y="0.0" width="414" height="813"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
Expand All @@ -79,6 +142,10 @@
<viewLayoutGuide key="safeArea" id="QYu-IY-owY"/>
</view>
<tabBarItem key="tabBarItem" title="Base" image="icon1" selectedImage="icon1" id="lap-bA-RHR"/>
<connections>
<outlet property="rocket" destination="C1x-nH-jru" id="8kx-0h-lUn"/>
<outlet property="world" destination="rez-lf-ilS" id="hen-cK-cxf"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="MIb-nC-bBM" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
Expand Down
Empty file modified UIAnimation/Info.plist
100644 → 100755
Empty file.
60 changes: 59 additions & 1 deletion UIAnimation/ViewController.swift
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,69 @@ import UIKit

class ViewController: UIViewController {

//puxei primeiro as duas imagens que eram o rocket e o world.
@IBOutlet weak var rocket: UIImageView!
@IBOutlet weak var world: UIImageView!

override func viewDidLoad() {
super.viewDidLoad()

}


//chamada para aparecer as coisas depois que carregar a tela.
override func viewDidAppear(_ animated: Bool) {


////aqui voce escreve o que é a sua animação.
//// em options existe o repetir, autoreverse que é pra ele continuar fazer a animacao, o ease ajuda a dar suavidade, deixar mais natural a animação.
//
// UIView.animate(withDuration: 2.0, delay: 2, options: [], animations: {
// self.rocket.center.y = self.view.frame.height - self.world.frame.height/2
//
////transform serve para voce rotacionar a imagem (faz vezez pi que da 180 graus e assim ele da meia volta).
// self.rocket.transform = self.rocket.transform.rotated(by: .pi/2)
//
////para que voce aumente sua imagem voce v=coloca essa linha de codigo.
// self.rocket.transform = self.rocket.transform.scaledBy(x: 2, y: 2)
//
////quando acabar o tempo da animacao voce entra nesse bloco de dados.
// }, completion: { finished in
//// self.rocket.image = UIImage(named: "rocket2.png" )
// self.outraAnimacao ()
//
// })
//para que o foguete fique orbitando em volta do mundo
let circlePath = UIBezierPath(arcCenter: self.world.center,radius: self.world.frame.height, startAngle: 0,
endAngle: .pi*2,
clockwise: true)
let animation = CAKeyframeAnimation(keyPath: #keyPath(CALayer.position))
animation.duration = 2
animation.repeatCount = MAXFLOAT
animation.path = circlePath.cgPath
rocket.layer.add(animation, forKey: nil)
self.rocket.transform = self.rocket.transform.rotated(by: .pi/2)

func outraAnimacao() {
UIView.animate(withDuration: 1.5, animations: {
self.rocket.center.x = self.view.frame.width*2

})
}
}

override func viewWillAppear(_ animated: Bool) {
//chamada para arrumar o conteúdo antes de aparecer na tela (o mundo estar la em baixo e o foguete tambem), ou seja irá ficar posicionado antes de aparecer na tela.

//tamanho e posição do mundo.
self.world.frame.size.width = self.view.frame.width
self.world.center.y = self.view.frame.height

//tamanho e posição do foguete.
self.rocket.frame.size.height = self.view.frame.height * 0.15
self.rocket.center.x = self.view.center.x
self.rocket.center.y = self.rocket.frame.height/2

}

}

Loading