Compare commits

...

15 Commits
1.1 ... master

Author SHA1 Message Date
Jeremy Rand
1930afd723 Update to the latest build engine. 2019-08-09 22:47:10 -04:00
Jeremy Rand
16dcc0afb0 Add support for cc65 2.17. 2018-10-17 23:55:09 -04:00
Jeremy Rand
b656515517 Update the build engine to support capturing build errors in Xcode itself. 2018-06-25 23:06:30 -04:00
Jeremy Rand
136314f3e1 Migrate to the new build engine. 2018-06-20 00:18:20 -04:00
Jeremy Rand
7844a867cf Update the readme. 2017-08-09 22:50:33 -04:00
Jeremy Rand
8c3f60dba8 Bump the version number. 2017-08-09 22:32:15 -04:00
Jeremy Rand
dffb5cc56e Fix problem where a floor off the left side of the screen was not being skipped as a potential floor to land on. 2017-08-09 22:31:54 -04:00
Jeremy Rand
5f3a76f4f2 Fix problem where sometimes the right cap of a floor is not correctly cleared as it scrolls off the screen. The problem is that we need to delay moving the grid along to the next floor until after the old base grid has been fully cleared. 2017-08-09 22:19:51 -04:00
Jeremy Rand
f7d4216224 Remove the interruptor export for the IRQ callback. 2017-08-08 23:34:43 -04:00
Jeremy Rand
e8150ba717 Draw the left cap as a floor scrolls in from the right correctly. 2017-08-08 23:28:06 -04:00
Jeremy Rand
5b686d5b47 Fix the drawing of the left cap to simplify the code and fix some drawing glitches. 2017-08-08 23:20:31 -04:00
Jeremy Rand
abb01d1dfd Adjust the point where the character starts to fall off the right edge of the floor. 2017-08-08 22:30:13 -04:00
Jeremy Rand
1c735c547d Fix bugs related to correctly detecting the floor underneath the runner when close to the left edge. General code cleanup. 2017-08-05 23:14:25 -04:00
Jeremy Rand
eec795b42f Update the readme with a link to the new release. 2017-07-21 23:24:13 -05:00
Jeremy Rand
7012b0080d Fix problem where we started from level 3 instead of level 1. 2017-07-21 23:20:58 -05:00
24 changed files with 1331 additions and 747 deletions

21
LICENSE Normal file
View File

