Author Topic: Fan game source code  (Read 33853 times)

0 Members and 1 Guest are viewing this topic.

Offline gumby

Fan game source code
« on: January 20, 2013, 03:05:52 PM »
Here's a suggestion:  how about creating an area for hosting all the fan game source code?  Reason being so it could be fully searchable.  Right now, I've got all fan game source code on my laptop and every time I want to find an example of how something is done I end up grepping the whole directory structure until I find examples of the code I want, then I go and open the script.  Works fine for me, but an online feature like this might make things more accessible for others.

I'm imagining something similar to an online SVN repository browser.

Maybe SMF has a plug-in for something like this?


In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline Collector

Re: Fan game source code
« Reply #1 on: January 20, 2013, 05:05:03 PM »
Or on the Wiki. The nature of the Wiki is such that makes it easy to find stuff. Each could have any category assigned to to make it easily searchable. Say, if a game had a good example of using a VIEW resource and a unique timer usage, it could be assigned categories of source, timer and view, or any other categories that would apply.

And no reason to not have it on both here and the Wiki. I believe in duplication as a safe guard against a crash or attack.
The information would still be accessible.
KQII Remake Pic

Offline Cloudee1

Re: Fan game source code
« Reply #2 on: January 20, 2013, 05:17:47 PM »
Except for a couple of games, most of them are really only a few rooms. I'm not sure I see storing all of the source code when 98% of it is actually duplicated template scripts. I'm open to ideas of how to organize it to make it useful. But at this second, I don't see "the vision" I guess.

What would work out for now though, and since the source code has been released I don't think many would see it as an issue, If you have found something useful in the source codes then just copy and paste it into a thread in the how to section.

ie. Examples of Blah Blah Blah.
Halloween Competition Brass Lantern Prop Competition Groundhog Day Competition

Offline gumby

Re: Fan game source code
« Reply #3 on: January 20, 2013, 06:11:02 PM »
I see what you are getting at.  If the code that we have isn't all the useful to provide examples, the it really doesn't make sense to expose it for searchability.  I guess I was thinking that there was more value embedded in the available source code than you indicate, though I certainly haven't spent much a lot of time pouring over the source.

You are right, I hadn't considered that most of the code would be duplicated from the template game.  Perhaps it is better to raise a particular problem then provide source code to solve that problem, in a similar fashion to how we've been doing it with forum posts.  This does seem better than having 98% of the searchable source code essentially useless.

Unless we could treat it like different branches (like an SVN branch) beginning with the template.  Start with the template, then do a comparison against a particular game, and the differences would be what make the game unique.  Not sure if this could be presented in a coherent way though.

Oh well, even if it doesn't come to anything it's been worth the discussion.  I'm always interested in considering how we can improve knowledge transfer to developers.
« Last Edit: January 20, 2013, 06:25:21 PM by gumby »
In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline Cloudee1

Re: Fan game source code
« Reply #4 on: January 20, 2013, 07:33:41 PM »
I did a search of the smf mods and I don't see where there is anything like a repository out there.

I'm not opposed to getting the code out there, I just haven't come up with a real good way yet to present it in a usable way.
Halloween Competition Brass Lantern Prop Competition Groundhog Day Competition

Offline gumby

Re: Fan game source code
« Reply #5 on: January 20, 2013, 08:39:23 PM »
Yeah, I don't we'd just want to have every page of code up - like you said, you wouldn't want lots of identical matches from a boilerplate template script.  I'll think about it and see if I can come up with something.
In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline Collector

Re: Fan game source code
« Reply #6 on: January 20, 2013, 08:58:18 PM »
It would take some effort on someone's part, but any games that have some bit of code that could prove useful as a "How To" could have that code copied into a new game from the template to have a small working example that only does that one thing. Something that could serve as a try it like the W3Schools. Snippets of code alone are not always that useful for someone trying to learn a new language. Working examples can be far more instructive.
« Last Edit: January 20, 2013, 09:03:18 PM by Collector »
KQII Remake Pic

Offline gumby

Re: Fan game source code
« Reply #7 on: January 20, 2013, 09:36:52 PM »
Collector, yeah I agree it makes sense to isolate the code we are trying to document and put it in a template game.  That way we don't have other code cluttering the how-to and potentially obfuscating what it is we are trying to demonstrate.

This whole topic sort of falls into the idea about possibly creating how-to's out of (or in conjunction with) walkthroughs.  Cloudee, you still thinking about doing this?
In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline Collector

Re: Fan game source code
« Reply #8 on: January 20, 2013, 10:01:55 PM »
Does any stand alone SCI script compiler exist? If so, it would not take that much to do something like this http://www.w3schools.com/css/tryit.asp?filename=trycss_default A full version of VS could let you do something in ASP with jDOSBox to do something similar with SCI. C# could easily do it as a local app.
KQII Remake Pic

