Added tvOS port
BIN
IB Images/DOOM_sigil_decal.png
Normal file
After Width: | Height: | Size: 428 KiB |
BIN
IB Images/MapOverlay.png
Normal file
After Width: | Height: | Size: 32 KiB |
BIN
IB Images/ResumeButton.png
Normal file
After Width: | Height: | Size: 7.9 KiB |
BIN
IB Images/Thumbs.db
Normal file
11
README.md
|
@ -1,6 +1,6 @@
|
|||
# DOOM for iOS 11
|
||||
# DOOM for iOS 11 and tvOS for Apple TV
|
||||
|
||||
This is my update for DOOM for iOS to run on iOS 11. It also runs in modern resolutions including the full width of the iPhone X.
|
||||
This is my update for DOOM for iOS to run on iOS 11, running in modern resolutions including the full width of the iPhone X. I have also made a target and version for tvOS to run on Apple TV
|
||||
|
||||
Improvements/Changes
|
||||
|
||||
|
@ -9,6 +9,7 @@ Improvements/Changes
|
|||
- C warnings fixed for Xcode 9.3
|
||||
- Basic MFi controller support
|
||||
- Structure and View Controller usage grafted in from the DOOM-iOS2 repository and public user forks, unused code and embedded xcodeproj use eliminated
|
||||
- Second project target for tvOS that takes advantage of focus model and removes on-screen controls.
|
||||
|
||||
This commit adds placeholder files for the "IB Images" folder and the `idGinzaNar-Md2.otf` font file. You will still need to provide your own copies of `doom.wad` and `base.iPack`.
|
||||
|
||||
|
@ -18,4 +19,10 @@ The file `base.iPack` is not included in any DOOM installation and is specific t
|
|||
|
||||
This repo contains changes from id's [DOOM-iOS2](https://github.com/id-Software/DOOM-IOS2) repo (different than the parent of this repo), changes from the [FinalJudgement](https://github.com/JadingTsunami/FinalJudgment-iOS) repo by [JadingTsunami](https://github.com/JadingTsunami/), and [MFi controller code](https://github.com/TheRohans/DOOM-IOS2/commit/5a6b69d5e9821134f4013b069faef29190dcd7a1) from [TheRohans](https://github.com/TheRohans/).
|
||||
|
||||
For a rundown of the effort to get it running on tvOS, I wrote a [second lenghty article](http://schnapple.com/wolfenstein-3d-and-doom-on-tvos-for-apple-tv/) on the subject. In addition to the work incorporated above, I incorporated the efforts of [yarsrevenge](https://github.com/yarsrvenge/DOOM-IOS2) in getting the basics of the tvOS version going.
|
||||
|
||||
[Video of DOOM running on an iPhone X](https://www.youtube.com/watch?v=IrY5L1kn-NA)
|
||||
|
||||
[Video of DOOM running on an Apple TV](https://www.youtube.com/watch?v=P8QmMSabaqQ)
|
||||
|
||||
Have fun. For any questions I can be reached at tomkidd@gmail.com
|
2
base.parm
Executable file
|
@ -0,0 +1,2 @@
|
|||
iphone/livetile_1.tga PVR2
|
||||
iphone/arialImageLAL.tga LA
|
BIN
code/.DS_Store
vendored
|
@ -37,6 +37,7 @@
|
|||
#define IS_IPHONE (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone)
|
||||
#define IS_IPHONE_X (IS_IPHONE && SCREEN_MAX_LENGTH == 812.0)
|
||||
#define IPHONE_X_BOTTOM_INSET 64
|
||||
#define IS_TV (TARGET_OS_TV)
|
||||
|
||||
#define PWAD_LIST_SEPARATOR ':'
|
||||
|
||||
|
|
|
@ -51,12 +51,12 @@ void EASGlueInit(void) {
|
|||
assert( EASLibraryCheck(pLibConfig) );
|
||||
|
||||
if (polyphony > pLibConfig->maxVoices)
|
||||
polyphony = pLibConfig->maxVoices;
|
||||
|
||||
polyphony = (int)pLibConfig->maxVoices;
|
||||
|
||||
EAS_I32 mixSize = pLibConfig->mixBufferSize;
|
||||
|
||||
bufferSize = mixSize * pLibConfig->numChannels * (EAS_I32)sizeof(EAS_PCM) * NUM_BUFFERS;
|
||||
|
||||
bufferSize = (int)(mixSize * pLibConfig->numChannels * (EAS_I32)sizeof(EAS_PCM) * NUM_BUFFERS);
|
||||
|
||||
/* calculate buffer size */
|
||||
//bufferSize = pLibConfig->mixBufferSize * pLibConfig->numChannels * (EAS_I32)sizeof(EAS_PCM) * NUM_BUFFERS;
|
||||
|
||||
|
|
|
@ -117,7 +117,7 @@ EAS_I32 EAS_Calculate2toX (EAS_I32 nCents)
|
|||
*/
|
||||
EAS_U16 EAS_LogToLinear16 (EAS_I32 nGain)
|
||||
{
|
||||
EAS_INT nExp;
|
||||
EAS_LONG nExp;
|
||||
EAS_U16 nTemp;
|
||||
|
||||
/* bias to positive */
|
||||
|
|
|
@ -60,7 +60,7 @@
|
|||
*/
|
||||
void EAS_CalcPanControl (EAS_INT pan, EAS_I16 *pGainLeft, EAS_I16 *pGainRight)
|
||||
{
|
||||
EAS_INT temp;
|
||||
EAS_LONG temp;
|
||||
EAS_INT netAngle;
|
||||
|
||||
/* impose hard limit */
|
||||
|
|
|
@ -19,7 +19,9 @@
|
|||
*/
|
||||
#import "LabelButton.h"
|
||||
#import "Label.h"
|
||||
#if !TARGET_OS_TV
|
||||
#import "Slider.h"
|
||||
#endif
|
||||
#import "Switch.h"
|
||||
#import "Carousel.h"
|
||||
#import "Localization.h"
|
||||
|
@ -28,6 +30,12 @@
|
|||
@synthesize label;
|
||||
@synthesize label2;
|
||||
|
||||
#if TARGET_OS_TV
|
||||
- (BOOL)canBecomeFocused {
|
||||
return YES;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
========================
|
||||
idLabelButton::awakeFromNib
|
||||
|
@ -37,7 +45,9 @@
|
|||
|
||||
// Do not optimize my class out
|
||||
[idLabel class ];
|
||||
#if !TARGET_OS_TV
|
||||
[idSlider class];
|
||||
#endif
|
||||
[idSwitch class];
|
||||
[idCarousel class];
|
||||
|
||||
|
|
|
@ -17,17 +17,19 @@
|
|||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
|
||||
*/
|
||||
#if !TARGET_OS_TV
|
||||
#import <Foundation/Foundation.h>
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
|
||||
@interface idSlider : UISlider {
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
- (void) CustomizeSlider:( UIImage* )minimumImage
|
||||
:( UIImage* )maximumImage
|
||||
:( UIImage* )thumbImage;
|
||||
:( UIImage* )maximumImage
|
||||
:( UIImage* )thumbImage;
|
||||
|
||||
@end
|
||||
#endif
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
*/
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
#import "Slider.h"
|
||||
|
||||
|
||||
|
@ -45,6 +46,7 @@
|
|||
[ self setThumbImage:thumbImage forState:UIControlStateHighlighted ];
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -25,6 +25,13 @@
|
|||
|
||||
@synthesize on;
|
||||
|
||||
#if TARGET_OS_TV
|
||||
- (BOOL)canBecomeFocused {
|
||||
return YES;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
========================
|
||||
setOn
|
||||
|
@ -51,9 +58,11 @@
|
|||
*/
|
||||
- (void)touchesBegan:(NSSet*)touches withEvent:(UIEvent*)event
|
||||
{
|
||||
[super touchesBegan:touches withEvent:event];
|
||||
NSLog(@"DOOM: touchesEnded");
|
||||
[super touchesBegan:touches withEvent:event];
|
||||
#if !TARGET_OS_TV
|
||||
[self setOn: !on ];
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
@ -64,8 +73,9 @@
|
|||
*/
|
||||
- (void)touchesEnded:(NSSet*)touches withEvent:(UIEvent*)event
|
||||
{
|
||||
[super touchesEnded:touches withEvent:event];
|
||||
|
||||
NSLog(@"DOOM: touchesEnded");
|
||||
[super touchesEnded:touches withEvent:event];
|
||||
#if !TARGET_OS_TV
|
||||
if (on)
|
||||
{
|
||||
[ self setHighlighted: YES ];
|
||||
|
@ -74,6 +84,31 @@
|
|||
{
|
||||
[ self setHighlighted: NO ];
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
- (void)pressesBegan:(NSSet<UIPress *> *)presses withEvent:(UIPressesEvent *)event {
|
||||
NSLog(@"DOOM: pressesBegan");
|
||||
[super pressesBegan:presses withEvent:event];
|
||||
#if TARGET_OS_TV
|
||||
// [self setOn: !on ];
|
||||
// if (on)
|
||||
// {
|
||||
// [ self setHighlighted: YES ];
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// [ self setHighlighted: NO ];
|
||||
// }
|
||||
#endif
|
||||
}
|
||||
|
||||
- (void)pressesEnded:(NSSet<UIPress *> *)presses withEvent:(UIPressesEvent *)event {
|
||||
NSLog(@"DOOM: pressesEnded");
|
||||
}
|
||||
|
||||
//- (void)drawRect:(CGRect)rect {
|
||||
//
|
||||
//}
|
||||
|
||||
@end
|
||||
|
|
|
@ -131,7 +131,9 @@ idView * gMainView; // global openGL View.
|
|||
*/
|
||||
- (void) Initialize {
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
self.multipleTouchEnabled = YES;
|
||||
#endif
|
||||
gMainView = self;
|
||||
|
||||
// Double the resolution on iPhone 4.
|
||||
|
|
BIN
code/iphone/.DS_Store
vendored
264
code/iphone/ControlsMenuView-tvos.xib
Executable file
|
@ -0,0 +1,264 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="12120" systemVersion="16F73" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_ControlsMenuViewController">
|
||||
<connections>
|
||||
<outlet property="dirWheelButton" destination="33" id="54"/>
|
||||
<outlet property="dualThumbButton" destination="35" id="55"/>
|
||||
<outlet property="movestickSize" destination="30" id="57"/>
|
||||
<outlet property="singleThumbButton" destination="46" id="58"/>
|
||||
<outlet property="tiltMoveSpeed" destination="41" id="59"/>
|
||||
<outlet property="tiltTurnSpeed" destination="38" id="60"/>
|
||||
<outlet property="turnstickSize" destination="37" id="61"/>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="MenuBackground.png" id="39" userLabel="Background">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="backgroundColor" red="1" green="1" blue="1" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="Divide.png" id="42">
|
||||
<rect key="frame" x="36" y="114" width="407" height="7"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="31" customClass="idLabelButton">
|
||||
<rect key="frame" x="425" y="264" width="50" height="50"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<size key="titleShadowOffset" width="1" height="2"/>
|
||||
<state key="normal" backgroundImage="AdvancedButton.png">
|
||||
<color key="titleColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.01420286763459444" green="0.0" blue="2.4540675440221094e-05" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="HudLayoutPressed" destination="-1" eventType="touchUpInside" id="65"/>
|
||||
<outlet property="label" destination="47" id="50"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="33" customClass="idLabelButton">
|
||||
<rect key="frame" x="329" y="7" width="123" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<size key="titleShadowOffset" width="1" height="2"/>
|
||||
<state key="normal" image="LayoutWheelButton.png">
|
||||
<color key="titleColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.01420286763459444" green="0.0" blue="2.4540675440221094e-05" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="DirWheelPressed" destination="-1" eventType="touchUpInside" id="63"/>
|
||||
<outlet property="label" destination="34" id="51"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="35" customClass="idLabelButton">
|
||||
<rect key="frame" x="178" y="7" width="123" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<size key="titleShadowOffset" width="1" height="2"/>
|
||||
<state key="normal" image="LayoutDualButton.png">
|
||||
<color key="titleColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.01420286763459444" green="0.0" blue="2.4540675440221094e-05" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="DualThumbpadPressed" destination="-1" eventType="touchUpInside" id="64"/>
|
||||
<outlet property="label" destination="36" id="52"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="43" customClass="idLabelButton">
|
||||
<rect key="frame" x="0.0" y="264" width="50" height="50"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" backgroundImage="BackButton.png">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="BackToMain" destination="-1" eventType="touchUpInside" id="62"/>
|
||||
<outlet property="label" destination="29" id="49"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="46" customClass="idLabelButton">
|
||||
<rect key="frame" x="28" y="7" width="123" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<size key="titleShadowOffset" width="1" height="2"/>
|
||||
<state key="normal" image="LayoutSingleButton.png">
|
||||
<color key="titleColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.01420286763459444" green="0.0" blue="2.4540675440221094e-05" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="SingleThumbpadPressed" destination="-1" eventType="touchUpInside" id="68"/>
|
||||
<outlet property="label" destination="32" id="53"/>
|
||||
</connections>
|
||||
</button>
|
||||
<slider opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="1.5" minValue="0.20000000000000001" maxValue="1.5" id="37" customClass="idSlider">
|
||||
<rect key="frame" x="34" y="156" width="411" height="29"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="minimumTrackTintColor" red="1" green="0.49936569364776573" blue="0.023189855779927049" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<connections>
|
||||
<action selector="TurnStickValChanged" destination="-1" eventType="valueChanged" id="71"/>
|
||||
</connections>
|
||||
</slider>
|
||||
<slider opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" minValue="1500" maxValue="3500" id="38" customClass="idSlider">
|
||||
<rect key="frame" x="34" y="224" width="411" height="29"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="minimumTrackTintColor" red="1" green="0.49936569364776573" blue="0.023189855779927049" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<connections>
|
||||
<action selector="TiltTurnValChanged" destination="-1" eventType="valueChanged" id="70"/>
|
||||
</connections>
|
||||
</slider>
|
||||
<slider opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" minValue="100" maxValue="300" id="41" customClass="idSlider">
|
||||
<rect key="frame" x="34" y="189" width="411" height="29"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="minimumTrackTintColor" red="1" green="0.49936569364776573" blue="0.023189855779927049" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<connections>
|
||||
<action selector="TiltMoveValChanged" destination="-1" eventType="valueChanged" id="69"/>
|
||||
</connections>
|
||||
</slider>
|
||||
<slider opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" value="0.5" minValue="0.20000000000000001" maxValue="1" id="30" customClass="idSlider">
|
||||
<rect key="frame" x="34" y="123" width="411" height="29"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="backgroundColor" red="0.0054347827099999997" green="0.0054347827099999997" blue="0.0054347827099999997" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="minimumTrackTintColor" red="1" green="0.49936569364776573" blue="0.023189855779927049" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<connections>
|
||||
<action selector="MoveStickValChanged" destination="-1" eventType="valueChanged" id="67"/>
|
||||
</connections>
|
||||
</slider>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Advanced" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="47" customClass="idLabel">
|
||||
<rect key="frame" x="417" y="259" width="63" height="18"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Tilt_Move_Speed" textAlignment="right" lineBreakMode="tailTruncation" minimumFontSize="10" id="48" customClass="idLabel">
|
||||
<rect key="frame" x="36" y="208" width="407" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Back" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="29" customClass="idLabel">
|
||||
<rect key="frame" x="9" y="259" width="32" height="18"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Single_Thumbpad" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="32" customClass="idLabel">
|
||||
<rect key="frame" x="34" y="91" width="111" height="20"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Dir_&_Wheel" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="34" customClass="idLabel">
|
||||
<rect key="frame" x="335" y="91" width="111" height="20"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Dual_Thumbpad" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="36" customClass="idLabel">
|
||||
<rect key="frame" x="184" y="91" width="111" height="20"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Move_Stick_Size" textAlignment="right" lineBreakMode="tailTruncation" minimumFontSize="10" id="40" customClass="idLabel">
|
||||
<rect key="frame" x="36" y="141" width="407" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Turn_Stick_Size" textAlignment="right" lineBreakMode="tailTruncation" minimumFontSize="10" id="44" customClass="idLabel">
|
||||
<rect key="frame" x="36" y="175" width="407" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="#Tilt_Turn_Speed" textAlignment="right" lineBreakMode="tailTruncation" minimumFontSize="10" id="45" customClass="idLabel">
|
||||
<rect key="frame" x="36" y="243" width="407" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="0.0" height="0.0"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="AdvancedButton.png" width="93" height="94"/>
|
||||
<image name="BackButton.png" width="93" height="94"/>
|
||||
<image name="Divide.png" width="764" height="11"/>
|
||||
<image name="LayoutDualButton.png" width="241" height="166"/>
|
||||
<image name="LayoutSingleButton.png" width="241" height="166"/>
|
||||
<image name="LayoutWheelButton.png" width="241" height="166"/>
|
||||
<image name="MenuBackground.png" width="960" height="640"/>
|
||||
</resources>
|
||||
<simulatedMetricsContainer key="defaultSimulatedMetrics">
|
||||
<nil key="statusBar"/>
|
||||
<simulatedOrientationMetrics key="orientation" orientation="landscapeRight"/>
|
||||
<simulatedScreenMetrics key="destination"/>
|
||||
</simulatedMetricsContainer>
|
||||
</document>
|
|
@ -27,11 +27,12 @@
|
|||
*/
|
||||
@interface Doom_ControlsMenuViewController : UIViewController {
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
IBOutlet UISlider * movestickSize;
|
||||
IBOutlet UISlider * turnstickSize;
|
||||
IBOutlet UISlider * tiltMoveSpeed;
|
||||
IBOutlet UISlider * tiltTurnSpeed;
|
||||
|
||||
#endif
|
||||
|
||||
IBOutlet UIButton * singleThumbButton;
|
||||
IBOutlet UIButton * dualThumbButton;
|
||||
|
@ -39,10 +40,11 @@
|
|||
|
||||
}
|
||||
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
- (void) SetupSlider:(UISlider*)slider minimumTrack:(UIImage*)minImage
|
||||
maximumTrack:(UIImage*)maxImage
|
||||
thumb:(UIImage*)thumbImage;
|
||||
#endif
|
||||
|
||||
- (IBAction) BackToMain;
|
||||
- (IBAction) HudLayoutPressed;
|
||||
|
|
|
@ -42,19 +42,30 @@
|
|||
UIImage* minimumTrackImage = [UIImage imageNamed:@"SliderBar.png"];
|
||||
NSInteger minimumTrackImageCap = (NSInteger)(minimumTrackImage.size.width * 0.5f);
|
||||
|
||||
UIImage* minimumTrackImageCapped = [minimumTrackImage stretchableImageWithLeftCapWidth:minimumTrackImageCap topCapHeight: 0];
|
||||
|
||||
#if TARGET_OS_TV
|
||||
UIImage* minimumTrackImageCapped = [minimumTrackImage resizableImageWithCapInsets:UIEdgeInsetsMake(0, minimumTrackImageCap, 0, 0)];
|
||||
NSLog(@"%@", minimumTrackImageCapped);
|
||||
#else
|
||||
UIImage* minimumTrackImageCapped = [minimumTrackImage stretchableImageWithLeftCapWidth:minimumTrackImageCap topCapHeight: 0];
|
||||
#endif
|
||||
|
||||
// Maximum track image setup.
|
||||
UIImage* maximumTrackImage = [UIImage imageNamed:@"SliderBackground.png"];
|
||||
NSInteger maximumTrackImageCap = (NSInteger)(maximumTrackImage.size.width * 0.5f);
|
||||
|
||||
UIImage* maximumTrackImageCapped = [maximumTrackImage stretchableImageWithLeftCapWidth:maximumTrackImageCap topCapHeight: 0];
|
||||
#if TARGET_OS_TV
|
||||
UIImage* maximumTrackImageCapped = [maximumTrackImage resizableImageWithCapInsets:UIEdgeInsetsMake(0, maximumTrackImageCap, 0, 0)];
|
||||
NSLog(@"%@", maximumTrackImageCapped);
|
||||
#else
|
||||
UIImage* maximumTrackImageCapped = [maximumTrackImage stretchableImageWithLeftCapWidth:maximumTrackImageCap topCapHeight: 0];
|
||||
#endif
|
||||
|
||||
// Thumb image.
|
||||
UIImage* thumbImage = [UIImage imageNamed:@"SliderSkull.png"];
|
||||
#if !TARGET_OS_TV
|
||||
|
||||
// Set up slider instances.
|
||||
// Thumb image.
|
||||
UIImage* thumbImage = [UIImage imageNamed:@"SliderSkull.png"];
|
||||
|
||||
// Set up slider instances.
|
||||
[self SetupSlider:movestickSize minimumTrack:minimumTrackImageCapped
|
||||
maximumTrack:maximumTrackImageCapped
|
||||
thumb:thumbImage];
|
||||
|
@ -81,7 +92,8 @@
|
|||
turnstickSize.value = stickTurn->value / 255;
|
||||
tiltMoveSpeed.value = tiltMove->value;
|
||||
tiltTurnSpeed.value = tiltTurn->value;
|
||||
|
||||
#endif
|
||||
|
||||
if( controlScheme->value == 0 ) {
|
||||
singleThumbButton.enabled = NO;
|
||||
dualThumbButton.enabled = YES;
|
||||
|
@ -138,6 +150,7 @@
|
|||
[ self Initialize ];
|
||||
}
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
/*
|
||||
========================
|
||||
Doom_ControlsMenuViewController::SetupSlider
|
||||
|
@ -153,6 +166,7 @@
|
|||
[slider setThumbImage:thumbImage forState:UIControlStateNormal];
|
||||
[slider setThumbImage:thumbImage forState:UIControlStateHighlighted];
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
========================
|
||||
|
@ -260,8 +274,10 @@
|
|||
*/
|
||||
- (IBAction) MoveStickValChanged {
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
Cvar_SetValue( stickMove->name, movestickSize.value * 256.0f );
|
||||
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -271,7 +287,9 @@
|
|||
*/
|
||||
- (IBAction) TurnStickValChanged {
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
Cvar_SetValue( stickTurn->name, turnstickSize.value * 256.0f );
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -280,6 +298,7 @@
|
|||
========================
|
||||
*/
|
||||
- (IBAction) TiltMoveValChanged {
|
||||
#if !TARGET_OS_TV
|
||||
Cvar_SetValue( tiltMove->name, tiltMoveSpeed.value );
|
||||
|
||||
if ( tiltMove->value == 100 ) {
|
||||
|
@ -290,7 +309,8 @@
|
|||
Cvar_SetValue( tiltTurn->name, 0 );
|
||||
tiltTurnSpeed.value = tiltTurn->value;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
@ -301,6 +321,7 @@
|
|||
========================
|
||||
*/
|
||||
- (IBAction) TiltTurnValChanged {
|
||||
#if !TARGET_OS_TV
|
||||
Cvar_SetValue( tiltTurn->name, tiltTurnSpeed.value );
|
||||
|
||||
if ( tiltTurn->value == 1500 ) {
|
||||
|
@ -311,7 +332,7 @@
|
|||
Cvar_SetValue( tiltMove->name, 0 );
|
||||
tiltMoveSpeed.value = tiltMove->value;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
}
|
||||
|
|
45
code/iphone/CreditsMenuView-tvos.xib
Executable file
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="14109" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="tvOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_CreditsMenuViewController">
|
||||
<connections>
|
||||
<outlet property="creditsList" destination="3Sp-Xq-zu5" id="9dL-Um-tgE"/>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="MenuBackground" id="42" userLabel="Background">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<tableView clipsSubviews="YES" contentMode="scaleToFill" misplaced="YES" alwaysBounceVertical="YES" style="plain" separatorStyle="default" rowHeight="-1" sectionHeaderHeight="66" sectionFooterHeight="66" id="3Sp-Xq-zu5">
|
||||
<rect key="frame" x="332" y="96" width="1265" height="853"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
||||
<connections>
|
||||
<outlet property="dataSource" destination="-1" id="7GO-IO-8U6"/>
|
||||
<outlet property="delegate" destination="-1" id="p2D-dg-PC4"/>
|
||||
</connections>
|
||||
</tableView>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="MenuBackground" width="960" height="640"/>
|
||||
</resources>
|
||||
</document>
|
|
@ -196,7 +196,7 @@ static const int CreditSizes[CREDITS_LINES] = {
|
|||
}
|
||||
|
||||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
|
||||
static NSString *MyIdentifier = @"MyIdentifier";
|
||||
static NSString *MyIdentifier = @"CreditsIdentifier";
|
||||
|
||||
UITableViewCell *cell = (UITableViewCell*)[self.creditsList dequeueReusableCellWithIdentifier:MyIdentifier];
|
||||
|
||||
|
@ -272,4 +272,10 @@ static const int CreditSizes[CREDITS_LINES] = {
|
|||
}
|
||||
}
|
||||
|
||||
#if TARGET_OS_TV
|
||||
-(NSArray<id<UIFocusEnvironment>> *)preferredFocusEnvironments {
|
||||
return @[creditsList];
|
||||
}
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
|
BIN
code/iphone/DOOM_400.png
Normal file
After Width: | Height: | Size: 46 KiB |
BIN
code/iphone/DOOM_sigil_decal.png
Normal file
After Width: | Height: | Size: 428 KiB |
|
@ -51,102 +51,6 @@
|
|||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "EpisodeMenuViewController.mm"
|
||||
timestampString = "544116064.121363"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "223"
|
||||
endingLineNumber = "223"
|
||||
landmarkName = "-tableView:didSelectRowAtIndexPath:"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "EpisodeMenuViewController.mm"
|
||||
timestampString = "544116064.121543"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "227"
|
||||
endingLineNumber = "227"
|
||||
landmarkName = "-tableView:didDeselectRowAtIndexPath:"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../prboom/g_game.c"
|
||||
timestampString = "543901652.77071"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "2767"
|
||||
endingLineNumber = "2767"
|
||||
landmarkName = "G_ReadDemoHeader"
|
||||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../prboom/p_enemy.c"
|
||||
timestampString = "543901652.770757"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "546"
|
||||
endingLineNumber = "546"
|
||||
landmarkName = "P_DoNewChaseDir"
|
||||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../prboom/p_enemy.c"
|
||||
timestampString = "543901652.770797"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "553"
|
||||
endingLineNumber = "553"
|
||||
landmarkName = "P_DoNewChaseDir"
|
||||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../prboom/r_bsp.c"
|
||||
timestampString = "543813494.672851"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "106"
|
||||
endingLineNumber = "106"
|
||||
landmarkName = "R_ClearClipSegs"
|
||||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
|
@ -159,9 +63,185 @@
|
|||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "225"
|
||||
endingLineNumber = "225"
|
||||
landmarkName = "landscapeViewport"
|
||||
landmarkName = "landscapeScissor"
|
||||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "MissionMenuViewController.mm"
|
||||
timestampString = "546355240.129087"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "233"
|
||||
endingLineNumber = "233"
|
||||
landmarkName = "-EasyPressed"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "MissionMenuViewController.mm"
|
||||
timestampString = "546355240.129148"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "279"
|
||||
endingLineNumber = "279"
|
||||
landmarkName = "-HardPressed"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "iphone_glViewController.mm"
|
||||
timestampString = "546322114.44634"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "169"
|
||||
endingLineNumber = "169"
|
||||
landmarkName = "-viewWillDisappear:"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "iphone_glViewController.mm"
|
||||
timestampString = "546322114.446382"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "166"
|
||||
endingLineNumber = "166"
|
||||
landmarkName = "iphone_glViewController"
|
||||
landmarkType = "3">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../prboom/f_finale.c"
|
||||
timestampString = "546062994.905203"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "221"
|
||||
endingLineNumber = "221"
|
||||
landmarkName = "F_Ticker"
|
||||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../prboom/f_finale.c"
|
||||
timestampString = "546063197.104556"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "214"
|
||||
endingLineNumber = "214"
|
||||
landmarkName = "F_Ticker"
|
||||
landmarkType = "9">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../ios/Switch.mm"
|
||||
timestampString = "546355240.129761"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "79"
|
||||
endingLineNumber = "79"
|
||||
landmarkName = "-touchesEnded:withEvent:"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "../ios/Switch.mm"
|
||||
timestampString = "546355240.129815"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "64"
|
||||
endingLineNumber = "64"
|
||||
landmarkName = "-touchesBegan:withEvent:"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "SettingsMenuViewController.mm"
|
||||
timestampString = "546355240.129872"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "115"
|
||||
endingLineNumber = "115"
|
||||
landmarkName = "-setValues"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "MainMenuViewController.mm"
|
||||
timestampString = "547165590.281443"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "520"
|
||||
endingLineNumber = "520"
|
||||
landmarkName = "-pressesEnded:withEvent:"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "MainMenuViewController.mm"
|
||||
timestampString = "547165590.281498"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "427"
|
||||
endingLineNumber = "427"
|
||||
landmarkName = "-ShowAboutBanner"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
</Breakpoints>
|
||||
</Bucket>
|
||||
|
|
|
@ -9,6 +9,11 @@
|
|||
<key>orderHint</key>
|
||||
<integer>0</integer>
|
||||
</dict>
|
||||
<key>DoomTV.xcscheme</key>
|
||||
<dict>
|
||||
<key>orderHint</key>
|
||||
<integer>1</integer>
|
||||
</dict>
|
||||
</dict>
|
||||
</dict>
|
||||
</plist>
|
||||
|
|
36
code/iphone/DoomTV/Info.plist
Normal file
|
@ -0,0 +1,36 @@
|
|||
<?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>CFBundleDevelopmentRegion</key>
|
||||
<string>$(DEVELOPMENT_LANGUAGE)</string>
|
||||
<key>CFBundleDisplayName</key>
|
||||
<string>DOOM</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>$(PRODUCT_NAME)</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>1.0</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>UIAppFonts</key>
|
||||
<array>
|
||||
<string>idGinzaNar-Md2.otf</string>
|
||||
</array>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
<array>
|
||||
<string>arm64</string>
|
||||
</array>
|
||||
<key>UIUserInterfaceStyle</key>
|
||||
<string>Automatic</string>
|
||||
</dict>
|
||||
</plist>
|
|
@ -28,8 +28,11 @@
|
|||
|
||||
// Create the Main Menu View controller.
|
||||
|
||||
Doom_MainMenuViewController *rootController = nil;
|
||||
rootController = [[Doom_MainMenuViewController alloc] initWithNibName:@"MainMenuView" bundle:nil];
|
||||
// Doom_MainMenuViewController *rootController = nil;
|
||||
// rootController = [[Doom_MainMenuViewController alloc] initWithNibName:@"MainMenuView" bundle:nil];
|
||||
|
||||
NSLog(@"width: %f height: %f", [[UIScreen mainScreen] bounds].size.width, [[UIScreen mainScreen] bounds].size.height);
|
||||
Doom_MainMenuViewController *rootController = [[Doom_MainMenuViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"MainMenuView"] bundle:nil];
|
||||
|
||||
// Create a Navigation Controller for Pushing/Popping Views.
|
||||
navigationController = [[MainNavController alloc] initWithRootViewController:rootController];
|
||||
|
@ -37,8 +40,8 @@
|
|||
[rootController release];
|
||||
|
||||
// Create the OpenGLView so that our context is created. Don't push it on yet though.
|
||||
openGLViewController = [ [ iphone_glViewController alloc] initWithNibName:@"OpenGLView" bundle:nil ];
|
||||
|
||||
openGLViewController = [ [ iphone_glViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"OpenGLView"] bundle:nil ];
|
||||
|
||||
[ openGLViewController StopDisplay];
|
||||
}
|
||||
|
||||
|
|
|
@ -56,8 +56,10 @@ CAEAGLLayer *eaglLayer;
|
|||
eaglview = self;
|
||||
|
||||
// allow multiple touch events
|
||||
self.multipleTouchEnabled = true;
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
self.multipleTouchEnabled = true;
|
||||
#endif
|
||||
|
||||
// Double the resolution on iPhone 4.
|
||||
if ( [[UIScreen mainScreen] respondsToSelector:@selector(scale)] &&
|
||||
[self respondsToSelector:@selector(setContentScaleFactor:)] ) {
|
||||
|
|
55
code/iphone/EpisodeCell-tvos.xib
Normal file
|
@ -0,0 +1,55 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="14109" targetRuntime="AppleTV" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="tvOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_EpisodeMenuViewController">
|
||||
<connections>
|
||||
<outlet property="episodeCell" destination="mwE-hQ-WaI" id="1u8-Ub-1aL"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<tableViewCell contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="default" indentationWidth="10" focusStyle="custom" rowHeight="224" id="mwE-hQ-WaI">
|
||||
<rect key="frame" x="0.0" y="0.0" width="168" height="224"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" preservesSuperviewLayoutMargins="YES" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="mwE-hQ-WaI" id="jxe-1l-Ti6">
|
||||
<rect key="frame" x="0.0" y="0.0" width="168" height="224"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" tag="3" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="4Da-L9-Pz0">
|
||||
<rect key="frame" x="0.0" y="0.0" width="168" height="224"/>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" tag="1" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="fW6-Gh-Cae">
|
||||
<rect key="frame" x="30" y="43" width="118" height="56"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="24"/>
|
||||
<color key="textColor" red="0.49411764740000003" green="0.1921568662" blue="0.0078431377190000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" tag="2" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="TDd-Cn-Vvr">
|
||||
<rect key="frame" x="30" y="102" width="167" height="79"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="34"/>
|
||||
<color key="textColor" red="0.85882353779999998" green="0.34117648010000001" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="0.80000001190000003" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<constraints>
|
||||
<constraint firstItem="fW6-Gh-Cae" firstAttribute="top" secondItem="jxe-1l-Ti6" secondAttribute="top" constant="43" id="2T5-HV-dWO"/>
|
||||
<constraint firstItem="fW6-Gh-Cae" firstAttribute="leading" secondItem="jxe-1l-Ti6" secondAttribute="leading" constant="30" id="2eN-UH-bDu"/>
|
||||
<constraint firstAttribute="trailing" secondItem="4Da-L9-Pz0" secondAttribute="trailing" id="FE8-4B-qhX"/>
|
||||
<constraint firstAttribute="bottom" secondItem="4Da-L9-Pz0" secondAttribute="bottom" id="H2W-Qr-hu1"/>
|
||||
<constraint firstItem="4Da-L9-Pz0" firstAttribute="top" secondItem="jxe-1l-Ti6" secondAttribute="top" id="XCw-yv-RYW"/>
|
||||
<constraint firstItem="4Da-L9-Pz0" firstAttribute="leading" secondItem="jxe-1l-Ti6" secondAttribute="leading" id="cul-a2-Vdn"/>
|
||||
<constraint firstItem="TDd-Cn-Vvr" firstAttribute="top" secondItem="fW6-Gh-Cae" secondAttribute="bottom" constant="3" id="sWn-A4-xCO"/>
|
||||
<constraint firstItem="TDd-Cn-Vvr" firstAttribute="leading" secondItem="jxe-1l-Ti6" secondAttribute="leading" constant="30" id="tQY-87-NRa"/>
|
||||
</constraints>
|
||||
</tableViewCellContentView>
|
||||
<point key="canvasLocation" x="177" y="173"/>
|
||||
</tableViewCell>
|
||||
</objects>
|
||||
</document>
|
|
@ -1,19 +1,13 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="13771" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14109" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<device id="retina4_7" orientation="portrait">
|
||||
<adaptation id="fullscreen"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13772"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<customFonts key="customFonts">
|
||||
<array key="Helvetica.ttc">
|
||||
<string>Helvetica</string>
|
||||
</array>
|
||||
</customFonts>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_EpisodeMenuViewController">
|
||||
<connections>
|
||||
|
|
|
@ -1,19 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="13771" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14109" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<device id="retina4_7" orientation="portrait">
|
||||
<adaptation id="fullscreen"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13772"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<customFonts key="customFonts">
|
||||
<array key="Helvetica.ttc">
|
||||
<string>Helvetica</string>
|
||||
</array>
|
||||
</customFonts>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_EpisodeMenuViewController">
|
||||
<connections>
|
||||
|
|
46
code/iphone/EpisodeMenuView-tvos.xib
Executable file
|
@ -0,0 +1,46 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="14109" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="tvOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_EpisodeMenuViewController">
|
||||
<connections>
|
||||
<outlet property="episodeList" destination="UXr-uA-jJu" id="XBp-1v-QLo"/>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" misplaced="YES" image="MenuBackground" id="32" userLabel="Background">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<tableView clipsSubviews="YES" contentMode="scaleToFill" misplaced="YES" alwaysBounceVertical="YES" style="plain" separatorStyle="default" rowHeight="-1" sectionHeaderHeight="66" sectionFooterHeight="66" id="UXr-uA-jJu">
|
||||
<rect key="frame" x="589" y="176" width="698" height="753"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
||||
<color key="tintColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
||||
<connections>
|
||||
<outlet property="dataSource" destination="-1" id="KCw-qF-lFS"/>
|
||||
<outlet property="delegate" destination="-1" id="Bsi-MC-Ugp"/>
|
||||
</connections>
|
||||
</tableView>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="MenuBackground" width="960" height="640"/>
|
||||
</resources>
|
||||
</document>
|
|
@ -35,7 +35,6 @@
|
|||
int episodeSelection;
|
||||
IBOutlet idLabelButton * nextButton;
|
||||
IBOutlet idLabel * nextLabel;
|
||||
|
||||
}
|
||||
|
||||
@property (nonatomic, assign) IBOutlet UITableViewCell *episodeCell;
|
||||
|
|
|
@ -98,14 +98,14 @@ static const char * const EpisodeNames[TOTAL_EPISODES][4] = {
|
|||
|
||||
// TODO: Select the current episode. Haven't yet figured out a good way to get the table
|
||||
// view to load with a default row selected, so for now always select episode 1.
|
||||
#if !TARGET_OS_TV
|
||||
int initialEpisode = 0;
|
||||
|
||||
NSIndexPath *initialPath = [NSIndexPath indexPathForRow:initialEpisode inSection:0];
|
||||
|
||||
[self.episodeList selectRowAtIndexPath:initialPath animated:YES scrollPosition:UITableViewScrollPositionNone];
|
||||
[self handleSelectionAtIndexPath:initialPath];
|
||||
self.episodeList.separatorStyle = UITableViewCellSeparatorStyleNone;
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -126,11 +126,8 @@ static const char * const EpisodeNames[TOTAL_EPISODES][4] = {
|
|||
*/
|
||||
- (IBAction) NextToMissions {
|
||||
|
||||
Doom_MissionMenuViewController *vc = nil;
|
||||
|
||||
|
||||
vc = [[Doom_MissionMenuViewController alloc] initWithNibName:@"MissionMenuView" bundle:nil];
|
||||
|
||||
Doom_MissionMenuViewController *vc = [[Doom_MissionMenuViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"MissionMenuView"] bundle:nil];
|
||||
|
||||
[self.navigationController pushViewController:vc animated:NO];
|
||||
[vc setEpisode:episodeSelection ];
|
||||
[vc release];
|
||||
|
@ -151,7 +148,6 @@ static const char * const EpisodeNames[TOTAL_EPISODES][4] = {
|
|||
Cvar_SetValue( episode->name, indexPath.row );
|
||||
|
||||
[self setCellSelected:YES atIndexPath:indexPath];
|
||||
|
||||
}
|
||||
|
||||
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
|
||||
|
@ -159,12 +155,12 @@ static const char * const EpisodeNames[TOTAL_EPISODES][4] = {
|
|||
}
|
||||
|
||||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
|
||||
static NSString *MyIdentifier = @"MyIdentifier";
|
||||
static NSString *MyIdentifier = @"EpisodeIdentifier";
|
||||
UITableViewCell *cell = (UITableViewCell*)[self.episodeList dequeueReusableCellWithIdentifier:MyIdentifier];
|
||||
|
||||
if (cell == nil) {
|
||||
//cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:MyIdentifier] autorelease];
|
||||
[[NSBundle mainBundle] loadNibNamed:@"EpisodeCell" owner:self options:nil];
|
||||
[[NSBundle mainBundle] loadNibNamed:[gAppDelegate GetNibNameForDevice:@"EpisodeCell"] owner:self options:nil];
|
||||
|
||||
if ( episodeCell == nil ) {
|
||||
// Couldn't create from nib file, load a default cell.
|
||||
|
@ -230,20 +226,39 @@ static const char * const EpisodeNames[TOTAL_EPISODES][4] = {
|
|||
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
|
||||
if (IS_IPAD) {
|
||||
return 158;
|
||||
} else if (IS_TV) {
|
||||
return 185;
|
||||
} else {
|
||||
return 79;
|
||||
}
|
||||
}
|
||||
|
||||
#if TARGET_OS_TV
|
||||
- (void)didUpdateFocusInContext:(UIFocusUpdateContext *)context withAnimationCoordinator:(UIFocusAnimationCoordinator *)coordinator {
|
||||
|
||||
[super didUpdateFocusInContext:context withAnimationCoordinator:coordinator];
|
||||
|
||||
if ([context.nextFocusedView isKindOfClass:[UITableViewCell class]]) {
|
||||
[coordinator addCoordinatedAnimations:^{
|
||||
[context.nextFocusedView setBackgroundColor:[UIColor redColor]];
|
||||
[context.previouslyFocusedView setBackgroundColor:[UIColor clearColor]];
|
||||
} completion:nil];
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
- (void)setCellSelected:(BOOL)selected atIndexPath:(NSIndexPath*)indexPath {
|
||||
// Get the cell that was selected.
|
||||
[ nextButton setEnabled: YES ];
|
||||
[ nextLabel setEnabled: YES ];
|
||||
episodeSelection = (int)indexPath.row;
|
||||
|
||||
#if TARGET_OS_TV
|
||||
[self NextToMissions];
|
||||
#else
|
||||
UITableViewCell * cell = [episodeList cellForRowAtIndexPath:indexPath];
|
||||
|
||||
[self setCellSelected:selected cell:cell];
|
||||
#endif
|
||||
}
|
||||
|
||||
- (void)setCellSelected:(BOOL)selected cell:(UITableViewCell*)cell {
|
||||
|
|
|
@ -108,11 +108,18 @@ bool iphoneControllerIsAvailable() {
|
|||
if(!initialized) {
|
||||
NSArray *controllers = [GCController controllers];
|
||||
if(controllers.count > 0) {
|
||||
controller = controllers[0]; // Just use the first one
|
||||
// controller = controllers[0]; // Just use the first one
|
||||
|
||||
// If we have neither gamepad nor extended gamepad support, just make controller nil
|
||||
if(![controller gamepad] && ![controller extendedGamepad]) {
|
||||
// if(![controller gamepad] && ![controller extendedGamepad]) {
|
||||
controller = nil;
|
||||
// }
|
||||
|
||||
for (int i = 0; i < controllers.count; i++)
|
||||
{
|
||||
if([controllers[i] gamepad] || [controllers[i] extendedGamepad]) {
|
||||
controller = controllers[i];
|
||||
}
|
||||
}
|
||||
|
||||
setupPauseButtonHandler(controller);
|
||||
|
@ -173,6 +180,18 @@ void iphoneControllerInput(ticcmd_t* cmd) {
|
|||
cmd->buttons |= newWeapon << BT_WEAPONSHIFT;
|
||||
}
|
||||
|
||||
// if(gamepad.dpad.left.pressed && players[consoleplayer].playerstate == PST_DEAD) {
|
||||
// cmd->buttons |= BT_USE;
|
||||
// }
|
||||
//
|
||||
// if(gamepad.dpad.up.pressed && players[consoleplayer].playerstate == PST_DEAD) {
|
||||
// cmd->buttons |= BT_SPECIAL;
|
||||
// }
|
||||
//
|
||||
// if(gamepad.dpad.right.pressed && players[consoleplayer].playerstate == PST_DEAD) {
|
||||
// cmd->buttons |= BT_SPECIALMASK;
|
||||
// }
|
||||
|
||||
if(togglePause) {
|
||||
cmd->buttons |= BT_SPECIAL | (BTS_PAUSE & BT_SPECIALMASK);
|
||||
togglePause = false;
|
||||
|
|
54
code/iphone/LegalMenuView-tvos.xib
Executable file
|
@ -0,0 +1,54 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="14109" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="tvOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_LegalMenuViewController">
|
||||
<connections>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="MenuBackground" id="10" userLabel="Background">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" misplaced="YES" image="DoomLogo" id="14">
|
||||
<rect key="frame" x="468" y="72" width="1052" height="453"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" textAlignment="center" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="bcE-fr-wwO">
|
||||
<rect key="frame" x="110" y="533" width="1700" height="357"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<string key="text">
|
||||
Doom® Classic © 2009-2012 id Software LLC, a ZeniMax Media company.
|
||||
DOOM, id, id Software, id Tech and related logos are registered
|
||||
trademarks or trademarks of id Software LLC in the U.S. and/or other
|
||||
countries. Bethesda, Bethesda Softworks, ZeniMax and related logos
|
||||
are registered trademarks or trademarks of ZeniMax Media Inc. in the
|
||||
U.S. and/or other countries. All Rights Reserved
|
||||
</string>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="36"/>
|
||||
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="DoomLogo" width="557" height="358"/>
|
||||
<image name="MenuBackground" width="960" height="640"/>
|
||||
</resources>
|
||||
</document>
|
427
code/iphone/MainMenuView-tvos.xib
Executable file
|
@ -0,0 +1,427 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="14109" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="tvOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_MainMenuViewController">
|
||||
<connections>
|
||||
<outlet property="mAboutButton" destination="436" id="Eu3-C0-Z3G"/>
|
||||
<outlet property="mAboutSubMenu" destination="xLp-S2-s9n" id="ai6-6i-8qg"/>
|
||||
<outlet property="mExtrasSubMenu" destination="Zo7-59-XnS" id="ptu-dv-mV4"/>
|
||||
<outlet property="mPlayButton" destination="439" id="488"/>
|
||||
<outlet property="mPlaySubMenu" destination="442" id="489"/>
|
||||
<outlet property="mSettingsSubMenu" destination="FC3-QB-3W9" id="KTh-2R-F5U"/>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" image="MenuBackground" id="443" userLabel="Background">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" misplaced="YES" image="DoomLogo" id="440" userLabel="Logo">
|
||||
<rect key="frame" x="468" y="72" width="1052" height="453"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<view alpha="0.0" contentMode="scaleToFill" misplaced="YES" id="Zo7-59-XnS" userLabel="Extras SubMenu" customClass="Banner_SubMenu">
|
||||
<rect key="frame" x="468" y="310" width="1052" height="334"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="SubMenuBackground" id="7ti-aI-23g">
|
||||
<rect key="frame" x="3" y="-47" width="1047" height="383"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<button opaque="NO" tag="1" contentMode="scaleAspectFit" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="5A3-bO-kP5" userLabel="More Games Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="255" y="8" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted.png">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="OtherIdGamesPressed" destination="-1" eventType="touchUpInside" id="Ixg-3J-beH"/>
|
||||
<action selector="OtherIdGamesPressed" destination="-1" eventType="primaryActionTriggered" id="Oi8-zE-for"/>
|
||||
<outlet property="label" destination="Xf7-RV-pzg" id="KiE-AZ-645"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="ozW-Mr-pfk" userLabel="Demo Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="574" y="8" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="DemoPressed" destination="-1" eventType="touchUpInside" id="NqG-JI-FHD"/>
|
||||
<action selector="DemoPressed" destination="-1" eventType="primaryActionTriggered" id="ahc-l3-EXx"/>
|
||||
<outlet property="label" destination="eNm-pn-xNc" id="igL-MN-plZ"/>
|
||||
</connections>
|
||||
</button>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="3" contentMode="left" text="MORE GAMES" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="Xf7-RV-pzg" customClass="idLabel">
|
||||
<rect key="frame" x="313" y="174" width="110" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="4" contentMode="left" text="DEMO" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="eNm-pn-xNc" customClass="idLabel">
|
||||
<rect key="frame" x="619" y="176" width="136" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</view>
|
||||
<view alpha="0.69999999999999996" contentMode="scaleToFill" misplaced="YES" id="NIq-nO-MJE">
|
||||
<rect key="frame" x="261" y="597" width="1467" height="278"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<subviews>
|
||||
<button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" reversesTitleShadowWhenHighlighted="YES" adjustsImageWhenHighlighted="NO" lineBreakMode="middleTruncation" id="439" userLabel="Play Button" customClass="idLabelButton">
|
||||
<rect key="frame" x="200" y="57" width="161" height="161"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Button">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="Button_Highlighted.png"/>
|
||||
<state key="highlighted" image="Button_Highlighted.png">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="ShowPlayBanner" destination="-1" eventType="primaryActionTriggered" id="4AL-uA-TqT"/>
|
||||
<action selector="ShowPlayBanner" destination="-1" eventType="touchUpInside" id="ZJt-gr-o0i"/>
|
||||
<outlet property="label" destination="432" id="470"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="436" userLabel="About Button" customClass="idLabelButton">
|
||||
<rect key="frame" x="823" y="57" width="154" height="147"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Button">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="Button_Highlighted.png"/>
|
||||
<state key="highlighted" image="Button_Highlighted.png">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="ShowAboutBanner" destination="-1" eventType="primaryActionTriggered" id="KXT-bH-Iss"/>
|
||||
<action selector="ShowAboutBanner" destination="-1" eventType="touchUpInside" id="eKT-rh-DVN"/>
|
||||
<outlet property="label" destination="441" id="472"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="447" userLabel="SettingsButton" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="1113" y="63" width="146" height="134"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Button">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted.png">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="SettingsOptionsPressed" destination="-1" eventType="primaryActionTriggered" id="KcQ-be-D4C"/>
|
||||
<outlet property="label" destination="449" id="477"/>
|
||||
</connections>
|
||||
</button>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="4" contentMode="left" misplaced="YES" text="SETTINGS" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="449" customClass="idLabel">
|
||||
<rect key="frame" x="1118" y="223" width="136" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="PLAY GAME" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="432" customClass="idLabel">
|
||||
<rect key="frame" x="200" y="221" width="161" height="49"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="19"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="ABOUT" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="441" customClass="idLabel">
|
||||
<rect key="frame" x="823" y="221" width="154" height="36"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="19"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="4" contentMode="left" misplaced="YES" text="DEMO" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="468" customClass="idLabel">
|
||||
<rect key="frame" x="519" y="234" width="136" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="467" userLabel="Demo Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="510" y="57" width="154" height="154"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Button">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted.png">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="DemoPressed" destination="-1" eventType="primaryActionTriggered" id="glG-bU-gbu"/>
|
||||
<outlet property="label" destination="468" id="481"/>
|
||||
</connections>
|
||||
</button>
|
||||
</subviews>
|
||||
<color key="backgroundColor" white="0.0" alpha="1" colorSpace="calibratedWhite"/>
|
||||
</view>
|
||||
<view alpha="0.0" contentMode="scaleToFill" misplaced="YES" id="442" userLabel="Play SubMenu" customClass="Banner_SubMenu">
|
||||
<rect key="frame" x="468" y="310" width="1052" height="334"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SubMenuBackground" id="457">
|
||||
<rect key="frame" x="3" y="-47" width="1047" height="383"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<button opaque="NO" tag="1" contentMode="scaleAspectFit" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="456" userLabel="New Game Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="255" y="8" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted.png">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="NewGamePressed" destination="-1" eventType="touchUpInside" id="497"/>
|
||||
<action selector="NewGamePressed" destination="-1" eventType="primaryActionTriggered" id="pnh-50-OiT"/>
|
||||
<outlet property="label" destination="455" id="474"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="454" userLabel="Resume Game Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="574" y="8" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="ResumeGamePressed" destination="-1" eventType="touchUpInside" id="499"/>
|
||||
<action selector="ResumeGamePressed" destination="-1" eventType="primaryActionTriggered" id="JbF-UN-kzA"/>
|
||||
<outlet property="label" destination="453" id="475"/>
|
||||
</connections>
|
||||
</button>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="3" contentMode="left" misplaced="YES" text="NEW GAME" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="455" customClass="idLabel">
|
||||
<rect key="frame" x="313" y="174" width="110" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="4" contentMode="left" misplaced="YES" text="RESUME GAME" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="453" customClass="idLabel">
|
||||
<rect key="frame" x="619" y="176" width="136" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</view>
|
||||
<view alpha="0.0" contentMode="scaleToFill" misplaced="YES" id="FC3-QB-3W9" userLabel="Settings SubMenu" customClass="Banner_SubMenu">
|
||||
<rect key="frame" x="468" y="310" width="1052" height="334"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="SubMenuBackground" id="be4-gH-A9e">
|
||||
<rect key="frame" x="3" y="-47" width="1047" height="383"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<button opaque="NO" tag="1" contentMode="scaleAspectFit" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="5r4-xC-SAe" userLabel="Controls Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="255" y="8" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted.png">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="ControlsOptionsPressed" destination="-1" eventType="touchUpInside" id="5ri-Dp-Jj6"/>
|
||||
<action selector="ControlsOptionsPressed" destination="-1" eventType="primaryActionTriggered" id="76t-vF-mMB"/>
|
||||
<outlet property="label" destination="URw-Gg-gag" id="Wmh-7Y-5v1"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="JDT-Ds-GWb" userLabel="Settings Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="574" y="8" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="SettingsOptionsPressed" destination="-1" eventType="primaryActionTriggered" id="XfY-lw-Wxb"/>
|
||||
<action selector="SettingsOptionsPressed" destination="-1" eventType="touchUpInside" id="r6F-a7-ena"/>
|
||||
<outlet property="label" destination="IWN-Zo-KBn" id="cQg-IJ-uNm"/>
|
||||
</connections>
|
||||
</button>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="3" contentMode="left" text="CONTROLS" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="URw-Gg-gag" customClass="idLabel">
|
||||
<rect key="frame" x="313" y="174" width="110" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="4" contentMode="left" text="SETTINGS" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="IWN-Zo-KBn" customClass="idLabel">
|
||||
<rect key="frame" x="619" y="176" width="136" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</view>
|
||||
<view alpha="0.0" contentMode="scaleToFill" misplaced="YES" id="xLp-S2-s9n" userLabel="About SubMenu" customClass="Banner_SubMenu">
|
||||
<rect key="frame" x="468" y="310" width="1052" height="334"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="SubMenuBackground" id="Gvg-kb-tvB">
|
||||
<rect key="frame" x="3" y="-47" width="1047" height="383"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<button opaque="NO" tag="1" contentMode="scaleAspectFit" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="HNE-2o-3d6" userLabel="Legal Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="111" y="7" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted.png">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="LegalPressed" destination="-1" eventType="primaryActionTriggered" id="aog-dn-0tP"/>
|
||||
<action selector="LegalPressed" destination="-1" eventType="touchUpInside" id="yxC-IM-XaD"/>
|
||||
<outlet property="label" destination="ahe-j1-bQA" id="lCO-L0-3Z6"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="YaH-5G-61O" userLabel="Support Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="770" y="8" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="SupportPressed" destination="-1" eventType="primaryActionTriggered" id="LCY-fs-6bY"/>
|
||||
<action selector="SupportPressed" destination="-1" eventType="touchUpInside" id="lyz-c2-9S0"/>
|
||||
<outlet property="label" destination="7Bf-Qo-6Ik" id="7s5-Zo-6Qb"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="abd-cU-3Qo" userLabel="Credits Button" customClass="Banner_SubItem">
|
||||
<rect key="frame" x="413" y="7" width="226" height="200"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SubMenuButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="SubMenuButton_Highlighted">
|
||||
<color key="titleColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SubMenuButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="CreditsPressed" destination="-1" eventType="primaryActionTriggered" id="Eo9-Ag-ZVy"/>
|
||||
<action selector="CreditsPressed" destination="-1" eventType="touchUpInside" id="z76-Sa-VbR"/>
|
||||
</connections>
|
||||
</button>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="3" contentMode="left" misplaced="YES" text="LEGAL" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="ahe-j1-bQA" customClass="idLabel">
|
||||
<rect key="frame" x="169" y="176" width="110" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="4" contentMode="left" misplaced="YES" text="SUPPORT" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="7Bf-Qo-6Ik" customClass="idLabel">
|
||||
<rect key="frame" x="815" y="176" width="136" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" tag="3" contentMode="left" misplaced="YES" text="CREDITS" textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" adjustsFontSizeToFit="NO" id="D6E-eG-9BN" customClass="idLabel">
|
||||
<rect key="frame" x="471" y="176" width="110" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.87843137979999997" green="0.3843137324" blue="0.1137254909" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</view>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="Button" width="191" height="191"/>
|
||||
<image name="Button_Highlighted" width="191" height="191"/>
|
||||
<image name="Button_Highlighted.png" width="191" height="191"/>
|
||||
<image name="DoomLogo" width="557" height="358"/>
|
||||
<image name="MenuBackground" width="960" height="640"/>
|
||||
<image name="SubMenuBackground" width="959" height="574"/>
|
||||
<image name="SubMenuButton" width="195" height="174"/>
|
||||
<image name="SubMenuButton_Highlighted" width="195" height="174"/>
|
||||
<image name="SubMenuButton_Highlighted.png" width="195" height="174"/>
|
||||
</resources>
|
||||
</document>
|
|
@ -146,6 +146,11 @@
|
|||
*/
|
||||
@implementation Doom_MainMenuViewController
|
||||
|
||||
BOOL playMenuSelected = NO;
|
||||
BOOL extrasMenuSelected = NO;
|
||||
BOOL aboutMenuSelected = NO;
|
||||
BOOL settingsMenuSelected = NO;
|
||||
|
||||
/*
|
||||
========================
|
||||
MainMenuViewController::initWithNibName
|
||||
|
@ -209,9 +214,7 @@
|
|||
- (IBAction) NewGamePressed {
|
||||
|
||||
// Switch to episode view menu.
|
||||
Doom_EpisodeMenuViewController *vc = nil;
|
||||
|
||||
vc = [[Doom_EpisodeMenuViewController alloc] initWithNibName:@"EpisodeMenuView" bundle:nil];
|
||||
Doom_EpisodeMenuViewController *vc = [[Doom_EpisodeMenuViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"EpisodeMenuView"] bundle:nil];
|
||||
|
||||
[self.navigationController pushViewController:vc animated:NO];
|
||||
[vc release];
|
||||
|
@ -267,9 +270,7 @@
|
|||
*/
|
||||
- (IBAction) CreditsPressed {
|
||||
|
||||
Doom_CreditsMenuViewController *vc = nil;
|
||||
|
||||
vc = [[Doom_CreditsMenuViewController alloc] initWithNibName:@"CreditsMenuView" bundle:nil];
|
||||
Doom_CreditsMenuViewController *vc = [[Doom_CreditsMenuViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"CreditsMenuView"] bundle:nil];
|
||||
|
||||
[self.navigationController pushViewController:vc animated:NO];
|
||||
[vc release];
|
||||
|
@ -296,10 +297,8 @@
|
|||
*/
|
||||
- (IBAction) LegalPressed {
|
||||
|
||||
Doom_LegalMenuViewController *vc = nil;
|
||||
|
||||
vc = [[Doom_LegalMenuViewController alloc] initWithNibName:@"LegalMenuView" bundle:nil];
|
||||
|
||||
Doom_LegalMenuViewController *vc = [[Doom_LegalMenuViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"LegalMenuView"] bundle:nil];
|
||||
|
||||
[self.navigationController pushViewController:vc animated:NO];
|
||||
[vc release];
|
||||
|
||||
|
@ -339,9 +338,7 @@
|
|||
*/
|
||||
- (IBAction) ControlsOptionsPressed {
|
||||
|
||||
Doom_ControlsMenuViewController *vc = nil;
|
||||
|
||||
vc = [[Doom_ControlsMenuViewController alloc] initWithNibName:@"ControlsMenuView" bundle:nil];
|
||||
Doom_ControlsMenuViewController *vc = [[Doom_ControlsMenuViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"ControlsMenuView"] bundle:nil];
|
||||
|
||||
[self.navigationController pushViewController:vc animated:NO];
|
||||
[vc release];
|
||||
|
@ -357,10 +354,7 @@
|
|||
*/
|
||||
- (IBAction) SettingsOptionsPressed {
|
||||
|
||||
|
||||
Doom_SettingsMenuViewController *vc = nil;
|
||||
|
||||
vc = [[Doom_SettingsMenuViewController alloc] initWithNibName:@"SettingsMenuView" bundle:nil];
|
||||
Doom_SettingsMenuViewController *vc = [[Doom_SettingsMenuViewController alloc] initWithNibName:[gAppDelegate GetNibNameForDevice:@"SettingsMenuView"] bundle:nil];
|
||||
|
||||
[self.navigationController pushViewController:vc animated:NO];
|
||||
[vc release];
|
||||
|
@ -385,6 +379,15 @@
|
|||
[ mExtrasSubMenu Hide ];
|
||||
[ mAboutSubMenu Hide ];
|
||||
|
||||
#if TARGET_OS_TV
|
||||
playMenuSelected = YES;
|
||||
extrasMenuSelected = NO;
|
||||
settingsMenuSelected = NO;
|
||||
aboutMenuSelected = NO;
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -403,6 +406,15 @@
|
|||
[ mPlaySubMenu Hide ];
|
||||
[ mExtrasSubMenu Hide ];
|
||||
[ mAboutSubMenu Hide ];
|
||||
|
||||
#if TARGET_OS_TV
|
||||
playMenuSelected = NO;
|
||||
extrasMenuSelected = NO;
|
||||
settingsMenuSelected = YES;
|
||||
aboutMenuSelected = NO;
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -421,6 +433,16 @@
|
|||
[ mPlaySubMenu Hide ];
|
||||
[ mSettingsSubMenu Hide ];
|
||||
[ mExtrasSubMenu Hide ];
|
||||
|
||||
#if TARGET_OS_TV
|
||||
playMenuSelected = NO;
|
||||
extrasMenuSelected = NO;
|
||||
settingsMenuSelected = NO;
|
||||
aboutMenuSelected = YES;
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -448,8 +470,85 @@
|
|||
[ mPlaySubMenu Hide ];
|
||||
[ mExtrasSubMenu Show ];
|
||||
[ mAboutSubMenu Hide ];
|
||||
|
||||
|
||||
#if TARGET_OS_TV
|
||||
playMenuSelected = NO;
|
||||
extrasMenuSelected = YES;
|
||||
settingsMenuSelected = NO;
|
||||
aboutMenuSelected = NO;
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
#if TARGET_OS_TV
|
||||
-(NSArray<id<UIFocusEnvironment>> *)preferredFocusEnvironments {
|
||||
if (playMenuSelected) {
|
||||
return @[mPlaySubMenu];
|
||||
} else if (extrasMenuSelected) {
|
||||
return @[mExtrasSubMenu];
|
||||
} else if (settingsMenuSelected) {
|
||||
return @[mSettingsSubMenu];
|
||||
} else if (aboutMenuSelected) {
|
||||
return @[mAboutSubMenu];
|
||||
} else {
|
||||
return @[mPlayButton];
|
||||
}
|
||||
}
|
||||
|
||||
- (void)pressesBegan:(NSSet<UIPress *> *)presses withEvent:(UIPressesEvent *)event {
|
||||
for (UIPress* press in presses) {
|
||||
switch (press.type) {
|
||||
case UIPressTypeMenu:
|
||||
if (playMenuSelected || extrasMenuSelected || settingsMenuSelected || aboutMenuSelected) {
|
||||
break;
|
||||
} else {
|
||||
[super pressesBegan: presses withEvent: event];
|
||||
}
|
||||
default:
|
||||
[super pressesBegan: presses withEvent: event];
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
- (void)pressesEnded:(NSSet<UIPress *> *)presses withEvent:(UIPressesEvent *)event {
|
||||
for (UIPress* press in presses) {
|
||||
switch (press.type) {
|
||||
case UIPressTypeMenu:
|
||||
if (playMenuSelected) {
|
||||
playMenuSelected = NO;
|
||||
[mPlaySubMenu Hide];
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
} else if (extrasMenuSelected) {
|
||||
extrasMenuSelected = NO;
|
||||
[mExtrasSubMenu Hide];
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
} else if (settingsMenuSelected) {
|
||||
settingsMenuSelected = NO;
|
||||
[mSettingsSubMenu Hide];
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
} else if (aboutMenuSelected) {
|
||||
aboutMenuSelected = NO;
|
||||
[mAboutSubMenu Hide];
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
} else {
|
||||
[super pressesEnded: presses withEvent: event];
|
||||
}
|
||||
break;
|
||||
default:
|
||||
[super pressesEnded: presses withEvent: event];
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
*/
|
||||
|
||||
#import "MainNavController.h"
|
||||
//#import "doomiphone.h"
|
||||
|
||||
@interface MainNavController ()
|
||||
|
||||
|
|
237
code/iphone/MissionMenuView-tvos.xib
Executable file
|
@ -0,0 +1,237 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="14109" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="tvOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_MissionMenuViewController">
|
||||
<connections>
|
||||
<outlet property="NightmareSelection" destination="18" id="76"/>
|
||||
<outlet property="easyButton" destination="7" id="lzG-bx-qcD"/>
|
||||
<outlet property="easySelection" destination="17" id="69"/>
|
||||
<outlet property="easySelectionLabel" destination="12" id="70"/>
|
||||
<outlet property="hardButton" destination="9" id="RGq-Or-U8x"/>
|
||||
<outlet property="hardSelection" destination="24" id="72"/>
|
||||
<outlet property="hardSelectionLabel" destination="22" id="73"/>
|
||||
<outlet property="mediumSelection" destination="10" id="74"/>
|
||||
<outlet property="mediumSelectionLabel" destination="4" id="75"/>
|
||||
<outlet property="missionList" destination="G18-6R-2NQ" id="cCj-8w-jkR"/>
|
||||
<outlet property="nightmareButton" destination="23" id="Z0g-5v-dta"/>
|
||||
<outlet property="nightmareSelectionLabel" destination="11" id="77"/>
|
||||
<outlet property="normalButton" destination="30" id="4AY-hS-Ems"/>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="MenuBackground" id="25" userLabel="Background">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="DifficultyBackground" id="14">
|
||||
<rect key="frame" x="415" y="688" width="1149" height="239"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="10">
|
||||
<rect key="frame" x="779" y="754" width="123" height="123"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="17">
|
||||
<rect key="frame" x="504" y="757" width="123" height="123"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="18">
|
||||
<rect key="frame" x="1322" y="761" width="123" height="123"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="24">
|
||||
<rect key="frame" x="1054" y="759" width="123" height="123"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="MissonBackground" id="20">
|
||||
<rect key="frame" x="388" y="169" width="1176" height="481"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="6" customClass="idLabelButton">
|
||||
<rect key="frame" x="974" y="635" width="44" height="21"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="DownArrow">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="DownArrow_Highlighted.png">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="DownMission" destination="-1" eventType="touchUpInside" id="89"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="28" customClass="idLabelButton">
|
||||
<rect key="frame" x="972" y="145" width="44" height="21"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="UpArrow">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted" image="UpArrow_Highlighted.png">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="UpMission" destination="-1" eventType="touchUpInside" id="103"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="1" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="7" customClass="idLabelButton">
|
||||
<rect key="frame" x="504" y="755" width="123" height="123"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Easy">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="Button_Highlighted"/>
|
||||
<state key="highlighted" image="Button_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="EasyPressed" destination="-1" eventType="touchUpInside" id="98"/>
|
||||
<action selector="EasyPressed" destination="-1" eventType="primaryActionTriggered" id="pxW-Cp-ZJX"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="3" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="9" customClass="idLabelButton">
|
||||
<rect key="frame" x="1054" y="761" width="121" height="121"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Hard">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="Button_Highlighted"/>
|
||||
<state key="highlighted" image="Button_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="HardPressed" destination="-1" eventType="touchUpInside" id="99"/>
|
||||
<action selector="HardPressed" destination="-1" eventType="primaryActionTriggered" id="9yl-ml-lv7"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="4" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="23" customClass="idLabelButton">
|
||||
<rect key="frame" x="1322" y="763" width="121" height="121"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Nightmare">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="Button_Highlighted"/>
|
||||
<state key="highlighted" image="Button_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="NightmarePressed" destination="-1" eventType="touchUpInside" id="101"/>
|
||||
<action selector="NightmarePressed" destination="-1" eventType="primaryActionTriggered" id="UBG-xK-vrZ"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="30" customClass="idLabelButton">
|
||||
<rect key="frame" x="779" y="757" width="121" height="121"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="Medium">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="Button_Highlighted"/>
|
||||
<state key="highlighted" image="Button_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="Button_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="MediumPressed" destination="-1" eventType="touchUpInside" id="100"/>
|
||||
<action selector="MediumPressed" destination="-1" eventType="primaryActionTriggered" id="zFY-G3-ixA"/>
|
||||
</connections>
|
||||
</button>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Mission" lineBreakMode="tailTruncation" minimumFontSize="10" id="29" customClass="idLabel">
|
||||
<rect key="frame" x="432" y="108" width="121" height="43"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="36"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Ultra-Violence." textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="11" customClass="idLabel">
|
||||
<rect key="frame" x="838" y="949" width="236" height="43"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="36"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="I'm Too Young To Die." textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="12" customClass="idLabel">
|
||||
<rect key="frame" x="786" y="949" width="340" height="43"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="36"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Hey, Not Too Rough." textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="4" customClass="idLabel">
|
||||
<rect key="frame" x="795" y="949" width="324" height="43"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="36"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Difficulty" lineBreakMode="tailTruncation" minimumFontSize="10" id="19" customClass="idLabel">
|
||||
<rect key="frame" x="440" y="637" width="141" height="43"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="36"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
<tableView clipsSubviews="YES" contentMode="scaleToFill" misplaced="YES" alwaysBounceVertical="YES" style="plain" separatorStyle="default" rowHeight="-1" sectionHeaderHeight="66" sectionFooterHeight="66" id="G18-6R-2NQ">
|
||||
<rect key="frame" x="440" y="206" width="1093" height="411"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
||||
<connections>
|
||||
<outlet property="dataSource" destination="-1" id="lJf-CT-IVc"/>
|
||||
<outlet property="delegate" destination="-1" id="WfK-bU-fmT"/>
|
||||
</connections>
|
||||
</tableView>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Hurt Me Plenty." textAlignment="center" lineBreakMode="tailTruncation" minimumFontSize="10" id="22" customClass="idLabel">
|
||||
<rect key="frame" x="825" y="949" width="244" height="43"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="36"/>
|
||||
<color key="textColor" red="0.87058824300000004" green="0.71372550729999995" blue="0.34509804840000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</label>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="Button_Highlighted" width="191" height="191"/>
|
||||
<image name="DifficultyBackground" width="636" height="152"/>
|
||||
<image name="DownArrow" width="80" height="36"/>
|
||||
<image name="DownArrow_Highlighted.png" width="80" height="36"/>
|
||||
<image name="Easy" width="123" height="123"/>
|
||||
<image name="Hard" width="121" height="121"/>
|
||||
<image name="Medium" width="121" height="121"/>
|
||||
<image name="MenuBackground" width="960" height="640"/>
|
||||
<image name="MissonBackground" width="656" height="363"/>
|
||||
<image name="Nightmare" width="121" height="121"/>
|
||||
<image name="SelectedBracket" width="133" height="133"/>
|
||||
<image name="UpArrow" width="80" height="36"/>
|
||||
<image name="UpArrow_Highlighted.png" width="80" height="36"/>
|
||||
</resources>
|
||||
</document>
|
|
@ -41,6 +41,12 @@
|
|||
IBOutlet idLabel * hardSelectionLabel;
|
||||
IBOutlet idLabel * nightmareSelectionLabel;
|
||||
|
||||
|
||||
IBOutlet idLabelButton * easyButton;
|
||||
IBOutlet idLabelButton * normalButton;
|
||||
IBOutlet idLabelButton * hardButton;
|
||||
IBOutlet idLabelButton * nightmareButton;
|
||||
|
||||
IBOutlet idLabelButton * playButton;
|
||||
IBOutlet idLabel * playLabel;
|
||||
|
||||
|
|
|
@ -36,6 +36,8 @@
|
|||
*/
|
||||
@implementation Doom_MissionMenuViewController
|
||||
|
||||
BOOL levelSelected = NO;
|
||||
|
||||
#define TOTAL_EPISODES 4
|
||||
|
||||
static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
||||
|
@ -100,6 +102,8 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
hardSelectionLabel.hidden = YES;
|
||||
NightmareSelection.hidden = YES;
|
||||
nightmareSelectionLabel.hidden = YES;
|
||||
|
||||
[missionList reloadData];
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -236,6 +240,9 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
nightmareSelectionLabel.hidden = YES;
|
||||
|
||||
Sound_StartLocalSound( "iphone/controller_down_01_SILENCE.wav" );
|
||||
#if TARGET_OS_TV
|
||||
[self Play];
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -256,7 +263,10 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
nightmareSelectionLabel.hidden = YES;
|
||||
|
||||
Sound_StartLocalSound( "iphone/controller_down_01_SILENCE.wav" );
|
||||
|
||||
#if TARGET_OS_TV
|
||||
[self Play];
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -277,7 +287,10 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
nightmareSelectionLabel.hidden = YES;
|
||||
|
||||
Sound_StartLocalSound( "iphone/controller_down_01_SILENCE.wav" );
|
||||
|
||||
#if TARGET_OS_TV
|
||||
[self Play];
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -298,6 +311,9 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
nightmareSelectionLabel.hidden = NO;
|
||||
|
||||
Sound_StartLocalSound( "iphone/controller_down_01_SILENCE.wav" );
|
||||
#if TARGET_OS_TV
|
||||
[self Play];
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -314,6 +330,13 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
|
||||
[self setCellSelected:YES atIndexPath:indexPath];
|
||||
|
||||
|
||||
#if TARGET_OS_TV
|
||||
levelSelected = YES;
|
||||
[self setNeedsFocusUpdate];
|
||||
[self updateFocusIfNeeded];
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
|
||||
|
@ -321,7 +344,7 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
}
|
||||
|
||||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
|
||||
static NSString *MyIdentifier = @"MyIdentifier";
|
||||
static NSString *MyIdentifier = @"MissionIdentifier";
|
||||
|
||||
UITableViewCell *cell = (UITableViewCell*)[self.missionList dequeueReusableCellWithIdentifier:MyIdentifier];
|
||||
|
||||
|
@ -381,4 +404,51 @@ static const char * const MissionNames[TOTAL_EPISODES][9] = {
|
|||
cell.textLabel.highlighted = selected;
|
||||
}
|
||||
|
||||
#if TARGET_OS_TV
|
||||
-(NSArray<id<UIFocusEnvironment>> *)preferredFocusEnvironments {
|
||||
if (levelSelected) {
|
||||
levelSelected = NO;
|
||||
return @[normalButton];
|
||||
}
|
||||
else {
|
||||
return @[missionList];
|
||||
}
|
||||
}
|
||||
|
||||
- (void)didUpdateFocusInContext:(UIFocusUpdateContext *)context withAnimationCoordinator:(UIFocusAnimationCoordinator *)coordinator {
|
||||
NSLog(@"%@", context.nextFocusedView);
|
||||
|
||||
[super didUpdateFocusInContext:context withAnimationCoordinator:coordinator];
|
||||
|
||||
if ([context.nextFocusedView isKindOfClass:[idLabelButton class]]) {
|
||||
|
||||
if (context.nextFocusedView.tag > 0) {
|
||||
easySelection.hidden = YES;
|
||||
easySelectionLabel.hidden = YES;
|
||||
mediumSelection.hidden = YES;
|
||||
mediumSelectionLabel.hidden = YES;
|
||||
hardSelection.hidden = YES;
|
||||
hardSelectionLabel.hidden = YES;
|
||||
NightmareSelection.hidden = YES;
|
||||
nightmareSelectionLabel.hidden = YES;
|
||||
|
||||
|
||||
if (context.nextFocusedView.tag == 1) {
|
||||
easySelection.hidden = NO;
|
||||
easySelectionLabel.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 2) {
|
||||
mediumSelection.hidden = NO;
|
||||
mediumSelectionLabel.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 3) {
|
||||
hardSelection.hidden = NO;
|
||||
hardSelectionLabel.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 4) {
|
||||
NightmareSelection.hidden = NO;
|
||||
nightmareSelectionLabel.hidden = NO;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
|
29
code/iphone/OpenGLView-tvos.xib
Executable file
|
@ -0,0 +1,29 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="12120" systemVersion="16F73" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="iphone_glViewController">
|
||||
<connections>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1" customClass="idView">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<simulatedMetricsContainer key="defaultSimulatedMetrics">
|
||||
<nil key="statusBar"/>
|
||||
<simulatedOrientationMetrics key="orientation" orientation="landscapeRight"/>
|
||||
<simulatedScreenMetrics key="destination"/>
|
||||
</simulatedMetricsContainer>
|
||||
</document>
|
327
code/iphone/SettingsMenuView-tvos.xib
Executable file
|
@ -0,0 +1,327 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder.AppleTV.XIB" version="3.0" toolsVersion="14109" targetRuntime="AppleTV" propertyAccessControl="none" colorMatched="YES">
|
||||
<device id="appleTV" orientation="landscape">
|
||||
<adaptation id="light"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="tvOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_SettingsMenuViewController">
|
||||
<connections>
|
||||
<outlet property="autoUseSelection" destination="GpA-uv-hwS" id="Sgr-Fn-6fY"/>
|
||||
<outlet property="autoUseSwitch" destination="21" id="25"/>
|
||||
<outlet property="centerSticksSelection" destination="hXs-He-4Au" id="dWH-w7-Kbs"/>
|
||||
<outlet property="centerSticksSwitch" destination="23" id="26"/>
|
||||
<outlet property="drawControlsSelection" destination="kTB-Rx-Cjw" id="ZIk-YX-90c"/>
|
||||
<outlet property="drawControlsSwitch" destination="6" id="27"/>
|
||||
<outlet property="musicSelection" destination="XEF-L9-UtI" id="8oY-wJ-gQs"/>
|
||||
<outlet property="musicSwitch" destination="18" id="28"/>
|
||||
<outlet property="rampTurnSelection" destination="Rrx-ZD-8Sh" id="mgw-bh-tqo"/>
|
||||
<outlet property="rampTurnSwitch" destination="17" id="29"/>
|
||||
<outlet property="resetButton" destination="9" id="HLX-Sj-S74"/>
|
||||
<outlet property="resetSelection" destination="uOa-s9-Vvs" id="6d8-Pl-q3A"/>
|
||||
<outlet property="statusbarSelection" destination="j9E-qL-KlF" id="KH2-4q-mfZ"/>
|
||||
<outlet property="statusbarSwitch" destination="7" id="30"/>
|
||||
<outlet property="textMessageSelection" destination="fRB-yD-Zz1" id="W74-uU-aCq"/>
|
||||
<outlet property="textMessageSwitch" destination="16" id="31"/>
|
||||
<outlet property="touchclickSelection" destination="i0k-tQ-CBc" id="hYd-8q-W9E"/>
|
||||
<outlet property="touchclickSwitch" destination="14" id="32"/>
|
||||
<outlet property="view" destination="1" id="3"/>
|
||||
</connections>
|
||||
</placeholder>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" id="1">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="MenuBackground" id="10" userLabel="Background">
|
||||
<rect key="frame" x="0.0" y="0.0" width="1920" height="1080"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<view alpha="0.5" contentMode="scaleToFill" misplaced="YES" id="FuL-ah-z1s">
|
||||
<rect key="frame" x="574" y="161" width="882" height="701"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<subviews>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Text Messages:" lineBreakMode="tailTruncation" minimumFontSize="10" id="5" customClass="idLabel">
|
||||
<rect key="frame" x="118" y="398" width="123" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Status Bar:" lineBreakMode="tailTruncation" minimumFontSize="10" id="11" customClass="idLabel">
|
||||
<rect key="frame" x="136" y="173" width="87" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Draw Controls:" lineBreakMode="tailTruncation" minimumFontSize="10" id="12" customClass="idLabel">
|
||||
<rect key="frame" x="433" y="67" width="117" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Auto Use:" lineBreakMode="tailTruncation" minimumFontSize="10" id="13" customClass="idLabel">
|
||||
<rect key="frame" x="134" y="67" width="75" height="21"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Reset" lineBreakMode="tailTruncation" minimumFontSize="10" id="15" customClass="idLabel">
|
||||
<rect key="frame" x="422" y="621" width="38" height="20"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="14"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Center Sticks:" lineBreakMode="tailTruncation" minimumFontSize="10" id="19" customClass="idLabel">
|
||||
<rect key="frame" x="442" y="280" width="108" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Ramp Turn:" lineBreakMode="tailTruncation" minimumFontSize="10" id="20" customClass="idLabel">
|
||||
<rect key="frame" x="450" y="397" width="93" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text=" Hud Audio:" lineBreakMode="tailTruncation" minimumFontSize="10" id="22" customClass="idLabel">
|
||||
<rect key="frame" x="134" y="280" width="90" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" misplaced="YES" text="Music:" lineBreakMode="tailTruncation" minimumFontSize="10" id="24" customClass="idLabel">
|
||||
<rect key="frame" x="491" y="173" width="52" height="23"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="shadowColor" red="0.03260869533" green="0.03260869533" blue="0.03260869533" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<size key="shadowOffset" width="1" height="2"/>
|
||||
</label>
|
||||
<button opaque="NO" tag="1" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="21" customClass="idSwitch">
|
||||
<rect key="frame" x="263" y="36" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="selected" image="SettingsButton_Highlighted"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="AutoUseChanged" destination="-1" eventType="primaryActionTriggered" id="ryV-q1-2eT"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="5" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="6" customClass="idSwitch">
|
||||
<rect key="frame" x="592" y="36" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="DrawControlsChanged" destination="-1" eventType="primaryActionTriggered" id="79f-36-ojb"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="2" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="7" customClass="idSwitch">
|
||||
<rect key="frame" x="263" y="143" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="StatusBarChanged" destination="-1" eventType="primaryActionTriggered" id="sEB-hV-j9E"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="6" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="18" customClass="idSwitch">
|
||||
<rect key="frame" x="592" y="143" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="MusicChanged" destination="-1" eventType="primaryActionTriggered" id="OG1-jl-UGu"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="3" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="14" customClass="idSwitch">
|
||||
<rect key="frame" x="263" y="250" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="TouchClickChanged" destination="-1" eventType="primaryActionTriggered" id="1c7-uE-wNl"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="7" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="23" customClass="idSwitch">
|
||||
<rect key="frame" x="592" y="250" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="CenterSticksChanged" destination="-1" eventType="primaryActionTriggered" id="hOb-qq-nJz"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="4" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="16" customClass="idSwitch">
|
||||
<rect key="frame" x="263" y="368" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="TextMessagesChanged" destination="-1" eventType="primaryActionTriggered" id="Y3B-m6-XYO"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" tag="8" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="17" customClass="idSwitch">
|
||||
<rect key="frame" x="592" y="368" width="83" height="83"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<state key="normal" image="SettingsButton">
|
||||
<color key="titleColor" red="0.19607843459999999" green="0.30980393290000002" blue="0.52156865600000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="disabled" image="SettingsButton_Highlighted.png"/>
|
||||
<state key="highlighted" image="SettingsButton_Highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<connections>
|
||||
<action selector="RampTurnChanged" destination="-1" eventType="primaryActionTriggered" id="cV4-cU-Wd3"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" id="9" customClass="idLabelButton">
|
||||
<rect key="frame" x="401" y="541" width="81" height="80"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/>
|
||||
<size key="titleShadowOffset" width="1" height="2"/>
|
||||
<state key="normal" image="NextButton">
|
||||
<color key="titleColor" red="0.99199116230010986" green="0.59887534379959106" blue="0.1355646550655365" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<color key="titleShadowColor" red="0.01420286763459444" green="0.0" blue="2.4540675440221094e-05" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="highlighted">
|
||||
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</state>
|
||||
<state key="focused" image="SettingsButton_Highlighted"/>
|
||||
<connections>
|
||||
<action selector="ResetToDefaults" destination="-1" eventType="primaryActionTriggered" id="pEI-NW-C2n"/>
|
||||
</connections>
|
||||
</button>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="GpA-uv-hwS">
|
||||
<rect key="frame" x="262" y="36" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="kTB-Rx-Cjw">
|
||||
<rect key="frame" x="591" y="36" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="j9E-qL-KlF">
|
||||
<rect key="frame" x="263" y="142" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="XEF-L9-UtI">
|
||||
<rect key="frame" x="592" y="142" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="i0k-tQ-CBc">
|
||||
<rect key="frame" x="261" y="250" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="hXs-He-4Au">
|
||||
<rect key="frame" x="592" y="250" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="fRB-yD-Zz1">
|
||||
<rect key="frame" x="263" y="366" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="Rrx-ZD-8Sh">
|
||||
<rect key="frame" x="592" y="366" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" image="SelectedBracket" id="uOa-s9-Vvs">
|
||||
<rect key="frame" x="401" y="541" width="85" height="85"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
</subviews>
|
||||
<color key="backgroundColor" white="0.0" alpha="1" colorSpace="calibratedWhite"/>
|
||||
</view>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="simulatedStatusBarMetrics"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="MenuBackground" width="960" height="640"/>
|
||||
<image name="NextButton" width="93" height="94"/>
|
||||
<image name="SelectedBracket" width="133" height="133"/>
|
||||
<image name="SettingsButton" width="80" height="89"/>
|
||||
<image name="SettingsButton_Highlighted" width="80" height="89"/>
|
||||
<image name="SettingsButton_Highlighted.png" width="80" height="89"/>
|
||||
</resources>
|
||||
</document>
|
|
@ -20,6 +20,7 @@
|
|||
|
||||
#import <UIKit/UIKit.h>
|
||||
#import "../ios/Switch.h"
|
||||
#import "../ios/LabelButton.h"
|
||||
|
||||
/*
|
||||
================================================================================================
|
||||
|
@ -38,7 +39,18 @@
|
|||
IBOutlet idSwitch * musicSwitch;
|
||||
IBOutlet idSwitch * centerSticksSwitch;
|
||||
IBOutlet idSwitch * rampTurnSwitch;
|
||||
|
||||
IBOutlet idLabelButton * resetButton;
|
||||
|
||||
IBOutlet UIImageView * autoUseSelection;
|
||||
IBOutlet UIImageView * statusbarSelection;
|
||||
IBOutlet UIImageView * touchclickSelection;
|
||||
IBOutlet UIImageView * textMessageSelection;
|
||||
IBOutlet UIImageView * drawControlsSelection;
|
||||
IBOutlet UIImageView * musicSelection;
|
||||
IBOutlet UIImageView * centerSticksSelection;
|
||||
IBOutlet UIImageView * rampTurnSelection;
|
||||
IBOutlet UIImageView * resetSelection;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -29,6 +29,8 @@
|
|||
*/
|
||||
@implementation Doom_SettingsMenuViewController
|
||||
|
||||
UIFocusGuide *focusGuide;
|
||||
|
||||
/*
|
||||
========================
|
||||
Doom_SettingsMenuViewController::initWithNibName
|
||||
|
@ -67,14 +69,18 @@
|
|||
{
|
||||
[super viewDidLoad];
|
||||
|
||||
[ autoUseSwitch setOn: (BOOL)autoUse->value ];
|
||||
[ statusbarSwitch setOn: (BOOL)statusBar->value ];
|
||||
[ touchclickSwitch setOn: (BOOL)touchClick->value ];
|
||||
[ textMessageSwitch setOn: (BOOL)messages->value ];
|
||||
[ drawControlsSwitch setOn: (BOOL)drawControls->value ];
|
||||
[ musicSwitch setOn: (BOOL)music->value ];
|
||||
[ centerSticksSwitch setOn: (BOOL)centerSticks->value ];
|
||||
[ rampTurnSwitch setOn: (BOOL)rampTurn->value ];
|
||||
[self setValues];
|
||||
|
||||
#if TARGET_OS_TV
|
||||
focusGuide = [[UIFocusGuide alloc] init];
|
||||
[self.view addLayoutGuide:focusGuide];
|
||||
|
||||
[focusGuide.widthAnchor constraintEqualToAnchor:textMessageSwitch.widthAnchor].active = YES;
|
||||
[focusGuide.heightAnchor constraintEqualToAnchor:resetButton.heightAnchor].active = YES;
|
||||
[focusGuide.topAnchor constraintEqualToAnchor:resetButton.topAnchor].active = YES;
|
||||
focusGuide.preferredFocusEnvironments = @[resetButton];
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -87,6 +93,30 @@
|
|||
Sound_StartLocalSound( "iphone/controller_down_01_SILENCE.wav" );
|
||||
}
|
||||
|
||||
- (void)setValues {
|
||||
[ autoUseSwitch setOn: (BOOL)autoUse->value ];
|
||||
[ statusbarSwitch setOn: (BOOL)statusBar->value ];
|
||||
[ touchclickSwitch setOn: (BOOL)touchClick->value ];
|
||||
[ textMessageSwitch setOn: (BOOL)messages->value ];
|
||||
[ drawControlsSwitch setOn: (BOOL)drawControls->value ];
|
||||
[ musicSwitch setOn: (BOOL)music->value ];
|
||||
[ centerSticksSwitch setOn: (BOOL)centerSticks->value ];
|
||||
[ rampTurnSwitch setOn: (BOOL)rampTurn->value ];
|
||||
|
||||
#if TARGET_OS_TV
|
||||
// This may be a bad way to do it but it lets me leave them as idSwitches instead of changing the type
|
||||
[ autoUseSwitch setImage:(BOOL)autoUse->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
[ statusbarSwitch setImage:(BOOL)statusBar->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
[ touchclickSwitch setImage:(BOOL)touchClick->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
[ textMessageSwitch setImage:(BOOL)messages->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
[ drawControlsSwitch setImage:(BOOL)drawControls->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
[ musicSwitch setImage:(BOOL)music->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
[ centerSticksSwitch setImage:(BOOL)centerSticks->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
[ rampTurnSwitch setImage:(BOOL)rampTurn->value ? [UIImage imageNamed:@"SettingsButton_Highlighted"] : [UIImage imageNamed:@"SettingsButton"] forState:UIControlStateFocused];
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
========================
|
||||
Doom_SettingsMenuViewController::ResetToDefaults
|
||||
|
@ -105,14 +135,7 @@
|
|||
|
||||
Sound_StartLocalSound( "iphone/controller_down_01_SILENCE.wav" );
|
||||
|
||||
[ autoUseSwitch setOn: (BOOL)autoUse->value ];
|
||||
[ statusbarSwitch setOn: (BOOL)statusBar->value ];
|
||||
[ touchclickSwitch setOn: (BOOL)touchClick->value ];
|
||||
[ textMessageSwitch setOn: (BOOL)messages->value ];
|
||||
[ drawControlsSwitch setOn: (BOOL)drawControls->value ];
|
||||
[ musicSwitch setOn: (BOOL)music->value ];
|
||||
[ centerSticksSwitch setOn: (BOOL)centerSticks->value ];
|
||||
[ rampTurnSwitch setOn: (BOOL)rampTurn->value ];
|
||||
[self setValues];
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -122,6 +145,8 @@
|
|||
*/
|
||||
- (IBAction) AutoUseChanged {
|
||||
Cvar_SetValue( autoUse->name, !autoUse->value );
|
||||
// NSLog(@"DOOM: AutoUseChanged: %f", autoUse->value);
|
||||
[self setValues];
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -131,6 +156,8 @@
|
|||
*/
|
||||
- (IBAction) StatusBarChanged {
|
||||
Cvar_SetValue( statusBar->name, !statusBar->value );
|
||||
// NSLog(@"DOOM: StatusBarChanged: %f", statusBar->value);
|
||||
[self setValues];
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -140,6 +167,8 @@
|
|||
*/
|
||||
- (IBAction) TouchClickChanged {
|
||||
Cvar_SetValue( touchClick->name, !touchClick->value );
|
||||
// NSLog(@"DOOM: TouchClickChanged: %f", touchClick->value);
|
||||
[self setValues];
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -149,6 +178,8 @@
|
|||
*/
|
||||
- (IBAction) TextMessagesChanged {
|
||||
Cvar_SetValue( messages->name, !messages->value );
|
||||
// NSLog(@"DOOM: TextMessagesChanged: %f", messages->value);
|
||||
[self setValues];
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -158,6 +189,8 @@
|
|||
*/
|
||||
- (IBAction) DrawControlsChanged {
|
||||
Cvar_SetValue( drawControls->name, !drawControls->value );
|
||||
// NSLog(@"DOOM: DrawControlsChanged: %f", drawControls->value);
|
||||
[self setValues];
|
||||
}
|
||||
extern int mus_pause_opt; // From m_misc.c
|
||||
extern bool mus_on;
|
||||
|
@ -170,6 +203,8 @@ extern bool mus_on;
|
|||
- (IBAction) MusicChanged {
|
||||
if ( !SysIPhoneOtherAudioIsPlaying() ) {
|
||||
Cvar_SetValue( music->name, !music->value );
|
||||
// NSLog(@"DOOM: MusicChanged: %f", music->value);
|
||||
[self setValues];
|
||||
if ( music->value ) {
|
||||
mus_on = true;
|
||||
mus_pause_opt = 1;
|
||||
|
@ -190,6 +225,8 @@ extern bool mus_on;
|
|||
*/
|
||||
- (IBAction) CenterSticksChanged {
|
||||
Cvar_SetValue( centerSticks->name, !centerSticks->value );
|
||||
// NSLog(@"DOOM: CenterSticksChanged: %f", centerSticks->value);
|
||||
[self setValues];
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -199,6 +236,54 @@ extern bool mus_on;
|
|||
*/
|
||||
- (IBAction) RampTurnChanged {
|
||||
Cvar_SetValue( rampTurn->name, !rampTurn->value );
|
||||
// NSLog(@"DOOM: RampTurnChanged: %f", rampTurn->value);
|
||||
[self setValues];
|
||||
}
|
||||
|
||||
#if TARGET_OS_TV
|
||||
|
||||
- (void)didUpdateFocusInContext:(UIFocusUpdateContext *)context withAnimationCoordinator:(UIFocusAnimationCoordinator *)coordinator {
|
||||
NSLog(@"DOOM: %@", context.nextFocusedView);
|
||||
NSLog(@"DOOM: %@", context.previouslyFocusedView);
|
||||
|
||||
[super didUpdateFocusInContext:context withAnimationCoordinator:coordinator];
|
||||
|
||||
if ([context.nextFocusedView isKindOfClass:[idSwitch class]]) {
|
||||
|
||||
if (context.nextFocusedView.tag > 0) {
|
||||
|
||||
autoUseSelection.hidden = YES;
|
||||
statusbarSelection.hidden = YES;
|
||||
touchclickSelection.hidden = YES;
|
||||
textMessageSelection.hidden = YES;
|
||||
drawControlsSelection.hidden = YES;
|
||||
musicSelection.hidden = YES;
|
||||
centerSticksSelection.hidden = YES;
|
||||
rampTurnSelection.hidden = YES;
|
||||
|
||||
if (context.nextFocusedView.tag == 1) {
|
||||
autoUseSelection.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 2) {
|
||||
statusbarSelection.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 3) {
|
||||
touchclickSelection.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 4) {
|
||||
textMessageSelection.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 5) {
|
||||
drawControlsSelection.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 6) {
|
||||
musicSelection.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 7) {
|
||||
centerSticksSelection.hidden = NO;
|
||||
} else if (context.nextFocusedView.tag == 8) {
|
||||
rampTurnSelection.hidden = NO;
|
||||
}
|
||||
}
|
||||
|
||||
[self setValues];
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
|
|
@ -1,20 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="3.0" toolsVersion="13771" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14109" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<device id="ipad9_7" orientation="portrait">
|
||||
<adaptation id="fullscreen"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13772"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
|
||||
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<customFonts key="customFonts">
|
||||
<array key="Helvetica.ttc">
|
||||
<string>Helvetica</string>
|
||||
<string>Helvetica-Bold</string>
|
||||
</array>
|
||||
</customFonts>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="Doom_SettingsMenuViewController">
|
||||
<connections>
|
||||
|
|
|
@ -1464,6 +1464,8 @@ class OpenALObject
|
|||
extern "C"
|
||||
void interruptionCallback(void* arg, UInt32 interruptionState)
|
||||
{
|
||||
#if !TARGET_OS_TV
|
||||
|
||||
(void)arg;
|
||||
|
||||
printf("Excuse this interruption...\n");
|
||||
|
@ -1481,6 +1483,7 @@ void interruptionCallback(void* arg, UInt32 interruptionState)
|
|||
// gInterrupted = false;
|
||||
// break;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
@ -1505,7 +1508,8 @@ OSStatus SoundEngine_Initialize(Float32 inMixerOutputRate)
|
|||
if(gInterrupted)
|
||||
return noErr;
|
||||
|
||||
if( !isInitialized )
|
||||
#if !TARGET_OS_TV
|
||||
if( !isInitialized )
|
||||
{
|
||||
printf("WARNING! Sound engine was not initialized!\n");
|
||||
//FIXME: JadingTsunami (fix) AudioSessionInitialize( NULL, NULL, interruptionCallback, NULL );
|
||||
|
@ -1513,7 +1517,9 @@ OSStatus SoundEngine_Initialize(Float32 inMixerOutputRate)
|
|||
// AudioSessionSetProperty( kAudioSessionProperty_AudioCategory, sizeof( sessionCategory ), &sessionCategory );
|
||||
isInitialized = true;
|
||||
}
|
||||
|
||||
#else
|
||||
(void)isInitialized;
|
||||
#endif
|
||||
if (sOpenALObject)
|
||||
delete sOpenALObject;
|
||||
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
*/
|
||||
|
||||
#include "doomiphone.h"
|
||||
#include "TargetConditionals.h"
|
||||
#include <math.h>
|
||||
|
||||
hud_t huds;
|
||||
|
@ -67,6 +68,7 @@ void SetHudSpot( ibutton_t *hp, int x, int y, int dw, int dh ) {
|
|||
}
|
||||
|
||||
void HudSetTexnums() {
|
||||
|
||||
SetHudPic( &huds.forwardStick, "iphone/up_down.tga" );
|
||||
SetHudPic( &huds.sideStick, "iphone/side_2_side.tga" );
|
||||
SetHudPic( &huds.turnStick, "iphone/directional_2.tga" );
|
||||
|
@ -79,6 +81,7 @@ void HudSetTexnums() {
|
|||
}
|
||||
|
||||
void HudSetForScheme( int schemeNum ) {
|
||||
|
||||
for ( ibutton_t *hud = (ibutton_t *)&huds ; hud != (ibutton_t *)(&huds+1) ; hud++ ) {
|
||||
hud->buttonFlags = BF_IGNORE;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"layers" : [
|
||||
{
|
||||
"filename" : "Middle.imagestacklayer"
|
||||
},
|
||||
{
|
||||
"filename" : "Back.imagestacklayer"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"filename" : "doom_tv_back.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 179 KiB |
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
"layers" : [
|
||||
{
|
||||
"filename" : "Front.imagestacklayer"
|
||||
},
|
||||
{
|
||||
"filename" : "Middle.imagestacklayer"
|
||||
},
|
||||
{
|
||||
"filename" : "Back.imagestacklayer"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"filename" : "doom_tv_front.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 106 KiB |
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"filename" : "doom_tv_middle.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 98 KiB |
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
32
code/iphone/icons.xcassets/Brand Assets.brandassets/Contents.json
Executable file
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
"assets" : [
|
||||
{
|
||||
"size" : "1280x768",
|
||||
"idiom" : "tv",
|
||||
"filename" : "App Icon - Large.imagestack",
|
||||
"role" : "primary-app-icon"
|
||||
},
|
||||
{
|
||||
"size" : "400x240",
|
||||
"idiom" : "tv",
|
||||
"filename" : "App Icon - Small.imagestack",
|
||||
"role" : "primary-app-icon"
|
||||
},
|
||||
{
|
||||
"size" : "2320x720",
|
||||
"idiom" : "tv",
|
||||
"filename" : "Top Shelf Image Wide.imageset",
|
||||
"role" : "top-shelf-image-wide"
|
||||
},
|
||||
{
|
||||
"size" : "1920x720",
|
||||
"idiom" : "tv",
|
||||
"filename" : "Top Shelf Image.imageset",
|
||||
"role" : "top-shelf-image"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
16
code/iphone/icons.xcassets/Brand Assets.brandassets/Top Shelf Image Wide.imageset/Contents.json
vendored
Executable file
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
17
code/iphone/icons.xcassets/Brand Assets.brandassets/Top Shelf Image.imageset/Contents.json
vendored
Executable file
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"filename" : "doom_banner_2.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "tv",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
BIN
code/iphone/icons.xcassets/Brand Assets.brandassets/Top Shelf Image.imageset/doom_banner_2.png
vendored
Normal file
After Width: | Height: | Size: 3 MiB |
6
code/iphone/icons.xcassets/Contents.json
Executable file
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"orientation" : "landscape",
|
||||
"idiom" : "tv",
|
||||
"extent" : "full-screen",
|
||||
"minimum-system-version" : "11.0",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"orientation" : "landscape",
|
||||
"idiom" : "tv",
|
||||
"filename" : "doom_tv_launch.png",
|
||||
"extent" : "full-screen",
|
||||
"minimum-system-version" : "9.0",
|
||||
"scale" : "1x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 2.9 KiB |
|
@ -29,6 +29,7 @@
|
|||
|
||||
#include "doomiphone.h"
|
||||
//#include "DoomGameCenterMatch.h"
|
||||
#include "TargetConditionals.h"
|
||||
|
||||
//#include "ios/GameCenter.h"
|
||||
|
||||
|
@ -552,6 +553,7 @@ static void iphoneBuildTiccmd(ticcmd_t* cmd) {
|
|||
if ( numTouches == numPrevTouches + 1 ) {
|
||||
cmd->buttons |= BT_ATTACK;
|
||||
}
|
||||
iphoneControllerInput(cmd);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -562,7 +564,21 @@ static void iphoneBuildTiccmd(ticcmd_t* cmd) {
|
|||
|
||||
// don't built a tic when dead, other than the respawn use
|
||||
if ( players[consoleplayer].playerstate == PST_DEAD ) {
|
||||
return;
|
||||
#if TARGET_OS_TV
|
||||
// unless we're on apple tv
|
||||
iphoneControllerInput(cmd);
|
||||
|
||||
// just to keep things simple all we can do is respawn
|
||||
// load saved game and respawn with gear are not possible
|
||||
// may re-evaluate this later but for now this is a tv change
|
||||
if (cmd->buttons & BT_USE) {
|
||||
players[consoleplayer].playerstate = PST_REBORN;
|
||||
}
|
||||
|
||||
return;
|
||||
#else
|
||||
return;
|
||||
#endif
|
||||
}
|
||||
|
||||
//------------------------
|
||||
|
|
|
@ -24,8 +24,12 @@
|
|||
|
||||
@class EAGLView;
|
||||
|
||||
@interface iphoneApp : NSObject <UIApplicationDelegate, UIAccelerometerDelegate> {
|
||||
|
||||
#if TARGET_OS_TV
|
||||
@interface iphoneApp : NSObject <UIApplicationDelegate> {
|
||||
#else
|
||||
@interface iphoneApp : NSObject <UIApplicationDelegate, UIAccelerometerDelegate> {
|
||||
#endif
|
||||
|
||||
UIWindow * window; // Main Application Window.
|
||||
UINavigationController * navigationController; // Our View Stack
|
||||
iphone_glViewController * openGLViewController; // our OpenGL (Game) View
|
||||
|
@ -46,5 +50,7 @@ extern iphoneApp * gAppDelegate;
|
|||
- (void) HideGLView;
|
||||
- (void) PopGLView;
|
||||
|
||||
- (NSString*) GetNibNameForDevice:(NSString*) nibName;
|
||||
|
||||
@end
|
||||
|
||||
|
|
|
@ -40,6 +40,9 @@ touch_t sysTouches[MAX_TOUCHES];
|
|||
touch_t gameTouches[MAX_TOUCHES];
|
||||
|
||||
#define FRAME_HERTZ 30.0f
|
||||
#if !TARGET_OS_TV
|
||||
const static float ACCELEROMETER_UPDATE_INTERVAL = 1.0f / FRAME_HERTZ;
|
||||
#endif
|
||||
//FIXME: JadingTsunami (fix) const static float ACCELEROMETER_UPDATE_INTERVAL = 1.0f / FRAME_HERTZ;
|
||||
|
||||
/*
|
||||
|
@ -59,6 +62,8 @@ touch_t gameTouches[MAX_TOUCHES];
|
|||
// Disable Screen Dimming.
|
||||
[[ UIApplication sharedApplication] setIdleTimerDisabled: YES ];
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
|
||||
// Initial Application Style config.
|
||||
[UIApplication sharedApplication].statusBarHidden = YES;
|
||||
|
||||
|
@ -69,6 +74,8 @@ touch_t gameTouches[MAX_TOUCHES];
|
|||
[ accelerometer setUpdateInterval: ACCELEROMETER_UPDATE_INTERVAL ];
|
||||
*/
|
||||
|
||||
#endif
|
||||
|
||||
[self InitializeInterfaceBuilder ];
|
||||
|
||||
CommonSystemSetup( [navigationController topViewController] );
|
||||
|
@ -145,6 +152,8 @@ touch_t gameTouches[MAX_TOUCHES];
|
|||
[super dealloc];
|
||||
}
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
|
||||
/*
|
||||
========================
|
||||
accelerometer
|
||||
|
@ -161,7 +170,9 @@ touch_t gameTouches[MAX_TOUCHES];
|
|||
iphoneTiltEvent( acc );
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
========================
|
||||
HACK_PushController - Removes Flicker from Loading Wads.
|
||||
|
@ -220,6 +231,17 @@ touch_t gameTouches[MAX_TOUCHES];
|
|||
|
||||
}
|
||||
|
||||
- (NSString*) GetNibNameForDevice:(NSString*) nibName
|
||||
{
|
||||
NSString *extension = @"";
|
||||
|
||||
#if TARGET_OS_TV
|
||||
extension = @"-tvos";
|
||||
#endif
|
||||
|
||||
return [NSString stringWithFormat:@"%@%@", nibName, extension];
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
void ShowGLView( void ) {
|
||||
|
|
|
@ -34,8 +34,10 @@
|
|||
- (bool) IsDisplaying;
|
||||
|
||||
// JDS revised orientation code
|
||||
#if !TARGET_OS_TV
|
||||
-(BOOL)shouldAutorotate;
|
||||
- (UIInterfaceOrientation)preferredInterfaceOrientationForPresentation;
|
||||
- (UIInterfaceOrientationMask)supportedInterfaceOrientations;
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
|
|
@ -21,8 +21,13 @@
|
|||
#import "EAGLView.h"
|
||||
#import <QuartzCore/CADisplayLink.h>
|
||||
#include "doomiphone.h"
|
||||
#include "iphone_delegate.h"
|
||||
|
||||
#if TARGET_OS_TV
|
||||
const static int DISPLAY_LINK_FRAME_INTERVAL = 30;
|
||||
#else
|
||||
const static int DISPLAY_LINK_FRAME_INTERVAL = 2;
|
||||
#endif
|
||||
|
||||
// Need one buffer frame when transitioning from IB menus to the OpenGL game view.
|
||||
// Otherwise, occasionally the IB view stays onscreen during the Doom loading frame.
|
||||
|
@ -66,14 +71,22 @@ static bool inTransition = false;
|
|||
if (self) {
|
||||
|
||||
// Create the OpenGL View.
|
||||
#if TARGET_OS_TV
|
||||
EAGLView *glView = [[EAGLView alloc] initWithFrame:[UIScreen mainScreen].bounds];
|
||||
#else
|
||||
EAGLView *glView = [[EAGLView alloc] initWithFrame:[UIScreen mainScreen].applicationFrame];
|
||||
#endif
|
||||
self.view = glView;
|
||||
[glView release];
|
||||
|
||||
|
||||
// Setup the Display Link
|
||||
CADisplayLink *aDisplayLink = [CADisplayLink displayLinkWithTarget:self selector:@selector(runFrame)];
|
||||
#if TARGET_OS_TV
|
||||
aDisplayLink.preferredFramesPerSecond= DISPLAY_LINK_FRAME_INTERVAL;
|
||||
#else
|
||||
[ aDisplayLink setFrameInterval: DISPLAY_LINK_FRAME_INTERVAL];
|
||||
#endif
|
||||
[ aDisplayLink addToRunLoop:[NSRunLoop currentRunLoop] forMode:NSDefaultRunLoopMode];
|
||||
[ self setDisplayLink: aDisplayLink ];
|
||||
|
||||
|
@ -92,6 +105,7 @@ shouldAutorotateToInterfaceOrientation
|
|||
}
|
||||
*/
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
- (BOOL)shouldAutorotate {
|
||||
return NO;
|
||||
}
|
||||
|
@ -103,6 +117,7 @@ shouldAutorotateToInterfaceOrientation
|
|||
- (UIInterfaceOrientationMask)supportedInterfaceOrientations {
|
||||
return UIInterfaceOrientationMaskLandscape;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
|
@ -149,6 +164,14 @@ shouldAutorotateToInterfaceOrientation
|
|||
[super dealloc];
|
||||
}
|
||||
|
||||
- (void)viewWillDisappear:(BOOL)animated {
|
||||
[super viewWillDisappear:animated];
|
||||
|
||||
#if TARGET_OS_TV
|
||||
[ gAppDelegate HideGLView ];
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
========================
|
||||
StartDisplay
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
*/
|
||||
|
||||
#include "doomiphone.h"
|
||||
#include "TargetConditionals.h"
|
||||
|
||||
playState_t playState;
|
||||
|
||||
|
@ -894,6 +895,11 @@ void iphoneDrawRotorControl( ibutton_t *hud ) {
|
|||
|
||||
|
||||
void iphoneDrawHudControl( ibutton_t *hud ) {
|
||||
|
||||
if (TARGET_OS_TV) {
|
||||
return;
|
||||
}
|
||||
|
||||
if ( hud->buttonFlags & BF_IGNORE ) {
|
||||
return;
|
||||
}
|
||||
|
@ -1513,8 +1519,9 @@ void iphoneFrame() {
|
|||
// this probably doesn't need to be tic-synced, but it doesn't hurt
|
||||
if (players[displayplayer].mo) {
|
||||
// move positional sounds and free up channels that have completed
|
||||
S_UpdateSounds(players[displayplayer].mo);
|
||||
}
|
||||
//GUS temporarily removed
|
||||
//S_UpdateSounds(players[displayplayer].mo);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1599,11 +1606,17 @@ void iphoneDrawScreen() {
|
|||
if ( statusBar->modified ) {
|
||||
statusBar->modified = false;
|
||||
|
||||
if ( statusBar->value ) {
|
||||
R_SetViewSize( 10 );
|
||||
} else {
|
||||
R_SetViewSize( 11 );
|
||||
}
|
||||
if ( statusBar->value ) {
|
||||
R_SetViewSize( 10 );
|
||||
hud_displayed = 0;
|
||||
hud_active = 0;
|
||||
hud_distributed = 0;
|
||||
} else {
|
||||
R_SetViewSize( 11 );
|
||||
hud_displayed = 1;
|
||||
hud_active = 2;
|
||||
hud_distributed = 1;
|
||||
}
|
||||
}
|
||||
|
||||
//------------------------------------------------
|
||||
|
@ -1675,12 +1688,25 @@ void iphoneDrawScreen() {
|
|||
if ( players[consoleplayer].playerstate == PST_DEAD ) {
|
||||
// when dead, only show the main menu con and the
|
||||
// respawn / load game icons
|
||||
#if !TARGET_OS_TV
|
||||
if ( HandleButton( &huds.menu ) ) {
|
||||
iphonePauseMusic();
|
||||
menuState = IPM_MAIN;
|
||||
iphoneMainMenu();
|
||||
}
|
||||
#endif
|
||||
if ( !deathmatch && !netgame ) {
|
||||
|
||||
// for now we're going to not draw these on the screen for the TV version
|
||||
// all you can do is respawn with the USE button (A)
|
||||
|
||||
#if TARGET_OS_TV
|
||||
static ibutton_t btnRespawn;
|
||||
SetButtonPicsAndSizes( &btnRespawn, "iphone/respawn.tga", "Press A to restart", 240 - 48, 80, 96, 96 );
|
||||
if ( HandleButton( &btnRespawn ) ) {
|
||||
// players[consoleplayer].playerstate = PST_REBORN;
|
||||
}
|
||||
#else
|
||||
static ibutton_t btnSaved;
|
||||
static ibutton_t btnRespawn;
|
||||
static ibutton_t btnGear;
|
||||
|
@ -1702,6 +1728,7 @@ void iphoneDrawScreen() {
|
|||
players[consoleplayer].playerstate = PST_REBORN;
|
||||
addGear = true;
|
||||
}
|
||||
#endif
|
||||
} else {
|
||||
static ibutton_t btnNetRespawn;
|
||||
if ( !btnNetRespawn.texture ) {
|
||||
|
@ -1724,17 +1751,20 @@ void iphoneDrawScreen() {
|
|||
iphoneDrawRotorControl( &huds.turnRotor );
|
||||
// iphoneDrawHudControl( &huds.fire );
|
||||
}
|
||||
|
||||
if ( HandleButton( &huds.menu ) ) {
|
||||
iphonePauseMusic();
|
||||
menuState = IPM_MAIN;
|
||||
iphoneMainMenu();
|
||||
}
|
||||
if ( HandleButton( &huds.map ) ) {
|
||||
AM_Start();
|
||||
}
|
||||
if ( HandleButton( &huds.fire ) ) {
|
||||
}
|
||||
|
||||
if (!TARGET_OS_TV) {
|
||||
|
||||
if ( HandleButton( &huds.menu ) ) {
|
||||
iphonePauseMusic();
|
||||
menuState = IPM_MAIN;
|
||||
iphoneMainMenu();
|
||||
}
|
||||
if ( HandleButton( &huds.map ) ) {
|
||||
AM_Start();
|
||||
}
|
||||
if ( HandleButton( &huds.fire ) ) {
|
||||
}
|
||||
}
|
||||
|
||||
if ( netgame ) {
|
||||
#if 0
|
||||
|
|
|
@ -51,14 +51,20 @@ static ALCdevice *Device;
|
|||
}
|
||||
- (void)registerInterruptionListener {
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
[[NSNotificationCenter defaultCenter] addObserver:self
|
||||
selector:@selector(handleAudioSessionInterruption:)
|
||||
name:AVAudioSessionInterruptionNotification
|
||||
object:[AVAudioSession sharedInstance]];
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
- (void)handleAudioSessionInterruption:(NSNotification *)notification {
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
|
||||
|
||||
NSDictionary *interruptionDict = notification.userInfo;
|
||||
NSInteger interruptionType = [[interruptionDict valueForKey:AVAudioSessionInterruptionTypeKey] integerValue];
|
||||
printf("Session interrupted! --- %s ---\n", interruptionType == AVAudioSessionInterruptionTypeBegan ? "Begin Interruption" : "End Interruption");
|
||||
|
@ -135,6 +141,8 @@ static ALCdevice *Device;
|
|||
iphoneResumeMusic();
|
||||
}
|
||||
*/
|
||||
|
||||
#endif
|
||||
}
|
||||
@end
|
||||
|
||||
|
@ -194,6 +202,7 @@ void Sound_Init(void) {
|
|||
|
||||
Cmd_AddCommand( "play", Sound_Play_f );
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
// make sure background ipod music mixes with our sound effects
|
||||
Com_Printf( "...Initializing AudioSession\n" );
|
||||
|
||||
|
@ -239,7 +248,8 @@ void Sound_Init(void) {
|
|||
NSLog(@"%@", error);
|
||||
}
|
||||
//JDS deprecated status = AudioSessionSetActive(true); // else "couldn't set audio session active\n"
|
||||
|
||||
#endif
|
||||
|
||||
Com_Printf( "...Initializing OpenAL subsystem\n" );
|
||||
|
||||
// get the OpenAL device
|
||||
|
|
|
@ -61,6 +61,19 @@ void ResumeGame() {
|
|||
advancedemo = false;
|
||||
menuState = IPM_GAME;
|
||||
lastState = IPM_GAME;
|
||||
|
||||
if ( statusBar->value ) {
|
||||
R_SetViewSize( 10 );
|
||||
hud_displayed = 0;
|
||||
hud_active = 0;
|
||||
hud_distributed = 0;
|
||||
} else {
|
||||
R_SetViewSize( 11 );
|
||||
hud_displayed = 1;
|
||||
hud_active = 2;
|
||||
hud_distributed = 1;
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -117,7 +130,18 @@ void GameSetup() {
|
|||
consoleplayer = 0;
|
||||
displayplayer = 0;
|
||||
playeringame[consoleplayer] = 1;
|
||||
}
|
||||
|
||||
if ( statusBar->value ) {
|
||||
R_SetViewSize( 10 );
|
||||
hud_displayed = 0;
|
||||
hud_active = 0;
|
||||
hud_distributed = 0;
|
||||
} else {
|
||||
R_SetViewSize( 11 );
|
||||
hud_displayed = 1;
|
||||
hud_active = 2;
|
||||
hud_distributed = 1;
|
||||
}}
|
||||
|
||||
/*
|
||||
=======================
|
||||
|
|
|
@ -70,14 +70,20 @@ void SysIPhoneVibrate() {
|
|||
|
||||
|
||||
void SysIPhoneOpenURL( const char *url ) {
|
||||
#if !TARGET_OS_TV
|
||||
Com_Printf( "OpenURL char *: %s\n", url );
|
||||
|
||||
NSString *nss = [NSString stringWithCString: url encoding: NSASCIIStringEncoding];
|
||||
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: nss]];
|
||||
#endif
|
||||
}
|
||||
|
||||
int SysIPhoneIsDeviceLandscapeRight( void ) {
|
||||
#if TARGET_OS_TV
|
||||
return 0;
|
||||
#else
|
||||
return [UIDevice currentDevice].orientation == UIDeviceOrientationLandscapeRight;
|
||||
#endif
|
||||
}
|
||||
|
||||
void SysIPhoneSetUIKitOrientation( int isLandscapeRight ) {
|
||||
|
|
|
@ -1528,6 +1528,9 @@ void G_LoadGame(int slot, boolean command)
|
|||
} else {
|
||||
// Do the old thing, immediate load
|
||||
gameaction = ga_loadgame;
|
||||
//#warning FIXME checksum: was false, but issues when loading savegames (checksum seems to be different)
|
||||
// forced_loadgame = true;
|
||||
// MAY NEED TVOS FIXES? -tkidd
|
||||
forced_loadgame = false;
|
||||
savegameslot = slot;
|
||||
demoplayback = false;
|
||||
|
|
|
@ -2667,7 +2667,7 @@ static void gld_DrawSprite(GLSprite *sprite)
|
|||
|
||||
// transparent sprites blend and don't write to the depth buffer
|
||||
glEnable( GL_BLEND );
|
||||
glDepthMask( 0 );
|
||||
// glDepthMask( 0 );
|
||||
|
||||
glEnable( GL_ALPHA_TEST );
|
||||
|
||||
|
@ -2707,7 +2707,7 @@ static void gld_DrawSprite(GLSprite *sprite)
|
|||
}
|
||||
|
||||
glDisable( GL_ALPHA_TEST );
|
||||
glDepthMask( 1 );
|
||||
// glDepthMask( 1 );
|
||||
}
|
||||
|
||||
void gld_AddSprite(vissprite_t *vspr)
|
||||
|
|
|
@ -158,7 +158,7 @@ void T_VerticalDoor (vldoor_t* door)
|
|||
break;
|
||||
|
||||
case normal:
|
||||
case close:
|
||||
case closeDoor:
|
||||
case genRaise:
|
||||
case genClose:
|
||||
door->sector->ceilingdata = NULL; //jff 2/22/98
|
||||
|
@ -195,7 +195,7 @@ void T_VerticalDoor (vldoor_t* door)
|
|||
case genClose:
|
||||
case genBlazeClose:
|
||||
case blazeClose:
|
||||
case close: // Close types do not bounce, merely wait
|
||||
case closeDoor: // Close types do not bounce, merely wait
|
||||
break;
|
||||
|
||||
case blazeRaise:
|
||||
|
@ -252,7 +252,7 @@ void T_VerticalDoor (vldoor_t* door)
|
|||
|
||||
case close30ThenOpen: // close and close/open doors are done
|
||||
case blazeOpen:
|
||||
case open:
|
||||
case openDoor:
|
||||
case genBlazeOpen:
|
||||
case genOpen:
|
||||
case genCdO:
|
||||
|
@ -395,7 +395,7 @@ int EV_DoDoor
|
|||
S_StartSound((mobj_t *)&door->sector->soundorg,sfx_bdcls);
|
||||
break;
|
||||
|
||||
case close:
|
||||
case closeDoor:
|
||||
door->topheight = P_FindLowestCeilingSurrounding(sec);
|
||||
door->topheight -= 4*FRACUNIT;
|
||||
door->direction = -1;
|
||||
|
@ -419,7 +419,7 @@ int EV_DoDoor
|
|||
break;
|
||||
|
||||
case normal:
|
||||
case open:
|
||||
case openDoor:
|
||||
door->direction = 1;
|
||||
door->topheight = P_FindLowestCeilingSurrounding(sec);
|
||||
door->topheight -= 4*FRACUNIT;
|
||||
|
@ -613,7 +613,7 @@ int EV_VerticalDoor
|
|||
case 32:
|
||||
case 33:
|
||||
case 34:
|
||||
door->type = open;
|
||||
door->type = openDoor;
|
||||
line->special = 0;
|
||||
break;
|
||||
|
||||
|
|
|
@ -1027,7 +1027,7 @@ void A_KeenDie(mobj_t* mo)
|
|||
}
|
||||
|
||||
junk.tag = 666;
|
||||
EV_DoDoor(&junk,open);
|
||||
EV_DoDoor(&junk,openDoor);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -918,6 +918,9 @@ void P_RemoveMobj (mobj_t* mobj)
|
|||
|
||||
// stop any playing sound
|
||||
|
||||
// GUS temporarily disable
|
||||
//S_StopSound (mobj);
|
||||
// MAY NEED TVOS STUFF HERE -tkidd
|
||||
S_StopSound (mobj);
|
||||
|
||||
// killough 11/98:
|
||||
|
|
|
@ -1265,13 +1265,13 @@ void P_CrossSpecialLine(line_t *line, int side, mobj_t *thing)
|
|||
|
||||
case 2:
|
||||
// Open Door
|
||||
if (EV_DoDoor(line,open) || demo_compatibility)
|
||||
if (EV_DoDoor(line,openDoor) || demo_compatibility)
|
||||
line->special = 0;
|
||||
break;
|
||||
|
||||
case 3:
|
||||
// Close Door
|
||||
if (EV_DoDoor(line,close) || demo_compatibility)
|
||||
if (EV_DoDoor(line,closeDoor) || demo_compatibility)
|
||||
line->special = 0;
|
||||
break;
|
||||
|
||||
|
@ -1534,7 +1534,7 @@ void P_CrossSpecialLine(line_t *line, int side, mobj_t *thing)
|
|||
|
||||
case 75:
|
||||
// Close Door
|
||||
EV_DoDoor(line,close);
|
||||
EV_DoDoor(line,closeDoor);
|
||||
break;
|
||||
|
||||
case 76:
|
||||
|
@ -1579,7 +1579,7 @@ void P_CrossSpecialLine(line_t *line, int side, mobj_t *thing)
|
|||
|
||||
case 86:
|
||||
// Open Door
|
||||
EV_DoDoor(line,open);
|
||||
EV_DoDoor(line,openDoor);
|
||||
break;
|
||||
|
||||
case 87:
|
||||
|
@ -2134,7 +2134,7 @@ void P_ShootSpecialLine
|
|||
|
||||
case 46:
|
||||
// 46 GR open door, stay open
|
||||
EV_DoDoor(line,open);
|
||||
EV_DoDoor(line,openDoor);
|
||||
P_ChangeSwitchTexture(line,1);
|
||||
break;
|
||||
|
||||
|
|
4
code/prboom/p_spec.h
Normal file → Executable file
|
@ -366,8 +366,8 @@ typedef enum
|
|||
{
|
||||
normal,
|
||||
close30ThenOpen,
|
||||
close,
|
||||
open,
|
||||
closeDoor,
|
||||
openDoor,
|
||||
raiseIn5Mins,
|
||||
blazeRaise,
|
||||
blazeOpen,
|
||||
|
|
8
code/prboom/p_switch.c
Normal file → Executable file
|
@ -494,7 +494,7 @@ P_UseSpecialLine
|
|||
|
||||
case 50:
|
||||
// Close Door
|
||||
if (EV_DoDoor(line,close))
|
||||
if (EV_DoDoor(line,closeDoor))
|
||||
P_ChangeSwitchTexture(line,0);
|
||||
break;
|
||||
|
||||
|
@ -532,7 +532,7 @@ P_UseSpecialLine
|
|||
|
||||
case 103:
|
||||
// Open Door
|
||||
if (EV_DoDoor(line,open))
|
||||
if (EV_DoDoor(line,openDoor))
|
||||
P_ChangeSwitchTexture(line,0);
|
||||
break;
|
||||
|
||||
|
@ -1021,7 +1021,7 @@ P_UseSpecialLine
|
|||
// Buttons (retriggerable switches)
|
||||
case 42:
|
||||
// Close Door
|
||||
if (EV_DoDoor(line,close))
|
||||
if (EV_DoDoor(line,closeDoor))
|
||||
P_ChangeSwitchTexture(line,1);
|
||||
break;
|
||||
|
||||
|
@ -1045,7 +1045,7 @@ P_UseSpecialLine
|
|||
|
||||
case 61:
|
||||
// Open Door
|
||||
if (EV_DoDoor(line,open))
|
||||
if (EV_DoDoor(line,openDoor))
|
||||
P_ChangeSwitchTexture(line,1);
|
||||
break;
|
||||
|
||||
|
|
|
@ -175,6 +175,9 @@ void S_Start(void)
|
|||
// kill all playing sounds at start of level
|
||||
// (trust me - a good idea)
|
||||
|
||||
//S_Stop();
|
||||
//Gus Temporarily Disable
|
||||
// MAY NEED TVOS STUFF HERE -tkidd
|
||||
S_Stop();
|
||||
|
||||
//jff 1/22/98 return if music is not enabled
|
||||
|
|