Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 11:17 01 Aug 2025 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : Gauntlet: 2 players support

Author Message
MauroXavier
Guru

Joined: 06/03/2016
Location: Brazil
Posts: 303
Posted: 11:16pm 30 Aug 2020
Copy link to clipboard 
Print this post

Hello to all!

Today I published the new version of Gauntlet (0.4a) in GitHub:
https://github.com/mauroxavierneto/gauntlet_cmm2

And a video testing with my eight years son (but we doesn´t appear in the video, yet):
https://www.youtube.com/watch?v=jlyQugnwijw

For now, the controller inputs supported are only Wii Classic Controller and the keyboard, the Wii Nunchuk maybe will be available in the next release.

Internally the game is prepared to four players experience, but I will make it only when the game have optimized to get a stable speed.

I appreciate any feedback about the game and with the two players experience too.
 
capsikin
Guru

Joined: 30/06/2020
Location: Australia
Posts: 341
Posted: 05:37am 31 Aug 2020
Copy link to clipboard 
Print this post

Cool, I've just watch some of the video. I stopped at the treasure room to leave myself some surprises in the game. I'm not sure but I think it might  be running faster than before
Edited 2020-08-31 15:38 by capsikin
 
MauroXavier
Guru

Joined: 06/03/2016
Location: Brazil
Posts: 303
Posted: 11:26am 31 Aug 2020
Copy link to clipboard 
Print this post

Yes, it's a little faster. I'm trying to optimize the code a little while programming but isn't all focused on this now.

For the next releases, I must create the level editor and some new features that are part of the original game, like potions for extra enhancements, transporters, trap floors, and some annoying enemies, like the lobbers and thieves.

About the performance, the goal is to keep about 20/30 FPS, which appears to be slow but the current version is running at a maximum of 20 FPS and is still playable because none of the movements is one pixel-based, almost all moves by four to eight pixels grid.

I know to keep a 20 FPS with 50 or more enemies on screen with four players at the same time will be a great challenge, but I do not quit so easily.

I'm counting with the community to help me with the tests and to create some levels.
 
Sasquatch

Guru

Joined: 08/05/2020
Location: United States
Posts: 377
Posted: 02:04am 01 Sep 2020
Copy link to clipboard 
Print this post

Great Work Mauro

The latest version does not seem to work with OPTION RAM enabled.  I'm not sure exactly, but it seems to have something to do with accessing the higher numbered graphics pages in Mode 7,16 and Mode 7,8.  No worries though it works great in flash memory.  I am using the recent V5.05.05 release version of MMBasic.

Your quest for performance has gone almost too far now.  The action seems really fast!  Is there a simple way to slow the action down just a little for us older players?

Oh, and the Wii Classic Controller works fine, I haven't tried 2 player mode yet.

Update:  Ok well the Elf seems really fast and Thor seems a bit too slow.  The others are harder to judge somewhere in between?  I think the relative speeds are intentional?  Perhaps for us older folks it might be best to use the Wizard!

2 player mode seems to work as well as I can test by myself.  Now I just need to get the wife to play    Not going to hold my breath
Edited 2020-09-01 12:24 by Sasquatch
-Carl
 
diabolus
Newbie

Joined: 25/05/2020
Location: United Kingdom
Posts: 12
Posted: 03:00am 01 Sep 2020
Copy link to clipboard 
Print this post

Awesome work per usual, Mauro!
 
SimpleSafeName

Guru

Joined: 28/07/2019
Location: United States
Posts: 351
Posted: 05:40am 01 Sep 2020
Copy link to clipboard 
Print this post

Outstanding work!

Unfortunately, I'm doing a startup in Atlanta, GA at the moment and I'm about 400 Km away from my CMM2.

But I'll be back home in a few weeks and I will give it a shot then. :)
 
capsikin
Guru

Joined: 30/06/2020
Location: Australia
Posts: 341
Posted: 07:18am 01 Sep 2020
Copy link to clipboard 
Print this post

  MauroXavier said  Hello to all!

