Author Topic: Coding Competition- 27/11 to 11/12  (Read 5521 times)

Babar

  • Creator, Mutator and Defecator
    • I can help with proof reading
    • I can help with scripting
    • I can help with story design
    • I can help with translating
    • Babar worked on one or more games that won an AGS Award!
    •  
    • Babar worked on one or more games that was nominated for an AGS Award!
Coding Competition- 27/11 to 11/12
« on: 27 Nov 2005, 11:24 »
This time round, the competition is a little more peaceful. You must create a trading system. Like the shopkeeper guy in RPGs, or the lonely space station in in trading sims. You know the stuff- buying, selling, profitting, etc.

Here are the rules:
1. Must be open-source. We can hardly inspect your coding if we cant see it.
2. Must contain instructions for how to add to an existing game, this will obviously be easier if the scripting is done as a module
3. Only use of the 3D, TCP/IP and maths plugins are allowed
4. Must provide sample game using the trade engine (obviously!)
5. Team efforts are allowed, and you're probably expected to get help for sprites, etc from elsewhere.
6. As far as possible, entries will be judged on their scripting and gameplay rather than GFX, SFX, music, etc.
7. Winner will be decided by 1 week of voting at the end.

And please, like MAGS, post here if you're thinking of entering. And please post if you're a spriter, etc. who can offer their services to scripters who need a few images of a shopkeeper or space station or whatever.

Let the peaceful trade commence!

EDIT: Bzzzp! Fwap! What?
« Last Edit: 27 Nov 2005, 11:37 by Babar »
The ultimate Professional Amateur

Now, with his very own game: Alien Time Zone

Re: Coding Competition- 27/11 to 11/12
« Reply #1 on: 27 Nov 2005, 11:35 »
Hmmmm ... I don't understand what you mean by 'providing a sample game using the fight engine'?

Do you mean any fight engine, or THE fight engine?

EDIT: Oh, I see ... did you ctrl c that from the other thread and forget to change it?

DoorKnobHandle

  • Mittens Serf
    • DoorKnobHandle worked on one or more games that won an AGS Award!
    •  
    • DoorKnobHandle worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #2 on: 27 Nov 2005, 13:49 »
I probably won't find the time to enter ( because of ...other... projects 8) ) but I was just going to say, that I love how you guys keep coming up with good coding ideas. Keep it up.

Akumayo

  • Is Watching You
    • I can help with AGS tutoring
    • I can help with play testing
    • I can help with scripting
    • I can help with story design
    • I can help with voice acting
    • Akumayo worked on one or more games that won an AGS Award!
    •  
    • Akumayo worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #3 on: 03 Dec 2005, 04:50 »
I am soo entering this one!  I have already begun development, inside I hope no one else enters... then I would win, MUHAHAHAHA.... anyway, good luck to everyone else!  I hope this comp continues to live!
"Power is not a means - it is an end."

Akumayo

  • Is Watching You
    • I can help with AGS tutoring
    • I can help with play testing
    • I can help with scripting
    • I can help with story design
    • I can help with voice acting
    • Akumayo worked on one or more games that won an AGS Award!
    •  
    • Akumayo worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #4 on: 03 Dec 2005, 06:42 »
Here, it is finished.  I scrapped it together rather quickly.  It is very basic, and very adaptable, if, of course, you take the time to understand it.  The file itself is a test "game".  It is one room, two roger's standing in it.  (Your the roger that's off the walkable area).  You can sell items to the shopkeeper by clicking on him with them (a "do you really want to sell" gui or keypress can be added easily) and you can talk to the shopkeeper to access his shop, where three items are available.  You understand, of course, that this "game" is far from glamorous, has horribly drawn everthing, but beautiful coding within. 
     The system itself is ListBox based, and you could probably change it up rather easily.  As far as adding it to an existing game, you'd have to export the ListBox that controls the shop, and copy the code out, maybe even export the shopkeeper character.  This won't take too long.  Anyway, without further staling, here's my entry:
Akumayo's Shop!
http://www.2dadventure.com/ags/akumayosshop.zip

-Regards and happy coding, Akumayo
« Last Edit: 03 Dec 2005, 06:46 by Akumayo »
"Power is not a means - it is an end."

