Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
21 game in Inform PE
#1
Hi
this is an old game written some years ago and now, thanks to revival of Inform as Inform PE, I can adjourn an publish here as a demo of game of numbers.
The goal is to reach 21 summing or 1 or 2 or 3 to the actual total. It starts from 0.
Can you beat the AI? Take a try!
Here a screenshot:

[Image: 21game-demo.jpg]
and Here the code in compressed file, you need of QB64pe and Inform PE to compile and run.

.7z   21 game.7z (Size: 2.62 KB / Downloads: 13)
Reply
#2
@TempodiBasic you need to include all the include files when you distribute an InForm file.

It makes extraction and running your InForm code easy as eating spaghetti!
b = b + ...
Reply
#3
@TempodiBasic thank you and this is added to the repo.
Reply
#4
(05-11-2025, 12:42 AM)bplus Wrote: @TempodiBasic you need to include all the include files when you distribute an InForm file.

It makes extraction and running your InForm code easy as eating spaghetti!

I apologize Mark
here an useful addon pack for InformPE distributions:
it brings into it 3 files: Inform.bi  Inform.ui and Xp.uitheme.
you can extract them into the same folder where you extracted .BAS and .FRM and you must be sure that the $include: instructions into .BAS point to them with the relative path ".\NameFile.extensionfile"

Thanks for feedback!

About easy as eating spaghetti... you open an universe!  You can eat spaghetti using sticks (like in China and Japan) or forks and spoon or only forks (someone must use fork and knife). Choose your way


.7z   InformPackageIncludeFiles.7z (Size: 54.5 KB / Downloads: 7)
Reply
#5
Again everything would be easier if you put the whole package into 1 zip file.

I don't know what is wrong with this setup:
   

I try to run 21 Game and this red line???
   

It looks OK to me???
   
b = b + ...
Reply
#6
OK this doesn't even work when I put all the InForm files in the same dierectory as 21 Game.

BTW the InForm.Bi has an Include: InFormCommon.bi where is that?
   
b = b + ...
Reply
#7
Everything needed is in: https://github.com/a740g/InForm-PE/tree/master/InForm

Create a sub-directory called "InForm" in your project directory and then copy the files listed below from the above location inside the newly created directory.

InForm/InForm.bi
InForm/InForm.ui
InForm/InFormCommon.bi
InForm/InFormVersion.bi
InForm/xp.uitheme
InForm/extensions/*.*

Then in your code:
Code: (Select All)
'$INCLUDE:'InForm/InForm.bi'
'$INCLUDE:'Your_Form_Here.frm'
'$INCLUDE:'InForm/InForm.ui'

The other files are included by InForm.bi and InForm.ui.
Reply
#8
Like I said all this should be done by the person distributing the code.

The person should not make it a big hassle just to check out the code. At this point I don't care about another 21 Game.
b = b + ...
Reply
#9
(05-11-2025, 05:45 PM)bplus Wrote: Like I said all this should be done by the person distributing the code.

The person should not make it a big hassle just to check out the code. At this point I don't care about another 21 Game.

Honestly, I'm of the opinion that when it comes to libraries and run-time packages, one shouldn't have to include them with every sample/program they place on the forums.   What's the point of having a dedicated download package for then?  

As a library creator, I place my libraries in the subforum here for that.  If I want to make use of them to showcase something unusual, I should be able to just post a note -- requires library from this spot -- rather than have to zip it up, save it, upload it, and require people to have 80 copies of the same library on their drive with it.  It may be convenient for one guy to grab, extract, test and delete, but it's a PITA for everyone else who already has versions set up and configured for it properly.

Anyone really interested in InForm should already have InForm.  If not, then just move on and say, "Oh, this isn't a demo for me.", just like when someone posts "This is Windows-Only" or "Linux-Only", and you're not running under that platform.  If you don't care enough to have the required run-time files on your machine, then I'd personally see that as being on you instead of the content creators.  Lots of games/programs require you to have the proper runtimes set up and configured to run them to reduce upload/download file sizes and bandwidth/storage issues.

Inform, to me, seems like it'd fall into that same category of runtime packages.  If it's something someone is interested in, they'd grab it once, be done with it, and then not want to have to grab repeated copies of it over and over and over with every sample placed on the forums.

No matter which way a dev goes, they can't win.  Package it all up and they get complaints over size, space, download times.  Package up only the essential bits and then they get fussed out because it won't work straight from the box.  It's a no win situation for a dev, in the long run, and even if they sigh deeply and share both versions, they then get a THIRD set of complainers who say, "It's too complicated!  I don't know which version I need.  F this S!  KISS!!"
Reply
#10
If they package it all, a person can just take out what they need to checkout the code.

Simple!
b = b + ...
Reply




Users browsing this thread: 1 Guest(s)