Today I published the new version of Gauntlet (0.4a) in GitHub:
https://github.com/mauroxavierneto/gauntlet_cmm2

And a video testing with my eight years son (but we doesn´t appear in the video, yet):
https://www.youtube.com/watch?v=jlyQugnwijw

For now, the controller inputs supported are only Wii Classic Controller and the keyboard, the Wii Nunchuk maybe will be available in the next release.

Internally the game is prepared to four players experience, but I will make it only when the game have optimized to get a stable speed.

I appreciate any feedback about the game and with the two players experience too.


I don't know if I'll be able to do real two player testing, but I tried out both players by myself on the keyboard and found the second set of keys wasn't supported in player_select or the main game. I was able to add some code to make it work but I don't know if I may have added my own bugs too.

One thing I found it that if one player goes left from the starting point to the left edge, and one goes right to the nearest wall, whenever the player on the left tries to move left into the left wall, the view shifts towards them, and when the other player tries to move right towards the other wall, the view shifts towards them, and if both do it at the same time the view moves back and forth quickly.
 
MauroXavier
Guru

Joined: 06/03/2016
Location: Brazil
Posts: 303
Posted: 11:46am 01 Sep 2020
Copy link to clipboard 
Print this post

  capsikin said  I don't know if I'll be able to do real two player testing, but I tried out both players by myself on the keyboard and found the second set of keys wasn't supported in player_select or the main game. I was able to add some code to make it work but I don't know if I may have added my own bugs too.

One thing I found it that if one player goes left from the starting point to the left edge, and one goes right to the nearest wall, whenever the player on the left tries to move left into the left wall, the view shifts towards them, and when the other player tries to move right towards the other wall, the view shifts towards them, and if both do it at the same time the view moves back and forth quickly.


I'm not implemented yet the two players using only the keyboard and the Nunchuk control. The keyboard control for two players that I'm testing maybe doesn't work well in all keyboards because will use easily six keys simultaneously.

The screen scroll needs some adjustments for two players, I will fix somethings in the next release.

  Sasquatch said  Your quest for performance has gone almost too far now.  The action seems really fast!  Is there a simple way to slow the action down just a little for us older players?

Oh, and the Wii Classic Controller works fine, I haven't tried 2 player mode yet.

Update:  Ok well the Elf seems really fast and Thor seems a bit too slow.  The others are harder to judge somewhere in between?  I think the relative speeds are intentional?  Perhaps for us older folks it might be best to use the Wizard!


About the differences in characters, I based on the version from NES:

- The Warrior is slow as the Wizard but has maximum firepower and good fight power, but your shoot speed is slow too, he has the weakest magic power and he can't shot in diagonal walls;
- The Valkyrie is the most equilibrated char and has the maximum armor giving her an outstanding chance to pass running through a group of enemies with a minimum of life penalty;
- The Elf has very weak armor and fighting power, then the speed must be the main starting characteristic of him;
- The Wizard is slow and is even weaker than the Elf, but the firepower is good enough and he has maximum magic power and shot speed.

The bad thing is if anyone gets the Elf and the other player gets the Wizard or Warrior, the screen scroll always is a challenge to the players and the Elf can easily get all the items on the screen, but this is the key of the cooperation in Gauntlet... If anyone is a hungry player for resources, this can kill all the team with the time.
Edited 2020-09-01 21:50 by MauroXavier
 
capsikin
Guru

Joined: 30/06/2020
Location: Australia
Posts: 341
Posted: 01:26pm 01 Sep 2020
Copy link to clipboard 
Print this post

I liked the music going between the faster or louder songs and the softer songs. I think Lemmings did that too.
  Quote  I'm not implemented yet the two players using only the keyboard and the Nunchuk control. The keyboard control for two players that I'm testing maybe doesn't work well in all keyboards because will use easily six keys simultaneously.


Ah, okay.

Maybe the Shift and Alt keys in keydown(7) would be useful, since they don't count against the limit of 6, and keyboards tend to support combining the modifier keys with other keys.
 
