gametechmods

Robot Arena => General Support => Topic started by: 70 CUDA on November 11, 2008, 11:36:30 AM

Title: AI tool wont work.
Post by: 70 CUDA on November 11, 2008, 11:36:30 AM
this week i started to AI my tourny bots but my bot exportor wont work and when i dl from GTM it has the same eror message as before i dled it. what the heck.
Title: AI tool wont work.
Post by: Gigafrost on November 11, 2008, 12:41:22 PM
Which bot exporter did you use? Did you .zip/.rar your bot files?
Title: AI tool wont work.
Post by: 70 CUDA on November 11, 2008, 02:57:26 PM
apanx_bot_exporter. i thought this is the one that shows you the component nubers for your AI ing. is it a iff programe? no it wont even open at all i get this
(https://gametechmods.com/uploads/images/66789123456789.jpg)
Title: AI tool wont work.
Post by: Gigafrost on November 14, 2008, 08:40:48 PM
Yeah (apparently) that was probably an old "wasusuableinthepast" program. The best way to upload a bot is to simply do it with GTM's file uploader or with some download program.
Title: AI tool wont work.
Post by: Clickbeetle on November 15, 2008, 09:27:26 PM
It's not as good, but you can use apanx's earlier Export AI to find out the ID# and component type (SpinMotor, Weapon, etc.) of a bot's parts, but not the txt file name.

https://gametechmods.com/uploads/files/Export.zip (https://gametechmods.com/uploads/files/Export.zip)

Just AI a bot with Export and it will create a txt file with the info in it when you do a battle.  (The modified __init__.py included in there is necessary for it to work).

I don't know what could be wrong with your exporter.exe.  It works on my computer.

And Gigafrost, this is a program to find out the ID numbers of components on bots.  Not to upload them on the internet.
Title: AI tool wont work.
Post by: philetbabe on November 18, 2008, 03:26:37 PM
you can also put this code in your AI , in the function 'activate', after the 'if active ...'

   fout = open("C:/tmp/mybotsId.txt", 'a') # change the file name if you want
   goon = 1
        i = 0
        while goon == 1:
             if i  > self.GetNumComponents(): break
            currentType =  self.GetComponentType(i)
            fout.write("identifier " + str(i) + " : " + currentType + "\n" )
            i = i+ 1
   if fout: fout.close()

(be aware of the indentation problem).
Title: AI tool wont work.
Post by: 70 CUDA on November 18, 2008, 03:33:41 PM
thanks guys the one for DL from here is broken.
Title: AI tool wont work.
Post by: Serge on November 18, 2008, 04:18:01 PM
Quote from: 70hemicuda;21181
apanx_bot_exporter. i thought this is the one that shows you the component nubers for your AI ing. is it a iff programe? no it wont even open at all i get this
(https://gametechmods.com/uploads/images/66789123456789.jpg)


Downlaod this:
http://www.ascentive.com/support/new/images/lib/COMDLG32.OCX
Put it in C:\WINDOWS\System32\.
Then do Start->Run and type
Code: [Select]
regsvr32 \windows\system32\COMDLG32.OCX.
Title: AI tool wont work.
Post by: Serge on November 18, 2008, 04:19:53 PM
Quote from: philetbabe;22232
you can also put this code in your AI , in the function 'activate', after the 'if active ...'

   fout = open("C:/tmp/mybotsId.txt", 'a') # change the file name if you want
   goon = 1
        i = 0
        while goon == 1:
             if i  > self.GetNumComponents(): break
            currentType =  self.GetComponentType(i)
            fout.write("identifier " + str(i) + " : " + currentType + "\n" )
            i = i+ 1
   if fout: fout.close()

(be aware of the indentation problem).


Here, code tags:
Code: [Select]
fout = open("C:/tmp/mybotsId.txt", 'a') # change the file name if you want
goon = 1
        i = 0
        while goon == 1:
             if i  > self.GetNumComponents(): break
            currentType =  self.GetComponentType(i)
            fout.write("identifier " + str(i) + " : " + currentType + "\n" )
            i = i+ 1
if fout: fout.close()
Title: AI tool wont work.
Post by: Madiaba on November 18, 2008, 04:36:24 PM
Thanks for the reminder, Serge. I forget that this forum has that capability...
ACAMS is the man...