Author Topic: JAGI redux - Java AGI Interpreter  (Read 2992 times)

0 Members and 1 Guest are viewing this topic.

Offline vafada

JAGI redux - Java AGI Interpreter
« on: December 01, 2022, 07:27:20 PM »
I'd like to announce that after hundreds of commits, JAGI is now in a playable state:

https://github.com/vafada/jagi

That is my fork of JAGI which a fork from @lance.ewing JAGI repo (https://github.com/lanceewing/jagi)

Dr. Z started the JAGI project, at the time it was abandoned, it wasn't really in a playable state. Though almost 90% of the code was already done. Lance Ewing did some fixes on Oct 2016 and then development stopped.

I started plugging all holes and fixing bugs starting on Sept 2022 using AGILE as reference, learning a lot during the process.

Now it's at a state where is usable.

Most of the features are now implemented, saving and restoring game, LSL quiz part, display inventory, etc.

I was able to finish KQ1 and SQ1 using JAGI.

I'm sure there are still weird bugs out there but for now its at a really good state.




Offline lance.ewing

Re: JAGI redux - Java AGI Interpreter
« Reply #1 on: December 02, 2022, 03:01:18 AM »
Hey, that's really good work! Well done! I'm glad that someone has picked that up and progressed it further. I haven't had a chance to take much of a look, but I did load up SQ1 and moved around a few rooms, picked up an item. Quite impressive that you were able to finish SQ1 and KQ1. It must be quite complete then. I'll take a better look at it tomorrow morning my time. I'm quite looking forward to it, as I remember that JAGI had some quite cool debug features. I think I had a feature branch in my repo for debugging the Apple II AGI V1 games. Can't remember how far I got with that though.


Offline Collector

Re: JAGI redux - Java AGI Interpreter
« Reply #2 on: December 02, 2022, 10:04:24 AM »
I wonder how hard it would be to add those debug features to Agile?
KQII Remake Pic

Offline vafada

Re: JAGI redux - Java AGI Interpreter
« Reply #3 on: December 02, 2022, 11:29:46 AM »
ohh.. i haven't played much with the debugger... let me try working on it.

I just push a fix so the debugger will display the current values of the variables and flags but it doesn't refresh when a value changes.... ill work on that soon

edit: that was easy.... the debug window should update vars and flags in real time.

https://github.com/vafada/jagi/blob/master/img/ss11.png

« Last Edit: December 02, 2022, 12:14:53 PM by vafada »

Offline lance.ewing

Re: JAGI redux - Java AGI Interpreter
« Reply #4 on: December 02, 2022, 03:27:16 PM »
I've had another play with it, this time trying out the debugger. I really like how it can step through the code line by line like a real debugger (which obviously it is  ;D) and the variables update in real time. This is definitely something that will be useful for people working on building AGI games.

A few observations that I'm sure you have probably seen:

  • I noticed that the game screen seems to cut off the right and bottom edges. Does it do that for you?
  • Also, the speed seems a little slower than the original interpreter. Increasing the speed to "fast" or "fastest" does increase the speed, but not as much as the original interpreter. I find that I have to increase the speed to "fastest" in order to move around quick enough to be useful. Did you find that as well?
  • And I noticed that the responsiveness to the keyboard is a little sluggish. For example, hitting a key to skip the intro is almost always ignored. Hitting again and again... no response. But if I hold down a key, then it picks it up, but by then it seems too late, as it has then picked up multiple occurrences of the key. So in SQ1, if I hold down the SPACE key to skip the intro, then the player name entry screen ends up with lots of spaces in it.
  • TAB key is not working for viewing inventory.
  • The window's close button is not working.


Offline lance.ewing

Re: JAGI redux - Java AGI Interpreter
« Reply #5 on: December 02, 2022, 03:38:07 PM »
I wonder how hard it would be to add those debug features to Agile?

The way I eventually see that working is that the Visual AGI repo you're putting together would effectively become the debug tool for AGILE. So the interaction between those two could be two way. The official AGILE release would start in AGILE mode, i.e. expecting to run a game, but if you launch the debug mode from within it, then the game execution would pause and Visual AGI would pop up, which would (in a future version) include the ability to step through the LOGIC code and see the current values of the variables and flags change, similar to how JAGI is doing it.

And likewise, the official release build of Visual AGI would start in the editor mode, i.e. where it expects someone to load a game for editing and viewing, but when the game is run, then it launches AGILE.

Given that both are using the AGI Library, then hopefully that kind of two way integration would be fairly clean to get working.

Offline vafada

Re: JAGI redux - Java AGI Interpreter
« Reply #6 on: December 02, 2022, 04:12:19 PM »
I've had another play with it, this time trying out the debugger. I really like how it can step through the code line by line like a real debugger (which obviously it is  ;D) and the variables update in real time. This is definitely something that will be useful for people working on building AGI games.

A few observations that I'm sure you have probably seen:

  • I noticed that the game screen seems to cut off the right and bottom edges. Does it do that for you?
  • Also, the speed seems a little slower than the original interpreter. Increasing the speed to "fast" or "fastest" does increase the speed, but not as much as the original interpreter. I find that I have to increase the speed to "fastest" in order to move around quick enough to be useful. Did you find that as well?
  • And I noticed that the responsiveness to the keyboard is a little sluggish. For example, hitting a key to skip the intro is almost always ignored. Hitting again and again... no response. But if I hold down a key, then it picks it up, but by then it seems too late, as it has then picked up multiple occurrences of the key. So in SQ1, if I hold down the SPACE key to skip the intro, then the player name entry screen ends up with lots of spaces in it.
  • TAB key is not working for viewing inventory.
  • The window's close button is not working.

the TAB issue, screen cutting out and the window's close button works on non-debug app (AGI.java), the windows close button definitely does not work on debug mode (AGId.java)

the speed and keyboard responsive is definitely some issues i've seen on AGI.java

I'll start playing around AGId.java, I was concentrated on AGI.java (regular gameplay)

I just recently fixed AGId.java to allow to view/edit variables and flags during game play and its wacky... i can teleport, change score, turn sound off/on, etc...  ;D

I'll add view/edit inventory items on AGId.java


I'm looking forward on the Visual AGI project!


Offline Collector

Re: JAGI redux - Java AGI Interpreter
« Reply #7 on: December 03, 2022, 10:02:24 AM »
  • The window's close button is not working.

That was a problem with NAGI.
KQII Remake Pic

Offline Collector

Re: JAGI redux - Java AGI Interpreter
« Reply #8 on: December 03, 2022, 10:38:36 AM »
Programming-wise, I have been working on little else than Visual AGI. I ended up dredging up an old copy of Visual AGI to start from and and updated those to newer VS standards. It did not split form scripts into two partial classes. I had split them earlier, but not perfectly. The Main method was not in the designer class, etc. It had depreciated controls that needed to be replaced and added Lance's updated AGI Library.

After that I started adding in things I liked from my old Developer project. Some of those relied on using the Registry that I have been moving to the app settings and XML to keep a light touch on the Registry. Adding those features brought in bits SCI from the old AGI-SCI Developer that I have been stripping out as I add them.

Right now I am in the process of cleaning up the code. The Pic and View editors are working and I wrote a nice logic editor, even if it is not yet hooked into the AGI library. As soon as it is in better shape I'll put a repo of it on GitHub for the two of you to start kicking around.
« Last Edit: December 03, 2022, 08:37:30 PM by Collector »
KQII Remake Pic

Offline lance.ewing

Re: JAGI redux - Java AGI Interpreter
« Reply #9 on: December 03, 2022, 01:23:13 PM »
the TAB issue, screen cutting out and the window's close button works on non-debug app (AGI.java), the windows close button definitely does not work on debug mode (AGId.java)

Ah, yes, I have now tried the non-debug AGI main class, and, as you say, those issues are not present. So they're only in AGId.

I just recently fixed AGId.java to allow to view/edit variables and flags during game play and its wacky... i can teleport, change score, turn sound off/on, etc...  ;D

Nice!  :)

Offline lance.ewing

Re: JAGI redux - Java AGI Interpreter
« Reply #10 on: December 03, 2022, 01:24:48 PM »
Programming-wise, I have been working on little else than Visual AGI. I ended up dredging up an old copy of Visual AGI to start from and and updated those to newer VS standards. did not split form scripts into two partial classes. I had split them earlier, but not perfectly. The Main method was not in the designer class, etc. It had depreciated controls that needed to be replaced and added Lance's updated AGI Library.

After that I started adding in things I liked from my old Developer project. Some of those relied on using the Registry that I have been moving to the app settings and XML to keep a light touch on the Registry. Adding those features brought in bits SCI from the old AGI-SCI Developer that I have been stripping out as I add them.

Right now I am in the process of cleaning up the code. The Pic and View editors are working and I wrote a nice logic editor, even if it is not yet hooked into the AGI library. As soon as it is in better shape I'll put a repo of it on GitHub for the two of you to start kicking around.

Sounds like you're making good progress. I look forward to seeing it.


SMF 2.0.19 | SMF © 2021, Simple Machines
Simple Audio Video Embedder

Page created in 0.061 seconds with 22 queries.