Skip to content

Commit

Permalink
restore zlib directory for older versions of Xcode
Browse files Browse the repository at this point in the history
  • Loading branch information
mfessenden committed Sep 22, 2017
1 parent 11da652 commit 4bf2fb3
Show file tree
Hide file tree
Showing 9 changed files with 36 additions and 26 deletions.
6 changes: 1 addition & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Change Log
- add `SKTilesetData.setTexture(_:forFrame:)`
- add `SKTilesetData.setDuration(interval:forFrame:)`
- add `SKTileObject.tileData` property
- add `SKTiledSceneCamera.clampZoomValue`
- add `SKTiledSceneCamera.clampZoomValue`
- add `SKTiledSceneCamera.zoomClamping` property
- remove `SKTile.pauseAnimation`

Expand All @@ -29,8 +29,6 @@ Change Log

- invert layer y-offsets properly
- add `DemoController` to manage scenes in iOS/macOS demo targets


- add `SKTilemap.getLayer(atPath:)`
- add `SKTilemapDelegate.didAddNavigationGraph(_:)`
- add `SKTilemap.newTileLayer(named:group:)`
Expand Down Expand Up @@ -73,8 +71,6 @@ Change Log
- update API for new layer & object types, more consistent naming, etc.
- improved grid drawing quality
- debug functions moved to `SKTiled+Debug.swift`


- add `SKObjectGroup.textObjects`
- add `SKTilemap.textObjects`
- add `SKTilemap.showGrid`
Expand Down
2 changes: 1 addition & 1 deletion Demo/Assets.xcassets/AppIcon.appiconset/Contents.json
Original file line number Diff line number Diff line change
Expand Up @@ -212,4 +212,4 @@
"properties" : {
"pre-rendered" : true
}
}
}
24 changes: 19 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
> SKTiled is a Swift framework for using [Tiled][tiled-url] assets with Apple's SpriteKit.
[![Swift Version][swift-image]][swift-url]
[![Xcode Version][xcode9-image]][xcode-downloads-url]
[![Build Status][travis-image]][travis-url]
[![License][license-image]][license-url]
[![Platforms][platforms-image]][platforms-url]
Expand All @@ -13,10 +14,11 @@
**SKTiled** is a framework for using [Tiled][tiled-url] assets with [Apple's SpriteKit][spritekit-url], built from the ground up with Swift. This project began life as an exercise to learn Apple's new programming language for a game project, but I've decided to release it as open source with the hopes that others will find it useful. **SKTiled** is up-to-date and supports **Tiled's** major features, including all map & object types.


Current release is Swift 3.2/macOS 10.11/iOS 10+. For Swift 4, see the [**swift4**][swift4-url] branch.
![Demo Image][demo-iphone-img]


![Demo Image][demo-image]
- for Xcode 8, see the [**xcode8**][branch-xcode8-url] branch
- for Swift 4, see the [**swift4**][branch-swift4-url] branch


Check out the [Official Documentation](https://mfessenden.github.io/SKTiled).
Expand Down Expand Up @@ -45,7 +47,7 @@ Check out the [Official Documentation](https://mfessenden.github.io/SKTiled).

- iOS 9+
- macOS 10.12+
- Xcode 9+
- Xcode 9/Swift 3.2

## Installation

Expand Down Expand Up @@ -266,6 +268,7 @@ let allWalkable = tilemap.getTilesWithProperty("walkable", true")
- [Clint Bellanger: Isometric Tiles Math](http://clintbellanger.net/articles/isometric_math)
[swift4-image]:https://img.shields.io/badge/Swift-4-brightgreen.svg
[swift-image]:https://img.shields.io/badge/Swift-3.2-brightgreen.svg
[swift-url]: https://swift.org/
[license-image]:https://img.shields.io/badge/License-MIT-blue.svg
Expand All @@ -277,10 +280,21 @@ let allWalkable = tilemap.getTilesWithProperty("walkable", true")
[carthage-image]:https://img.shields.io/badge/Carthage-compatible-4BC51D.svg
[carthage-url]:https://github.com/Carthage/Carthage
[pod-image]:https://img.shields.io/cocoapods/v/SKTiled.svg
[xcode8-image]:https://img.shields.io/badge/Xcode-8-orange.svg
[xcode9-image]:https://img.shields.io/badge/Xcode-9-orange.svg
[xcode-downloads-url]:https://developer.apple.com/download/more/
[pod-url]:https://cocoapods.org/pods/SKTiled
[swift4-url]:https://github.com/mfessenden/SKTiled/tree/swift4
[branch-master-url]:https://github.com/mfessenden/SKTiled
[branch-xcode8-url]:https://github.com/mfessenden/SKTiled/tree/xcode8
[branch-swift4-url]:https://github.com/mfessenden/SKTiled/tree/swift4
[header-image]:https://mfessenden.github.io/SKTiled/images/Header-@1x.png
[demo-image]:https://mfessenden.github.io/SKTiled/images/images/demo-macos-iso.png
[demo-mac-image]:https://mfessenden.github.io/SKTiled/images/demo-macos-iso.png
[demo-iphone-img]:https://mfessenden.github.io/SKTiled/images/demo-iphone.png
<!--- Documentation --->
Expand Down
2 changes: 1 addition & 1 deletion Resources/roguelike-16x16.tmx
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
<ellipse/>
</object>
</objectgroup>
<layer name="Graph" width="42" height="42" opacity="0.8">
<layer name="Graph" width="42" height="42" visible="0" opacity="0.8">
<data encoding="base64" compression="zlib">
eJztl1EKwzAMQ/u1+x+zu8XYR8EIyZbdZmXQgNm6JPaLbJfs/dq292OP/ZF9x90MHc7VvPtFjMeotM7Os4PFtVPObEw5kVdxdnLncFY+j7kdOJimqzjxk+1VbEzDbt5j/Gp0euPQTrGv4nR8IUfkQS58dmI4+XbPq3hZDSvfSp8up/NblZuM80wfqVqZ5Kjqoyq2wxmf8bszkFPFOMPJ9p3lrGqmm6cVnJk/Jwbmw/E34XR9O5xXMjLOlf2+krOKG+fUWrbGZcV4qt8dTvVcxewyxj7K1rh1EH1m94cpZ6ZTp1YnNe9oz/R0dY1rcP3kDsbiqvtUZZXu8exdNuaverdPcs841cg0ZHnBPWc5mX+Xk+nKcvhrTswr07bbj925DmfmD+9ILB8uJ5tXnOw/T+ccEy0zDa40VbtdTqXlxId7d2PzXdbJ/euIUe1FXd36VJyTPCAnY0C/VT1crafL2amDX3Gutofz4byL8wMKo/+y
</data>
Expand Down
12 changes: 2 additions & 10 deletions SKTiled.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1174,7 +1174,6 @@
PRODUCT_NAME = SKTiledDemo;
SDKROOT = macosx;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_VERSION = 3.1;
};
name = Debug;
};
Expand All @@ -1194,7 +1193,6 @@
PRODUCT_NAME = SKTiledDemo;
SDKROOT = macosx;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
SWIFT_VERSION = 3.1;
};
name = Release;
};
Expand Down Expand Up @@ -1224,7 +1222,6 @@
SDKROOT = macosx;
SKIP_INSTALL = YES;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_VERSION = 3.0;
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
};
Expand Down Expand Up @@ -1255,7 +1252,6 @@
PROVISIONING_PROFILE_SPECIFIER = "";
SDKROOT = macosx;
SKIP_INSTALL = YES;
SWIFT_VERSION = 3.0;
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
};
Expand Down Expand Up @@ -1285,7 +1281,6 @@
PROVISIONING_PROFILE_SPECIFIER = "";
SKIP_INSTALL = YES;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_VERSION = 3.0;
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
};
Expand Down Expand Up @@ -1314,7 +1309,6 @@
PRODUCT_NAME = SKTiled;
PROVISIONING_PROFILE_SPECIFIER = "";
SKIP_INSTALL = YES;
SWIFT_VERSION = 3.0;
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
};
Expand Down Expand Up @@ -1366,8 +1360,8 @@
ONLY_ACTIVE_ARCH = YES;
OTHER_LDFLAGS = "-lz";
SDKROOT = iphoneos;
SWIFT_INCLUDE_PATHS = zlib;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 3.2;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
Expand Down Expand Up @@ -1411,8 +1405,8 @@
MTL_ENABLE_DEBUG_INFO = NO;
OTHER_LDFLAGS = "-lz";
SDKROOT = iphoneos;
SWIFT_INCLUDE_PATHS = zlib;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
SWIFT_VERSION = 3.2;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
};
Expand All @@ -1431,7 +1425,6 @@
PRODUCT_BUNDLE_IDENTIFIER = com.supermeerkat.SKTiled;
PRODUCT_NAME = SKTiledDemo;
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_VERSION = 3.1;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
Expand All @@ -1449,7 +1442,6 @@
PRODUCT_BUNDLE_IDENTIFIER = com.supermeerkat.SKTiledDemo;
PRODUCT_NAME = SKTiledDemo;
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_VERSION = 3.1;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
Expand Down
8 changes: 5 additions & 3 deletions Sources/SKTileLayer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2351,11 +2351,13 @@ extension SKTiledLayerObject {
/**
Returns a tile coordinate for a given vector_int2 coordinate.

- parameter vec2: `int2` vector int2.
- parameter vec2: `int2` vector int2 coordinate.
- parameter offsetX: `CGFloat` x-offset value.
- parameter offsetY: `CGFloat` y-offset value.
- returns: `CGPoint` position in layer.
*/
public func pointForCoordinate(vec2: int2) -> CGPoint {
return self.pointForCoordinate(coord: vec2.cgPoint)
public func pointForCoordinate(vec2: int2, offsetX: CGFloat=0, offsetY: CGFloat=0) -> CGPoint {
return self.pointForCoordinate(coord: vec2.cgPoint, offsetX: offsetX, offsetY: offsetY)
}

/**
Expand Down
2 changes: 1 addition & 1 deletion Sources/SKTilemap.swift
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ public class SKTilemap: SKNode, SKTiledObject {
/**
Returns a tile coordinate for a given vector_int2 coordinate.

- parameter vec2: `int2` vector int2.
- parameter vec2: `int2` vector int2 coordinate.
- returns: `CGPoint` position in layer.
*/
public func pointForCoordinate(vec2: int2) -> CGPoint {
Expand Down
1 change: 1 addition & 0 deletions zlib/include.h
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#include <zlib.h>
5 changes: 5 additions & 0 deletions zlib/module.modulemap
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module zlib [system] {
header "include.h"
link "z"
export *
}

0 comments on commit 4bf2fb3

Please sign in to comment.