SyntaxBomb - Indie Coders

General Category => Worklogs => Topic started by: BasicBoy on October 12, 2019, 06:58:58 PM

Title: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 12, 2019, 06:58:58 PM
Here's where I am so far (although bear in mind that the game won't be anywhere near as busy as this, where I've filled the tunnel with an excessive number of objects for test purposes):



Furthermore, the tunnel won't be as twisty as that (for the most part), except perhaps the final level. I recently found that I can't change the diameter of the tunnel without causing side effects that I don't have time to handle. So, sadly, the tunnels will be of constant diameter.

The frame rate drop is rather alarming (no time now for optimisations), but hopefully the final version of the game won't get busy enough for such drastic frame rate drops.

Still to do:

* Four levels, each with an end-of-level boss
* Music & sound effects

and other bits and pieces.

The player will have to meet a kill quota, so even if they reach the end of the tunnel and kill the end-of-game boss, they can only proceed to the next level if they've killed enough baddies (there will be some kind of indicator showing the current kill count).

With so much yet to do there's no guarantee I'll be able to get this finished in time for the deadline, but I will try...


BasicBoy.
--
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Steve Elliott on October 12, 2019, 07:09:55 PM
Looking good, although I think your ship should be more vector-like than sprite-based.  More angular with some transparency perhaps.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 12, 2019, 07:19:48 PM
Looking good, although I think your ship should be more vector-like than sprite-based.  More angular with some transparency perhaps.

Yes, I've been meaning to replace the player's ship with something more '3D' (with correct perspective), but I probably won't have time. I'm not sure about the transparency suggestion. In line with the Retro requirement, I've chosen to use the 320x256 screen resolution and (horrible!) fixed 256-colour palette of the Acorn Archimedes, and transparency effects are probably not going to work well.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Steve Elliott on October 12, 2019, 07:28:18 PM
So you've thought about it, just tweak if you have time  :)

Transparency could be faked with a dot pattern, if you've ever seen Platypus you'll know what I'm talking about.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: GaborD on October 12, 2019, 07:43:58 PM
Looks great. I don't mind that it's busy, just adds more challenge, which is good.
You have nicely color separated the background from the gameplay elements, so it's not too hard to see what's coming your way. The background could maybe be a bit darker to separate it even more, but it works already.
Looking forward to the end result.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: RemiD on October 12, 2019, 07:55:05 PM
this looks cool :), it reminds me of "space harrier" on genesis

is it 3d ?
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 12, 2019, 08:18:50 PM
So you've thought about it, just tweak if you have time  :)

Hmm.. more than a tweak, I think! More like a 'whole day' job. (At least at the rate that I work at...)


is it 3d ?

I suppose it's meant to be at least pseudo-3D? The 3D effect would look more convincing with distance-dependent colour shading (faraway tunnel segments and objects should be darker, and near ones ligher). But there's no time (again!) for such enhancements because I have essential game elements that need implementing in time for the deadline.

Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: RemiD on October 12, 2019, 09:14:51 PM
@Basicboy>> no i mean, do you use 3d to make it (3axises with meshes and textures) ? or only 2d (2axises with images)
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 13, 2019, 05:43:48 AM
@Basicboy>> no i mean, do you use 3d to make it (3axises with meshes and textures) ? or only 2d (2axises with images)

It's purely 2D - no textures or even any GPU acceleration. All graphics (sprites, lines, etc.) are software rendered. It's all rather oldskool.

Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Qube on October 13, 2019, 06:34:32 AM
Love it ;D - That was the sort of style I was originally aiming for with Galaxy Defender when I did the ZX Collection for one of the game comps but didn't have the time to take it to that level.... Nice one :)
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: iWasAdam on October 21, 2019, 08:56:30 AM
All runs fine and dandy here :)
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 21, 2019, 09:12:51 AM
All runs fine and dandy here :)

Thanks, as does yours on my system.

