Recent Posts

Pages: [1] 2 3 ... 10
* to package their bads
AGI Development Tools / Re: How to distribute fan made translation?
« Last post by Collector on February 21, 2021, 07:55:10 PM »
You can find more on the NSIS Wiki and there is the NSIS subforum on the Winamp forum if you need more guidance.
AGI Development Tools / Re: Introducing agikit
« Last post by Collector on February 21, 2021, 07:50:30 PM »
I saw your name and was wondering if you were the same natbudin that did a couple of fan AGI games. Welcome. There are a few from the old AGI crowd that has reemerged here, Peter Kelly, Lance Ewing, and Chris Cromer. Andrew Korson has been fairly active here, too.
AGI Development Tools / Re: Russian translation / AGDS tool?
« Last post by Collector on February 21, 2021, 07:39:49 PM »
AGDS has been available on the Wiki for some time, now.
Apparently, it violates the Terms of Service, since it is allegedly infected with a virus. Try again. I think the Vpatch.exe is what set it off. Fortunately, the .vpj file, the important uncompiled patch file, is still there.

I have never had Vpatch.exe flagged as malware, but the stub files with NSIS sometimes will give a false positive since a number of malware authors have used NSIS to package their goods. Usually just zipping the compiled installers is enough to get scanners to ignore them.
AGI Development Tools / Re: How to distribute fan made translation?
« Last post by ZvikaZ on February 21, 2021, 03:59:43 AM »
The GUI isn't installed by default, but it doesn't really matter. I prefer without GUIs ;)

@Collector, it's a great tool, but it'd be nice to elaborate a little in the documentation (e.g, recommend usage of the 'VPatchFile' macro) and give more complete example (e.g., with error catching).

If it's interesting anyone, I'm pasting my code, complete with backing up the original files, a handy macro, an uninstaller, removing of previous installation before installing a new one, and registering to Windows Add/Remove programs.

Code: [Select]
# In order to create the patches, run:
# "C:\Program Files (x86)\NSIS\Bin\GenPat.exe" C:\Zvika\Games\PoliceQuest\AGI.check\WORDS.TOK C:\Zvika\Games\PoliceQuest\AGI\WORDS.TOK WORDS.TOK.patch
# "C:\Program Files (x86)\NSIS\Bin\GenPat.exe" C:\Zvika\ames\PoliceQuest\AGI.check\LOGDIR C:\Zvika\Games\PoliceQuest\AGI\LOGDIR logdir.patch
# "C:\Program Files (x86)\NSIS\Bin\GenPat.exe" C:\Zvika\Games\PoliceQuest\AGI.check\VOL.0 C:\Zvika\Games\PoliceQuest\AGI\VOL.0 VOL.0.patch

!include MUI2.nsh

!define UNINSTALLER_NAME "pq1_heb_uninsaller.exe"

!macro BackupAndUpdateFile FILE
    IfFileExists "$INSTDIR\${BACKUPDIR}\*.*" +2
        CreateDirectory "$INSTDIR\${BACKUPDIR}"
    IfFileExists "$INSTDIR\${BACKUPDIR}\${FILE}" +2
        CopyFiles "$INSTDIR\${FILE}" "$INSTDIR\${BACKUPDIR}\${FILE}"

    DetailPrint "Updating ${FILE} using patch..."
    !insertmacro VPatchFile ${FILE}.patch "$INSTDIR\${FILE}" "$INSTDIR\${FILE}.tmp"

    IfErrors 0 +2

Name "התרגום העברי של PQ1"

OutFile "pq1-hebrew-installer.exe"

BrandingText "הרפתקה עברית"
Unicode true

InstallDir "C:\Zvika\Games\PoliceQuest\AGI.check"  #TODO remove this

!define MUI_TEXT_WELCOME_INFO_TEXT "ברוכים הבאים.$\r$\n \
$\r$\n \
לפני שנמשיך, יש לוודא כי:$\r$\n$\r$\n  \
ē יש ברשותך עותק תקין של PQ1 בגרסה המקורית עם ממשק הקלדת פקודות (ניתן לקנות ב GoG)$\r$\n \
ē מותקנת גרסת Daily של ScummVM$\r$\n \
ē המשחק באנגלית רץ בצורה תקינה ב ScummVM" ;" ; gvim get's confused without that extra "

!define MUI_FINISHPAGE_TEXT  "ההתקנה הושלמה בהצלחה.$\r$\n$\r$\n \
נשמח לשמור על קשר! $\r$\n \
חפשו 'הרפתקה עברית' בפייסבוק.$\r$\n \
מוזמנים להצטרף לדיונים, או סתם לראות איך דברים נראים מאחורי הקלעים, בערוץ הדיסקורד שלנו \
(קישור בתחתית העמוד)." ;"

!define MUI_FINISHPAGE_LINK "הצטרפות לדיסקורד 'הרפתקה עברית'"

!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_FINISH
!insertmacro MUI_UNPAGE_FINISH

!insertmacro MUI_LANGUAGE "Hebrew"

