Duke4.net Forums: Faceman - My complete waste of time - Duke4.net Forums

Jump to content

  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

Faceman - My complete waste of time  "Collect 20 gems in 100 moves or less"

User is offline   MusicallyInspired 

  • The Sarien Encounter

#1

Sometimes I dabble in programming. I wrote this little game in Turbo C++ for DOS and then made a win32 port with Borland C++ Builder a couple years back. It's a very simplistic game with a strange set of rules. It's an ASCII game similar to KROZ but not near as big in scope. The object is to collect 20 randomly placed gems on the screen but you can only make 100 moves. Because of the moves limitation it forces you to be strategic with your movements, which was somewhat interesting to me...at the time. If you succeed it'll display your best score on the top so you can try to outdo yourself.

Download Faceman (includes DOS port, Win32 port, and source)

Posted Image
Posted Image

The controls are:

-Up, Down, Left, Right Arrow keys (move around)
-Home (move to far left edge of screen)
-End (move to far right edge of screen)
-PgUp (move to top edge of screen)
-PgDown (move to bottom edge of screen)
-C (move to center of screen)
-F2 (turn sound on/off)
-Esc (End game/Quit)

Thinking back I probably could have added diagonal controls and controls to move to only the horizontal or vertical center. Like I said, it's a weird game but it was fun to create and it felt good to actually set out to do something and finish it. See what the highest score you can get is! Or ignore it because it's not very interesting. Just thought I'd share it. Maybe some aspiring programmer can learn from the source or something. Or perhaps a more experienced programmer can berate me for using such convoluted code. :) Either way, enjoy.

This post has been edited by MusicallyInspired: 19 June 2016 - 11:00 AM

7

User is offline   Hank 

#2

View PostMusicallyInspired, on 19 June 2016 - 10:57 AM, said:

Download Faceman (includes DOS port, Win32 port, and source)

It gives me 404 error. - Yep, I am interested to actually give it a go. Posted Image
0

User is offline   MusicallyInspired 

  • The Sarien Encounter

#3

Try again. Silly case-sensitivity internet.
0

User is offline   Hank 

#4

best score 98 Posted Image Thanks for sharing.

[added]
How about placing a copyright somewhere?
You may think it's not a good game, but it would be a shame, if someone like me, takes the idea, ports it to another engine, and gets cash from iTunes. Posted Image
We've just been for coffee at Tim Hortons, 60% of the peeps play with their cell phone. Posted Image

This post has been edited by Hank: 19 June 2016 - 04:31 PM

2

User is offline   MusicallyInspired 

  • The Sarien Encounter

#5

Congrats! I think my best score was 83.

I don't see how a game like this could work on a cell phone, but I suppose it couldn't hurt. I'm quite unversed in source code licensing and whatnot, though.

This post has been edited by MusicallyInspired: 19 June 2016 - 04:45 PM

0

User is offline   Kyanos 

#6

View PostMusicallyInspired, on 19 June 2016 - 04:42 PM, said:

Congrats! I think my best score was 83.

I don't see how a game like this could work on a cell phone, but I suppose it couldn't hurt. I'm quite unversed in source code licensing and whatnot, though.

You should try to port it to android using libgdx. I use libgdx, it's a great engine, well documented, you will have no problem considering you are skilled enough to get the game this far. Java, is easy, eclipse is handy but troublesome at times, if you do try you will definitely learn a lot.

This post has been edited by Drek: 19 June 2016 - 04:54 PM

2

User is offline   MusicallyInspired 

  • The Sarien Encounter

#7

I may just attempt it at some point. I have never used Java before. As good a time as any to start.
2

User is offline   Kyanos 

#8

When I first used java I was like, "oh, this is c still, what's even different?" I still couldn't tell you what's different besides some syntax.
1

#9

Are all screens supposed to be possible? I have played it about 20 times or so and can't get close. I have had as few as four dots left, but it was around 20 more moves to get them.

CatNapDreams
0

User is offline   Hank 

#10

^ are you using short cuts like Home, End, C keys? It took me half an hour to get a favorable layout. You need also a bit of luck (patience), to have the gems in clusters.
0