All the entries seem to work fine on my PC.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: 3DzForMe on October 21, 2019, 09:30:00 AM
Works great here also, frantic fun!
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on October 22, 2019, 05:36:49 PM
Here's the two error messages when I've tried to run the game. I've done this via Parallels both times so far. Original version message is first image and your diag version is the second. Also probably worth noting is it appears my Parallels installation was trying to do a slog-worthy crawling speed windows update in background although this Mac is powerful enough that it wouldn't normally be much of an issue...

Anyway this error comes after starting game. The logo scrolls across and the options to pick a level are present and correct, along with the music. Soon as you press space then it's done.

I will be testing it on proper Windows machine at weekend but this info might be useful to you anyway.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 22, 2019, 06:00:00 PM
Here's the two error messages when I've tried to run the game.

Thanks Xerra, that was very helpful. I now know what the cause of the error is.

The game uses delta time in an attempt to make it frame-rate independent. For this, I chose to use a high precision timer rather than a 'standard' Windows millisecond timer (which would have been a safer choice, although offering less resolution). So, using the standard Windows API function QueryPerformanceFrequency to obtain the frequency of the high res timer, which on the system you tested the program on (under Parallels) returned zero! Yes, I should have allowed for that possibility, but I presumed Windows would always return a sensible non-zero result. The error occurs on line 16730 as you reported:

Code: [Select]
dt# = 60.0 * ABS(time1%% - time0%%) / Freq%%
There's the division by zero. (By the way, the %% indicates 64-bit integers in BBC BASIC).

Actually, under Parallels, it's possible that QueryPerformanceCounter (which I use as the effective high res timer) is also returning zero or junk values.

I suppose I could use the millisecond fallback option (via standard Windows API calls GetTickCount or TimeGetTime) which would almost certainly work.

Anyway, thanks again. I'll consider implementing the safe fallback option.


BasicBoy.
--












 
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 22, 2019, 06:34:17 PM
Okay, I've just uploaded version 1.02 of Tyoob. It fixes (or should have fixed!) the issue raised by Xerra.

@ Xerra : If you test the updated version, and it runs ok, could you let me know what kind of frame rate you're getting? It's reported (in faint green) at the top-left of the window during gameplay.

http://www.proggies.uk/progs/zip/tyoob.zip (http://www.proggies.uk/progs/zip/tyoob.zip)

Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on October 22, 2019, 08:38:15 PM
Glad to have been helpful. As soon as QPR give Reading a right thrashing on Sky Sports then I'll give it a test run and make sure it's all good :)
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on October 22, 2019, 10:19:26 PM
Think you may be over-worrying about having a reduced frame rate when running via emulation or some other resource hugging issue. My Parallels installation is mid-way through 89 windows updates but I tried running the game anyway and got a solid 60fps all the way through playing it. I wanted to try it out straight on level 4 rather than working my way up there, under the assumption that it's going to be doing a lot more grunt work, but my crapness at the game ensured i can only play up to level 2 at present.

I'll give it a proper play at the weekend on real hardware anyway, along with all the other Windows games.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on October 22, 2019, 10:26:38 PM
Think you may be over-worrying about having a reduced frame rate when running via emulation or some other resource hugging issue. My Parallels installation is mid-way through 89 windows updates but I tried running the game anyway and got a solid 60fps all the way through playing it.

That's good news  :)

