Hacker Evolution Source Code

Hacker Evolution Source Code

PezOfDoom May 11, 2015 @ 8:59pm
Why release the source?
So, just curious, what made you decide to release the source code for the game? I'm digging it because it seems the natural evolution of the hacker games would be to allow people to see the source code...
< >
Showing 1-13 of 13 comments
exosyphen May 12, 2015 @ 3:31am 
For educational purposes.
It contain a lot of good and clean code.

I have learned a lot from Carmack's Quake source code :)
Rock Jun 19, 2015 @ 5:33am 
Difference is: Carmack released his sources for free. I appreciate your idea to publish the sources to your games, it's also innovative to put code on Steam and I agree with the OP that it feels like the natural evolution of a hacker game to provide source code, but I'm not sure charging 50 bucks for it is the way to go. It clearly copies the approach the Uplink developers have taken and it's your right to charge people for it, but I just don't think quoting Carmack as an inspiration works out. Carmack would have and has released his sources for free. I have thought for a while about buying the source code for half the price during the sale, but ultimately decided against it.

In my opinion, you should include it with the games if you don't want to give it away. That would not just give you an advantage over the Uplink competition, but it also follows Carmack's spirit more closely. Furthermore, I'm not quite sure the complexity of either game legitimizes charging money. Without criticizing the games for what they are, putting some text boxes and overlays on screen is comparably simple, whereas both Quake and Doom provided state of the art concepts in CG. Your example regarding the difficulty of aligning a circle and a line despite your background in mathematics might be true [even simple problems sometimes take time to be solved elegantly], but it is just magnitudes away from what Carmack provided for free.
exosyphen Jun 21, 2015 @ 12:58pm 
Carmack release the source code "as is" on a FTP. You were on your own and that's it.

We released it as a product. Meaning we offer (our world famous) tech support and some of my personal time if you need help with any aspect.

Whoever want to spend serious time with the source code, will find solid tech support usefull and the $50 paid for being able to get hands on help from who made the game ... a solid deal :)

Programming a game like this is more than "putting boxes and texts" on the screen.

Here is a deal.
Write me a simple C text mode app that replicates the command line parser functionality.
It doesn't have to execute the in-game commands.
Just the code that allows you to input the command (with editing function, using the arrows, autocompletion, etc).
For every command, just have the code write out the command name it parsed and parameters given.

I will give you a free STEAM key for the source code and 50 bucks.

You will see that is far from easy :)
Brune Jun 21, 2015 @ 3:24pm 
Originally posted by exosyphen:
Here is a deal.
Write me a simple C text mode app that replicates the command line parser functionality.
It doesn't have to execute the in-game commands.
Just the code that allows you to input the command (with editing function, using the arrows, autocompletion, etc).
For every command, just have the code write out the command name it parsed and parameters given.

I will give you a free STEAM key for the source code and 50 bucks.

You will see that is far from easy :)
Fellow game developer here... 50 dollar you say? Is C++ acceptable or does it have to be C only?

Streaming here: http://www.twitch.tv/mjbrune
Last edited by Brune; Jun 21, 2015 @ 3:49pm
PezOfDoom Jun 21, 2015 @ 4:03pm 
Wow, this got away from my main post, but uh, cheers and I hope things are going well for you, exo!
Brune Jun 21, 2015 @ 5:50pm 
https://github.com/MJBrune/Command-Line-Emulator

Completed. BSDL license so feel free to use it in whatever, for free, without paying me anything.

Exosyphen please let me know how to contact you for my 50 dollars and the source code key. ;) If there are any missing features let me know and I will even add them.
Last edited by Brune; Jun 21, 2015 @ 8:21pm
Rock Jun 22, 2015 @ 10:22pm 
Thanks for stealing my key, Mr. Fishy :D: [You solved the challenge, before I even read it - impressive.]

