Merge branch 'feature/ds' into develop

This commit is contained in:
Riley Testut 2019-08-05 23:05:08 -07:00
commit 0d5a7ba19f
19 changed files with 111 additions and 25 deletions

3
.gitmodules vendored
View File

@ -22,3 +22,6 @@
[submodule "Cores/N64DeltaCore"]
path = Cores/N64DeltaCore
url = git@github.com:rileytestut/N64DeltaCore.git
[submodule "Cores/DSDeltaCore"]
path = Cores/DSDeltaCore
url = https://github.com/rileytestut/DSDeltaCore.git

1
Cores/DSDeltaCore Submodule

@ -0,0 +1 @@
Subproject commit 3c0306fcee19010175ae83a31b9b185dda7430fe

@ -1 +1 @@
Subproject commit 9d060fb341666abc55da96d216430af90df32927
Subproject commit 119fafb193b2a6561e8f87d7eb64c1a663fc9b5c

@ -1 +1 @@
Subproject commit 6c763da1513fbe762edbca2cf33cec556ce9536e
Subproject commit 14474b02ec607953cdc6dd3959856f7de1449bdb

@ -1 +1 @@
Subproject commit 4dcb34a47e71b81a099bff4dc0ebd28c217ef85b
Subproject commit 85ced43f5f220ee7f19b99e0949d9091c963d549

@ -1 +1 @@
Subproject commit 0246be2de6dc282397703ce2190ee7f3ed4cc9fc
Subproject commit a4bdecdd53ad20d3f343bd4f06df1ed3a6f8760d

@ -1 +1 @@
Subproject commit 4dc0f283116aadf6397c88c1f7fdabcac32367a6
Subproject commit b2b8636f085fba41defb7ea601067928400b0043

@ -1 +1 @@
Subproject commit dc0ec5b74c0e47e0e35912dfd63dd70f2a3d932e
Subproject commit f54e0440f1a9ed1fc005f5ea4729ebe26f36f945

View File