On the Title Page keep Ctrl+F7 pressed for about 5 seconds until you hear a beep, then quickly press the Tab key (you'll hear another beep). You can then select any level.

hehe

 
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on November 19, 2019, 10:10:06 PM
The Apple Mac (macOS) versions of two of my games are now available as DMG files (I can't personally test these as I don't have access to a Mac):

Tyoob:
http://www.proggies.uk/bbcsdl/downloads/Tyoob.dmg (http://www.proggies.uk/bbcsdl/downloads/Tyoob.dmg)

Forces of Darkness:
http://www.proggies.uk/bbcsdl/downloads/FoD.dmg (http://www.proggies.uk/bbcsdl/downloads/FoD.dmg)

The DMG files aren't signed, so users may have to override security warnings.

BBCSDL (BBC BASIC for SDL 2.0) Games web page:
http://www.proggies.uk/bbcsdl/index.html (http://www.proggies.uk/bbcsdl/index.html)

Here's a YouTube video of 'Forces of Darkness' running under macOS:




Any feedback appreciated.  :D

I'm grateful to Richard Russell for porting the original, entirely Windows-based versions of my games to the cross-platform version of BBC BASIC (BBCSDL).


BasicBoy.
--
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on November 19, 2019, 10:12:56 PM
Files not found when i tried to download them.

Edit: Although they were both downloadable from the index page.

I'll give them a test run and let you know if they work ok.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on November 19, 2019, 10:19:16 PM
First, Forces of Darkness. Either put in a keyboard configuration option or just switch the ctrl key (fire) to use maybe space. I'm not sure if it's part of the mac system or an app I'm using but ctrl and arrow keys minimize my screen and shift it into a different area.

Imagine the fun I had trying to play with that little problem :-)
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on November 19, 2019, 10:24:15 PM
Tyoob runs ok as well. There are a few frame rate stutters I noticed but nothing game destroying. I'd kill for auto-fire, however. Tapping the enter key is killing me.

Should also point out that neither game gave me any security issues installing or running.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on November 19, 2019, 10:33:56 PM
Files not found when i tried to download them.

Links now fixed.  :)


First, Forces of Darkness. Either put in a keyboard configuration option or just switch the ctrl key (fire) to use maybe space. I'm not sure if it's part of the mac system or an app I'm using but ctrl and arrow keys minimize my screen and shift it into a different area.

Imagine the fun I had trying to play with that little problem :-)

Thanks, I'll look into this.


Tyoob runs ok as well. There are a few frame rate stutters I noticed but nothing game destroying. I'd kill for auto-fire, however. Tapping the enter key is killing me.

Should also point out that neither game gave me any security issues installing or running.


Yes, my games tend to be rather RSI-inducing, don't they!

With both Tyoob and FoD, you can collect 'autofire' tokens which do bring some temporary relief.

Thanks for the feedback, Xerra.  :)


BasicBoy.
--

Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Qube on November 20, 2019, 06:34:39 AM
Yay \o/ downloaded and will give them a play tomorrow ;D
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Qube on November 22, 2019, 08:28:29 PM
Tested and both play great. No frame rate stutters on my iMac but I suspect the Radeon Pro 580 8GB helps here.

As Xerra mentions, using the CTRL + arrows isn't the best choice for Mac's as that switches between virtual desktops / exposé etc. Best to stick with arrow keys + space bar for firing :)
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on November 22, 2019, 10:08:38 PM
Thanks Qube, the feedback is much appreciated. I will definitely be going with spacebar as the fire key in future. I hope to update the current versions of Tyoob and FoD within the next day or two.

In any future shoot-'em-up I might make, I'll probably do away with the fire key altogether and have autofire by default (or at least have it so that you just need to keep the fire key pressed down without having to hammer the crap out of it hundreds of times every minute). So much kinder to the player's tendons!  :)


BasicBoy.
--

   
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Qube on November 22, 2019, 11:01:10 PM
In any future shoot-'em-up I might make, I'll probably do away with the fire key altogether and have autofire by default (or at least have it so that you just need to keep the fire key pressed down without having to hammer the crap out of it hundreds of times every minute). So much kinder to the player's tendons!  :)
You could do auto fire by holding down the spacebar but have it slightly slower speed than key mashing so in the big mad moments the player can go into overdrive ;D
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on November 22, 2019, 11:42:16 PM
In any future shoot-'em-up I might make, I'll probably do away with the fire key altogether and have autofire by default (or at least have it so that you just need to keep the fire key pressed down without having to hammer the crap out of it hundreds of times every minute). So much kinder to the player's tendons!  :)
You could do auto fire by holding down the spacebar but have it slightly slower speed than key mashing so in the big mad moments the player can go into overdrive ;D