; The text to prompt the user to enter game's directory
DirText "בחר את התיקייה שקבצי PQ1 נמצאים בה"

!include "VPatchLib.nsh"

Section "Update file"
    ; Set output path to the installation directory
    SetOutPath $INSTDIR

    !insertmacro BackupAndUpdateFile VOL.0
    !insertmacro BackupAndUpdateFile LOGDIR
    !insertmacro BackupAndUpdateFile WORDS.TOK
    File agi-font-dos.bin
    File PQ1.WAG

    WriteUninstaller $INSTDIR\${UNINSTALLER_NAME}

    WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PQ1_Hebrew" \
                     "DisplayName" "PQ1 Hebrew translation"
    WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PQ1_Hebrew" \
                     "UninstallString" "$INSTDIR\${UNINSTALLER_NAME}"

Section "Uninstall"
    Delete $INSTDIR\agi-font-dos.bin
    Delete $INSTDIR\PQ1.WAG
    CopyFiles "$INSTDIR\${BACKUPDIR}\*.*" $INSTDIR
    Rmdir /r "$INSTDIR\${BACKUPDIR}"
    DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\PQ1_Hebrew"
Function .onInit
    IfFileExists $INSTDIR\${UNINSTALLER_NAME} 0 +3
        MessageBox MB_OK "יש להסיר תחילה את ההתקנה הישנה"

AGI Development Tools / Introducing agikit
« Last post by natbudin on February 20, 2021, 01:46:26 PM »
Hey AGI fans!  I'm pleased to introduce something I've been working on.  It's called agikit, and it's the beginnings of a cross-platform development toolchain for AGI.  agikit is written in TypeScript and aims to provide an extensible, flexible, open-source platform for building AGI development tools.  It is very, very early stage right now.  :)

NPM page:
Github repo:

Itís super early stage, itís not yet compatible with WinAGI, AGI Studio, or other similar tools, but: it can decompile and recompile Kingís Quest I, and the result runs in ScummVM.

Why do this, particularly when good IDEs are already out there?  Part of the reason was just nostalgia; I used to make AGI fan games back in high school and I wanted to revisit it now that I'm older and know more about software development.  Additionally, I wanted it to be possible to develop AGI games on non-Windows platforms and using your choice of text editor.  This isn't intended in any way to compete with the excellent tools that exist, but rather, to open up the world of AGI development to a wider audience.

Another big reason for this is that I wanted to learn about how compilers really work by building one, so the resulting app here is quite different from how Qt AGI Studio works, in that it does AST generation, control flow analysis, optimization passes, etc.  One interesting result of this is that the code it generates can't (yet) be decoded by Qt AGI Studio, because it can potentially reorder blocks in a way that doesn't guarantee that conditionals contain all their sub-statements in the assembled LOGIC resource.  I'm hoping to add an option to generate AGI Studio-compatible LOGIC resources in a future release, probably as a post-compilation reordering pass through the assembly code.  (I'm unsure whether all of this applies to WinAGI or not, because I don't have access to a Windows machine to try it on, but if someone would be willing to let me know, I'd greatly appreciate it!)

Right now all this compiler infrastructure doesnít actually amount to much, because the script language it compiles is very structurally similar to the binary LOGIC format, but because it does these things, it should be possible to greatly extend it to include stuff like functions, loops, and even variable types AGI doesnít natively support.  It also should make it easier to build a language server so someone could (for example) write AGI games in Visual Studio Code with full auto-completion and code navigation support.

Aside from this limitation, there are several other big ones right now that I hope to fix soon:

  • Only supports AGI version 2 for now
  • Doesn't fully support the LOGIC syntax in the standard:
    • Doesn't yet understand operators such as ==, <, >, +=, etc
    • #define (and therefore named variables) isn't yet supported
    • Probably other stuff
  • Doesn't decode or compile OBJECT files yet
  • Doesn't compile WORDS.TOK yet

As you can see, it is nowhere near ready for use, but overall Iím pretty pleased with how itís turned out so far!  I'd love any feedback folks have.
"It will also use the music from the Macintosh version as it has native General MIDI tracks (unlike the DOS version, which uses a music patch for the MT-32 tracks)."

Thanks for posting this. I'm going to guess that they (MT->GM and "native" GM) are one and the same.. but in case not, can you send me the SND files from the Mac version? :)

Also, have you found this with any other Mac version?

I just sent you a link to the files. They are in fact redone in native GM, not patched MT-32 tracks. I have no idea if the other Mac versions got the same treatment.
That sounds like a pretty simple way to do it to me! Thanks.
Here's how I do it (there may be different/better ways).  Reference the entire inventory, then update based on the index of the item in the inventory using the constant defined for the inventory item in

To set the value:
Code: [Select]
    ((gInv at: INV_TEST_OBJECT) count: 3)

To get the value:
Code: [Select]
    (FormatPrint "count = %d" ((gInv at: INV_TEST_OBJECT) count?))
Pages: [1] 2 3 ... 10

SMF 2.0.14 | SMF © 2017, Simple Machines
Simple Audio Video Embedder

Page created in 0.11 seconds with 17 queries.