User is offline   MusicallyInspired 

  • The Sarien Encounter

#11

They're not all guaranteed, no. At least, there's no special measures in place to ensure that every screen is completable. The gems are just randomly placed. But there is a bit of strategy like I said if you use some of the shortcut keys, which really are necessary. I tried to find a balance of challenge vs not too easy with the amount of gems, moves, and controls available. I've been musing and throwing around ideas on how to make it more interesting, like increasing the number of gems and the number of moves as you beat each screen or something along those lines. Adding diagonal controls would help too. I can finish about 80-90% of the screens I'm presented with.

I know it's not perfect. This literally is my first BBQ. :)

This post has been edited by MusicallyInspired: 19 June 2016 - 07:22 PM

1

#12

View PostMusicallyInspired, on 19 June 2016 - 07:09 PM, said:

I know it's not perfect. This literally is my first BBQ. :P

I played it for a bit and rage quit. You might have something there, if you make some pretty graphics and add some 90's game music you might have something. Although you are a bad person for coding it in Borland :).

This post has been edited by icecoldduke: 19 June 2016 - 07:47 PM

2

#13

View PostMusicallyInspired, on 19 June 2016 - 10:57 AM, said:

Thinking back I probably could have added diagonal controls and controls to move to only the horizontal or vertical center.

I disagree. Keeping it udlr simple is good.

Instead consider "strategic exceptional" choices. A fixed number of "move undos" and/or "free jumps".

Looking at the source I don't think you verify that it's actually possible to solve, so giving a fixed amount of power moves will help make it feel less futile. But I might not be staring at your InitGem() function deeply enough. Either way... the fun would be in reaching minimum moves (or with style) even if there are many ways to get there in less than 100 moves... rather than discovering a randomly generated solution.

You could also generate the board in a way where you can display the seed/ID number so that people could go back later and specify the seed they want to play and try to best their previous score or best someone else's.

This post has been edited by Wieder: 19 June 2016 - 08:38 PM

1

#14

View Posticecoldduke, on 19 June 2016 - 07:47 PM, said:

Although you are a bad person for coding it in Borland :).

Should have been Turbo Pascal 5.
0

User is offline   MusicallyInspired 

  • The Sarien Encounter

#15

View PostHank, on 19 June 2016 - 07:02 PM, said:

It took me half an hour to get a favorable layout.


You have my sympathies for spending such a lengthy amount of time trying to master this poor game. lol

View Posticecoldduke, on 19 June 2016 - 07:47 PM, said:

I played it for a bit and rage quit. You might have something there, if you make some pretty graphics and add some 90's game music you might have something. Although you are a bad person for coding it in Borland :).