Good suggestion!
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on November 23, 2019, 01:27:54 AM
You could do auto fire by holding down the spacebar but have it slightly slower speed than key mashing so in the big mad moments the player can go into overdrive ;D

Actually the perfect suggestion. I really considered going this way myself. Games that make you repeatedly press fire to shoot nowdays are out of touch with modern gameplay. Holding down the fire button should be enough and restrict the player in other ways to make it challenging. I won't ever write another game that's potentially RSI inducing. Not knocking Tyoob, just emphasizing that gameplay has moved on for us older game players.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on November 23, 2019, 02:44:05 PM
The cross-platform BBCSDL versions of 'Tyoob' and 'Forces of Darkness' have been updated so that space bar is now the fire key.

The Mac OS X (macOS) DMG file has also been updated (thanks, Richard).

http://www.proggies.uk/bbcsdl/index.html (http://www.proggies.uk/bbcsdl/index.html)


Direct links for macOS DMG files:

http://www.proggies.uk/bbcsdl/downloads/Tyoob.dmg (http://www.proggies.uk/bbcsdl/downloads/Tyoob.dmg)
http://www.proggies.uk/bbcsdl/downloads/FoD.dmg (http://www.proggies.uk/bbcsdl/downloads/FoD.dmg)


No 'autofire by default' yet, but I expect that will come at some point (or if it doesn't, I'll make sure any future shmups I make will have it!).

Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Steve Elliott on November 23, 2019, 02:52:20 PM
Congrats on going multi-platform.   :D

So BBC BASIC is using SDL and I thought SDL only allows integer adjustments for movement, does this version of BBC BASIC allow floating point movement for smoothness?
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: BasicBoy on November 23, 2019, 04:49:58 PM
Congrats on going multi-platform.   :D

So BBC BASIC is using SDL and I thought SDL only allows integer adjustments for movement, does this version of BBC BASIC allow floating point movement for smoothness?

Here's a reply from Richard Russell (to whom I'm grateful):

Quote
It depends on the version.  Starting with SDL 2.0.10 (the current
version) there are float variants of most of the rendering functions.
So for example there is now a SDL_RenderCopyF() which is like
SDL_RenderCopy() but coordinates are passed as floats instead of integers.

At the moment the editions of BBCSDL which I distribute with SDL
included (i.e. all except Linux/Raspbian) don't come with a recent
enough version to include those functions, but if it's something that is
deemed to be important I could update them.  Android and iOS are
trickier than the others in that respect, because of the build
processes, but I will need to face that issue sooner or later.

So if you wanted to experiment with float coordinates now you would need
to do it on Linux and ensure that you have installed SDL 2.0.10.  The
full list of float functions is: SDL_RenderDrawPointF(),
SDL_RenderDrawPointsF(), SDL_RenderDrawLineF(), SDL_RenderDrawLinesF(),
SDL_RenderDrawRectF(), SDL_RenderDrawRectsF(), SDL_RenderFillRectF(),
SDL_RenderFillRectsF(), SDL_RenderCopyF(), SDL_RenderCopyExF().

Of course SDL2 provides direct access to OpenGL if you need it (I rely
on that for 3D programs and for shader programs, and simply to achieve
the 'logical' GCOL plotting modes) so if float coordinates are vitally
important now you can bypass the SDL2 functions and call OpenGL
functions, but that's rather more work.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Steve Elliott on November 23, 2019, 04:57:09 PM
That's very interesting - thank you for investigating.  The last version I used was v2.0, which was integer based.
Title: Re: MIX-IT-UP Comp Entry - Tyoob
Post by: Xerra on November 23, 2019, 08:56:11 PM
Tyoob working just fine on my system. Having space as a fire button means I can actually play it properly on the Mac now :-)
SimplePortal 2.3.6 © 2008-2014, SimplePortal