A few remarks:
  • I have actually written a basic command line interpreter myself about 10 years ago as a kid [in Java, admittedly]. It was cool: It could even evaluate if statements and execute while loops, it supported file operations, autocompletion and basic mathematical expressions (+-*/ with correct order precedence and brackets, I think). Hence, I understand how complex such a task can be as I have also stated in my initial post ("even simple problems sometimes take time to be solved elegantly"). Note that I didn't call what you did simple in itself, but simple compared to what Carmack provided. If you inverse the challenge and now imagine writing a software renderer without libraries, you see how much more complex his project was. Without being judgemental about any value. And I think you will agree regarding pure complexity.
  • But this is not the core of what we are discussing. You are exactly right: What you offer is a product including a "support contract" and it certainly has good value for people who want that. However, imho it still does not follow Carmack's philosophy, which was not that selling source code with consulting services is a good idea, but that other developers might want to read interesting source, because this way they can learn a lot from each other, and that hence he wanted to make it available for others. Such developers often, even usually, do not need the original dev to babysit them. It's like getting a book with e-mail support from the author to explain certain parts to you. For certain people [esp. very bright and very stupid ones] this might make a lot of sense, but most will just want to read the book. If you want to sell your intellectual property, I can't and won't argue against it. I just disagree that this has much to do with what Carmack did. If your argument is that you learned a lot from him and now you want to contribute in a similar fashion, then provide the source and sell support to those who actually require it [maybe in combination with commercial licensing]. I agree that you would likely make less money this way, but that's why Carmack's contribution was so impressive: He also could have charged 50 bucks for his code easily, but he didn't, because he valued academic discourse higher.
  • About Mr. Fishy's code: Nice work and incredibly fast, but I don't think exo challenged the entire internet with his reply. That there are (professional?) developers who might accept a miniproject for $50 plus his product was to be expected, but he primarily wanted to support his line of argument targeted at me. He might also have taken into account that I already own all Hacker Evolution games including all DLC and 3 badges and am currently on a budget. I don't want to judge in any way whether you deserve the reward or not, I'm just saying that it's unclear this challenge was meant for you. It's like someone challenges a person in an argument: "Oh yeah? If you can climb that hill over there, I'll give you 50 bucks." and then some hobby rock climber comes around and shouts "There, did it in 5 minutes." Still, good job. I only found two problems with your code:
    a) You can easily make it fail, e.g.

    Type 'e', autocomplete to "exit", delete chars and press <Tab>

    Results in:

    Debug Assertion Failed!

    Program: C:\Windows\system32\MSVCP120D.dll
    File: c:\program files (x86)\microsoft visual studio 12.0\vc\include\vector
    Line: 159

    Expression: vector iterator + offset out of range

    ...

    Line: 160

    Expression: "Standard C++ Libraries Out of Range" && 0


    b) It doesn't seem to really parse parameters and autocompletion seems limited [only "exit" is supported by default - should include "decrypt" etc. to illustrate autocompletion better, esp. for commands with identical prefixes]. That's also when it becomes interesting: Polymorphism etc. How do you differentiate decrypt/2 and decrypt/3? How do you support nested commands like decrypt encrypt <key> <plain text>? Those are likely the problems he wanted me to see.

    In essence, I think exo wanted a way to do two things: Show me how complex his seemingly simple work really is [since he couldn't have known that I'm already aware of it] and offer me as a dedicated customer with limited budget a way to read the source without just giving it away. And I even think I might have declined, since I do get his point: Writing a half-decent shell for $70 bucks is not possible. Your best bet might be to use an existing framework like GNU readline or libtecla, but this is cheating and even then the other tasks take enough time that it just doesn't make too much economic sense.

    Also, autocompletion is much more complex to implement than one might think: Good autocompletion does not just complete entire commands, but actually parts of commands as well. "ming", for instance, might autocomplete to "mingw32-" and then 'm' might autocomplete to "mingw32-make.exe" and then the parameters also require specialized autocompletion, e.g. only autocomplete to file and directory names in proper UNIX or Windows notation after file commands.

    And I haven't even started talking about proper lexing and parsing - you can attend entire lectures about these topics.
Last edited by Rock; Jun 22, 2015 @ 10:28pm
Brune Jun 22, 2015 @ 11:04pm 
Originally posted by Rock:
Snip

I mainly wrote it quickly because I had some free time on a sunday and PezOfDoom suggested I do it so here we are. :D

While the autocomplete isn't perfect and I will admit I didn't think to delete then tab again and etc. I also didn't cover how advanced of autocomplete but with a few more hours it wouldn't be hard to get it working in a state exactly to what Bash terminals do. As for only one command the challenge said "It doesn't have to execute the in-game commands." So if it doesn't have any commands but exit to run then it doesn't need to auto-complete to them, although the system is written to support any number of commands. The auto-complete system also has a space on line 276 where you could easily implement a system that deals with multiple partial commands.

That said I never really expected to get 50 dollars and the key but hell, it's always worth a shot ;)

Although my feelings on the hacker evolution source code and it's (unfound) license is that it seems like 50 dollars is very steep for a non-commerial copy of the source. Why not just GPL it and give it away to everyone who buys the game like Jason Rohrer? Why restrict commerical usage of it? What is the license to the source code? It's not easily accessible from actively looking for it on the store front. I'm not going to state that the code was easy or hard because I really don't know. I also don't know what sort of conditions it was made under and what sort of time frame. Judging people from just purely written code isn't the way to go around this.

Really in the end though the fact the license isn't displayed up front and the steep cost has kept me away from purchase. For 50 dollars I don't see anything this code can teach me that a good C++ or C book couldn't do and more. (maybe that is because I've not seen the code.) If you buy a copy of K&R or The C++ Programming Language books you get the written words from the language creator themselves teaching you through code in the same way but better because its in a full book.

So really what does this offer that a book doesn't? Can I put this code up on a public github? What license covers it?
Last edited by Brune; Jun 22, 2015 @ 11:10pm
Rock Jun 23, 2015 @ 6:02am 
For those not familiar with what Mr. Fishy referred to: Jason Rohrer is an artist game designer who got known to a wider audience when he talked about his projects with Chris Crawford [video is on Youtube]. His games are usually very simple on the outside, but rather minute in their expression up to the point that they are among the few games that can / must be called art.