Haha I know. I have a fascination with how older things worked and I liked the KROZ/ASCII approach. And I figured it was the easiest way to start programming something with rudimentary graphics without having to put a graphics system together first (I know there are systems out there pre-built for that stuff too, I've dabbled with Allegro before but nothing complete or on my own). I have had Turbo C++ for a while and did some little things like program a game launcher for my 486. When I wrote Faceman it was on that machine so it was originally meant for DOS. It bugged me later that I couldn't run it on my main system without DOSBox so I compiled it in Borland as well since it uses the same libraries. It just needed CC3250MT.DLL with it or it wouldn't work. If I was to seriously persue enhancing this game, I'd port it to a proper graphics system with proper tools first....maybe. One thing I didn't know how to get around (or was too lazy to) was doing something other than trying to clean and redraw an ASCII screen because there is no buffering available. Not with what I was using anyway...

View PostWieder, on 19 June 2016 - 08:31 PM, said:

Looking at the source I don't think you verify that it's actually possible to solve, so giving a fixed amount of power moves will help make it feel less futile. But I might not be staring at your InitGem() function deeply enough.


No, it doesn't verify anything. I wouldn't know where to begin to verify a solveable screen!

Quote

Either way... the fun would be in reaching minimum moves (or with style) even if there are many ways to get there in less than 100 moves... rather than discovering a randomly generated solution.


That's an interesting thought. I'm thinking of some bonus powerup drops that place randomly (but rarely) during play while you move that give you special abilities. Like being able to collect all gems in a certain radius (like a "bomb"). I was especially mulling over how this might work on a mobile touchscreen device, what with the special "word processor" shortcut key approach I have but I don't really have any ideas beyond having a bunch of transparent controls on the scren taking up space...

Quote

You could also generate the board in a way where you can display the seed/ID number so that people could go back later and specify the seed they want to play and try to best their previous score or best someone else's.


That would be easy enough. Right now it just seeds from the system clock.

Thank you all for spending time on and giving feedback on my silly little game.

This post has been edited by MusicallyInspired: 19 June 2016 - 11:47 PM

0

#16

View PostMusicallyInspired, on 19 June 2016 - 11:42 PM, said:

If I was to seriously persue enhancing this game, I'd port it to a proper graphics system with proper tools first

Port it over to Unity, deploy it as a Android or ios app. You might be able to make some money off of it, if you do it right.
0

User is offline   Hendricks266 

  • Weaponized Autism

  #17

>ASCII game
>Unity

Just code it directly on top of SDL.
1

#18

View PostHendricks266, on 20 June 2016 - 05:38 AM, said:

>ASCII game
>Unity

Just code it directly on top of SDL.

I would disagree. Even if he kept the ASCII art, I think he would have more of a chance of shipping his title if he used a existing engine. I however think he should ditch the ascii art, keep the gameplay, take Charlie's suggestions, add some awesome 90's game music, put it up on the app store and see if he can make some money.

This post has been edited by icecoldduke: 20 June 2016 - 05:46 AM

0

User is offline   Kyanos 

#19

View Posticecoldduke, on 20 June 2016 - 05:46 AM, said:

put it up on the app store and see if he can make some money.


How would you advise someone to make some money from apps? One time sales?? Ads??? In app purchases????
0

#20

View PostDrek, on 20 June 2016 - 06:33 AM, said:

How would you advise someone to make some money from apps? One time sales?? Ads??? In app purchases????

For this particular title, I would advise putting it up for .99c. I can't imagine any worthwhile in app purchases, and Ads would over complicate what it would take to ship the title. Put it up for .99 cents and see what happens. For other titles my advise would be very specific towards the needs of the developer and what the game offers.

This post has been edited by icecoldduke: 20 June 2016 - 06:38 AM

0

User is offline   Kyanos 

#21

Usually very little happens, %99 of money in app dev is from ads. I am not saying it isn't worth doing, just not worth doing for cash profit, I'd give this away free open source with ads if I was greedy for cash :)
0

#22

View PostDrek, on 20 June 2016 - 06:40 AM, said:

Usually very little happens, %99 of money in app dev is from ads. I am not saying it isn't worth doing, just not worth doing for cash profit, I'd give this away free open source with ads if I was greedy for cash :)

Sure, but at least during the days of Unity 3.0, you had to integrate ad plugins into your title; which was a daunting task for cross platform titles. I want him to ship, and my advise is always geared towards the path of least resistance to ship. On average developers have to make and ship 5 games, before making any profit. I'm not saying he will make a bunch of money, but I think it would be a fun experience to get this title up on the store, and there is a chance he will be able to make some money based on how well the final product is polished up.

It's possible you are correct that ads would be the best way to get profit, releasing the app for free is a great way to build name recognition. Even if in the latest version of Unity adding ads is a streamlined process, that's another feature for him to add in, which IMO since this is his first game, would drastically cut down his chance of shipping. Remember the goal of the game is to ship. You can't make money if you don't ship.

This post has been edited by icecoldduke: 20 June 2016 - 06:52 AM

0

User is offline   Kyanos 

#23

Quote

Remember the goal of the game is to ship.

I'm pretty sure it was to collect gems :)

Quote

You can't make money if you don't ship.

My recommendation of using libgdx and porting this to android wasn't so that he could he make money or get on google play. As a fellow hobbyist programmer I've had a great experience with that engine and recommend anyone with an android phone and coding skills check it out.
0

User is offline   MusicallyInspired 

  • The Sarien Encounter

#24

View PostDrek, on 20 June 2016 - 09:08 AM, said:

I'm pretty sure it was to collect gems :)