@ -145,6 +145,8 @@
BFDE2CD2222DF36A008038E0 /* SwiftyDropbox.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = BFDE2CC8222DF345008038E0 /* SwiftyDropbox.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
BFDE2CD3222DF36A008038E0 /* Alamofire.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BFDE2CC7222DF345008038E0 /* Alamofire.framework */; };
BFDE2CD4222DF36A008038E0 /* Alamofire.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = BFDE2CC7222DF345008038E0 /* Alamofire.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
BFDF71DD22F94CF70074D92E /* DSDeltaCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BFDF71DA22F94CDF0074D92E /* DSDeltaCore.framework */; };
BFDF71DE22F94CF70074D92E /* DSDeltaCore.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = BFDF71DA22F94CDF0074D92E /* DSDeltaCore.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
BFE022A01F5B57FF0052D888 /* PopoverMenuButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = BFE0229F1F5B577D0052D888 /* PopoverMenuButton.swift */; };
BFE4269E1D9C68E600DC913F /* SaveStatesStoryboardSegue.swift in Sources */ = {isa = PBXBuildFile; fileRef = BFE4269D1D9C68E600DC913F /* SaveStatesStoryboardSegue.swift */; };
BFE593CA21F3F8B7003412A6 /* GameSave.swift in Sources */ = {isa = PBXBuildFile; fileRef = BFE593C921F3F8B7003412A6 /* GameSave.swift */; };
@ -185,6 +187,7 @@
BF0418151D01E93400E85BCF /* GBADeltaCore.framework in Embed Frameworks */,
BFDE2CD4222DF36A008038E0 /* Alamofire.framework in Embed Frameworks */,
BFB359442278FD7E00CFD920 /* N64DeltaCore_Video.framework in Embed Frameworks */,
BFDF71DE22F94CF70074D92E /* DSDeltaCore.framework in Embed Frameworks */,
BF144C652238511400C387E1 /* Harmony_Dropbox.framework in Embed Frameworks */,
BF98C9832204D9AB006B95AC /* NESDeltaCore.framework in Embed Frameworks */,
BF99C6951D0A9AA600BA92BC /* SNESDeltaCore.framework in Embed Frameworks */,
@ -320,6 +323,7 @@
BFDE2CC6222DF345008038E0 /* Harmony_Dropbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Harmony_Dropbox.framework; sourceTree = BUILT_PRODUCTS_DIR; };
BFDE2CC7222DF345008038E0 /* Alamofire.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Alamofire.framework; sourceTree = BUILT_PRODUCTS_DIR; };
BFDE2CC8222DF345008038E0 /* SwiftyDropbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = SwiftyDropbox.framework; sourceTree = BUILT_PRODUCTS_DIR; };
BFDF71DA22F94CDF0074D92E /* DSDeltaCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = DSDeltaCore.framework; sourceTree = BUILT_PRODUCTS_DIR; };
BFE0229F1F5B577D0052D888 /* PopoverMenuButton.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PopoverMenuButton.swift; sourceTree = "<group>"; };
BFE4269D1D9C68E600DC913F /* SaveStatesStoryboardSegue.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SaveStatesStoryboardSegue.swift; sourceTree = "<group>"; };
BFE593C921F3F8B7003412A6 /* GameSave.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GameSave.swift; sourceTree = "<group>"; };
@ -352,6 +356,7 @@
BFEC732D1AAECC4A00650035 /* Roxas.framework in Frameworks */,
BFDE2CD3222DF36A008038E0 /* Alamofire.framework in Frameworks */,
BF48F75B219A1F8A00BC2FC1 /* Harmony_Drive.framework in Frameworks */,
BFDF71DD22F94CF70074D92E /* DSDeltaCore.framework in Frameworks */,
BFB359452278FD8100CFD920 /* N64DeltaCore_RSP.framework in Frameworks */,
BF99C6941D0A9AA600BA92BC /* SNESDeltaCore.framework in Frameworks */,
BF98C9822204D9AB006B95AC /* NESDeltaCore.framework in Frameworks */,
@ -653,6 +658,7 @@
BF9F4FCD1AAD7B25004C9500 /* Frameworks */ = {
isa = PBXGroup;
children = (
BFDF71DA22F94CDF0074D92E /* DSDeltaCore.framework */,
BFB359412278FD6700CFD920 /* N64DeltaCore_Video.framework */,
BFB359422278FD6800CFD920 /* N64DeltaCore_RSP.framework */,
BF79966C224C075A009B094F /* N64DeltaCore.framework */,
@ -1224,7 +1230,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
IPHONEOS_DEPLOYMENT_TARGET = 12.2;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
OTHER_CFLAGS = "-DGLES_SILENCE_DEPRECATION";
@ -1277,7 +1283,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
IPHONEOS_DEPLOYMENT_TARGET = 12.2;
MTL_ENABLE_DEBUG_INFO = NO;
OTHER_CFLAGS = "-DGLES_SILENCE_DEPRECATION";
OTHER_SWIFT_FLAGS = "-Xfrontend -debug-time-function-bodies";

View File

@ -22,6 +22,9 @@
<FileRef
location = "group:Cores/N64DeltaCore/N64DeltaCore.xcodeproj">
</FileRef>
<FileRef
location = "group:Cores/DSDeltaCore/DSDeltaCore.xcodeproj">
</FileRef>
<FileRef
location = "group:External/Harmony/Harmony.xcodeproj">
</FileRef>

View File

@ -33,12 +33,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate
self.configureAppearance()
// Disable system gestures that delay touches on left edge of screen
for gestureRecognizer in self.window?.gestureRecognizers ?? [] where NSStringFromClass(type(of: gestureRecognizer)).contains("GateGesture")
{
gestureRecognizer.delaysTouchesBegan = false
}
// Controllers
ExternalGameControllerManager.shared.startMonitoring()

View File

@ -4,6 +4,7 @@
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14490.49"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@ -18,7 +19,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="0.93725490199999995" green="0.93725490199999995" blue="0.95686274510000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<label key="tableFooterView" opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Delta 0.6.0" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="Str-BY-agW">
<rect key="frame" x="0.0" y="905" width="375" height="44"/>
<rect key="frame" x="0.0" y="949" width="375" height="44"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="0.5" alpha="1" colorSpace="calibratedWhite"/>
@ -212,12 +213,29 @@
</subviews>
</tableViewCellContentView>
</tableViewCell>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" reuseIdentifier="Cell" textLabel="Etp-g5-W9R" style="IBUITableViewCellStyleDefault" id="p69-Xz-VoS">
<rect key="frame" x="0.0" y="507.5" width="375" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="p69-Xz-VoS" id="pwB-9y-EUf">
<rect key="frame" x="0.0" y="0.0" width="341" height="43.5"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<label opaque="NO" multipleTouchEnabled="YES" contentMode="left" text="System Name" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="Etp-g5-W9R">
<rect key="frame" x="16" y="0.0" width="324" height="43.5"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
</subviews>
</tableViewCellContentView>
</tableViewCell>
</cells>
</tableViewSection>
<tableViewSection headerTitle="Controller Opacity" footerTitle="Determines how translucent the controller appears, if supported by the controller skin." id="SwK-m9-8gt">
<cells>
<tableViewCell contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="none" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" id="Xxk-vo-eu4">
<rect key="frame" x="0.0" y="571" width="375" height="44"/>
<rect key="frame" x="0.0" y="615" width="375" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" preservesSuperviewLayoutMargins="YES" tableViewCell="Xxk-vo-eu4" id="vxt-Ex-b4b">
<rect key="frame" x="0.0" y="0.0" width="375" height="43.5"/>
@ -258,14 +276,14 @@
<tableViewSection headerTitle="Delta Sync" id="y6U-7a-bnX" userLabel="Syncing">
<cells>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" reuseIdentifier="DetailCell" textLabel="4U1-fe-PIb" detailTextLabel="kLY-5g-v8n" style="IBUITableViewCellStyleValue1" id="bwW-PG-BcV">
<rect key="frame" x="0.0" y="699" width="375" height="44"/>
<rect key="frame" x="0.0" y="743" width="375" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="bwW-PG-BcV" id="RNA-99-evH">
<rect key="frame" x="0.0" y="0.0" width="349" height="43.5"/>
<rect key="frame" x="0.0" y="0.0" width="341" height="43.5"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<label opaque="NO" multipleTouchEnabled="YES" contentMode="left" text="Service" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="4U1-fe-PIb">
<rect key="frame" x="15" y="12" width="54" height="19.5"/>
<rect key="frame" x="16" y="12" width="54" height="19.5"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="16"/>
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
@ -285,14 +303,14 @@
</connections>
</tableViewCell>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" reuseIdentifier="BadgeCell" textLabel="1u0-gh-zP7" style="IBUITableViewCellStyleDefault" id="JPg-6O-DRe" customClass="BadgedTableViewCell" customModule="Delta" customModuleProvider="target">
<rect key="frame" x="0.0" y="743" width="375" height="44"/>
<rect key="frame" x="0.0" y="787" width="375" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="JPg-6O-DRe" id="zcZ-QR-Nno">
<rect key="frame" x="0.0" y="0.0" width="349" height="43.5"/>
<rect key="frame" x="0.0" y="0.0" width="341" height="43.5"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<label opaque="NO" multipleTouchEnabled="YES" contentMode="left" text="Sync Status" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="1u0-gh-zP7">
<rect key="frame" x="15" y="0.0" width="325" height="43.5"/>
<rect key="frame" x="16" y="0.0" width="324" height="43.5"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
@ -309,14 +327,14 @@
<tableViewSection headerTitle="3D Touch" id="fdp-8c-oOc">
<cells>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" indentationWidth="10" reuseIdentifier="Cell" textLabel="c5i-qG-ir9" style="IBUITableViewCellStyleDefault" id="SSL-t4-QZj">
<rect key="frame" x="0.0" y="843" width="375" height="44"/>
<rect key="frame" x="0.0" y="887" width="375" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="SSL-t4-QZj" id="hQB-Iy-bzy">
<rect key="frame" x="0.0" y="0.0" width="349" height="43.5"/>
<rect key="frame" x="0.0" y="0.0" width="341" height="43.5"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<label opaque="NO" multipleTouchEnabled="YES" contentMode="left" text="App Icon Shortcuts" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="c5i-qG-ir9">
<rect key="frame" x="15" y="0.0" width="325" height="43.5"/>
<rect key="frame" x="16" y="0.0" width="324" height="43.5"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>

View File

@ -131,6 +131,10 @@ class GameViewController: DeltaCore.GameViewController
return !self.isGyroActive
}
override var preferredScreenEdgesDeferringSystemGestures: UIRectEdge {
return .all
}
required init()
{
super.init()
@ -342,6 +346,13 @@ extension GameViewController
self.pausingGameController = gameController
}
if self.game?.type == .ds
{
// Cheats and Fast Forwarding are not yet supported for DS games.
pauseViewController.cheatCodesItem = nil
pauseViewController.fastForwardItem = nil
}
self.pauseViewController = pauseViewController
default: break

View File

@ -20,6 +20,7 @@ extension DeltaCoreProtocol
case .gbc: return 1...4
case .gba: return 1...3
case .n64: return 1...3
case .ds: return 1...1
}
}
}