Re: Coding Competition- 27/11 to 11/12
« Reply #5 on: 06 Dec 2005, 15:54 »
Presenting my demo game:
Quest for Blue Cup!
In which you play a lovable greenhaired scamp, who wants to buy a Blue Cup for someone for Christmas. Or something. The graphics are either from Instagame, RPGM2K, or non-existant. (Well,   prettiness of the demo wasn't one of the critera ...)

And here's the source code:
Ashens Trade Engine Thing

Let's see ... It's Inventory based, and centered around a module & 3 GUIs. Instructions for using it in another game are included in the module, as are descriptions of the functions used - hopefully they shoud be easy enough to understand.
Oh, it was made in 2.7, and since it uses strings there'll likely be some problems with using it in 2.71. If this is a major problem, let me know & I'll post an updated version.
I know what you're thinking ... Don't think that.

scourge

  • Guest
Re: Coding Competition- 27/11 to 11/12
« Reply #6 on: 06 Dec 2005, 19:32 »
i would like to compete in this competition as i will be coding my shops for my game soon, but it probably won't be done for the comp. Well anyway, i'll try and finish it.

I'll use this post also to vote  ;)

mätzyboy

  • Oooohhh... The black suit...
Re: Coding Competition- 27/11 to 11/12
« Reply #7 on: 07 Dec 2005, 09:22 »
I just wanted to say I think this competition is an excellent idea. The resources that will emerge from all the solutions provided makes a great base for a library of modules for other projects.

Sorry for spamming...  ::)

Babar

  • Creator, Mutator and Defecator
    • I can help with proof reading
    • I can help with scripting
    • I can help with story design
    • I can help with translating
    • Babar worked on one or more games that won an AGS Award!
    •  
    • Babar worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #8 on: 07 Dec 2005, 11:31 »
Wonderful entries so far, though I am still waiting for more! I thought this was going to be a flop, but apparently not.
The ultimate Professional Amateur

Now, with his very own game: Alien Time Zone

Nikolas

  • just me in awful resolution
    • Nikolas worked on one or more games that won an AGS Award!
    •  
    • Nikolas worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #9 on: 07 Dec 2005, 11:49 »
Ok. a small comment for Ashen, The shop was perfect and could handle probably a lot of items.

While I was playing it, I was worried that the prices will change.

Spoiler: ShowHide
You know, I just bought 20 Circuit Cards B from the right merchant for 10 GP and sold them to the left one for 23 GP. I mean while I was clicking I was worrying that the left merchant would say to me. "Enough. I don't want any more", or because of the ammount he would be lowering the prices wihch he bought. That would really bring life to the game;) But it's perfect

