Forum Topic: Flash Programming Battles 2009

(2,120 views • 124 replies)

This topic is 5 pages long. [ 1 | 2 | 3 | 4 | 5 ]

<< < > >>
Happy

zuperxtreme

Reply To Post Reply & Quote

Posted at: 10/20/09 04:58 PM

zuperxtreme NEUTRAL LEVEL 08

Sign-Up: 01/02/05

Posts: 1,599

At 10/19/09 08:29 PM, jrdnllrd wrote:
At 10/19/09 05:07 PM, jrdnllrd wrote: Actually I am building a maze bot engine right now (my own little actionscript challenge). You make a class that extends a Bot class and add it's thinking. I am almost done and can post it later today and people can try to program the best AI. It's tile based, btw.
Here is a demo with Dumb Bot

Is anyone interested in participating?

Hey man, good stuff. :D I'll think I'll give it a go today at night and see what I come up with. I take it that he only sees what's in "front" of him, right?


None

jrdnllrd

Reply To Post Reply & Quote

Posted at: 10/20/09 06:37 PM

jrdnllrd NEUTRAL LEVEL 03

Sign-Up: 01/17/09

Posts: 76

Well the bot just goes straight until he runs into a wall then turns in a random direction. I am not sure what the bot should see. I think the bot should only be able see what's around him. I was thinking giving the bot the distance between him and the next wall in each direction. I will probably do that unless anyone thinks another way would be better.

Also, any ideas for different tiles? I am going to implement keys/ doors now but any more ideas welcome. After I add a few tiles I can release it and then people can compete to make the best AI.


None

zuperxtreme

Reply To Post Reply & Quote

Posted at: 10/20/09 07:03 PM

zuperxtreme NEUTRAL LEVEL 08

Sign-Up: 01/02/05

Posts: 1,599

Teleport tiles? Take him to a random/predetermined tile in the map?


None

jrdnllrd

Reply To Post Reply & Quote

Posted at: 10/20/09 07:06 PM

jrdnllrd NEUTRAL LEVEL 03

Sign-Up: 01/17/09

Posts: 76

Good idea, I'll add that once I finish the key's/door's


None

Nicholas-Deary

Reply To Post Reply & Quote

Posted at: 10/20/09 07:06 PM

Nicholas-Deary LIGHT LEVEL 30

Sign-Up: 05/12/06

Posts: 5,911

on(release) {
gotoAndStop(1) ;
}

I'm winning!


None

zuperxtreme

Reply To Post Reply & Quote

Posted at: 10/20/09 07:23 PM

zuperxtreme NEUTRAL LEVEL 08

Sign-Up: 01/02/05

Posts: 1,599

At 10/20/09 06:37 PM, jrdnllrd wrote: Well the bot just goes straight until he runs into a wall then turns in a random direction. I am not sure what the bot should see. I think the bot should only be able see what's around him. I was thinking giving the bot the distance between him and the next wall in each direction. I will probably do that unless anyone thinks another way would be better.

And as far as this goes, I don't think there's a better way. That's how it is in real life, you pretty much have to do it by random chance. Maybe you can leave a "crum" trail? To show the bot that he's been through there already.


None

Schmastalukas

Reply To Post Reply & Quote

Posted at: 10/20/09 07:36 PM

Schmastalukas NEUTRAL LEVEL 17

Sign-Up: 10/22/07

Posts: 393

At 10/20/09 12:45 PM, Vexagon wrote: As the fact that no-one has made a "voiding grid" yet...

I'm working on one now. I'm gonna make a 3d ball thing too once I'm done.

Winning = failing at failing
Failing at failing = failing
Therefore... Winning = failing

BBS Signature

None

Treerung

Reply To Post Reply & Quote

Posted at: 10/20/09 08:10 PM

Treerung DARK LEVEL 11

Sign-Up: 04/18/08

Posts: 567

At 10/20/09 07:06 PM, Nicholas-Deary wrote: on(release) {
gotoAndStop(1) ;
}

I'm winning!

lol sadly, you are winning.
I haven't seen anything impressive at all in this thread..

:'(

BBS Signature

Goofy

jrdnllrd

Reply To Post Reply & Quote

Posted at: 10/20/09 08:51 PM

jrdnllrd NEUTRAL LEVEL 03

Sign-Up: 01/17/09

Posts: 76

At 10/20/09 08:10 PM, Treerung wrote:
At 10/20/09 07:06 PM, Nicholas-Deary wrote: on(release) {
gotoAndStop(1) ;
}

