Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Summer AI Challenge
Index -> Contests
Goto page Previous  1, 2, 3, 4  Next
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
bugzpodder




PostPosted: Mon Jun 02, 2003 10:06 pm   Post subject: (No subject)

a good AI should deal with a lot of situations, at least i would think so.
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Tue Jun 03, 2003 10:10 am   Post subject: (No subject)

yeah... and you could determine your relative starting position and execute different strategies if you'd like 8)
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
bugzpodder




PostPosted: Tue Jun 03, 2003 8:12 pm   Post subject: (No subject)

i am trying to write the snake engine and i am stuck on some problems. i want to have easy access of everyone's AI (ie store the pointers in an array) but stupid turing cant handle this. so in the end, i will probably put the whole engine into the SampleAI. but for now I'll leave it be. anyone have other bright ideas?
Catalyst




PostPosted: Tue Jun 03, 2003 8:34 pm   Post subject: (No subject)

what type of pointers are you talking about (to store in the array)
cpp or turing?
bugzpodder




PostPosted: Tue Jun 03, 2003 8:56 pm   Post subject: (No subject)

turing. everyone is going to have seperate classes and i am trying to find a way to combine everything.

here is the *NEW* samplesnake code, which i added one line of label 0:

and the engine, which allows you to test your own AI. its not finalized.

the simpliest way to use it is to not modify the name of the SampleSnakeAI and just modify the Think() procedure in it.


code:

look at later posts for updated code

code:

look at later posts for updated code

Catalyst




PostPosted: Tue Jun 03, 2003 9:19 pm   Post subject: (No subject)

i like the ; and () Very Happy

u could write a generic class
and have the users classes overide the base (like virtual functions)
class using deferred

or

you could have the functions and procedure outside the program
and brought in using parameters to the class
bugzpodder




PostPosted: Tue Jun 03, 2003 9:27 pm   Post subject: (No subject)

well these things sound promising i am going to try it in the next few days. anywayz here is a screen shot of my AI, based on the one i made in stage 2 (the 2nd zig-zag one, its my trademark Wink). the main part was only 10 lines Wink
Posted Image, might have been reduced in size. Click Image to view fullscreen.
Posted Image, might have been reduced in size. Click Image to view fullscreen.



tmp2.JPG
 Description:
 Filesize:  75 KB
 Viewed:  4070 Time(s)

tmp2.JPG



tmp.JPG
 Description:
 Filesize:  77.64 KB
 Viewed:  4141 Time(s)

tmp.JPG


Catalyst




PostPosted: Tue Jun 03, 2003 9:30 pm   Post subject: (No subject)

ur sample ai stops after a few turns
Sponsor
Sponsor
Sponsor
sponsor
Catalyst




PostPosted: Tue Jun 03, 2003 9:33 pm   Post subject: (No subject)

nvr mind, didnt know they turned on themselves
Tony




PostPosted: Tue Jun 03, 2003 9:38 pm   Post subject: (No subject)

thats because his sample AI moves randomly... so it crashes into itself and stops
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
bugzpodder




PostPosted: Tue Jun 03, 2003 9:52 pm   Post subject: (No subject)

well i hurriedly made these things so everyone could start making their AI and use the program to test it out. let me know when you've made something.
Catalyst




PostPosted: Tue Jun 03, 2003 11:35 pm   Post subject: (No subject)

edit: see below
bugzpodder




PostPosted: Wed Jun 04, 2003 7:43 am   Post subject: (No subject)

dead link.
Catalyst




PostPosted: Wed Jun 04, 2003 2:52 pm   Post subject: (No subject)

two ai's i tried out

new algo:

Posted Image, might have been reduced in size. Click Image to view fullscreen.

old algo:

Posted Image, might have been reduced in size. Click Image to view fullscreen.
bugzpodder




PostPosted: Wed Jun 04, 2003 5:07 pm   Post subject: (No subject)

Catalyst wrote:
i like the ; and () Very Happy

u could write a generic class
and have the users classes overide the base (like virtual functions)
class using deferred

or

you could have the functions and procedure outside the program
and brought in using parameters to the class


I basically want something that without modifying my code, I could specify which AIs to use. or if thats not possible then i need to at least have the pointers/functions stored in an array so i could loop through them in my code. i am not interested in having seperate calls to each AI using their name. anyone?
Display posts from previous:   
   Index -> Contests
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 2 of 4  [ 55 Posts ]
Goto page Previous  1, 2, 3, 4  Next
Jump to:   


Style:  
Search: