Skip to content

Commit 8faac2a

Browse files
committed
Refactored Stack playground file
1 parent d93f1e8 commit 8faac2a

File tree

1 file changed

+0
-21
lines changed

1 file changed

+0
-21
lines changed

Data Structures.playground/Pages/Stack.xcplaygroundpage/Contents.swift

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -134,27 +134,6 @@ debugPrint("pushed 10: ", stack)
134134
import SpriteKit
135135
import PlaygroundSupport
136136

137-
class StackElementNode: SKSpriteNode {
138-
139-
init() {
140-
let size = CGSize(width: 50, height: 150)
141-
142-
let randomHue = CGFloat(arc4random_uniform(255))
143-
let randomSaturation = CGFloat(arc4random_uniform(255))
144-
let randomBrightness = CGFloat(arc4random_uniform(255))
145-
let color = SKColor(hue: randomHue, saturation: randomSaturation, brightness: randomBrightness, alpha: 1.0)
146-
147-
super.init(texture: SKTexture(imageNamed: "book spine"), color: color, size: size)
148-
zRotation = 90 * CGFloat.pi / 180.0
149-
}
150-
151-
required init?(coder aDecoder: NSCoder) {
152-
fatalError(#function + " required initizlier for NSCode has not been implemented")
153-
}
154-
}
155-
156-
157-
158137
class StackScene: SKScene {
159138

160139
var stackElements: Stack<StackElementNode>! {

0 commit comments

Comments
 (0)