I'm winning!
lol sadly, you are winning.
I haven't seen anything impressive at all in this thread..
[Embed(source = 'winBTN.png')]
private var WinBTN:Class;

public function Main() 
{
    var winBTN:SimpleButton = new WinBTN();
    winBTN.addEventListener(MouseEvent.Click, win);
}
private function win(e:MouseEvent):void
{
    trace("jrdnllrd has won!");
}

ASVer++;

I think I win :P

Also, does anyone know how to copy array values? I can seem to get it. Just a copy of the reference. Nothing I tried seems to work including looping over the array.


None

jrdnllrd

Reply To Post Reply & Quote

Posted at: 10/20/09 09:04 PM

jrdnllrd NEUTRAL LEVEL 03

Sign-Up: 01/17/09

Posts: 76

At 10/20/09 08:51 PM, jrdnllrd wrote: Also, does anyone know how to copy array values? I can seem to get it. Just a copy of the reference. Nothing I tried seems to work including looping over the array.

Nevermind, everything I tried doesn't work on 2D arrays. Including the looping cause I didn't copy each element just each array in the array. Anyway, I fixed it using a ByteArray.


Resigned

Vexagon

Reply To Post Reply & Quote

Posted at: 10/21/09 04:30 AM

Vexagon LIGHT LEVEL 11

Sign-Up: 02/11/09

Posts: 239

At 10/20/09 07:36 PM, Schmastalukas wrote:
At 10/20/09 12:45 PM, Vexagon wrote: As the fact that no-one has made a "voiding grid" yet...
I'm working on one now. I'm gonna make a 3d ball thing too once I'm done.

Yay, finally someone. How about the 3D ball, did I win?

if (script == "ActionScript 3.0") {
return happyFace;
}

BBS Signature

None

Logidude

Reply To Post Reply & Quote

Posted at: 10/21/09 05:15 AM

Logidude FAB LEVEL 07

Sign-Up: 02/05/09

Posts: 527

That 3d ball one of yours Vexagon, was very good! I was wondering how you did it. Did you use AS2 or AS3. Please PM me. I want to get more into programming.


Elated

HonterGames

Reply To Post Reply & Quote

Posted at: 10/21/09 06:00 AM

HonterGames DARK LEVEL 08

Sign-Up: 06/18/09

Posts: 180

Done my 3D room with magnet. Was pretty easy. Only 4 library items :D but there was heaps of code (200+), well for a couple hours work. Anyways instructions are at start but:
- Arrow keys - move ball
- Space - jump
- mouseDown - Magnetise towards you

Yeah the magnet thing was stupid cos i couldnt think of another way to do it but yeah there is a little magnetism. Anyways here it is http://spamtheweb.com/ul/upload/3109/645 99_3D_ROOM_DEMO.swf

PS Vexagon i beat you :D hahaha. Ur a good coder, lets do more battles sometime :D
PPS AS2

BBS Signature

None

Logidude

Reply To Post Reply & Quote

Posted at: 10/21/09 07:01 AM

Logidude FAB LEVEL 07

Sign-Up: 02/05/09

Posts: 527

That was very good. Hey HonterGames, I went to my animation class a couple weeks back, and they where laughing at your Madness 3D thing. They said it wasn't 3d but was ok. But it wasn't very good. I don't believe them. I think it was very good! Keep on trying.


Goofy

Vexagon

Reply To Post Reply & Quote

Posted at: 10/21/09 07:10 AM

Vexagon LIGHT LEVEL 11

Sign-Up: 02/11/09

Posts: 239

PS Vexagon i beat you :D hahaha. Ur a good coder, lets do more battles sometime :D

What is there to beat me? Congrats u made a worse engine than mine (3x more code, doesn't lie steady on the grond, magnet isn't 3D, later finished, one less library item but no shadow). I dont c y u won.

Try make that voiding grid like in gridwars if u want a real challange.

if (script == "ActionScript 3.0") {
return happyFace;
}

BBS Signature

None

Logidude

Reply To Post Reply & Quote

Posted at: 10/21/09 07:26 AM

Logidude FAB LEVEL 07

Sign-Up: 02/05/09

Posts: 527

I might try that voiding grid one for a real challenge. I PMed you Vexagon.


Elated

Vexagon

Reply To Post Reply & Quote

Posted at: 10/21/09 07:49 AM

Vexagon LIGHT LEVEL 11

Sign-Up: 02/11/09

Posts: 239

At 10/21/09 07:26 AM, Logidude wrote: I might try that voiding grid one for a real challenge. I PMed you Vexagon.

Ive read it, not replied yet. I reuploaded the ball thing:
http://fjodorvanveen.nl/3Dball.swf

Did I won now? U can throw the ball around with ur mouse, move it with the arrows and jump with space.
I fixed the unrealistic movement, as well as ball rotation issues.

now i have 73 lines of AS2 code, still 5 library items. Did I won NOW?

if (script == "ActionScript 3.0") {
return happyFace;
}

BBS Signature

None

Logidude

Reply To Post Reply & Quote

Posted at: 10/21/09 08:14 AM

Logidude FAB LEVEL 07

Sign-Up: 02/05/09

Posts: 527

Ok. I'm making a challenge.

Scripting: Whatever you want to use. I am using AS2

What to make it do: Make a bouncing ball, with wind controled by the mouse. Something like you put the mouse bellow the ball, and it flys up. And the mouse above it and it goes down

Deadline: 1 week from now, which is the 28th of October, 8am NG time.


None

HonterGames

Reply To Post Reply & Quote

Posted at: 10/21/09 08:31 AM

HonterGames DARK LEVEL 08

Sign-Up: 06/18/09

Posts: 180

At 10/21/09 07:01 AM, Logidude wrote: That was very good. Hey HonterGames, I went to my animation class a couple weeks back, and they where laughing at your Madness 3D thing. They said it wasn't 3d but was ok. But it wasn't very good. I don't believe them. I think it was very good! Keep on trying.

Hahaha really. Lol thanks man. Its funny cos i made the thing in a couple of hours and got frontpaged, made some money. Tis all good :D. And yeah it wasnt 3D cos it wasnt, it was just using 2D graphics like the 3D ball :D. Real 3D in flash requires C++ and Alchemy dont it? If anyone knows otherwise drop me a PM. Anyways thanks man :D

BBS Signature

Elated

HonterGames

Reply To Post Reply & Quote

Posted at: 10/21/09 08:39 AM

HonterGames DARK LEVEL 08

Sign-Up: 06/18/09

Posts: 180

At 10/21/09 07:10 AM, Vexagon wrote:
What is there to beat me? Congrats u made a worse engine than mine (3x more code, doesn't lie steady on the grond, magnet isn't 3D, later finished, one less library item but no shadow). I dont c y u won.

Try make that voiding grid like in gridwars if u want a real challange.

HAHAHA jesus dude cant you take a joke :P hahaha
1) More code because of bad coding practices :( hahaha
2) Magnetism in life doesnt create elasticity effects like urs, but i guess in flash its wat we were looking for wasnt it? Anyways mine wasnt even close to magnetism anyway so hahahaha
3) Later date as i only found thread late one night while the wind was blowing and it was dark outside, with branches scratching against my window.... yeah....
4) Shadow is just some little add on, not required. Had it before but killed it cos thought it looked gay :(
5) I HAVE NO IDEA WAT A VOIDING GRID IS :( hahaha
6) PM me if u wanna different challenge later on down the track. Something i can actually inderstand :)hahaha. BTW i wont be able to do any challenges at the moment but PM me anytime you want a challenge and ill try to responds :D
7) ILY
8) Yeah.......

BBS Signature

None

Toast

Reply To Post Reply & Quote

Posted at: 10/21/09 09:43 AM

Toast DARK LEVEL 09

Sign-Up: 04/02/05

Posts: 8,918

At 10/20/09 12:45 PM, Vexagon wrote: As the fact that no-one has made a "voiding grid" yet, i decided to make the ball. No magnet, but the basic engine is done.

5 library items
62 lines of code
http://fjodorvanveen.nl/fjo/3Dball.swf

Wait a second, that's what you call magnetism? I thought spacebar was just a "jump" command. That doesn't really cut it. The movement is really smooth and nice but the "magnet" isn't a magnet at all


Thinking

Vexagon

Reply To Post Reply & Quote

Posted at: 10/21/09 10:39 AM

Vexagon LIGHT LEVEL 11

Sign-Up: 02/11/09

Posts: 239

At 10/21/09 09:43 AM, Toast wrote:
At 10/20/09 12:45 PM, Vexagon wrote: As the fact that no-one has made a "voiding grid" yet, i decided to make the ball. No magnet, but the basic engine is done.

5 library items
62 lines of code
http://fjodorvanveen.nl/fjo/3Dball.swf
Wait a second, that's what you call magnetism? I thought spacebar was just a "jump" command. That doesn't really cut it. The movement is really smooth and nice but the "magnet" isn't a magnet at all

http://fjodorvanveen.nl/3Dball.swf
Too bad you didn't read my post above before u replied, now there is a kind of light magnetism with the mouse.
And yes space is a jump function....

if (script == "ActionScript 3.0") {
return happyFace;
}

BBS Signature

Elated

crazyalthechicken

Reply To Post Reply & Quote

Posted at: 10/21/09 02:13 PM

crazyalthechicken LIGHT LEVEL 06

Sign-Up: 05/26/08

Posts: 15

Vexagon, i think your 3d ball wins but i found 1 small problem

cieling.

Flash Programming Battles 2009


None

hesselbom

Reply To Post Reply & Quote

Posted at: 10/21/09 04:50 PM

hesselbom NEUTRAL LEVEL 01

Sign-Up: 07/19/08

Posts: 307

At 10/19/09 04:26 PM, zuperxtreme wrote: 500 x 500 bitmap would be 25000 nodes, I think that'd get a bit processor intensive.

Well, if processing time would be the timing factor the programmer would have to try and optimize that. Going by number of steps I think would be pretty pointless because if implemented correctly it will always find the shortest path, ie the lowest amount of steps.

I don't know, maybe I just don't get what these challenges are about.


None

jrdnllrd

Reply To Post Reply & Quote

Posted at: 10/21/09 07:40 PM

jrdnllrd NEUTRAL LEVEL 03

Sign-Up: 01/17/09

Posts: 76

Here is the Maze Actionscript Challenge thinger.

If I do something like that again it will something funner, with more action. :)

Now I might do a challenge from somewhere in this thread.


None

Schmastalukas

Reply To Post Reply & Quote

Posted at: 10/21/09 08:04 PM

Schmastalukas NEUTRAL LEVEL 17

Sign-Up: 10/22/07

Posts: 393

Alright here's my voiding grid. Not quite like the one in grid wars, but you get the point.
http://www.truploader.com/view/498229

Winning = failing at failing
Failing at failing = failing
Therefore... Winning = failing

BBS Signature

None

jrdnllrd

Reply To Post Reply & Quote

Posted at: 10/21/09 08:31 PM

jrdnllrd NEUTRAL LEVEL 03

Sign-Up: 01/17/09

Posts: 76

At 10/21/09 08:04 PM, Schmastalukas wrote: Alright here's my voiding grid. Not quite like the one in grid wars, but you get the point.
http://www.truploader.com/view/498229

How did you do it? Displacement Map?


Elated

Schmastalukas

Reply To Post Reply & Quote

Posted at: 10/21/09 09:03 PM

Schmastalukas NEUTRAL LEVEL 17

Sign-Up: 10/22/07

Posts: 393

No, ha.

I made an array of points, then moved them around based on how far away they were from the mouse, and I connected all the points with API.

I bet a displacement map produce a better result in less lines, but I don't really know how to use them. :(

Winning = failing at failing
Failing at failing = failing
Therefore... Winning = failing

BBS Signature

Sleeping

Archon68

Reply To Post Reply & Quote

Posted at: 10/21/09 09:53 PM

Archon68 LIGHT LEVEL 22

Sign-Up: 09/09/07

Posts: 3,374

At 10/21/09 09:03 PM, Schmastalukas wrote: No, ha.

I made an array of points, then moved them around based on how far away they were from the mouse, and I connected all the points with API.

I bet a displacement map produce a better result in less lines, but I don't really know how to use them. :(

Here's the same thing made with a Displacement Map....

http://spamtheweb.com/ul/upload/3109/788 07_Grid_Warp.php

I got kinda lazy so it isn't as high quality or as good looking as I'd hoped. But hey, It's late and I did it in about 10 minutes...

I code in AS2, in case I forgot to mention it.

BBS Signature

None

jrdnllrd

Reply To Post Reply & Quote

Posted at: 10/21/09 10:05 PM

jrdnllrd NEUTRAL LEVEL 03

Sign-Up: 01/17/09

Posts: 76

At 10/21/09 09:03 PM, Schmastalukas wrote: I bet a displacement map produce a better result in less lines, but I don't really know how to use them. :(

I thought about doing this challenge and I was looking up displacement maps, but I it seems you have to create a map which is a bitmap with red a green channels and it didn't really seem to be exact. So I just said "screw it". With more detailed grids it would be better since it's modifies the bitmap but I like how you did it.


All times are Eastern Standard Time (GMT -5) | Current Time: 01:36 PM

<< Back

This topic is 5 pages long. [ 1 | 2 | 3 | 4 | 5 ]

<< < > >>
You need a Grounds Gold Account to post on the NG BBS! If you don't have one, click here to sign up now! It's fast, free, and easy — and opens up tons of great NG features!