| Home | Tutorials | Forums | Articles | Blogs | Movies | Library | Employment | Press | Buy templates |
|
|
#1 |
|
Senior Member
Join Date: Oct 2002
Location: NY
Posts: 657
|
will accept entry until July 31th or even longer if ppl request it
![]() and will compete on League format(i think that is what they call) meaning one will compete with every other player. read thread from general chat forum for general info. http://www.actionscript.org/forums/s...3&goto=newpost lets force the move under 1 minute. if i missed some detail i should mention. please inform me.. i work full time and have very little time to work on this.. but i will do my best to win. Start the challenge!~!~!~!~!~
__________________
"If a man does not keep pace with his companions, perhaps it is because he hears a different drummer." Thoreau |
|
|
|
|
|
#2 |
|
Goldmember
Join Date: Feb 2003
Location: bavaria in germany
Posts: 1,627
|
1 minute???
I would say 20 seconds on a P3 1ghz should be more than enough. You should not try to precalculate the whole game! --------------------------------------------------------------------- the stage will load your swf and call a function named "ai". it will also give a copy of an array containing the whole information you will need in your function. Your function will return an array with the x and the y coordinate of your turn. example for your function function ai(infoarray) { return (/*any x between 0 and 7 i.e.:*/ 4, /*any y between 0 and 7 i.e.:*/ 5); } the infoarray will contain the current player (you) and an array with the current field. infoarray= [Current_Player, Current_Field_Array]; with Current_Field_Array containing 8 arrays with the x rows, containing 8 arrays with the y fields. trace(infoarray[1][3][5]) //aka infoarray[1][x][y] will return the owner of the field x=4, y=6 which is either 0 (empty) 1 (player1) 2 (player2) so an example for an infoarray would be Code:
infoarray=[1,[ [0,0,0,0,2,0,0,0], [0,0,0,0,2,0,0,0], [0,0,0,0,2,0,0,0], [0,0,0,1,2,0,0,0], [0,0,1,1,2,0,0,0], [0,0,0,0,0,0,0,0], [0,0,0,0,0,0,0,0], [0,0,0,0,0,0,0,0] ]] [2][4] [3][3] [3][4] are yours (infoarray[1][2][4]==infoarray[0]) and [4][0] [4][1] [4][2] [4][3] [4][4] belong to your enermy Your function has to return a legal turn (legal x and y coordinates) legal turns in the upper example are [5][1] [5][2] [5][3] [5][4] so your function could return([5,1]) if you return an invalid turn, you will lose. if your function does not return a turn within the the time limits, your movie will be unloaded and you loose. ------------------------------------------------------------------- You are not allowed to use - other code from outside the swf (you may not load an other swf, nor you may pass the variables to an extern script that may calculate your thing,...) - any _global tag - any _level tags (i.e.: _level0) - any setInterval tags - any on or onClipEvent statements (i.e. onEnterFrame) - any code outside functions or prototypes (i.e. code that will be called when the movie loads) -anything that may influence the variables on the stage (_level0) and anything that will run after the return of your answer (i.e. setInterval wit huge for loops that will slow down the other player) that I forgot to name here You are allowed to use - _root tag (since the stage will apply flash7's _lockroot on the subswfs ) - as many functions and prototype functions as you want so basically your swf has to contain a function with the name "ai" that will return a valid turn. the stage size of your Movieclip should be 50x50 and can contain some avatar. I am still working on the stage, but I have only few time at the moment. I have to learn, because there (maybe) is a school test on tuesday or wednesday. We have a print date that is much too early for our school newspaper, so I have to work for that too. My mother is in hospital for pneumonia (she got it from my grandma who is in hospital too), and I visit my ma at least 1 time a day there. I actually got pneumonia too, and I am feeling a little sick now, but I can't allow myself to get really ill or go to hospital, because I won't be abled to finish my work then. (and there would be noone cooking for my little brother and my dad (who is an abolute incapable cook). Last edited by McGiver; 06-13-2004 at 11:08 AM.. |
|
|
|
|
|
|
|
|
#3 |
|
Senior Member
Join Date: Oct 2002
Location: NY
Posts: 657
|
ok 30 second is enough
![]()
__________________
"If a man does not keep pace with his companions, perhaps it is because he hears a different drummer." Thoreau |
|
|
|
|
|
#4 |
|
Senior Member
Join Date: Oct 2002
Location: NY
Posts: 657
|
i mean 20:
__________________
"If a man does not keep pace with his companions, perhaps it is because he hears a different drummer." Thoreau |
|
|
|
|
|
#5 |
|
Addicted To FLASH
|
heheheeeee
20 is cool okey, who is the first poster??
__________________
â€* GOD Is Near â€* Questions Don't PM for Questions An eye for an eye, make the whole world blind _____________________________________________GHANDI |
|
|
|
|
|
#6 |
|
Senior Member
Join Date: Oct 2002
Location: NY
Posts: 657
|
i have invited marshdabeachy from bit-101
he already finished good othello program. lets hope he comes.
__________________
"If a man does not keep pace with his companions, perhaps it is because he hears a different drummer." Thoreau |
|
|
|
|
|
#7 |
|
Goldmember
Join Date: Feb 2003
Location: bavaria in germany
Posts: 1,627
|
hmm even 5 seconds should be enough (still a very long time)
but if people want we can say 20 seconds |
|
|
|
|
|
#8 |
|
Goldmember
Join Date: Feb 2003
Location: bavaria in germany
Posts: 1,627
|
I didn't forget it, I was just bound to bed with my pneumonia.
As soon as I get up to date with my work, I will do this next ![]() |
|
|
|
|
|
#9 |
|
Super Moderator
Join Date: Jan 2002
Location: Centreville, VA
Posts: 24,878
|
Hey, hope you get better, McGiver... We all want you to...
![]()
__________________
CyanBlue / Jason Je / Macromedia Certified Flash Developer & Designer http://CyanBlue.FlashVacuum.com http://www.FlashVacuum.com http://tutorials.FlashVacuum.com Do NOT PM, Email or Call me... Your question belongs right in this forum...
|
|
|
|
|
|
#10 | |
|
Addicted To FLASH
|
Quote:
WE or YOU ![]()
__________________
â€* GOD Is Near â€* Questions Don't PM for Questions An eye for an eye, make the whole world blind _____________________________________________GHANDI |
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|