View File

@ -34,6 +34,10 @@ class LaunchViewController: RSTLaunchViewController
return self.gameViewController
}
override var childForScreenEdgesDeferringSystemGestures: UIViewController? {
return self.gameViewController
}
override var shouldAutorotate: Bool {
return self.gameViewController?.shouldAutorotate ?? true
}

View File

@ -429,6 +429,7 @@ private extension ControllerInputsViewController
switch item.inputs
{
case .standard: itemFrame = item.frame
case .touch: itemFrame = item.frame
case let .directional(up, down, left, right):
let frame = (item.kind == .thumbstick) ? item.extendedFrame : item.frame

View File

@ -206,6 +206,7 @@ private extension Settings
case .gbc: systemName = "gbc"
case .gba: systemName = "gba"
case .n64: systemName = "n64"
case .ds: systemName = "ds"
}
let orientation: String

View File

@ -102,6 +102,20 @@
<string>com.rileytestut.delta.game.n64</string>
</array>
</dict>
<dict>
<key>CFBundleTypeIconFiles</key>
<array/>
<key>CFBundleTypeName</key>
<string>DS Game</string>
<key>CFBundleTypeRole</key>
<string>Viewer</string>
<key>LSHandlerRank</key>
<string>Owner</string>
<key>LSItemContentTypes</key>
<array>
<string>com.rileytestut.delta.game.ds</string>
</array>
</dict>
</array>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
@ -318,6 +332,26 @@
</array>
</dict>
</dict>
<dict>
<key>UTTypeConformsTo</key>
<array>
<string>com.rileytestut.delta.game</string>
</array>
<key>UTTypeDescription</key>
<string>DS Game</string>
<key>UTTypeIconFiles</key>
<array/>
<key>UTTypeIdentifier</key>
<string>com.rileytestut.delta.game.ds</string>
<key>UTTypeTagSpecification</key>
<dict>
<key>public.filename-extension</key>
<array>
<string>nds</string>
<string>ds</string>
</array>
</dict>
</dict>
</array>
</dict>
</plist>