Offline Cloudee1

Re: Fan game source code
« Reply #9 on: January 20, 2013, 10:07:16 PM »
Collector, I don't know if it is feasable or not.

Gumby, Yes and no. Before I was thinking that we tackle all of the games... and then I uploaded and played President's quest. That kind of killed my spirits, I even filled in a rating for it. But it got me to thinking, how many of these other games are going to discourage me in the same way by just plain sucking. I mean really I hate to put down anybody's work, I understand that we all come from different places with different strengths but still that game... Kind of like the zelda demo. From what I remember it was just the ego on white background.

Here is where my thoughts on this subject have led me. Not necesarily a final call, but a current idea. I create a special board in which each thread is a room of a game, including all of the existing template scripts. Other rooms either from submitted games source code, or just expansions of the how to scripts can be added. It would be nice if we use the how to's to explain the idea of something with just the necesary bits of code and point from there to the whole roomscript in this other board to view it in place and in action.

Now the problem comes up, views pics and the actual game itself. Where and how should we keep this tutorial game updated to match the scripts found in the threads of the board.
« Last Edit: January 20, 2013, 10:10:30 PM by Cloudee1 »
Halloween Competition Brass Lantern Prop Competition Groundhog Day Competition

Offline Collector

Re: Fan game source code
« Reply #10 on: January 20, 2013, 10:35:29 PM »
Without ASP, it would have to be an Windows Form application that could be downloaded. If we had a compiler that could be called from the app, the script in question could be compiled into a script.* file in a template's base game that had any needed extra resources already packed into the game's archive. The script in the game's base would override the packed script. This would allow the user to modify that script and be able to see the results right away. I have already written similar code in C#, sans the compiler, to do this.
KQII Remake Pic

Offline gumby

Re: Fan game source code
« Reply #11 on: January 20, 2013, 10:49:49 PM »
Collector - yes, a standalone version of a script compiler does exist.  It's Brian's, but I cannot for the life of me figure out how to make it work properly.  I'm all for this idea, but I have no bandwidth right now to take it on.

Cloudee, yeah some games should probably not be rated.  The majority of mine probably shouldn't - most of them just show off some things you can do and really shouldn't be considered games at all but should be classified as 'instructional' - it may actually make sense to add another category for 'games' such as this (or rename the 'demo' category maybe?).  Maybe we should only do walkthroughs of complete games, based on a specific set of criteria, though I'm not sure what that criteria should be.

Sounds like your current idea is looping back around to the idea of creating a sort of tutorial game.  Or mini-tutorials, not necessarily interconnected.  I like the idea of extremely focused, very short working examples.

I've got a suggestion, what if we start with the template game (our newest, latest-greatest template game).  Then we provide tutorials illustrating a particular feature.  Then provide a 'diff' code download, then the developer has to apply it as a 'patch' into the template game, creating a complete working game.  Diff/Patch tools already exist for this purpose, though I haven't used a diff/patch in years.

Basically, it's no different than what I just did with testing your avoid script, except you would have created a diff file & attached it to your post.  I could download it, apply it to a copy of the template game & would have a complete working game in a couple of clicks, no copy-paste necessary.  You'd create the diff, then everyone else could download it and patch it into a clean copy of the template game.
In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline Collector

Re: Fan game source code
« Reply #12 on: January 20, 2013, 11:11:07 PM »
If we are talking about just one or two scripts, all we need is a "base game". This app could maintain a sort of catalog of different "TryIt"s. New ones could be added by copying a download a sub folder of the app. These download packages would only need have the relevant scripts and extra resources over the base game. One could be chosen from an auto populated combbox that would list all downloads. it could just copy the extra needed resources to the base game's folder. and when closed, the raw resources could be deleted from the game's folder. The archive/map would not have to be touched.

All of this would be fairly straight forward to do if we had a working compiler. Where is a copy of Brian's standalone compiler?
KQII Remake Pic

Offline gumby

Re: Fan game source code
« Reply #13 on: January 20, 2013, 11:37:20 PM »
In the Great Underground Empire (Zork port in development)
Winter Break 2012 Rope Prop Competition

Offline Collector

Re: Fan game source code
« Reply #14 on: January 21, 2013, 12:13:34 AM »
I played around with it for a while, but it seems to want to compile the entire game, not just the single script. It also wants an sci.sh, which is missing from any template game. It will accept the game.sh renamed to sci.sh and continues.
KQII Remake Pic


SMF 2.0.19 | SMF © 2021, Simple Machines
Simple Audio Video Embedder

Page created in 0.038 seconds with 23 queries.