|
Post by Jonathan Cauldwell on Feb 17, 2018 22:53:36 GMT
New this time: Added an Amstrad CPC engine and compiler. Converting games from one platform to another should just be a case of dropping dropping in new graphics and very little else, even DEFINEOBJECT and SPRITEPOSITION coordinates will not have to change between versions. I've fixed a bug which meant that some variables were not being set properly and CONTROL could not be accessed at all. The language reference has been updated for all three formats and the Test.AGD example file has been expanded slightly. There's also a new coding template file for the Amstrad CPC as the machine uses JOYSTICK0 and JOYSTICK1 in place of KEMPSTON and SINCLAIR. Enjoy! AGD0.4.zip (226.79 KB)
|
|
|
Post by alessandro on Feb 18, 2018 14:53:40 GMT
Hi Jonathan, since there was no executable file within the archive, I compiled the CompileZX.c file myself by using an open source program named Dev-C++. Then I obtained a CompileZX.exe file which I renamed to AGD.exe. I tried to create an ASM file out of the test.AGD file provided with the archive, which I emendated by deleting all references to non-Spectrum code and the semicolons before Spectrum code. But after entering "AGD test" at the command prompt, a copyright message appeared, followed by a window telling me that AGD.exe had stopped working. In the directory, a number of test.* files appeared, all of them 0 bytes long. Issuing the command with administrator privileges had no effect. My OS is Windows 10, Home edition, 64-bit.
|
|
|
Post by Jonathan Cauldwell on Feb 18, 2018 18:37:41 GMT
Oops, seems it didn't like me setting up filenames with { NULL }. Here's a new version containing x64 executables and updated .c files. AGD0.4.zip (337.31 KB)
|
|
|
Post by tpenalver on Feb 19, 2018 9:03:04 GMT
I compile the CPC version to 32 bits version but have the same problem. Crash after create empty files!!!
|
|
kma
Cold Store
Posts: 3
|
Post by kma on Feb 19, 2018 14:47:51 GMT
I get this with the new download. C:\Users\Barry\Desktop\AGD0.4>CompilerZX.exe MainLoopScrollingLandscape.AGD AGD Compiler for ZX Spectrum Version 0.4 (C) Jonathan Cauldwell February 2018 Sourcename: MainLoopScrollingLandscape.AGD.agd Output: MainLoopScrollingLandscape.AGD.asm
C:\Users\Barry\Desktop\AGD0.4>sjasmplus.exe -iC:\Users\Barry\Desktop\AGD0.4 MainLoopScrollingLandscape.AGD.asm SjASMPlus Z80 Cross-Assembler v1.07 RC7 (build 02-04-2008) Pass 1 complete (0 errors) Pass 2 complete (0 errors) MainLoopScrollingLandscape.AGD.asm(65): error: Label not found: WINDOWTOP MainLoopScrollingLandscape.AGD.asm(66): error: Label not found: WINDOWLFT MainLoopScrollingLandscape.AGD.asm(67): error: Label not found: WINDOWHGT MainLoopScrollingLandscape.AGD.asm(68): error: Label not found: WINDOWWID MainLoopScrollingLandscape.AGD.asm(75): error: Label not found: WINDOWTOP MainLoopScrollingLandscape.AGD.asm(76): error: Label not found: WINDOWLFT MainLoopScrollingLandscape.AGD.asm(77): error: Label not found: WINDOWTOP
|
|
|
Post by billamu on Feb 20, 2018 2:16:00 GMT
Hi kma, I had a similar issue with the CPC exporter with "Label not found: WINDOWTOP" etc.
|
|
|
Post by tpenalver on Feb 20, 2018 8:22:00 GMT
Hi, The same thing happens to me, but when I do it in WinAPE
Undefined Symbols .....
|
|
|
Post by Jonathan Cauldwell on Feb 20, 2018 16:40:25 GMT
Sorry for the confusion folks, the code templates are not complete game files, just snippets of code to be copied into the relevant events. The only two complete files are test.agd and skeleton.agd. You're right, it's confusing and I should have made that clear in the instructions.
You should be able to build test.agd for the CPC by typing CompilerCPC test (EDIT: without the .agd extension). Hopefully that will create an assembler listing, test.asm, which can be loaded into the assembler in WinApe. Type MEMORY 1999 first, then assemble with F9. Type call 2000 to run the game.
Editing test.agd you should see where the blocks, sprites and objects are defined. Spectrum and Timex versions are commented out so if you want to build for either of those machines you'll need to uncomment the relevant blocks and comment out the CPC ones instead.
Thought I'd taken out that scrolling landscape event, obviously must have forgotten to remove it.
|
|
kma
Cold Store
Posts: 3
|
Post by kma on Feb 21, 2018 10:59:24 GMT
Hi, I am now trying out test.agd with the spectrum code enabled and cpc code disabled. I still get errors with the labels not being found. I am using sjasmplus to compile it. Is there something specific I need to add to get it to compile?
|
|
|
Post by tpenalver on Feb 21, 2018 13:00:10 GMT
Sorry for the confusion folks, the code templates are not complete game files, just snippets of code to be copied into the relevant events. The only two complete files are test.agd and skeleton.agd. You're right, it's confusing and I should have made that clear in the instructions. You should be able to build test.agd for the CPC by typing CompilerCPC test.agd. Hopefully that will create an assembler listing, test.agd.asm, which can be loaded into the assembler in WinApe. Type MEMORY 1999 first, then assemble with F9. Type call 2000 to run the game. Editing test.agd you should see where the blocks, sprites and objects are defined. Spectrum and Timex versions are commented out so if you want to build for either of those machines you'll need to uncomment the relevant blocks and comment out the CPC ones instead. Thought I'd taken out that scrolling landscape event, obviously must have forgotten to remove it. Hi, i've 47 errors when try assemble with f9 in winAPE (test.agd.asm)
|
|
|
Post by alessandro on Feb 22, 2018 11:43:22 GMT
Hi, I am now trying out test.agd with the spectrum code enabled and cpc code disabled. I still get errors with the labels not being found. I am using sjasmplus to compile it. Is there something specific I need to add to get it to compile? Hi kma, after Jonathan released the second version with the compiler executable, I tested it with the TEST.AGD file, which I also previously emendated by deleting all Next and CPC code, and adding an ORG 32000 directive before the start: label. At the command prompt I entered: CompilerZX testand a TEST.ASM file, together with other files, was created. Then I assembled it with Pasmo, by entering: pasmo --t test.asm test.tapand the TEST.TAP file was created. Then I launched Spectaculator, inserted the file in the virtual tape recorder, and at the 48K command prompt I entered: CLEAR 31999: LOAD "" CODE: RANDOMIZE USR 32000and the test game was launched.
|
|
|
Post by Jonathan Cauldwell on Feb 22, 2018 19:35:42 GMT
Thanks for confirming that you got it to build Alessandro. Sorry for the confusion folks, the code templates are not complete game files, just snippets of code to be copied into the relevant events. The only two complete files are test.agd and skeleton.agd. You're right, it's confusing and I should have made that clear in the instructions. You should be able to build test.agd for the CPC by typing CompilerCPC test.agd. Hopefully that will create an assembler listing, test.agd.asm, which can be loaded into the assembler in WinApe. Type MEMORY 1999 first, then assemble with F9. Type call 2000 to run the game. Editing test.agd you should see where the blocks, sprites and objects are defined. Spectrum and Timex versions are commented out so if you want to build for either of those machines you'll need to uncomment the relevant blocks and comment out the CPC ones instead. Thought I'd taken out that scrolling landscape event, obviously must have forgotten to remove it. Hi, i've 47 errors when try assemble with f9 in winAPE (test.agd.asm) I've been playing around and recreated your results, 47 errors in WinApe. If you type CompilerCPC test.agd then this creates a listing, test.agd.asm, which generates 47 errors. If you type CompilerCPC test you should get a listing, test.asm, which assembles without errors. This is slightly unexpected behaviour, I'll look at making sure both methods work in future. Meanwhile, I've amended my previous post accordingly. Just leave out the .agd extension for now.
|
|
kma
Cold Store
Posts: 3
|
Post by kma on Feb 26, 2018 12:24:45 GMT
I have managed to compile it and get it into spectaculator but for some reason I cant redefine the keys? Also what keys is it meant to use? So far it seems to be 2,w,9,0.
|
|
|
Post by tpenalver on Feb 26, 2018 16:30:19 GMT
Thanks for confirming that you got it to build Alessandro. Hi, i've 47 errors when try assemble with f9 in winAPE (test.agd.asm) I've been playing around and recreated your results, 47 errors in WinApe. If you type CompilerCPC test.agd then this creates a listing, test.agd.asm, which generates 47 errors. If you type CompilerCPC test you should get a listing, test.asm, which assembles without errors. This is slightly unexpected behaviour, I'll look at making sure both methods work in future. Meanwhile, I've amended my previous post accordingly. Just leave out the .agd extension for now. Really works. Thanks for your support!!!
|
|
|
Post by oss003 on Mar 5, 2018 14:25:48 GMT
Jonathan, I have a question about the AGDv0.4 compiler: The compiler converts LINE in charx and COLUMN in chary. This works fine for messages but not for the routine pattr. Pattr used dispx and dispy to calculate the screenaddress. Does this work for you or did you add a patch?
|
|