Originally posted by Mr.Fishy:
That said I never really expected to get 50 dollars and the key but hell, it's always worth a shot ;)
♥♥♥♥ it, I'll take sides: While I still think that it wasn't intended like this [and would have liked to get the source myself], I think you should get both rewards. I mean we are behind nicknames, so whether he challenged "Rock" or "Mr. Fishy" doesn't matter and you finished before I even read the challenge, so you won fair & square in my book. If he doesn't want to leave me out, he can send me an e-mail with the code, but I understand if he does not. You, however, should definitely get it.

What is interesting to me is that when we two would like to read the source, but decided against paying 50 bucks, how many others must feel the same way. Maybe split the product into a read-only offer and a premium one with support? Someone mentioned the similar Uplink offering for about $50. I actually know this source and it a) is not worth $50 in my opinion [not much, uninteresting] and b) it was available for much less [like $3.5 or similar] for a long time.

Finally, if this was my product, I would solve the issue as follows: Make the source without assets [namely images, sounds etc.] freely available to everyone with thanks to John Carmack and as PR - everyone can read it for educational purposes, but noone can compile it into the final game without actually owning it. Give everyone who owns the game general access to the source plus assets in a separate package, so the game can be installed without the source and the source compiled into the complete game as it is on Steam. Charge for support and commercial licensing in dedicated products.

PS:
Originally posted by Mr.Fishy:
I also didn't cover how advanced of autocomplete but with a few more hours it wouldn't be hard to get it working in a state exactly to what Bash terminals do.
No. I agree with everything else you said, but bash has >150k loc with all kinds of goodness. Now I'm close to offering you another $50 if you do [before anyone starts: close to, no actual offer]. Even bash-completion has about 10k loc, so that's no weekend project, either. Look at how long it took Microsoft to get a decent shell...
Last edited by Rock; Jun 23, 2015 @ 6:30am
PezOfDoom Jun 23, 2015 @ 5:37pm 
Thank you both for a thoughtful and entertaining thread. Although I'm not a programmer myself, I know enough to follow along and discussions like this I've not been able to get enough of since I finished college.
Brune Jun 23, 2015 @ 10:44pm 
Originally posted by Rock:
No. I agree with everything else you said, but bash has >150k loc with all kinds of goodness. Now I'm close to offering you another $50 if you do [before anyone starts: close to, no actual offer]. Even bash-completion has about 10k loc, so that's no weekend project, either. Look at how long it took Microsoft to get a decent shell...
Hmm I guess I might be estimating a bit low on the hours but also note that while bash has to do things like support an OS level of commands and systems an emulated environment does not and can be streamlined code-wise to have the same functionality but in fact less LOC. Different systems call for different implementations. Less lines doesn't mean its better or worse. On top of that Bash is an underlying shell of most commands, needing to be optimized. Emulation on this level needs way less optimization which allows for a less complex implementation.
exosyphen Jul 18, 2015 @ 9:15am 
So ... if a few of us find this code easy, the rest should be kept in the dark?

What do you think about those books that teach you C from scratch and retail for $25?
Those shouldn't exist because a few of us already know C and screw the rest.
Brune Jul 18, 2015 @ 12:02pm 
Originally posted by exosyphen:
So ... if a few of us find this code easy, the rest should be kept in the dark?

What do you think about those books that teach you C from scratch and retail for $25?
Those shouldn't exist because a few of us already know C and screw the rest.
I never said that at all and certainly didn't mean to imply that. I would say though that pure source code probably isn't worth the same as a full book. A full book with source code in it is going to teach you a lot more and costs a lot less than what you say you are providing. (I don't actually know what you are providing because I've not gotten a copy yet.)

Lastly there are tons of open source games out there. Little sell their source only like you are doing and little more sell them for the price of a triple A retail game. When they do sell the source you can actually do something with it. Seeing you can grab the source of the Unreal Engine 4 for free.

https://en.wikipedia.org/wiki/List_of_open-source_video_games is a list of open source games.
https://en.wikipedia.org/wiki/List_of_commercial_video_games_with_available_source_code is a list of commercial games that released their source

https://github.com/KeenSoftwareHouse/SpaceEngineers is the source code to space engineers.
http://www.introversion.co.uk/store/ here is the one for uplink. It's the closest thing I've seen to you're 50 dollar price point but with them you get access to their SVN. Which includes commit history.

So while I am not saying you shouldn't release your source what I am saying is that if you want people to learn from it. Make it cheaper. Right now there are clearly better avenues of learning than reading someones (hopefully commented, but not over commented) source code.

Lastly the games above aren't selling their source to sell it, it's so programmers that are already experienced can pick it up and do something with it. Your EULA restricts this completely. So I don't see the reason for the price point being so high if you are just trying to allow people to learn.
Last edited by Brune; Jul 18, 2015 @ 12:03pm
< >
Showing 1-13 of 13 comments
Per page: 1530 50