I LOL'd.

Unity seems pretty hefty and overblown for a game like this. I'd be much more comfortable with using something like SDL or Allegro. I don't see the sense in using a 3D engine for a 2D game. I wouldn't keep the ASCII art, though. But it would remain 2D.

Before I even think about asking money for this it needs to be an actual game and not a proof of concept rage quit inducer. :P I'll continue tinkering around with this ASCII version first and see if I can get a decent fun experience going.
2

User is offline   Micky C 

  • Honored Donor

#25

Is it even possible to verify that it's doable in the code before outputting it as a level? I suppose one way would be to dynamically constrain the random positions of remaining gems to ranges that result in it being solvable. Although it might be easier to just cycle through levels until a solvable one is found.
0

User is offline   MusicallyInspired 

  • The Sarien Encounter

#26

That's why I never bothered putting in any verification.
0

User is offline   Micky C 

  • Honored Donor

#27

Another option could be to randomly simulate 100 moves, and randomly dropping a gems along the way. The tricky bit is having a random probability distribution that ensures all the gems are dropped by the end. Sure, a uniform probability of (number of gems)/(number of moves) would on average do the job, but might occasionally overshoot or fall short. I suppose you can simply stop when you hit the gem limit. And if you've hit the step limit, ensure the final step has a gem on it, then (having stored the player at each position), randomly insert extra gems along the path into empty spaces.

The downside of this is that there could be a tendency to a single probable path rather than it being random enough to allow the possibility of multiple paths. There's also the issue that the path may become somewhat more obvious.

Still, it'd be really interesting to see what it looks like.

This post has been edited by Micky C: 22 June 2016 - 01:51 AM

0

User is offline   MusicallyInspired 

  • The Sarien Encounter

#28

Does anybody know of any good console/ASCII manipulation libraries for modern compilers/Windows so I don't have to use Borland or TurboC to continue working on this? I don't have either installed anymore right now. Well, I do have TurboC in DOSBox but I hate working with it because it has no syntax highlighting. And I really don't want to mess with adapting a graphics backend to emulate it. I've got to think that there are people out there who create rogue-ish ASCII console games somewhere, but I haven't had much luck. I've found references but no content.

This post has been edited by MusicallyInspired: 05 July 2016 - 09:04 AM

0

User is offline   Striker 

  • Auramancer

#29

To verify the gems can be collected in 100 moves at most, perform 100 moves at random, recording which cells have been traversed along the way in an array, then after, iterate through that array and randomly place gems in the cells that were traversed until there's enough, making sure to skip cells that already have a gem.

This post has been edited by StrikerMan780: 04 July 2016 - 11:32 PM

1

User is offline   Micky C 

  • Honored Donor

#30

View PostStrikerMan780, on 04 July 2016 - 11:31 PM, said:

To verify the gems can be collected in 100 moves at most, perform 100 moves at random, recording which cells have been traversed along the way in an array, then after, iterate through that array and randomly place gems in the cells that were traversed until there's enough, making sure to skip cells that already have a gem.


Dude, that's exactly what I said 2 posts above. Well, almost the same thing at any rate.

View PostMicky C, on 22 June 2016 - 01:48 AM, said:

Another option could be to randomly simulate 100 moves, and randomly dropping a gems along the way. The tricky bit is having a random probability distribution that ensures all the gems are dropped by the end. Sure, a uniform probability of (number of gems)/(number of moves) would on average do the job, but might occasionally overshoot or fall short. I suppose you can simply stop when you hit the gem limit. And if you've hit the step limit, ensure the final step has a gem on it, then (having stored the player at each position), randomly insert extra gems along the path into empty spaces.

The downside of this is that there could be a tendency to a single probable path rather than it being random enough to allow the possibility of multiple paths. There's also the issue that the path may become somewhat more obvious.

Still, it'd be really interesting to see what it looks like.


This post has been edited by Micky C: 05 July 2016 - 02:09 AM

1

Share this topic:


  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic


All copyrights and trademarks not owned by Voidpoint, LLC are the sole property of their respective owners. Play Ion Fury! ;) © Voidpoint, LLC

Enter your sign in name and password


Sign in options