Re: Coding Competition- 27/11 to 11/12
« Reply #10 on: 07 Dec 2005, 14:28 »
Nikolas: Thank you! Obviously, the limit to different items is 300 (being the maximum number of Inv Items - although, the effective limit at the moment is about 5, I realised after I posted that I hadn't included scroll buttons on the shop GUIs), I don't know whatthe limit to the number of each item is (what's the upper limit of an int? 2 million something?).

In reference to your spoiler:
Spoiler: ShowHide
That'd be a great idea! It's not quite possible at the moment, as I added a check to prevent prices being changed by accident (e.g. calling Shop[2].AddItem(iKey, 2, 25); when the price was already set at 20). However, it'd be easy enough to work around for anyone who wants to. Hmm, unless ...


Are we allowed to modify our code after entry ...? I mean to actually add functions, not just clean up what's already there.
I know what you're thinking ... Don't think that.

Akumayo

  • Is Watching You
    • I can help with AGS tutoring
    • I can help with play testing
    • I can help with scripting
    • I can help with story design
    • I can help with voice acting
    • Akumayo worked on one or more games that won an AGS Award!
    •  
    • Akumayo worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #11 on: 07 Dec 2005, 23:36 »
Ahh man!  Ashen entered... that means I'm going to lose!  Just kidding Ashen... well... not really... you are a big threat...  Good luck!   ;D
"Power is not a means - it is an end."

Babar

  • Creator, Mutator and Defecator
    • I can help with proof reading
    • I can help with scripting
    • I can help with story design
    • I can help with translating
    • Babar worked on one or more games that won an AGS Award!
    •  
    • Babar worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #12 on: 08 Dec 2005, 13:53 »
Are we allowed to modify our code after entry ...? I mean to actually add functions, not just clean up what's already there.

Sure you are! Incorporate as many ideas as you can think of, as long as you have submitted your final entry before the voting starts.
The ultimate Professional Amateur

Now, with his very own game: Alien Time Zone

Re: Coding Competition- 27/11 to 11/12
« Reply #13 on: 10 Dec 2005, 15:30 »
OK, just squeezed this in by the deadline. The source is still available a the same place (Right Here), but has new functions added for changing item costs in game. This could be used (as Nikolas suggested) to de-value something after you've sold a certain amount to the shop, e.g.:
Code: [Select]
if (Shop[1].CheckStock(iKey) == 0) Shop[1].ChangeCost(iKey,  25);
else if (Shop[1].CheckStock(iKey) <= 10) Shop[1].ChangeCost(iKey,  20);
else if (Shop[1].CheckStock(iKey) > 10) Shop[1].ChangeCost(iKey,  15);

It can also be used (for those who've already tried the engine) in place of AddStock(Item, 0, Cost) to set the price of something without adding to the inventory.
I know what you're thinking ... Don't think that.

Babar

  • Creator, Mutator and Defecator
    • I can help with proof reading
    • I can help with scripting
    • I can help with story design
    • I can help with translating
    • Babar worked on one or more games that won an AGS Award!
    •  
    • Babar worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #14 on: 13 Dec 2005, 11:22 »
Ok, times up, so if anyone else has something going on that they want to submit, they better speak up now, and perhaps the deadline can be extended. Buloght, what about you? Anyone else who hasn't spoken up? Because as it goes, there are only two (admittedly awesome) entries, and that isn't much of a competition.
The ultimate Professional Amateur

Now, with his very own game: Alien Time Zone

scourge

  • Guest
Re: Coding Competition- 27/11 to 11/12
« Reply #15 on: 13 Dec 2005, 22:28 »
i did finish my shop system, but its not in a state to submit. Its very much integrated into my ugly game code  ;D from my RPG

Babar

  • Creator, Mutator and Defecator
    • I can help with proof reading
    • I can help with scripting
    • I can help with story design
    • I can help with translating
    • Babar worked on one or more games that won an AGS Award!
    •  
    • Babar worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #16 on: 16 Dec 2005, 14:13 »
Ok, considering all the enthusiasm for the idea, I'd have thought there'd be a few more entries. I'm not to sure what to do in this situation, so if Akumayo and Ashen could come up with an idea for the next competition together, everything would be nice and peachy.
The ultimate Professional Amateur

Now, with his very own game: Alien Time Zone

Akumayo

  • Is Watching You
    • I can help with AGS tutoring
    • I can help with play testing
    • I can help with scripting
    • I can help with story design
    • I can help with voice acting
    • Akumayo worked on one or more games that won an AGS Award!
    •  
    • Akumayo worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #17 on: 17 Dec 2005, 06:21 »
Eh, I think Ashen's shop was way better than mine, and I'm sure a great deal of you will agree, so by Babar's idea, I give all my rights to deciding the next topic to Ashen for his lovely entry.  Get to it Ashen, I'll beat you this time!
"Power is not a means - it is an end."

SSH

  • Flying round the world at the speed of haggis
    • I can help with scripting
    • SSH worked on one or more games that won an AGS Award!
    •  
    • SSH worked on one or more games that was nominated for an AGS Award!
Re: Coding Competition- 27/11 to 11/12
« Reply #18 on: 17 Dec 2005, 07:25 »
But Akumayo wins the sportsmanship award!  ;D

You are Miss Congeniality!

Re: Coding Competition- 27/11 to 11/12
« Reply #19 on: 17 Dec 2005, 13:26 »
Thank you Babar and Akumayo!

Quote
But Akumayo wins the sportsmanship award!
Agreed.

It's actually kind of ironic, in that I only really entered so it wouldn't be a one horse race, and so I have no idea what to do next (I was hoping to share duties with Akumayo, and steal his suggestions). Guess I'll have to come up with something, now. Look for it soon-ish.

Quote
Get to it Ashen, I'll beat you this time!
Well ... if I'm hosting, I won't be competing.

The time after next, though, we shall see  ...  ;)
I know what you're thinking ... Don't think that.