@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2019 Jeremy Rand
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@ -1,4 +1,4 @@
# colourgo
A game in the spirit of Chameleon Run for the Apple //. It is my HackFest entry for KansasFest 2017.
[Download a disk image](https://github.com/jeremysrand/colourgo/releases/download/1.0/colourgo.dsk)
[Download a disk image](https://github.com/jeremysrand/colourgo/releases/download/1.5/colourgo.dsk)

View File

@ -3,90 +3,167 @@
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objectVersion = 50;
objects = {
/* Begin PBXBuildFile section */
9DD31AFB22FE661A00F65886 /* Makefile in Sources */ = {isa = PBXBuildFile; fileRef = 9DD31AFA22FE661A00F65886 /* Makefile */; };
9DD31AFE22FE661A00F65886 /* AppleCommander.jar in Frameworks */ = {isa = PBXBuildFile; fileRef = 9DD31AFD22FE661A00F65886 /* AppleCommander.jar */; };
9DD31B0022FE661A00F65886 /* bastokenizer-tools-bt-0.2.0.jar in Frameworks */ = {isa = PBXBuildFile; fileRef = 9DD31AFF22FE661A00F65886 /* bastokenizer-tools-bt-0.2.0.jar */; };
9DD31B0222FE661A00F65886 /* createDiskImage in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0122FE661A00F65886 /* createDiskImage */; };
9DD31B0422FE661A00F65886 /* bt in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0322FE661A00F65886 /* bt */; };
9DD31B0622FE661A00F65886 /* DevApple.vii in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0522FE661A00F65886 /* DevApple.vii */; };
9DD31B0822FE661A00F65886 /* dos33_template.dsk in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0722FE661A00F65886 /* dos33_template.dsk */; };
9DD31B0A22FE661A00F65886 /* errorFilter.sh in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0922FE661A00F65886 /* errorFilter.sh */; };
9DD31B0C22FE661A00F65886 /* head.mk in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0B22FE661A00F65886 /* head.mk */; };
9DD31B0E22FE661A00F65886 /* prodos_template.dsk in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0D22FE661A00F65886 /* prodos_template.dsk */; };
9DD31B1022FE661A00F65886 /* tail.mk in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B0F22FE661A00F65886 /* tail.mk */; };
9DD31B1222FE661A00F65886 /* V2Make.scpt in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B1122FE661A00F65886 /* V2Make.scpt */; };
9DD31B1522FE661A00F65886 /* colourgo.xcscheme in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9DD31B1422FE661A00F65886 /* colourgo.xcscheme */; };
9DD31B2F22FE667000F65886 /* main.c in Sources */ = {isa = PBXBuildFile; fileRef = 9DD31B2622FE666F00F65886 /* main.c */; };
9DD31B3022FE667000F65886 /* game.s in Sources */ = {isa = PBXBuildFile; fileRef = 9DD31B2822FE666F00F65886 /* game.s */; };
9DD31B3122FE667000F65886 /* mouseWrapper.c in Sources */ = {isa = PBXBuildFile; fileRef = 9DD31B2A22FE666F00F65886 /* mouseWrapper.c */; };
9DD31B3222FE667000F65886 /* machine.c in Sources */ = {isa = PBXBuildFile; fileRef = 9DD31B2B22FE666F00F65886 /* machine.c */; };
9DD31B3322FE667000F65886 /* vbl.s in Sources */ = {isa = PBXBuildFile; fileRef = 9DD31B2D22FE666F00F65886 /* vbl.s */; };
/* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */
9DD31AF422FE661A00F65886 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = /usr/share/man/man1/;
dstSubfolderSpec = 0;
files = (
9DD31B0E22FE661A00F65886 /* prodos_template.dsk in CopyFiles */,
9DD31B0422FE661A00F65886 /* bt in CopyFiles */,
9DD31B0822FE661A00F65886 /* dos33_template.dsk in CopyFiles */,
9DD31B0222FE661A00F65886 /* createDiskImage in CopyFiles */,
9DD31B1222FE661A00F65886 /* V2Make.scpt in CopyFiles */,
9DD31B0C22FE661A00F65886 /* head.mk in CopyFiles */,
9DD31B0622FE661A00F65886 /* DevApple.vii in CopyFiles */,
9DD31B1522FE661A00F65886 /* colourgo.xcscheme in CopyFiles */,
9DD31B0A22FE661A00F65886 /* errorFilter.sh in CopyFiles */,
9DD31B1022FE661A00F65886 /* tail.mk in CopyFiles */,
);
runOnlyForDeploymentPostprocessing = 1;
};
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
9DF837AE1F22FB4300FFFEF2 /* a2e.stdmou.s */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.asm; path = a2e.stdmou.s; sourceTree = "<group>"; };
9DF837AF1F22FB7500FFFEF2 /* mouseWrapper.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = mouseWrapper.c; sourceTree = "<group>"; };
9DF837B01F22FB7500FFFEF2 /* mouseWrapper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = mouseWrapper.h; sourceTree = "<group>"; };
9DF837B21F23061700FFFEF2 /* README.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = "<group>"; };
9DFD77C91F1F9C2500639A48 /* game.s */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.asm; path = game.s; sourceTree = "<group>"; };
9DFD77CA1F1F9C2500639A48 /* Makefile */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.make; path = Makefile; sourceTree = "<group>"; };
9DFD77CC1F1F9C2500639A48 /* AppleCommander.jar */ = {isa = PBXFileReference; lastKnownFileType = archive.jar; name = AppleCommander.jar; path = make/AppleCommander.jar; sourceTree = "<group>"; };
9DFD77CD1F1F9C2500639A48 /* createDiskImage */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; name = createDiskImage; path = make/createDiskImage; sourceTree = "<group>"; };
9DFD77CE1F1F9C2500639A48 /* DevApple.vii */ = {isa = PBXFileReference; lastKnownFileType = file.bplist; name = DevApple.vii; path = make/DevApple.vii; sourceTree = "<group>"; };
9DFD77CF1F1F9C2500639A48 /* dos33_template.dsk */ = {isa = PBXFileReference; lastKnownFileType = file; name = dos33_template.dsk; path = make/dos33_template.dsk; sourceTree = "<group>"; };
9DFD77D01F1F9C2500639A48 /* head.mk */ = {isa = PBXFileReference; lastKnownFileType = text; name = head.mk; path = make/head.mk; sourceTree = "<group>"; };
9DFD77D11F1F9C2500639A48 /* prodos_template.dsk */ = {isa = PBXFileReference; lastKnownFileType = file; name = prodos_template.dsk; path = make/prodos_template.dsk; sourceTree = "<group>"; };
9DFD77D21F1F9C2500639A48 /* tail.mk */ = {isa = PBXFileReference; lastKnownFileType = text; name = tail.mk; path = make/tail.mk; sourceTree = "<group>"; };
9DFD77D31F1F9C2500639A48 /* V2Make.scpt */ = {isa = PBXFileReference; lastKnownFileType = file; name = V2Make.scpt; path = make/V2Make.scpt; sourceTree = "<group>"; };
9DFD77D91F1FA47900639A48 /* main.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = main.c; sourceTree = "<group>"; };
9DFD77DB1F1FA4A400639A48 /* game.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = game.h; sourceTree = "<group>"; };
9DFD77DC1F1FB69600639A48 /* vbl.s */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.asm; path = vbl.s; sourceTree = "<group>"; };
9DFD77DD1F1FB69600639A48 /* vbl.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = vbl.h; sourceTree = "<group>"; };
9DFD77DE1F1FB69600639A48 /* machine.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = machine.c; sourceTree = "<group>"; };
9DFD77DF1F1FB69600639A48 /* machine.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = machine.h; sourceTree = "<group>"; };
9DD31AEE22FE661A00F65886 /* colourgo */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = colourgo; sourceTree = BUILT_PRODUCTS_DIR; };
9DD31AF122FE661A00F65886 /* colourgo.dsk */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = colourgo.dsk; sourceTree = BUILT_PRODUCTS_DIR; };
9DD31AF622FE661A00F65886 /* doNotBuild */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = doNotBuild; sourceTree = BUILT_PRODUCTS_DIR; };
9DD31AFA22FE661A00F65886 /* Makefile */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.make; path = Makefile; sourceTree = "<group>"; };
9DD31AFD22FE661A00F65886 /* AppleCommander.jar */ = {isa = PBXFileReference; lastKnownFileType = archive.jar; name = AppleCommander.jar; path = make/AppleCommander.jar; sourceTree = "<group>"; };
9DD31AFF22FE661A00F65886 /* bastokenizer-tools-bt-0.2.0.jar */ = {isa = PBXFileReference; lastKnownFileType = archive.jar; name = "bastokenizer-tools-bt-0.2.0.jar"; path = "make/bastokenizer-tools-bt-0.2.0.jar"; sourceTree = "<group>"; };
9DD31B0122FE661A00F65886 /* createDiskImage */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; name = createDiskImage; path = make/createDiskImage; sourceTree = "<group>"; };
9DD31B0322FE661A00F65886 /* bt */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; name = bt; path = make/bt; sourceTree = "<group>"; };
9DD31B0522FE661A00F65886 /* DevApple.vii */ = {isa = PBXFileReference; lastKnownFileType = file.bplist; name = DevApple.vii; path = make/DevApple.vii; sourceTree = "<group>"; };
9DD31B0722FE661A00F65886 /* dos33_template.dsk */ = {isa = PBXFileReference; lastKnownFileType = file; name = dos33_template.dsk; path = make/dos33_template.dsk; sourceTree = "<group>"; };
9DD31B0922FE661A00F65886 /* errorFilter.sh */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; name = errorFilter.sh; path = make/errorFilter.sh; sourceTree = "<group>"; };
9DD31B0B22FE661A00F65886 /* head.mk */ = {isa = PBXFileReference; lastKnownFileType = text; name = head.mk; path = make/head.mk; sourceTree = "<group>"; };
9DD31B0D22FE661A00F65886 /* prodos_template.dsk */ = {isa = PBXFileReference; lastKnownFileType = file; name = prodos_template.dsk; path = make/prodos_template.dsk; sourceTree = "<group>"; };
9DD31B0F22FE661A00F65886 /* tail.mk */ = {isa = PBXFileReference; lastKnownFileType = text; name = tail.mk; path = make/tail.mk; sourceTree = "<group>"; };
9DD31B1122FE661A00F65886 /* V2Make.scpt */ = {isa = PBXFileReference; lastKnownFileType = file; name = V2Make.scpt; path = make/V2Make.scpt; sourceTree = "<group>"; };
9DD31B1422FE661A00F65886 /* colourgo.xcscheme */ = {isa = PBXFileReference; lastKnownFileType = text.xml; name = colourgo.xcscheme; path = colourgo.xcodeproj/xcshareddata/xcschemes/colourgo.xcscheme; sourceTree = SOURCE_ROOT; };
9DD31B2422FE664100F65886 /* README.md */ = {isa = PBXFileReference; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = "<group>"; };
9DD31B2522FE664D00F65886 /* LICENSE */ = {isa = PBXFileReference; lastKnownFileType = text; path = LICENSE; sourceTree = "<group>"; };
9DD31B2622FE666F00F65886 /* main.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = main.c; sourceTree = "<group>"; };
9DD31B2722FE666F00F65886 /* mouseWrapper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mouseWrapper.h; sourceTree = "<group>"; };
9DD31B2822FE666F00F65886 /* game.s */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = game.s; sourceTree = "<group>"; };
9DD31B2922FE666F00F65886 /* game.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = game.h; sourceTree = "<group>"; };
9DD31B2A22FE666F00F65886 /* mouseWrapper.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = mouseWrapper.c; sourceTree = "<group>"; };
9DD31B2B22FE666F00F65886 /* machine.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = machine.c; sourceTree = "<group>"; };
9DD31B2C22FE666F00F65886 /* vbl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = vbl.h; sourceTree = "<group>"; };
9DD31B2D22FE666F00F65886 /* vbl.s */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = vbl.s; sourceTree = "<group>"; };
9DD31B2E22FE667000F65886 /* machine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = machine.h; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
9DD31AF322FE661A00F65886 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
9DD31AFE22FE661A00F65886 /* AppleCommander.jar in Frameworks */,
9DD31B0022FE661A00F65886 /* bastokenizer-tools-bt-0.2.0.jar in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
9DF837B11F22FB7B00FFFEF2 /* mouse */ = {
9DD31AE722FE661A00F65886 = {
isa = PBXGroup;
children = (
9DF837AE1F22FB4300FFFEF2 /* a2e.stdmou.s */,
9DF837AF1F22FB7500FFFEF2 /* mouseWrapper.c */,
9DF837B01F22FB7500FFFEF2 /* mouseWrapper.h */,
);
name = mouse;
sourceTree = "<group>";
};
9DFD77C21F1F9C2500639A48 = {
isa = PBXGroup;
children = (
9DF837B21F23061700FFFEF2 /* README.md */,
9DFD77C81F1F9C2500639A48 /* colourgo */,
9DD31B2422FE664100F65886 /* README.md */,
9DD31B2522FE664D00F65886 /* LICENSE */,
9DD31AF722FE661A00F65886 /* colourgo */,
9DD31AEF22FE661A00F65886 /* Products */,
);
sourceTree = "<group>";
};
9DFD77C81F1F9C2500639A48 /* colourgo */ = {
9DD31AEF22FE661A00F65886 /* Products */ = {
isa = PBXGroup;
children = (
9DFD77D91F1FA47900639A48 /* main.c */,
9DFD77C91F1F9C2500639A48 /* game.s */,
9DFD77DB1F1FA4A400639A48 /* game.h */,
9DFD77DC1F1FB69600639A48 /* vbl.s */,
9DFD77DD1F1FB69600639A48 /* vbl.h */,
9DFD77DE1F1FB69600639A48 /* machine.c */,
9DFD77DF1F1FB69600639A48 /* machine.h */,
9DF837B11F22FB7B00FFFEF2 /* mouse */,
9DFD77CA1F1F9C2500639A48 /* Makefile */,
9DFD77CB1F1F9C2500639A48 /* make */,
9DD31AEE22FE661A00F65886 /* colourgo */,
9DD31AF122FE661A00F65886 /* colourgo.dsk */,
9DD31AF622FE661A00F65886 /* doNotBuild */,
);
name = Products;
sourceTree = "<group>";
};
9DD31AF722FE661A00F65886 /* colourgo */ = {
isa = PBXGroup;
children = (
9DD31B2922FE666F00F65886 /* game.h */,
9DD31B2822FE666F00F65886 /* game.s */,
9DD31B2B22FE666F00F65886 /* machine.c */,
9DD31B2E22FE667000F65886 /* machine.h */,
9DD31B2622FE666F00F65886 /* main.c */,
9DD31B2A22FE666F00F65886 /* mouseWrapper.c */,
9DD31B2722FE666F00F65886 /* mouseWrapper.h */,
9DD31B2C22FE666F00F65886 /* vbl.h */,
9DD31B2D22FE666F00F65886 /* vbl.s */,
9DD31AFA22FE661A00F65886 /* Makefile */,
9DD31AFC22FE661A00F65886 /* make */,
9DD31B1322FE661A00F65886 /* Supporting Files */,
);
path = colourgo;
sourceTree = "<group>";
};
9DFD77CB1F1F9C2500639A48 /* make */ = {
9DD31AFC22FE661A00F65886 /* make */ = {
isa = PBXGroup;
children = (
9DFD77CC1F1F9C2500639A48 /* AppleCommander.jar */,
9DFD77CD1F1F9C2500639A48 /* createDiskImage */,
9DFD77CE1F1F9C2500639A48 /* DevApple.vii */,
9DFD77CF1F1F9C2500639A48 /* dos33_template.dsk */,
9DFD77D01F1F9C2500639A48 /* head.mk */,
9DFD77D11F1F9C2500639A48 /* prodos_template.dsk */,
9DFD77D21F1F9C2500639A48 /* tail.mk */,
9DFD77D31F1F9C2500639A48 /* V2Make.scpt */,
9DD31AFD22FE661A00F65886 /* AppleCommander.jar */,
9DD31AFF22FE661A00F65886 /* bastokenizer-tools-bt-0.2.0.jar */,
9DD31B0122FE661A00F65886 /* createDiskImage */,
9DD31B0322FE661A00F65886 /* bt */,
9DD31B0522FE661A00F65886 /* DevApple.vii */,
9DD31B0722FE661A00F65886 /* dos33_template.dsk */,
9DD31B0922FE661A00F65886 /* errorFilter.sh */,
9DD31B0B22FE661A00F65886 /* head.mk */,
9DD31B0D22FE661A00F65886 /* prodos_template.dsk */,
9DD31B0F22FE661A00F65886 /* tail.mk */,
9DD31B1122FE661A00F65886 /* V2Make.scpt */,
);
name = make;
sourceTree = "<group>";
};
9DD31B1322FE661A00F65886 /* Supporting Files */ = {
isa = PBXGroup;
children = (
9DD31B1422FE661A00F65886 /* colourgo.xcscheme */,
);
name = "Supporting Files";
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXLegacyTarget section */
9DFD77C71F1F9C2500639A48 /* colourgo */ = {
9DD31AEC22FE661A00F65886 /* colourgo */ = {
isa = PBXLegacyTarget;
buildArgumentsString = "-C colourgo $(ACTION)";
buildConfigurationList = 9DFD77D61F1F9C2500639A48 /* Build configuration list for PBXLegacyTarget "colourgo" */;
buildConfigurationList = 9DD31B1822FE661A00F65886 /* Build configuration list for PBXLegacyTarget "colourgo" */;
buildPhases = (
);
buildToolPath = /usr/bin/make;
@ -98,63 +175,149 @@
};
/* End PBXLegacyTarget section */
/* Begin PBXNativeTarget section */
9DD31AED22FE661A00F65886 /* Binary */ = {
isa = PBXNativeTarget;
buildConfigurationList = 9DD31B1B22FE661A00F65886 /* Build configuration list for PBXNativeTarget "Binary" */;
buildPhases = (
);
buildRules = (
);
dependencies = (
);
name = Binary;
productName = Binary;
productReference = 9DD31AEE22FE661A00F65886 /* colourgo */;
productType = "com.apple.product-type.tool";
};
9DD31AF022FE661A00F65886 /* DiskImage */ = {
isa = PBXNativeTarget;
buildConfigurationList = 9DD31B1E22FE661A00F65886 /* Build configuration list for PBXNativeTarget "DiskImage" */;
buildPhases = (
);
buildRules = (
);
dependencies = (
);
name = DiskImage;
productName = DiskImage;
productReference = 9DD31AF122FE661A00F65886 /* colourgo.dsk */;
productType = "com.apple.product-type.tool";
};
9DD31AF522FE661A00F65886 /* doNotBuild */ = {
isa = PBXNativeTarget;
buildConfigurationList = 9DD31B2122FE661A00F65886 /* Build configuration list for PBXNativeTarget "doNotBuild" */;
buildPhases = (
9DD31AF222FE661A00F65886 /* Sources */,
9DD31AF322FE661A00F65886 /* Frameworks */,
9DD31AF422FE661A00F65886 /* CopyFiles */,
);
buildRules = (
);
dependencies = (
);
name = doNotBuild;
productName = doNotBuild;
productReference = 9DD31AF622FE661A00F65886 /* doNotBuild */;
productType = "com.apple.product-type.tool";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
9DFD77C31F1F9C2500639A48 /* Project object */ = {
9DD31AE822FE661A00F65886 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0830;
LastUpgradeCheck = 1030;
ORGANIZATIONNAME = "Jeremy Rand";
TargetAttributes = {
9DFD77C71F1F9C2500639A48 = {
CreatedOnToolsVersion = 8.3.3;
ProvisioningStyle = Automatic;
9DD31AEC22FE661A00F65886 = {
CreatedOnToolsVersion = 10.3;
};
9DD31AED22FE661A00F65886 = {
CreatedOnToolsVersion = 10.3;
};
9DD31AF022FE661A00F65886 = {
CreatedOnToolsVersion = 10.3;
};
9DD31AF522FE661A00F65886 = {
CreatedOnToolsVersion = 10.3;
};
};
};
buildConfigurationList = 9DFD77C61F1F9C2500639A48 /* Build configuration list for PBXProject "colourgo" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
buildConfigurationList = 9DD31AEB22FE661A00F65886 /* Build configuration list for PBXProject "colourgo" */;
compatibilityVersion = "Xcode 9.3";
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
);
mainGroup = 9DFD77C21F1F9C2500639A48;
mainGroup = 9DD31AE722FE661A00F65886;
productRefGroup = 9DD31AEF22FE661A00F65886 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
9DFD77C71F1F9C2500639A48 /* colourgo */,
9DD31AEC22FE661A00F65886 /* colourgo */,
9DD31AED22FE661A00F65886 /* Binary */,
9DD31AF022FE661A00F65886 /* DiskImage */,
9DD31AF522FE661A00F65886 /* doNotBuild */,
);
};
/* End PBXProject section */
/* Begin PBXSourcesBuildPhase section */
9DD31AF222FE661A00F65886 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
9DD31B3322FE667000F65886 /* vbl.s in Sources */,
9DD31B2F22FE667000F65886 /* main.c in Sources */,
9DD31B3122FE667000F65886 /* mouseWrapper.c in Sources */,
9DD31B3222FE667000F65886 /* machine.c in Sources */,
9DD31AFB22FE661A00F65886 /* Makefile in Sources */,
9DD31B3022FE667000F65886 /* game.s in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
9DFD77D41F1F9C2500639A48 /* Debug */ = {
9DD31B1622FE661A00F65886 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
@ -168,38 +331,49 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MTL_ENABLE_DEBUG_INFO = YES;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
};
name = Debug;
};
9DFD77D51F1F9C2500639A48 /* Release */ = {
9DD31B1722FE661A00F65886 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
@ -208,14 +382,17 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
};
name = Release;
};
9DFD77D71F1F9C2500639A48 /* Debug */ = {
9DD31B1922FE661A00F65886 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEBUGGING_SYMBOLS = YES;
DEBUG_INFORMATION_FORMAT = dwarf;
DEVELOPMENT_TEAM = VD9FGCW36C;
GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
OTHER_CFLAGS = "";
@ -224,38 +401,131 @@
};
name = Debug;
};
9DFD77D81F1F9C2500639A48 /* Release */ = {
9DD31B1A22FE661A00F65886 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = VD9FGCW36C;
OTHER_CFLAGS = "";
OTHER_LDFLAGS = "";
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Release;
};
9DD31B1C22FE661A00F65886 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = VD9FGCW36C;
PRODUCT_NAME = colourgo;
};
name = Debug;
};
9DD31B1D22FE661A00F65886 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = VD9FGCW36C;
PRODUCT_NAME = colourgo;
};
name = Release;
};
9DD31B1F22FE661A00F65886 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = VD9FGCW36C;
PRODUCT_NAME = colourgo.dsk;
};
name = Debug;
};
9DD31B2022FE661A00F65886 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = VD9FGCW36C;
PRODUCT_NAME = colourgo.dsk;
};
name = Release;
};
9DD31B2222FE661A00F65886 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = VD9FGCW36C;
GCC_PREPROCESSOR_DEFINITIONS = "__fastcall__=\"\"";
HEADER_SEARCH_PATHS = (
$TEMP_ROOT/colourgo.build/$CONFIGURATION/colourgo.build/DerivedSources,
/usr/local/share/cc65/include,
);
PRODUCT_NAME = doNotBuild;
};
name = Debug;
};
9DD31B2322FE661A00F65886 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = VD9FGCW36C;
GCC_PREPROCESSOR_DEFINITIONS = "__fastcall__=\"\"";
HEADER_SEARCH_PATHS = (
$TEMP_ROOT/colourgo.build/$CONFIGURATION/colourgo.build/DerivedSources,
/usr/local/share/cc65/include,
);
PRODUCT_NAME = doNotBuild;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
9DFD77C61F1F9C2500639A48 /* Build configuration list for PBXProject "colourgo" */ = {
9DD31AEB22FE661A00F65886 /* Build configuration list for PBXProject "colourgo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
9DFD77D41F1F9C2500639A48 /* Debug */,
9DFD77D51F1F9C2500639A48 /* Release */,
9DD31B1622FE661A00F65886 /* Debug */,
9DD31B1722FE661A00F65886 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
9DFD77D61F1F9C2500639A48 /* Build configuration list for PBXLegacyTarget "colourgo" */ = {
9DD31B1822FE661A00F65886 /* Build configuration list for PBXLegacyTarget "colourgo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
9DFD77D71F1F9C2500639A48 /* Debug */,
9DFD77D81F1F9C2500639A48 /* Release */,
9DD31B1922FE661A00F65886 /* Debug */,
9DD31B1A22FE661A00F65886 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
9DD31B1B22FE661A00F65886 /* Build configuration list for PBXNativeTarget "Binary" */ = {
isa = XCConfigurationList;
buildConfigurations = (
9DD31B1C22FE661A00F65886 /* Debug */,
9DD31B1D22FE661A00F65886 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
9DD31B1E22FE661A00F65886 /* Build configuration list for PBXNativeTarget "DiskImage" */ = {
isa = XCConfigurationList;
buildConfigurations = (
9DD31B1F22FE661A00F65886 /* Debug */,
9DD31B2022FE661A00F65886 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
9DD31B2122FE661A00F65886 /* Build configuration list for PBXNativeTarget "doNotBuild" */ = {
isa = XCConfigurationList;
buildConfigurations = (
9DD31B2222FE661A00F65886 /* Debug */,
9DD31B2322FE661A00F65886 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 9DFD77C31F1F9C2500639A48 /* Project object */;
rootObject = 9DD31AE822FE661A00F65886 /* Project object */;
}

View File

@ -0,0 +1,8 @@
<?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>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

View File

@ -0,0 +1,8 @@
<?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>BuildSystemType</key>
<string>Original</string>
</dict>
</plist>

View File

@ -14,7 +14,7 @@
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9DFD77C71F1F9C2500639A48"
BlueprintIdentifier = "9D0B917C1F526C2D004D7E0B"
BuildableName = "colourgo"
BlueprintName = "colourgo"
ReferencedContainer = "container:colourgo.xcodeproj">
@ -34,23 +34,53 @@
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
selectedDebuggerIdentifier = ""
selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<PathRunnable
runnableDebuggingMode = "0"
FilePath = "/usr/bin/make">
</PathRunnable>
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9DFD77C71F1F9C2500639A48"
BlueprintIdentifier = "9D0B917C1F526C2D004D7E0B"
BuildableName = "colourgo"
BlueprintName = "colourgo"
ReferencedContainer = "container:colourgo.xcodeproj">
</BuildableReference>
</MacroExpansion>
<CommandLineArguments>
<CommandLineArgument
argument = "-C"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "$PROJECT_DIR/colourgo"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "OBJECT_FILE_DIR=$OBJECT_FILE_DIR"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "DERIVED_SOURCES_DIR=$DERIVED_SOURCES_DIR"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "TARGET_BUILD_DIR=$TARGET_BUILD_DIR"
isEnabled = "YES">
</CommandLineArgument>
<CommandLineArgument
argument = "execute"
isEnabled = "YES">
</CommandLineArgument>
</CommandLineArguments>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
@ -63,7 +93,7 @@
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9DFD77C71F1F9C2500639A48"
BlueprintIdentifier = "9D0B917C1F526C2D004D7E0B"
BuildableName = "colourgo"
BlueprintName = "colourgo"
ReferencedContainer = "container:colourgo.xcodeproj">

View File

@ -4,18 +4,25 @@
<dict>
<key>SchemeUserState</key>
<dict>
<key>colourgo.xcscheme</key>
<key>Binary.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>1</integer>
</dict>
<key>DiskImage.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>2</integer>
</dict>
<key>colourgo.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
<key>SuppressBuildableAutocreation</key>
<dict>
<key>9DFD77C71F1F9C2500639A48</key>
<key>doNotBuild.xcscheme_^#shared#^_</key>
<dict>
<key>primary</key>
<true/>
<key>orderHint</key>
<integer>3</integer>
</dict>
</dict>
</dict>

View File

@ -18,10 +18,6 @@ include make/head.mk
# The name of your system or binary file to build goes here:
PGM=colourgo
# Set the config you are building for. See these pages for details:
# http://cc65.github.io/cc65/doc/apple2.html#s4
# http://cc65.github.io/cc65/doc/apple2enh.html#s4
#
# Uncomment the one you want below (the first one is the default):
# MACHINE = apple2
# MACHINE = apple2-dos33
@ -34,6 +30,13 @@ MACHINE = apple2-loader
# MACHINE = apple2enh-loader
# MACHINE = apple2enh-reboot
# Uncomment the appropriate project type. If your entry point is
# main() in a .c file, then your project type is cc65. If your
# entry point is in an assembly file, then you project type is
# ca65:
PROJECT_TYPE = cc65
# PROJECT_TYPE = ca65
# Uncomment and set this to your starting address in Apple II memory
# if necessary:
START_ADDR = 6000
@ -48,26 +51,19 @@ START_ADDR = 6000
# Note: You can assemble for 65816 in 16-bit mode but the C compiler
# will only produce 8-bit code.
# Any *.c files in your main project directory will automatically be
# built. But, if you have subdirectories with C files in them, you
# should add them to the list of C_SRCS to build. Do that by
# uncommenting the following line and changing "someSubDir" to match
# the subdirectory you have created. Add multiple lines like this
# for each subdirectory:
# C_SRCS += $(wildcard someSubDir/*.c)
# Any *.s files in your main project directory will automatically be
# built. But, if you have subdirectories with assembly files in them,
# you should add them to the list of ASM_SRCS to build. Do that by
# uncommenting the following line and changing "someSubDir" to match
# the subdirectory you have created. Add multiple lines like this
# for each subdirectory:
# ASM_SRCS += $(wildcard someSubDir/*.s)
# Add any other directories where you are putting C or assembly source
# files to this list. Note that if you are generating source files into
# $(GENDIR), you should add $(GENDIR) to SRCDIRS here:
SRCDIRS+=
# If you have a non-standard cc65 install, you may need to change
# some of these. Uncomment the following line and change it to the
# correct path to CC65_HOME if the default is not correct:
# export CC65_HOME := /usr/local/lib/cc65
# correct path to CC65_HOME if the default is not correct. If you
# are using cc65 v2.13.3, the default is:
# /usr/local/lib/cc65
# If you are using cc65 v2.17, the default is:
# /usr/local/share/cc65
# export CC65_HOME := /path/to/your/cc65/directory
#
# If the path to the cc65 binaries is not correct, uncomment this
# line and change it:
@ -85,10 +81,174 @@ START_ADDR = 6000
# this variable:
# LDFLAGS += -v
# If you want to add arguments to the BASIC tokenizer commandline,
# add them to this valiable:
# BASICFLAGS += --optimize
# If you want to link the lores graphics driver with your executable,
# uncomment the next line.
# DRIVERS += loresgr
#
# To use the lores driver, add code which looks like this to your
# project:
#
# #include "drivers/a2_lores_drv.h"
# int main(void)
# {
# tgi_install(&a2_lores_drv);
# tgi_init();
# // Use the graphics driver
# tgi_uninstall();
# }
#
# Read the $CC65_HOME/include/tgi.h file to see what the
# driver interface provides. Also check out
# $CC65_HOME/include/apple2.h to see the colour definitions.
# If you want to link the hires graphics driver with your executable,
# uncomment the next line.
# DRIVERS += hiresgr
#
# To use the hires driver, add code which looks like this to your
# project:
#
# #include "drivers/a2_hires_drv.h"
# int main(void)
# {
# tgi_install(&a2_hires_drv);
# tgi_init();
# // Use the graphics driver
# tgi_uninstall();
# }
#
# Read the $CC65_HOME/cc65/include/tgi.h file to see what the
# driver interface provides. Also check out
# $CC65_HOME/include/apple2.h to see the colour definitions.
# If you want to link the extended memory driver with your executable,
# uncomment the next line.
# DRIVERS += auxmem
#
# To use the auxmem driver, add code which looks like this to your
# project:
#
# #include "drivers/a2_auxmem_drv.h"
# int main(void)
# {
# em_install(&a2_auxmem_drv);
# // Use the auxmem driver
# em_uninstall();
# }
#
# Read the $CC65_HOME/include/em.h file to see what the
# driver interface provides.
# If you want to link the joystick driver with your executable,
# uncomment the next line.
# DRIVERS += joystick
#
# To use the joystick driver, add code which looks like this to your
# project:
#
# #include "drivers/a2_joystick_drv.h"
# int main(void)
# {
# joy_install(&a2_joystick_drv);
# // Use the joystick driver
# joy_uninstall();
# }
#
# Read the $CC65_HOME/include/joystick.h file to see what the
# driver interface provides.
# If you want to link the mouse driver with your executable,
# uncomment the next line.
DRIVERS += mouse
#
# To use the mouse driver, add code which looks like this to your
# project:
#
# #include "drivers/a2_mouse_drv.h"
# int main(void)
# {
# mouse_install(&mouse_def_callbacks, &a2_mouse_drv);
# // Use the mouse driver
# mouse_uninstall();
# }
#
# Read the $CC65_HOME/include/mouse.h file to see what the
# driver interface provides.
# If you want to link the serial driver with your executable,
# uncomment the next line.
# DRIVERS += serial
#
# To use the serial driver, add code which looks like this to your
# project:
#
# #include "drivers/a2_serial_drv.h"
# int main(void)
# {
# ser_install(&a2_serial_drv);
# // Use the serial driver
# ser_uninstall();
# }
#
# Read the $CC65_HOME/include/serial.h file to see what the
# driver interface provides.
# If you have java installed in a non-standard location, you can set
# the path to it by uncommenting the following line:
# export JAVA=/usr/bin/java
# If you want to copy one or more files or directories to the target disk
# image, add the root directory to this variable. All files will be
# copied from the source to the target using the same path from the source.
#
# For example, if you set COPYDIRS to dir and in your project you have
# the following files:
# dir/mySystemFile
# dir/newDir/anotherFile
#
# Then, during the copy phase, mySystemFile will be copied into the root
# of the disk and anotherFile will be copied into a directory named
# newDir. The newDir directory will be created if it does not already
# exist.
#
# The name of the file to copy is checked and if it ends in:
# .as - It assumes the file is in AppleSingle format. The .as
# suffix is stripped from the name when copied to the
# disk image.
# .<char> - If the file ends with a single character which matches
# a DOS 3.3 file type (A, B, T, etc) it uses that value as
# the file type of the file copied to the disk image. The
# single character is removed from the file name.
# .<TLA> - If the file ends with a three letter alpha extension, it
# uses that TLA as the file type of the file copied to the
# disk image. The TLA is removed from the file name.
#
# If you do not provide any type information for your filenames,
# it will be copied as a binary.
#
COPYDIRS=
# Add any rules you want to execute before any compiles or assembly
# commands are called here, if any. You can generate .c, .s or .h
# files for example. You can generate data files. Whatever you
# might need.
#
# You should generate these files in the $(GENDIR) directory or
# within a subdirectory under $(GENDIR) which you create yourself.
#
# All of your commands associated with a rule _must_ start with a tab
# character. Xcode makes it a bit tough to type a tab character by
# default. Press option-tab within Xcode to insert a tab character.
gen:
# For any files you generated in the gen target above, you should
# add rules in genclean to remove those generated files when you
# clean your build.
genclean:
# Do not change anything else below here...
include make/tail.mk

View File

@ -1,427 +0,0 @@
;
; File generated by co65 v 2.13.3 using model `cc65-module'
;
.fopt compiler,"co65 v 2.13.3"
.case on
.debuginfo off
.export _a2e_stdmou_mou
;
; CODE SEGMENT
;
.segment "CODE"
_a2e_stdmou_mou:
.byte $6D
.byte $6F
.byte $75
.byte $02
.word _a2e_stdmou_mou+41
.word _a2e_stdmou_mou+170
.word _a2e_stdmou_mou+286
.word _a2e_stdmou_mou+295
.word _a2e_stdmou_mou+180
.word _a2e_stdmou_mou+238
.word _a2e_stdmou_mou+253
.word _a2e_stdmou_mou+299
.word _a2e_stdmou_mou+305
.word _a2e_stdmou_mou+309
.word _a2e_stdmou_mou+322
.word _a2e_stdmou_mou+327
.byte $40
.byte $4C
.byte $00
.byte $00
.byte $4C
.byte $00
.byte $00
.byte $4C
.byte $00
.byte $00
.byte $4C
.byte $00
.byte $00
.byte $A9
.byte $00
.byte $85
.byte <(ZEROPAGE+8)
.byte $A9
.byte $C0
.byte $85
.byte <(ZEROPAGE+9)
.byte $E6
.byte <(ZEROPAGE+9)
.byte $A5
.byte <(ZEROPAGE+9)
.byte $C9
.byte $C8
.byte $90
.byte $05
.byte $A9
.byte $04
.byte $A2
.byte $00
.byte $60
.byte $A2
.byte $03
.byte $BC
.word _a2e_stdmou_mou+421
.byte $BD
.word _a2e_stdmou_mou+425
.byte $D1
.byte <(ZEROPAGE+8)
.byte $D0
.byte $E7
.byte $CA
.byte $10
.byte $F3
.byte $A5
.byte <(ZEROPAGE+9)
.byte $8D
.word DATA+2
.byte $8D
.word DATA+7
.byte $8D
.word DATA+12
.byte $78
.byte $29
.byte $0F
.byte $8D
.word BSS+13
.byte $0A
.byte $0A
.byte $0A
.byte $0A
.byte $8D
.word DATA+9
.byte $2C
.byte $82
.byte $C0
.byte $A2
.byte $19
.byte $20
.word DATA+0
.byte $2C
.byte $80
.byte $C0
.byte $A9
.byte $01
.byte $A2
.byte $12
.byte $20
.word DATA+0
.byte $A9
.byte <(_a2e_stdmou_mou+173)
.byte $A2
.byte >(_a2e_stdmou_mou+429)
.byte $20
.word _a2e_stdmou_mou+180
.byte $AE
.word BSS+13
.byte $A9
.byte $8B
.byte $9D
.byte $78
.byte $04
.byte $A9
.byte $00
.byte $9D
.byte $78
.byte $05
.byte $A9
.byte $5F
.byte $9D
.byte $F8
.byte $04
.byte $A9
.byte $00
.byte $9D
.byte $F8
.byte $05
.byte $A2
.byte $16
.byte $20
.word DATA+0
.byte $20
.word _a2e_stdmou_mou+372
.byte $A9
.byte $09
.byte $A2
.byte $12
.byte $20
.word DATA+0
.byte $58
.byte $A9
.byte $00
.byte $A2
.byte $00
.byte $60
.byte $78
.byte $20
.word _a2e_stdmou_mou+29
.byte $A9
.byte $00
.byte $A2
.byte $12
.byte $D0
.byte $ED
.byte $85
.byte <(ZEROPAGE+8)
.byte $86
.byte <(ZEROPAGE+9)
.byte $A2
.byte $00
.byte $A0
.byte $00
.byte $20
.word _a2e_stdmou_mou+195
.byte $A2
.byte $01
.byte $A0
.byte $02
.byte $78
.byte $B1
.byte <(ZEROPAGE+8)
.byte $99
.word BSS+0
.byte $8D
.byte $78
.byte $04
.byte $C8
.byte $B1
.byte <(ZEROPAGE+8)
.byte $99
.word BSS+0
.byte $8D
.byte $78
.byte $05
.byte $C8
.byte $C8
.byte $C8
.byte $B1
.byte <(ZEROPAGE+8)
.byte $99
.word BSS+0
.byte $8D
.byte $F8
.byte $04
.byte $C8
.byte $B1
.byte <(ZEROPAGE+8)
.byte $99
.word BSS+0
.byte $8D
.byte $F8
.byte $05
.byte $8A
.byte $A2
.byte $17
.byte $D0
.byte $B3
.byte $85
.byte <(ZEROPAGE+8)
.byte $86
.byte <(ZEROPAGE+9)
.byte $A0
.byte $07
.byte $B9
.word BSS+0
.byte $91
.byte <(ZEROPAGE+8)
.byte $88
.byte $10
.byte $F8
.byte $60
.byte $AC
.word BSS+13
.byte $78
.byte $99
.byte $F8
.byte $04
.byte $8A
.byte $99
.byte $F8
.byte $05
.byte $98
.byte $AA
.byte $A0
.byte $00
.byte $B1
.byte <(ZEROPAGE+0)
.byte $C8
.byte $9D
.byte $78
.byte $04
.byte $B1
.byte <(ZEROPAGE+0)
.byte $9D
.byte $78
.byte $05
.byte $20
.word _a2e_stdmou_mou+372
.byte $A2
.byte $16
.byte $D0
.byte $83
.byte $CE
.word BSS+14
.byte $78
.byte $20
.word _a2e_stdmou_mou+29
.byte $58
.byte $60
.byte $EE
.word BSS+14
.byte $60
.byte $AD
.word BSS+12
.byte $A2
.byte $00
.byte $60
.byte $A0
.byte $03
.byte $D0
.byte $02
.byte $A0
.byte $04
.byte $78
.byte $B9
.word BSS+8
.byte $91
.byte <(ZEROPAGE+8)
.byte $88
.byte $10
.byte $F8
.byte $58
.byte $60
.byte $A9
.byte $05
.byte $A2
.byte $00
.byte $60
.byte $AD
.word BSS+13
.byte $F0
.byte $08
.byte $A2
.byte $13
.byte $20
.word DATA+0
.byte $90
.byte $02
.byte $18
.byte $60
.byte $A2
.byte $14
.byte $20
.word DATA+0
.byte $AC
.word BSS+13
.byte $B9
.byte $78
.byte $07
.byte $AA
.byte $0A
.byte $29
.byte $20
.byte $F0
.byte $02
.byte $A9
.byte $01
.byte $90
.byte $02
.byte $09
.byte $10
.byte $8D
.word BSS+12
.byte $8A
.byte $29
.byte $20
.byte $F0
.byte $27
.byte $20
.word _a2e_stdmou_mou+29
.byte $AC
.word BSS+13
.byte $B9
.byte $78
.byte $04
.byte $BE
.byte $78
.byte $05
.byte $8D
.word BSS+8
.byte $8E
.word BSS+9
.byte $20
.word _a2e_stdmou_mou+35
.byte $AC
.word BSS+13
.byte $B9
.byte $F8
.byte $04
.byte $BE
.byte $F8
.byte $05
.byte $8D
.word BSS+10
.byte $8E
.word BSS+11
.byte $20
.word _a2e_stdmou_mou+38
.byte $AD
.word BSS+14
.byte $F0
.byte $03
.byte $20
.word _a2e_stdmou_mou+32
.byte $38
.byte $60
.byte $05
.byte $07
.byte $0B
.byte $0C
.byte $38
.byte $18
.byte $01
.byte $20
.byte $00
.byte $00
.byte $00
.byte $00
.byte $17
.byte $01
.byte $BF
.byte $00
;
; DATA SEGMENT
;
.segment "DATA"
DATA:
.byte $BC
.byte $00
.byte $FF
.byte $8C
.word DATA+11
.byte $A2
.byte $FF
.byte $A0
.byte $FF
.byte $4C
.byte $FF
.byte $FF
;
; BSS SEGMENT
;
.segment "BSS"
BSS:
.res 15
;
; ZEROPAGE SEGMENT
;
.import __ZP_START__ ; Linker generated symbol
ZEROPAGE = __ZP_START__
.end

View File

@ -53,6 +53,11 @@ GRID_HEIGHT=5
GRID_MAX_SHIFT=7
LEVEL_STRUCT_SIZE=5
LEVEL_STRUCT_START=0
LEVEL_STRUCT_WIDTH=1
LEVEL_STRUCT_TOP=2
LEVEL_STRUCT_BOTTOM=3
LEVEL_STRUCT_COLOUR=4
LINE0 = $2000
LINE1 = LINE0 + 1024
@ -254,7 +259,7 @@ LINE191 = LINE190 + 1024
; Set up hires screen
jsr clearScreen
jsr setLevelAddr
jsr resetGame
@nextframe:
jsr _vblWait
@ -262,6 +267,11 @@ LINE191 = LINE190 + 1024
jsr drawCharacter
jsr drawGrids
;@debugLoop:
; ldx KBD
; bpl @debugLoop
; ldx KBDSTRB
jsr updateGrid
jsr updateCharacter
@ -297,11 +307,7 @@ LINE191 = LINE190 + 1024
lda #CHAR_STATE_FALLING
sta characterState
jmp setLevelAddr
.endproc
.proc setLevelAddr
@setLevelAddr:
ldx level
lda levelsLo,x
sta LEVELADDR
@ -312,7 +318,7 @@ LINE191 = LINE190 + 1024
; If the high byte of the level address is 0, then there are no more levels
; For now, just loop back to level 0. TODO - Something better.
sta level
jsr setLevelAddr
jmp @setLevelAddr
@notAtTheEnd:
rts
@ -364,6 +370,7 @@ freq: .BYTE $00
.proc gameOver
jsr drawCharacter
jsr drawGrids
lda #0
ldx #36
@ -542,7 +549,7 @@ lastButtonState: .BYTE $00
adc #MAXXBYTE
sta screenRight
ldy #$1
ldy #LEVEL_STRUCT_WIDTH
lda (ZPADDR6),y
beq @noneFound
@ -550,7 +557,9 @@ lastButtonState: .BYTE $00
lda gridLeft
cmp screenRight
bcs @noneFound
ldy #$1
; Add the width of the grid to the current gridLeft
ldy #LEVEL_STRUCT_WIDTH
clc
adc (ZPADDR6),y
; If we got a carry, that means the width of the next grid plus
@ -560,42 +569,39 @@ lastButtonState: .BYTE $00
bcs @overflow
cmp gridXPos
bcc @nextGrid
sec
beq @nextGrid
@overflow:
sbc gridXPos
tax
lda gridXShift
ldx gridXShift
beq @skipRightAdjust
cmp #3
cpx #5
bcs @skipRightAdjust
dex
dex
sec
sbc #2
@skipRightAdjust:
cpx #MAXXBYTE
cmp #MAXXBYTE
bcc @rightIsNotOffScreen
ldx #MAXXBYTE
lda #MAXXBYTE
@rightIsNotOffScreen:
stx gridScreenRight
sta gridScreenRight
lda gridLeft
sec
sbc gridXPos
beq @skipLeftAdjust
bpl @leftIsOnScreen
lda #$0
tax
jmp @skipLeftAdjust
@leftIsOnScreen:
tax
lda gridXShift
ldx gridXShift
beq @skipLeftAdjust
cmp #4
bcs @skipLeftAdjust
dex
dex
sec
sbc #1
@skipLeftAdjust:
txa
cmp #CHAR_XPOS+1
bcs @noneFound
@ -612,11 +618,11 @@ lastButtonState: .BYTE $00
@doNotIncHiByte:
sta ZPADDR6
ldy #$1
ldy #LEVEL_STRUCT_WIDTH
lda (ZPADDR6),y
beq @noneFound
ldy #$0
ldy #LEVEL_STRUCT_START
lda gridLeft
clc
adc (ZPADDR6),y
@ -646,19 +652,19 @@ gridLeft: .BYTE $00
@loop:
jsr nextGridAtCharacter
bcs @floorGone
ldy #2
ldy #LEVEL_STRUCT_TOP
lda (ZPADDR6),y
cmp characterYBottom
bne @loop
ldy #4
ldy #LEVEL_STRUCT_COLOUR
lda (ZPADDR6),y
cmp characterColour
beq @checkForWin
jmp gameOver
@checkForWin:
ldy #LEVEL_STRUCT_SIZE+1
ldy #LEVEL_STRUCT_SIZE+LEVEL_STRUCT_WIDTH
lda (ZPADDR6),y
bne @return
jmp levelWon
@ -679,6 +685,8 @@ gridLeft: .BYTE $00
; For jumping, we need to calculate the top first and check
; for collisions
lda #$ff
sta didHitHead
lda characterY
sec
@ -690,11 +698,11 @@ gridLeft: .BYTE $00
jsr nextGridAtCharacter
bcs @didNotHitHead
ldy #2
ldy #LEVEL_STRUCT_TOP
lda (ZPADDR6),y
sta gridTop
ldy #3
ldy #LEVEL_STRUCT_BOTTOM
lda (ZPADDR6),y
sta gridBottom
@ -705,6 +713,9 @@ gridLeft: .BYTE $00
@wasBelowToStart:
cmp characterY
bcc @loop
ldy #0
sty didHitHead
jmp @startFalling
@hitCeiling:
@ -740,11 +751,24 @@ gridLeft: .BYTE $00
clc
adc #CHAR_HEIGHT
sta characterYBottom
lda didHitHead
bne @return
; Check that the colour matches
ldy #LEVEL_STRUCT_COLOUR
lda (ZPADDR6),y
cmp characterColour
beq @return
jmp gameOver
@return:
rts
; Locals
gridTop: .BYTE $00
gridBottom: .BYTE $00
didHitHead: .BYTE $ff
.endproc
@ -772,11 +796,11 @@ gridBottom: .BYTE $00
jsr nextGridAtCharacter
bcs @didNotLand
ldy #3
ldy #LEVEL_STRUCT_BOTTOM
lda (ZPADDR6),y
sta gridBottom
ldy #2
ldy #LEVEL_STRUCT_TOP
lda (ZPADDR6),y
cmp characterOldYBottom
@ -805,8 +829,8 @@ gridBottom: .BYTE $00
@dropToBottomOfGrid:
lda gridBottom
sec
sbc #CHAR_HEIGHT
clc
adc #CHAR_HEIGHT
sta characterYBottom
@didNotLand:
@ -822,6 +846,18 @@ gridBottom: .BYTE $00
sec
sbc #CHAR_HEIGHT
sta characterY
lda characterState
cmp #CHAR_STATE_NONE
bne @return
ldy #LEVEL_STRUCT_COLOUR
lda (ZPADDR6),y
cmp characterColour
beq @return
jmp gameOver
@return:
rts
; Locals
@ -965,15 +1001,16 @@ yPos: .BYTE $00
inc gridXPos
@loop:
ldy #$1
ldy #LEVEL_STRUCT_WIDTH
lda gridXPos
cmp (LEVELADDR),y
bcc @return
beq @return
; At this point, we know that this grid is not visible
; Check to see if the start of the next grid is left justified
; or off screen.
ldy #LEVEL_STRUCT_SIZE
ldy #LEVEL_STRUCT_SIZE+LEVEL_STRUCT_START
cmp (LEVELADDR),y
bcc @return
@ -988,7 +1025,7 @@ yPos: .BYTE $00
inc LEVELADDR+1
@doNotIncHiByte:
sta LEVELADDR
ldy #$0
ldy #LEVEL_STRUCT_START
lda gridXPos
sec
sbc (LEVELADDR),y
@ -1017,7 +1054,7 @@ yPos: .BYTE $00
adc #MAXXBYTE
sta screenRight
ldy #$1
ldy #LEVEL_STRUCT_WIDTH
lda (ZPADDR6),y
bne @gridLoop
rts
@ -1025,8 +1062,10 @@ yPos: .BYTE $00
@gridLoop:
lda gridLeft
cmp screenRight
beq @continue
bcs @return
ldy #$1
@continue:
ldy #LEVEL_STRUCT_WIDTH
clc
adc (ZPADDR6),y
; If we got a carry, that means the width of the next grid plus
@ -1079,9 +1118,21 @@ yPos: .BYTE $00
lda gridLeft
sec
sbc gridXPos
bpl @leftIsOnScreen
bmi @leftIsOffScreen
beq @doneLeftAdjust
ldx gridXShift
beq @doneLeftAdjust
cpx #$4
bcs @doneLeftAdjust
sec
sbc #$1
jmp @doneLeftAdjust
@leftIsOffScreen:
lda #$0
@leftIsOnScreen:
@doneLeftAdjust:
sta gridScreenLeft
jsr drawGrid
@ -1100,11 +1151,11 @@ yPos: .BYTE $00
@doNotIncHiByte:
sta ZPADDR6
ldy #$1
ldy #LEVEL_STRUCT_WIDTH
lda (ZPADDR6),y
beq @return
ldy #$0
ldy #LEVEL_STRUCT_START
lda gridLeft
clc
adc (ZPADDR6),y
@ -1126,7 +1177,7 @@ gridLeft: .BYTE $00
.proc drawGrid
ldy #$2
ldy #LEVEL_STRUCT_TOP
lda (ZPADDR6),y
tay
lda loAddrs,y
@ -1165,7 +1216,7 @@ gridLeft: .BYTE $00
sta ZPADDR5+1
ldx gridXShift
ldy #$4
ldy #LEVEL_STRUCT_COLOUR
lda (ZPADDR6),y
tay
lda colourEvenLookup,y
@ -1177,9 +1228,10 @@ gridLeft: .BYTE $00
and oddGrid,x
sta oddGridVal
ldy #LEVEL_STRUCT_SIZE+1
ldy #LEVEL_STRUCT_SIZE+LEVEL_STRUCT_WIDTH
lda (ZPADDR6),y
bne @notLastGrid
lda evenVal
sta evenGridVal
lda oddVal
@ -1194,15 +1246,14 @@ gridLeft: .BYTE $00
sta oddRightCap
ldy gridScreenLeft
beq @L1
cpx #$0
beq @L1
jmp @L2
@L1:
jmp @nextGridComponent
; Draw the left cap
beq @nextGridComponent
; Draw the left cap
dey
tya
and #$01
bne @leftCapOdd
@L2:
lda evenGridLeft,x
and evenVal
sta evenLeftCap
@ -1210,6 +1261,15 @@ gridLeft: .BYTE $00
eor #$ff
sta evenLeftMask
lda evenLeftCap
and evenGridVal
tax
lda evenLeftMask
and (ZPADDR0),y
ora evenLeftCap
jmp @drawLeftCapComponent
@leftCapOdd:
lda oddGridLeft,x
and oddVal
sta oddLeftCap
@ -1217,57 +1277,16 @@ gridLeft: .BYTE $00
eor #$ff
sta oddLeftMask
dey
tya
and #$01
bne @leftCapOdd1
lda evenLeftCap
and evenGridVal
tax
lda evenLeftMask
and (ZPADDR0),y
ora evenLeftCap
jmp @nextLeftCapComponent
@leftCapOdd1:
lda oddLeftCap
and oddGridVal
tax
lda oddLeftMask
and (ZPADDR0),y
ora oddLeftCap
ldx oddGridVal
@nextLeftCapComponent:
jsr drawGridComponent
dey
bmi @drawBodyComponents
tya
and #$01
bne @leftCapOdd2
lda evenLeftCap
and evenGridVal
tax
lda evenLeftMask
and (ZPADDR0),y
ora evenLeftCap
jsr drawGridComponent
jmp @drawBodyComponents
@leftCapOdd2:
lda oddLeftCap
and oddGridVal
tax
lda oddLeftMask
and (ZPADDR0),y
ora oddLeftCap
@drawLeftCapComponent:
jsr drawGridComponent
@drawBodyComponents:
ldy gridScreenLeft
@nextGridComponent:
cpy gridScreenRight
@ -1353,22 +1372,22 @@ oddRightCap: .BYTE $00
ldx #0
ldy #0
@L1:
@nextLine:
lda loAddrs,x
sta ZPADDR0
lda page1HiAddrs,x
sta ZPADDR0+1
lda #$0
@L2:
@nextByte:
sta (ZPADDR0),y
iny
cpy #MAXXBYTE
bne @L2
bne @nextByte
inx
cpx #MAXY
bne @L1
bne @nextLine
lda TXTCLR
lda MIXCLR
@ -1544,7 +1563,7 @@ gridScreenRight: .BYTE $00
shouldQuit: .BYTE $00
level: .BYTE $2
level: .BYTE $0
; A level consists of the following for each grid:
; Byte 0 - Offset of the start of this grid from the previous grid's start

View File

@ -20,7 +20,7 @@ void splashScreen(void)
printf(
// 0000000000111111111122222222223333333333
// 0123456789012345678901234567890123456789
" COLOURGO V1.0\n" // 00
" COLOURGO V1.5\n" // 00
" BY JEREMY RAND\n" // 01
"\n" // 02
"YOU MUST HAVE A COLOUR MONITOR TO PLAY\n" // 03

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

34
colourgo/make/bt Executable file
View File

@ -0,0 +1,34 @@
#!/bin/sh
if [ -z "$JAVA" ]
then
for item in "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home" /Library/Java/JavaVirtualMachines/*/Contents/Home /usr
do
if [ -x "$item/bin/java" ]
then
JAVA="$item/bin/java"
break
fi
done
fi
if [ -z "$JAVA" ]
then
echo Cannot find a path to a Java runtime.
echo Go to https://java.com/download if you do not have Java.
echo If you do have Java, you may need to uncomment the JAVA
echo line in the Makefile and set it to the path for your
echo Java runtime binary.
exit 1
fi
INPUTFILE=$1
shift
tr -d '©' < "$INPUTFILE" > /tmp/bt_filtered.$$
"$JAVA" -jar make/bastokenizer-tools-bt-0.2.0.jar $* /tmp/bt_filtered.$$
RESULT=$?
rm /tmp/bt_filtered.$$
exit $RESULT

View File

@ -1,8 +1,13 @@
#!/bin/sh
merlinStartAddr() {
awk '$1 ~ /^[oO][rR][gG]$/{print $2}' linkscript.s | sed 's/^[0$]*//'
}
if [ $# -lt 5 ]
then
echo USAGE: $0 '<AppleCommander> <machine> <diskimage> <binary>'
echo USAGE: $0 '<AppleCommander> <machine> <diskimage> <binary> <startaddress> <otherfilesordirs...>'
exit 1
fi
@ -29,16 +34,21 @@ then
fi
APPLECOMMANDER=$1
MACHINE=$2
DISKIMAGE=$3
PROGRAM=$4
STARTADDR=`echo $5 | sed 's/^0*//'`
shift
if [ ! -f "$PROGRAM" ]
then
echo "Cannot file executable $PROGRAM"
exit 1
fi
MACHINE=$1
shift
DISKIMAGE=$1
shift
PROGRAM=$1
shift
STARTADDR=`echo $1 | sed 's/^0*//'`
shift
SOURCEFILE=$PROGRAM
case "$MACHINE" in
apple2)
@ -46,8 +56,10 @@ case "$MACHINE" in
DELETELOADER=1
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=15
;;
@ -57,8 +69,10 @@ case "$MACHINE" in
DELETELOADER=1
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=15
;;
@ -68,8 +82,10 @@ case "$MACHINE" in
DELETELOADER=0
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
FILETYPE="B"
BASICFILETYPE="A"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=30
;;
@ -79,8 +95,10 @@ case "$MACHINE" in
DELETELOADER=0
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
FILETYPE="B"
BASICFILETYPE="A"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=30
;;
@ -90,8 +108,10 @@ case "$MACHINE" in
DELETELOADER=1
RENAMELOADER=0
DELETEBASIC=1
COPYBINARY=1
HASHEADER=0
FILETYPE="sys"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`.system
MAXFILENAMELEN=15
;;
@ -101,8 +121,10 @@ case "$MACHINE" in
DELETELOADER=1
RENAMELOADER=0
DELETEBASIC=1
COPYBINARY=1
HASHEADER=0
FILETYPE="sys"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`.system
MAXFILENAMELEN=15
;;
@ -112,8 +134,10 @@ case "$MACHINE" in
DELETELOADER=0
RENAMELOADER=1
DELETEBASIC=1
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=15
;;
@ -123,8 +147,10 @@ case "$MACHINE" in
DELETELOADER=0
RENAMELOADER=1
DELETEBASIC=1
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=15
;;
@ -134,8 +160,10 @@ case "$MACHINE" in
DELETELOADER=0
RENAMELOADER=1
DELETEBASIC=1
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=15
;;
@ -145,10 +173,68 @@ case "$MACHINE" in
DELETELOADER=0
RENAMELOADER=1
DELETEBASIC=1
COPYBINARY=1
HASHEADER=1
FILETYPE="bin"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=8
MAXFILENAMELEN=15
;;
apple2-basic)
TEMPLATE="make/prodos_template.dsk"
DELETELOADER=1
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=0
FILETYPE="bas"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
SOURCEFILE=${PROGRAM}.tok
MAXFILENAMELEN=15
;;
apple2-dos33-basic)
TEMPLATE="make/dos33_template.dsk"
DELETELOADER=0
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=0
FILETYPE="A"
BASICFILETYPE="A"
TARGETFILE=`basename $PROGRAM`
SOURCEFILE=${PROGRAM}.tok
MAXFILENAMELEN=30
;;
apple2-merlin)
TEMPLATE="make/prodos_template.dsk"
DELETELOADER=1
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=1
HASHEADER=0
FILETYPE="bin"
BASICFILETYPE="bas"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=15
STARTADDR=`merlinStartAddr`
;;
apple2-dos33-merlin)
TEMPLATE="make/dos33_template.dsk"
DELETELOADER=0
RENAMELOADER=0
DELETEBASIC=0
COPYBINARY=1
HASHEADER=0
FILETYPE="B"
BASICFILETYPE="A"
TARGETFILE=`basename $PROGRAM`
MAXFILENAMELEN=30
STARTADDR=`merlinStartAddr`
;;
*)
@ -157,6 +243,19 @@ case "$MACHINE" in
;;
esac
STARTARG=""
if [ ! -z "$STARTADDR" ]
then
STARTARG="0x$STARTADDR"
fi
if [ ! -f "$SOURCEFILE" ]
then
echo "Cannot file executable $SOURCEFILE"
exit 1
fi
if [ ${#TARGETFILE} -gt $MAXFILENAMELEN ]
then
echo "The filename $TARGETFILE exceeds the max name length of the filesystem ($MAXFILENAMELEN)"
@ -185,7 +284,7 @@ then
rm -f "$DISKIMAGE"
exit 1
fi
"$JAVA" -jar "$APPLECOMMANDER" -e "$DISKIMAGE" LOADER.SYSTEM | "$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$LOADERFILE" sys
"$JAVA" -jar "$APPLECOMMANDER" -g "$DISKIMAGE" LOADER.SYSTEM | "$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$LOADERFILE" sys
"$JAVA" -jar "$APPLECOMMANDER" -d "$DISKIMAGE" LOADER.SYSTEM
fi
@ -194,15 +293,81 @@ then
"$JAVA" -jar "$APPLECOMMANDER" -d "$DISKIMAGE" BASIC.SYSTEM
fi
if [ $HASHEADER -eq 1 ]
if [ $COPYBINARY -eq 1 ]
then
HDR_STARTADDR=`od -t x2 -N 2 < "$PROGRAM" | head -1 | awk '{print $2}' | sed 's/^0*//'`
if [ "$HDR_STARTADDR" = "$STARTADDR" ]
if [ "$CC65_SUPPORTS_APPLE_SINGLE" -eq 1 ]
then
dd if="$PROGRAM" bs=4 skip=1 | "$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$TARGETFILE" $FILETYPE 0x$STARTADDR
else
"$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$TARGETFILE" $FILETYPE 0x$STARTADDR < "$PROGRAM"
"$JAVA" -jar "$APPLECOMMANDER" -as "$DISKIMAGE" "$TARGETFILE" < "$SOURCEFILE"
elif [ $HASHEADER -eq 1 ]
then
HDR_STARTADDR=`od -t x2 -N 2 < "$SOURCEFILE" | head -1 | awk '{print $2}' | sed 's/^0*//'`
if [ "$HDR_STARTADDR" = "$STARTADDR" ]
then
dd if="$SOURCEFILE" bs=4 skip=1 | "$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$TARGETFILE" $FILETYPE $STARTARG
else
"$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$TARGETFILE" $FILETYPE $STARTARG < "$SOURCEFILE"
fi
else
"$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$TARGETFILE" $FILETYPE $STARTARG < "$SOURCEFILE"
fi
else
"$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$TARGETFILE" $FILETYPE < "$PROGRAM"
fi
for ITEM in $*
do
# If this is a file matching *.tok, then this is an Applesoft BASIC file
# to copy to the disk image.
if [ -f "$ITEM" ] && echo "$ITEM" | grep '\.tok$' > /dev/null
then
DESTFILE=`basename "$ITEM" | sed 's/\.tok$//'`
"$JAVA" -jar "$APPLECOMMANDER" -p "$DISKIMAGE" "$DESTFILE" "$BASICFILETYPE" 0x801 < "$ITEM"
continue
fi
if [ ! -d "$ITEM" ]
then
echo Unable to find directory $ITEM
exit 1
fi
OLDPWD=`pwd`
cd $ITEM
find . -type f -print | while read FILE
do
TRANSFERARG=-p
FILETYPE=bin
DESTFILE=`echo $FILE | sed 's/^\.\///'`
if echo $FILE | egrep '\.as$' > /dev/null
then
# If the file ends with .as, this means the input is AppleSingle format.
# Strip the .as from the end of the file name and set the args to do
# an AppleSingle transfer.
TRANSFERARG=-as
FILETYPE=""
DESTFILE=`echo $DESTFILE | sed 's/\.as$//'`
elif echo $FILE | egrep '\.[ABITSRab]$' > /dev/null
then
# If the file ends with a single character DOS 3.3 file type, then use
# that as the file type.
FILETYPE=`echo $DESTFILE | awk -F. '{print $NF}'`
DESTFILE=`echo $DESTFILE | sed 's/\.[ABITSRab]$//'`
elif echo $FILE | egrep '\.[a-zA-Z][a-zA-Z][a-zA-Z]$' > /dev/null
then
# If the file ends with a three letter extension, use that as
# the file type.
FILETYPE=`echo $DESTFILE | awk -F. '{print $NF}'`
DESTFILE=`echo $DESTFILE | sed 's/\.[a-zA-Z][a-zA-Z][a-zA-Z]$//'`
fi
# If the file type is text, convert the line feeds to carriage return
if [ $FILETYPE = txt ] || [ $FILETYPE = T ]
then
tr '\n' '\r' < $FILE | "$JAVA" -jar "$OLDPWD/$APPLECOMMANDER" $TRANSFERARG "$DISKIMAGE" "$DESTFILE" $FILETYPE
else
"$JAVA" -jar "$OLDPWD/$APPLECOMMANDER" $TRANSFERARG "$DISKIMAGE" "$DESTFILE" $FILETYPE < $FILE
fi
done
cd "$OLDPWD"
done

59
colourgo/make/errorFilter.sh Executable file
View File

@ -0,0 +1,59 @@
#!/bin/sh
PWD=`pwd`
$* 2> /tmp/errors.$$
RESULT=$?
if [ $RESULT -ne 0 ]
then
exec /usr/bin/perl -x $0 $RESULT /tmp/errors.$$ "$PWD"
fi
exit 0
#!/usr/bin/perl
use strict;
my $result = $ARGV[0];
my $filename = $ARGV[1];
my $pwd = $ARGV[2];
open(FILE, "<$filename") || die "$0: Unable to open file, $!";
my $unresolvedRefError = undef;
while (<FILE>) {
chomp;
if (defined $unresolvedRefError) {
if (m/^ ([^(]+)\(([0-9]+)\)/) {
my $file = $1;
my $lineno = $2;
if (! -f "$pwd/$file") {
$file =~ s/\.s$/.c/;
}
$_ = "$pwd/$file:$lineno:0: error: $unresolvedRefError";
} else {
$unresolvedRefError = undef;
}
}
if (m/^(Unresolved external .* referenced) in:/) {
$unresolvedRefError = $1;
$_ = "";
} elsif (m/^([^(]+)\(([0-9]+)\):(.*)$/) {
my $file = $1;
my $lineno = $2;
my $error = $3;
$_ = "$pwd/$file:$lineno:0: error: $error";
}
print STDERR "$_\n";
}
unlink($filename);
exit($result);

View File

@ -10,21 +10,74 @@
# http://www.quinndunki.com/blondihacks
#
export CC65_HOME := /usr/local/lib/cc65
CC65_BIN=/usr/local/bin
CC65_BIN = /usr/local/bin
ifneq ($(wildcard /usr/local/lib/cc65),)
export CC65_HOME := /usr/local/lib/cc65
else
export CC65_HOME := /usr/local/share/cc65
endif
CL65=$(CC65_BIN)/cl65
CA65=$(CC65_BIN)/ca65
CC65=$(CC65_BIN)/cc65
CO65=$(CC65_BIN)/co65
MERLIN_DIR=/usr/local
export MERLIN_BIN=$(MERLIN_DIR)/bin/Merlin32
export MERLIN_LIB=$(MERLIN_DIR)/lib/Merlin
MERLIN_ASM=make/merlin-asm
AC=make/AppleCommander.jar
C_SRCS=$(wildcard *.c)
ASM_SRCS=$(wildcard *.s)
SRCDIRS=.
# Check for Xcode build variables for the locations of build outputs and fall back
# to the current directory if not set.
ifeq ($(OBJECT_FILE_DIR),)
OBJDIR=.
else
export OBJECT_FILE_DIR
OBJDIR=$(OBJECT_FILE_DIR)
endif
ifeq ($(DERIVED_SOURCES_DIR),)
GENDIR=.
else
export DERIVED_SOURCES_DIR
GENDIR=$(DERIVED_SOURCES_DIR)
endif
ifeq ($(TARGET_BUILD_DIR),)
TARGETDIR=.
else
export TARGET_BUILD_DIR
TARGETDIR=$(TARGET_BUILD_DIR)
endif
MACHINE=apple2
CPU=6502
CFLAGS=
ASMFLAGS=
LDFLAGS=
DRIVERS=
DRVDIR=$(GENDIR)/drivers
MKDIR=mkdir -p
XCODE_PATH=/Applications/Xcode.app
XCODE_INFO=$(XCODE_PATH)/Contents/Info.plist
CC65_PLUGIN_PATH=$(HOME)/Library/Developer/Xcode/Plug-ins/cc65.ideplugin
CC65_PLUGIN_INFO=$(CC65_PLUGIN_PATH)/Contents/Info.plist
XCODE_PLUGIN_COMPATIBILITY=DVTPlugInCompatibilityUUID
.PHONY: all gen genclean
all:
@make gen
@make build

Binary file not shown.

View File

@ -10,98 +10,280 @@
# http://www.quinndunki.com/blondihacks
#
export PATH := $(PATH):$(CC65_BIN)
BUILD_TYPE := $(shell if echo $(MACHINE) | grep -q -- -basic; then echo basic; elif echo $(MACHINE) | grep -q -- -merlin; then echo merlin; else echo cc65; fi)
CWD=$(shell pwd)
C_OBJS=$(C_SRCS:.c=.o)
C_DEPS=$(C_SRCS:.c=.u)
ASM_OBJS=$(ASM_SRCS:.s=.o)
ASM_LSTS=$(ASM_SRCS:.s=.lst)
OBJS=$(C_OBJS) $(ASM_OBJS)
MAPFILE=$(PGM).map
DISKIMAGE=$(PGM).dsk
LINK_ARGS=
DISKIMAGE=$(TARGETDIR)/$(PGM).dsk
EXECCMD=
ALLTARGET=$(DISKIMAGE)
UNAME_S := $(shell uname -s)
ifeq ($(UNAME_S),Darwin)
ALLTARGET=execute
endif
vpath $(GENDIR)
ifneq ($(START_ADDR),)
# If the MACHINE is set to an option which does not support a variable start
# address, then error.
BASIC_SRCS=$(patsubst $(GENDIR)/%, %, $(patsubst ./%, %, $(wildcard $(addsuffix /*.bas, $(SRCDIRS)))))
BASIC_OBJS=$(patsubst %.bas, $(TARGETDIR)/%.tok, $(BASIC_SRCS))
ifeq ($(BUILD_TYPE),cc65)
export PATH := $(PATH):$(CC65_BIN)
# By default, use the a2 drivers. If the machine is one of the enhanced
# targets though, use the a2e drivers.
DRV_BASE_MACHINE=a2
BASE_MACHINE = apple2
ifneq ($(filter $(MACHINE), apple2enh apple2enh-dos33 apple2enh-system apple2enh-loader apple2enh-reboot),)
DRV_BASE_MACHINE=a2e
BASE_MACHINE = apple2enh
endif
export CC65_SUPPORTS_APPLE_SINGLE=1
CC65_CREATE_DEP_ARG=--create-dep $(@:.o=.u)
CC65_LIST_ARG=-l $(@:.o=.lst)
CC65_DRV_DIR=$(CC65_HOME)/target/$(BASE_MACHINE)/drv
MACHCONFIG= -t $(BASE_MACHINE)
ifneq ($(filter $(MACHINE), apple2-system apple2enh-system),)
$(error You cannot change start address with this machine type)
MACHCONFIG += -C $(BASE_MACHINE)-system.cfg
else
ifeq ($(PROJECT_TYPE),ca65)
MACHCONFIG += -C $(BASE_MACHINE)-asm.cfg
LDFLAGS += -u __EXEHDR__
else
MACHCONFIG += -C $(BASE_MACHINE).cfg
endif
endif
CFLAGS+=-I $(GENDIR)
ifneq ($(DRIVERS),)
SRCDIRS+=$(DRVDIR)
endif
C_SRCS=$(patsubst $(GENDIR)/%, %, $(patsubst ./%, %, $(wildcard $(addsuffix /*.c, $(SRCDIRS)))))
C_OBJS=$(patsubst %.c, $(OBJDIR)/%.o, $(C_SRCS))
C_DEPS=$(patsubst %.c, $(OBJDIR)/%.u, $(C_SRCS))
ASM_SRCS=$(patsubst $(GENDIR)/%, %, $(patsubst ./%, %, $(wildcard $(addsuffix /*.s, $(SRCDIRS)))))
ASM_OBJS=$(patsubst %.s, $(OBJDIR)/%.o, $(ASM_SRCS))
ASM_LSTS=$(patsubst %.s, $(OBJDIR)/%.lst, $(ASM_SRCS))
MAPFILE=$(TARGETDIR)/$(PGM).map
ifneq ($(START_ADDR),)
# If the MACHINE is set to an option which does not support a variable
# start address, then error.
ifneq ($(filter $(MACHINE), apple2-system apple2enh-system),)
$(error You cannot change start address with this machine type)
endif
else
# If not set, then use the default for the config as per cc65
# documentation
ifneq ($(filter $(MACHINE), apple2 apple2-dos33 apple2enh apple2enh-dos33),)
START_ADDR=803
endif
ifneq ($(filter $(MACHINE), apple2-system apple2enh-system),)
START_ADDR=2000
endif
ifneq ($(filter $(MACHINE), apple2-loader apple2-reboot apple2enh-loader apple2enh-reboot),)
START_ADDR=800
endif
endif
LDFLAGS += --start-addr 0x$(START_ADDR)
ifneq ($(filter $(MACHINE), apple2 apple2enh apple2-dos33 apple2enh-dos33),)
EXECCMD=$(shell echo brun $(PGM) | tr '[a-z]' '[A-Z]')
endif
else
# If not set, then use the default for the config as per cc65 documentation
ifneq ($(filter $(MACHINE), apple2 apple2-dos33 apple2enh apple2enh-dos33),)
START_ADDR=803
endif
ifneq ($(filter $(MACHINE), apple2-system apple2enh-system),)
START_ADDR=2000
endif
ifneq ($(filter $(MACHINE), apple2-loader apple2-reboot apple2enh-loader apple2enh-reboot),)
START_ADDR=800
endif
endif
LDFLAGS += --start-addr 0x$(START_ADDR)
C_OBJS=
C_DEPS=
ifneq ($(filter $(MACHINE), apple2 apple2enh apple2-dos33 apple2enh-dos33),)
ASM_OBJS=
ASM_LSTS=
endif
ifeq ($(BUILD_TYPE),merlin)
ASM_SRCS=$(patsubst ./%, %, $(wildcard $(addsuffix /*.s, $(SRCDIRS))))
MAPFILE=$(TARGETDIR)/_Output.txt
EXECCMD=$(shell echo brun $(PGM) | tr '[a-z]' '[A-Z]')
endif
MACHCONFIG= -t apple2
ifneq ($(filter $(MACHINE), apple2enh apple2apple2enh-dos33 apple2enh-system apple2enh-loader apple2enh-reboot),)
MACHCONFIG= -t apple2enh
ifeq ($(BUILD_TYPE),basic)
MAPFILE=
EXECCMD=$(shell echo run $(PGM) | tr '[a-z]' '[A-Z]')
endif
ifeq ($(filter $(MACHINE), apple2 apple2enh),)
MACHCONFIG += -C $(MACHINE).cfg
OBJS=$(C_OBJS) $(ASM_OBJS)
ALLTARGET=$(DISKIMAGE)
.PHONY: build execute clean cleandrivers xcodefix
build: $(ALLTARGET)
$(DISKIMAGE): $(TARGETDIR)/$(PGM) $(BASIC_OBJS)
make/createDiskImage $(AC) $(MACHINE) "$(DISKIMAGE)" "$(TARGETDIR)/$(PGM)" "$(START_ADDR)" $(BASIC_OBJS) $(COPYDIRS)
execute: $(DISKIMAGE)
osascript make/V2Make.scpt "$(TARGETDIR)" "$(PGM)" "$(CWD)/make/DevApple.vii" "$(EXECCMD)"
$(TARGETDIR)/%.tok: %.bas
$(MKDIR) `dirname $@`
make/bt $< $(BASICFLAGS) -o $@
ifneq ($(DRIVERS),)
cleandrivers:
rm -Rf "$(DRVDIR)"
else
cleandrivers:
endif
.PHONY: all execute clean
all: $(ALLTARGET)
clean:
rm -f "$(PGM)"
rm -f $(OBJS)
rm -f $(C_DEPS)
rm -f $(MAPFILE)
rm -f $(ASM_LSTS)
rm -f "$(DISKIMAGE)"
createPackage:
pkg/createPackage
clean: genclean cleandrivers
rm -f "$(TARGETDIR)/$(PGM)" $(OBJS) $(BASIC_OBJS) $(C_DEPS) $(MAPFILE) $(ASM_LSTS) "$(DISKIMAGE)"
cleanMacCruft:
rm -rf pkg
$(PGM): $(OBJS)
$(CL65) $(MACHCONFIG) --mapfile $(MAPFILE) $(LDFLAGS) -o "$(PGM)" $(OBJS)
# Some gen phase stuff...
gen: xcodefix $(DRIVERS)
$(DISKIMAGE): $(PGM)
make/createDiskImage $(AC) $(MACHINE) "$(DISKIMAGE)" "$(PGM)" "$(START_ADDR)"
xcodefix:
defaults write "$(CC65_PLUGIN_INFO)" $(XCODE_PLUGIN_COMPATIBILITY)s -array `defaults read "$(XCODE_INFO)" $(XCODE_PLUGIN_COMPATIBILITY)` || true
execute: $(DISKIMAGE)
osascript make/V2Make.scpt "$(CWD)" "$(PGM)" "$(CWD)/make/DevApple.vii" "$(EXECCMD)"
%.o: %.c
$(CL65) $(MACHCONFIG) $(CFLAGS) --create-dep -c -o $@ $<
sed -i .bak 's/\.s:/.o:/' $(@:.o=.u)
rm -f $(@:.o=.u).bak
ifeq ($(BUILD_TYPE),basic)
# Build rules for BASIC projects
%.o: %.s
$(CL65) $(MACHCONFIG) --cpu $(CPU) $(ASMFLAGS) -l -c -o $@ $<
$(TARGETDIR)/$(PGM): $(BASIC_OBJS)
cp $(TARGETDIR)/$(PGM).tok $(TARGETDIR)/$(PGM)
$(BASIC_OBJS): Makefile
endif
ifeq ($(BUILD_TYPE),merlin)
# Build rules for Merlin projects
$(TARGETDIR)/$(PGM): $(ASM_SRCS) Makefile
$(MKDIR) $(TARGETDIR)
rm -f $(TARGETDIR)/$(PGM)
$(MERLIN_ASM) linkscript.s $(PGM) $(TARGETDIR)/$(PGM)
endif
ifeq ($(BUILD_TYPE),cc65)
# Build rules for cc65 projects
$(TARGETDIR)/$(PGM): $(OBJS)
$(MKDIR) `dirname $@`
make/errorFilter.sh $(CL65) $(MACHCONFIG) --mapfile $(MAPFILE) $(LDFLAGS) -o "$(TARGETDIR)/$(PGM)" $(OBJS)
$(OBJS): Makefile
$(OBJDIR)/%.o: %.c
$(MKDIR) `dirname $@`
make/errorFilter.sh $(CL65) $(MACHCONFIG) $(CFLAGS) $(CC65_CREATE_DEP_ARG) -c -o $@ $<
sed -i .bak 's/\.s:/.o:/' $(@:.o=.u)
rm -f $(@:.o=.u).bak
$(OBJDIR)/%.o: $(GENDIR)/%.c
$(MKDIR) `dirname $@`
make/errorFilter.sh $(CL65) $(MACHCONFIG) $(CFLAGS) $(CC65_CREATE_DEP_ARG) -c -o $@ $<
sed -i .bak 's/\.s:/.o:/' $(@:.o=.u)
rm -f $(@:.o=.u).bak
$(OBJDIR)/%.o: %.s
$(MKDIR) `dirname $@`
make/errorFilter.sh $(CL65) $(MACHCONFIG) --cpu $(CPU) $(ASMFLAGS) $(CC65_LIST_ARG) -c -o $@ $<
$(OBJDIR)/%.o: $(GENDIR)/%.s
$(MKDIR) `dirname $@`
make/errorFilter.sh $(CL65) $(MACHCONFIG) --cpu $(CPU) $(ASMFLAGS) $(CC65_LIST_ARG) -c -o $@ $<
.PHONY: loresgr hiresgr auxmem joystick mouse serial
# Lores driver codegen
loresgr: $(DRVDIR)/a2_lores_drv.s $(DRVDIR)/a2_lores_drv.h
$(DRVDIR)/a2_lores_drv.s: $(CC65_DRV_DIR)/tgi/$(DRV_BASE_MACHINE).lo.tgi
mkdir -p $(DRVDIR)
$(CO65) --code-label _a2_lores_drv -o $@ $(CC65_DRV_DIR)/tgi/$(DRV_BASE_MACHINE).lo.tgi
$(DRVDIR)/a2_lores_drv.h:
mkdir -p $(DRVDIR)
echo '#include <tgi.h>' > $@
echo 'extern char a2_lores_drv;' >> $@
# Hires driver codegen
hiresgr: $(DRVDIR)/a2_hires_drv.s $(DRVDIR)/a2_hires_drv.h
$(DRVDIR)/a2_hires_drv.s: $(CC65_DRV_DIR)/tgi/$(DRV_BASE_MACHINE).hi.tgi
mkdir -p $(DRVDIR)
$(CO65) --code-label _a2_hires_drv -o $@ $(CC65_DRV_DIR)/tgi/$(DRV_BASE_MACHINE).hi.tgi
$(DRVDIR)/a2_hires_drv.h:
mkdir -p $(DRVDIR)
echo '#include <tgi.h>' > $@
echo 'extern char a2_hires_drv;' >> $@
# Auxmem driver codegen
auxmem: $(DRVDIR)/a2_auxmem_drv.s $(DRVDIR)/a2_auxmem_drv.h
$(DRVDIR)/a2_auxmem_drv.s: $(CC65_DRV_DIR)/emd/$(DRV_BASE_MACHINE).auxmem.emd
mkdir -p $(DRVDIR)
$(CO65) --code-label _a2_auxmem_drv -o $@ $(CC65_DRV_DIR)/emd/$(DRV_BASE_MACHINE).auxmem.emd
$(DRVDIR)/a2_auxmem_drv.h:
mkdir -p $(DRVDIR)
echo '#include <em.h>' > $@
echo 'extern char a2_auxmem_drv;' >> $@
# Joystick driver codegen
joystick: $(DRVDIR)/a2_joystick_drv.s $(DRVDIR)/a2_joystick_drv.h
$(DRVDIR)/a2_joystick_drv.s: $(CC65_DRV_DIR)/joy/$(DRV_BASE_MACHINE).stdjoy.joy
mkdir -p $(DRVDIR)
$(CO65) --code-label _a2_joystick_drv -o $@ $(CC65_DRV_DIR)/joy/$(DRV_BASE_MACHINE).stdjoy.joy
$(DRVDIR)/a2_joystick_drv.h:
mkdir -p $(DRVDIR)
echo '#include <joystick.h>' > $@
echo 'extern char a2_joystick_drv;' >> $@
# Mouse driver codegen
mouse: $(DRVDIR)/a2_mouse_drv.s $(DRVDIR)/a2_mouse_drv.h
$(DRVDIR)/a2_mouse_drv.s: $(CC65_DRV_DIR)/mou/$(DRV_BASE_MACHINE).stdmou.mou
mkdir -p $(DRVDIR)
$(CO65) --code-label _a2_mouse_drv -o $@ $(CC65_DRV_DIR)/mou/$(DRV_BASE_MACHINE).stdmou.mou
$(DRVDIR)/a2_mouse_drv.h:
mkdir -p $(DRVDIR)
echo '#include <mouse.h>' > $@
echo 'extern char a2_mouse_drv;' >> $@
# Serial driver codegen
serial: $(DRVDIR)/a2_serial_drv.s $(DRVDIR)/a2_serial_drv.h
$(DRVDIR)/a2_serial_drv.s: $(CC65_DRV_DIR)/ser/$(DRV_BASE_MACHINE).ssc.ser
mkdir -p $(DRVDIR)
$(CO65) --code-label _a2_serial_drv -o $@ $(CC65_DRV_DIR)/ser/$(DRV_BASE_MACHINE).ssc.ser
$(DRVDIR)/a2_serial_drv.h:
mkdir -p $(DRVDIR)
echo '#include <serial.h>' > $@
echo 'extern char a2_serial_drv;' >> $@
endif
-include $(C_DEPS)

View File

@ -14,11 +14,7 @@
#include "mouseWrapper.h"
#include "game.h"
#include "vbl.h"
// Extern to mouse driver
extern char a2e_stdmou_mou;
#include "drivers/a2_mouse_drv.h"
// Globals
@ -40,7 +36,7 @@ bool initMouse(void)
gMouseDrvCallbacks.movex = mouse_def_callbacks.movex;
gMouseDrvCallbacks.movey = mouse_def_callbacks.movey;
if (mouse_install(&gMouseDrvCallbacks, &a2e_stdmou_mou) == 0) {
if (mouse_install(&gMouseDrvCallbacks, &a2_mouse_drv) == 0) {
gMouseInstalled = true;
// This is required to ensure that the show callback is called

View File

@ -9,8 +9,7 @@
.export _vblWait, _vblWaitNon2c, _vblWait2c, _vblInit2gs
.export _gVblWait
.interruptor _vblIRQCallback
.export _gVblWait, _vblIRQCallback
.include "apple2.inc"