MauroXavier
Guru

Joined: 06/03/2016
Location: Brazil
Posts: 303
Posted: 02:00pm 01 Sep 2020
Copy link to clipboard 
Print this post

  capsikin said  Maybe the Shift and Alt keys in keydown(7) would be useful, since they don't count against the limit of 6, and keyboards tend to support combining the modifier keys with other keys.


Very well remembered. I'm already using modifier keys on Wolf3D but forgot that the keyboard read these keys in a different manner and probably will increase the compatibility with simultaneous keys.

The control scheme I will try to change to something like this:

- Up, down, left, right (same on numeric keys), Right Ctrl for shooting and Right Shift for magic.
- W, X, A, D, and if possible, Left Ctrl for shooting and Left Shift for magic.

If all things are okay with the keyboard use for two players, then I will enable three players (the other using Wii Classic Controller).
Edited 2020-09-02 00:01 by MauroXavier
 
capsikin
Guru

Joined: 30/06/2020
Location: Australia
Posts: 341
Posted: 04:51am 03 Sep 2020
Copy link to clipboard 
Print this post

  Sasquatch said  Great Work Mauro

The latest version does not seem to work with OPTION RAM enabled.  I'm not sure exactly, but it seems to have something to do with accessing the higher numbered graphics pages in Mode 7,16 and Mode 7,8.  No worries though it works great in flash memory.  I am using the recent V5.05.05 release version of MMBasic.

Your quest for performance has gone almost too far now.  The action seems really fast!  Is there a simple way to slow the action down just a little for us older players?


It slows down when there are lots of enemies on screen  

But maybe it would be good to limit the maximum speed when there are only one or two enemies.

update: I discovered there is already a speed limit.
Around the line: ' FPS / SPEED LIMITER
pausetimer=Timer+50
sets a minimum of 50 ms per frame I think
Edited 2020-09-03 17:24 by capsikin
 
MauroXavier
Guru

Joined: 06/03/2016
Location: Brazil
Posts: 303
Posted: 11:21am 03 Sep 2020
Copy link to clipboard 
Print this post

  capsikin said  It slows down when there are lots of enemies on screen  

But maybe it would be good to limit the maximum speed when there are only one or two enemies.

update: I discovered there is already a speed limit.
Around the line: ' FPS / SPEED LIMITER
pausetimer=Timer+50
sets a minimum of 50 ms per frame I think

Yes, the game slows down with about more than 30 enemies on screen, and it's related to collision detection. I got about 50% of speed up when changed how it the loop is done (removing some subroutines and inserting them inside the loop), and used  PEEK and POKE in other video page using colors as collision detection rather than reading a array. For sure there is much more room to optimize this code.

The frame limiter keeps the frame about 20 FPS, which appears to be slow but as the movements are not smooth and are using some pixel grids (2, 4, 6, 8), then the animation can create a good enough illusion. I was an MSX programmer in the past, and this isn't so different what the VDP of the machine had to use when animating some tiles and scrolled the screen to escape from the color crash thanks to the limited color attribute (8x1).

The scan of the enemies is made based on the number of current enemies on the screen divided by seven. For example, until 14 enemies, it will divide it and read half in each game loop (7 enemies on each game loop). If we have 28 enemies, then the scan will read the cycle four times to reach all enemies (7 x 4 game loops), and so on. This makes the enemies slower but this helps the gameplay and scroll performance.

In the future I will have to make two choices about the Gauntlet performance:

1) - Keep all the action constantly in 15 FPS without any slowdown
2) - Optimize all the code to reach 20 FPS or more, giving some room to make the animation a little smoother (this is my current target for now).

If I use CSUBs, obviously all of these "problems" could be solved, but then, in my particular opinion, it will not be a full MMBASIC game anymore, and as always, I really love the challenge to maintain all the game in BASIC only.
Edited 2020-09-03 21:25 by MauroXavier
 
Print this page


To reply to this topic, you need to log in.

The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025