View File

@ -13,6 +13,7 @@ import GBADeltaCore
import GBCDeltaCore
import NESDeltaCore
import N64DeltaCore
import DSDeltaCore
enum System: CaseIterable
{
@ -21,6 +22,7 @@ enum System: CaseIterable
case n64
case gbc
case gba
case ds
}
extension System
@ -33,6 +35,7 @@ extension System
case .n64: return NSLocalizedString("Nintendo 64", comment: "")
case .gbc: return NSLocalizedString("Game Boy Color", comment: "")
case .gba: return NSLocalizedString("Game Boy Advance", comment: "")
case .ds: return NSLocalizedString("Nintendo DS", comment: "")
}
}
@ -44,6 +47,7 @@ extension System
case .n64: return NSLocalizedString("N64", comment: "")
case .gbc: return NSLocalizedString("GBC", comment: "")
case .gba: return NSLocalizedString("GBA", comment: "")
case .ds: return NSLocalizedString("DS", comment: "")
}
}
@ -55,6 +59,7 @@ extension System
case .n64: return 1996
case .gbc: return 1998
case .gba: return 2001
case .ds: return 2004
}
}
}
@ -69,6 +74,7 @@ extension System
case .n64: return N64.core
case .gbc: return GBC.core
case .gba: return GBA.core
case .ds: return DS.core
}
}
@ -80,6 +86,7 @@ extension System
case .n64: return .n64
case .gbc: return .gbc
case .gba: return .gba
case .ds: return .ds
}
}
@ -92,6 +99,7 @@ extension System
case GameType.n64: self = .n64
case GameType.gbc: self = .gbc
case GameType.gba: self = .gba
case GameType.ds: self = .ds
default: return nil
}
}
@ -108,6 +116,7 @@ extension GameType
case "n64", "z64": self = .n64
case "gbc", "gb": self = .gbc
case "gba": self = .gba
case "ds", "nds": self = .ds
default: return nil
}
}