Someone_mad
Lesser Nub
Cakes 0
Posts: 102
Painted nails and long haired... I'm not a witch!
|
|
« Reply #100 on: September 26, 2010, 07:50:26 AM » |
|
Another bug report: I've add to my 'Baseoa' folder the bots'n'skin nammed 'Astartes' and then, when I play in single player mode, if I give an order the game just stop but don't quit... First bug I have...
|
|
|
Logged
|
|
|
|
Cacatoes
Banned for leasing own account
Posts a lot
Cakes 73
Posts: 1427
also banned for baiting another to violate rules
|
|
« Reply #101 on: September 26, 2010, 10:32:08 AM » |
|
I just tried, it half-works. There are 2 files for astartes: the model, and some "bot" file. Ensure you have both in your baseoa. He moves, he shoots with minigun but acts a bit stupid. Then it prints error messages ^1Error: weapon number out of range ^1Error: weapon number out of range ... etc Graion Dilach posted about it. According to that post, some solution would be to edit the bot files, which include a file which is mispelled. It seems then that OA broke compatibility with Quake 3 bots but those can be adapted to make them work without too big efforts.
|
|
|
Logged
|
Todo: Walk the cat.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #102 on: September 26, 2010, 11:06:07 AM » |
|
Cacatoes, that was a special case, in where even the model was broken as well. At that time, I mentioned the problem but without stating why or what is that about. Firstly, there is a half-solution DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/FAQ#How_can_I_use_maps.2C_models.2C_mods_made_for_Quake_3_Arena.3F]mentioned on the wiki, but IMHO that's a wrong one, because it changes the personality (the acquiring and using percentage) of the bot. The problem comes from the weapon list, which - probably copyright - changes the weapon and the item entities in the botcode. For example, Quake3's FS_HEALTH became FPH. This happens with every entity, while the _i.c and _w.c files are composed only from this entities. If the cause would be the missing missionpack entries, then the bots just wouldn't use them. The "Weapon out of range" message comes from those two files, because the game tries to find the Q3 entries on the OA list... and doesn't find anything. But because the main personality (aim, shoot, etc) are compatible, the bot uses what it gets... the machinegun.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
Someone_mad
Lesser Nub
Cakes 0
Posts: 102
Painted nails and long haired... I'm not a witch!
|
|
« Reply #103 on: September 26, 2010, 11:49:44 AM » |
|
Okay okay... Thank's Cacatoes, thank you as well Graion!
|
|
|
Logged
|
|
|
|
Gig
In the year 3000
Cakes 45
Posts: 4394
|
|
« Reply #104 on: September 27, 2010, 06:11:37 AM » |
|
We could write there about the "personality change" (but not the text chat, right?)... and it would be nice to give alternate instructions for how to fix the bot files without changing the personality... are you able to write down them? Anyway, it seems a bit strange that something like a variable name (like FS_HEALTH) could be covered by copyright...
|
|
« Last Edit: September 27, 2010, 06:45:45 AM by Gig »
|
Logged
|
I never want to be aggressive, offensive or ironic with my posts. If you find something offending in my posts, read them again searching for a different mood there. If you still see something bad with them, please ask me infos. I can be wrong at times, but I never want to upset anyone.
|
|
|
sago007
Posts a lot
Cakes 62
Posts: 1664
Open Arena Developer
|
|
« Reply #105 on: September 27, 2010, 11:10:58 AM » |
|
We could write there about the "personality change" (but not the text chat, right?)... and it would be nice to give alternate instructions for how to fix the bot files without changing the personality... are you able to write down them? Anyway, it seems a bit strange that something like a variable name (like FS_HEALTH) could be covered by copyright...
I believe that are more than just a few variable names. dmn_clown wrote the bot files from scrath based on a Master thesis that can be found in many of his posts on this forum. Apperntly the OA bots uses a slightly more advanced fuzzy logic compared to the original bots.
|
|
|
Logged
|
There are nothing offending in my posts.
|
|
|
Gig
In the year 3000
Cakes 45
Posts: 4394
|
|
« Reply #106 on: September 27, 2010, 12:12:25 PM » |
|
Do you mean that the problem would be that bot files would be covered by the iD Software copyright anyway, even if not copied (almost) 1:1 from the basq3 bots? Do you mean that, technically, every quake3 third party bot ever made should be considered a derivative work and thus a copyright infrignment?
Couldn't it be considered, each one of them, like a separate program written in a specific formal languange? Note: I haven't tried to open bot files, or to compare those from q3a with those from oa...
But, even if the q3-compatible bot files are still under copyright, why should we not read them? I suppose that the source code of the game, released in GPLv2 by iD Software, contains the instructions to decypher these files, thus the "phrases" written there (including the variable names) should be in GPLv2 as well, and we should be able to hold them here (not the bot files, but the way to read them). Thus, even if the new bots will be written in the new "OpenArena style" (with no copyright problem, and with the support for any new feature you will include in the game), it should be possible to restore the compatibiltiy with the "classic" bot files (the program should be made able to distinguish the old and the new format). The "derivative work" copyright of all the Q3 compatible bot files should not be our problem, since we would not make or distribute them, only will be able to read them. Probably, bots written for q3 will not use the three Team Arena weapons and may still have some problems in particular gametypes like "domination", but I suppose it would be better than now anyway.
What do you think about it?
|
|
|
Logged
|
I never want to be aggressive, offensive or ironic with my posts. If you find something offending in my posts, read them again searching for a different mood there. If you still see something bad with them, please ask me infos. I can be wrong at times, but I never want to upset anyone.
|
|
|
sago007
Posts a lot
Cakes 62
Posts: 1664
Open Arena Developer
|
|
« Reply #107 on: September 27, 2010, 12:24:49 PM » |
|
Do you mean that the problem would be that bot files would be covered by the iD Software copyright anyway, even if not copied (almost) 1:1 from the basq3 bots? Do you mean that, technically, every quake3 third party bot ever made should be considered a derivative work and thus a copyright infrignment?
I did not say anything about it. However on that subject the Quake 3 SDK likely allowed derivatives, I know the Unreal Tournament license allows it even between versions. The idea behind the current bots can likely be found in dmn_clowns early posts ( http://openarena.ws/board/index.php?action=profile;u=343;sa=showPosts;start=1475) they where supposed to be compatible but at some point he made a change that permanently broke compatibility with old bots. I don't understand exactly what.
|
|
|
Logged
|
There are nothing offending in my posts.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #108 on: September 27, 2010, 02:58:58 PM » |
|
We could write there about the "personality change" (but not the text chat, right?)... and it would be nice to give alternate instructions for how to fix the bot files without changing the personality... are you able to write down them? Anyway, it seems a bit strange that something like a variable name (like FS_HEALTH) could be covered by copyright...
Yep, the text chat's is untouched, because it is the _t.c file. I don't know the reason, what I do know is the effect. Tomorrow I'll write that alternative instuctions. But first I have to test without the TA entities, just to make sure. I always expanded the bots with the TA things... but maybe for a simple user that's too complicated. Sago, to answer your question, the main difference are contained in fuzw.c and fuzi.c which are the OA variants of fw_weap.c and fw_items.c. When I first checked them, back in 2007, I had no C knowledge, but today with a semester of C, as I can see, dmn_clown defined other situations for the bots, and that's why it had to be changed.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #109 on: September 28, 2010, 03:44:01 AM » |
|
OK, I finished my version. When you put a new bot into your game, and you play against that bot, you ca see that the bot uses only the machinegun and the console gives you ^1Error: weapon number out of range-errors. The problem lies within the differences of the Quake 3 and OpenArena's fuzzy logic but it is easy to correct this.
First, check what you've downloaded. If you got two files, like bot-lara.pk3 and md3-lara.pk3, unzip the botfile. If you got only one file, unzip that one. As you may know, pk3-files are usual zip-fles with a different extension and most . Go to botfiles/bots. In there, you'll see four files, usually with the bot's name but with different filename-endings. Two of these files are good as-is, the _c.c and_t.c, but the _i.c and _w.c files are the ones which we have to edit. These are unformatted text-files, so open them with Notepad or something similar.
I suggest to open an OA bot to see the difference and to make it easier to correct. You can find them within OA's pak6-misc.pk3 in the same path: botfiles/bots. As you can see, they're using similar files. The problem is actually within those files, so let's start with the _i.c.
As you can see, most of the lines within both files are starting with #define, a capslocked expression, some tabulators and a value. These expressions are used in the game to define how hard the bot tries to get the weapon/ammo/item (_i.c) or how much it'd use a weapon (_w.c). But the expressions are different and this is why the bots doesn't work properly. You just have to rewrite these expressions and add the missing ones. Actually, the lines follow each other in the same line, this helps us. Also, in the OpenArena botfile, every line is commented which also aids us, but if you don't know what you should rewrite to hat, here's a complete table which could be used for both _i.c and _w.c:
In Quake 3 In OpenArena
FS_HEALTH FPH FS_ARMOR FPA
W_SHOTGUN SGW W_MACHINEGUN MGW W_GRENADELAUNCHER GLW W_ROCKETLAUNCHER RLW W_RAILGUN RGW W_BFG10K BFW W_LIGHTNING LGW W_PLASMAGUN PGW
GWW_SHOTGUN GSGW GWW_MACHINEGUN GMGW GWW_GRENADELAUNCHER GGLW GWW_ROCKETLAUNCHER GRLW GWW_RAILGUN GRGW GWW_BFG10K GBFW GWW_LIGHTNING GLGW GWW_PLASMAGUN GPGW
W_TELEPORTER TELW W_MEDKIT MEDW W_QUAD QW W_ENVIRO ENVW W_HASTE HAW W_INVISIBILITY INW W_REGEN REGW W_FLIGHT FLW
FLAG_WEIGHT FGW
Also there's a last line with an #include "fw_items.c", rewrite that to #include "fuzi.c" in the _i.c and "fw_weap.c" to "fuzw.c" in the _w.c. About the tabulators, don't mind if the table became distorted. One tabulator must be there, the others are unnecessary, they're for easier understanding to the reader and not for the program.
If you rewritten these expressions, you're still not finished, because OA doesn't even load the bot, with the following error:
^1Error: file fuzi.c, line 294: can't evaluate NGW, not defined ^1Error: file fuzi.c, line 294: couldn't read expected token ^1Fatal: couldn't load weights
This means that you have to add the TA stuff for your bot. I usually set the proxlauncher near the grenade, chaingun between MG and plasma and nail near shotgun. About items, I suggest to put them near the other items but the cubes should get a relative high weight, like 200. Of course you can put zero to them but then the bot won't use them, also if you put zero for the cubes, the bot won't take skulls in Harvester and Overload mode.
After you finished these steps, the bot will be fully playable. But it's poosible that the bot was designed using the standard Q3 lines. If that's the case, sometimes you meet with a "^1Error: BotConstructChat: unknown random string XXX" line in the log. If that's the case, grab the _t.c file from the previos location and delete the capslocked lines. If this leaves a {} mark empty, add a line of ""; between them. Or if you want, extend the file with your content, but beware of the punctuations. Opening a generic OA bot's _t.c-file is also helps.
Sometimes when you add a bot to the game, you can't select the OpenArena bots instead you sees the Q3 ones. If this happens, your new bot came with a bots.txt. Open the bot's pk3 and open the scripts subfolder. There delete every Q3 entry from bots.txt, just leave your bot's one. Save and rename it to botname.bot. Rezip it and you're done. Although I'm not completely sure about grammar and I wrote it as an addendum to the current one on the wiki, not as a replacement, even if somewhere repeats the previous. I won't put this to the wiki until someone nods.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
Cacatoes
Banned for leasing own account
Posts a lot
Cakes 73
Posts: 1427
also banned for baiting another to violate rules
|
|
« Reply #110 on: September 28, 2010, 05:11:26 AM » |
|
I can't aprove your text since I have no knowledge about that, but that looks good Almost makes worth the repackaging, hosting, image previewing of every of ioq3 models. Heh, I don't feel courageous enough (and more importantly I have no good host for non-free material ... maybe we could get in touch with ioquake3 to see if there is something to do on these points).
|
|
|
Logged
|
Todo: Walk the cat.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #111 on: September 29, 2010, 01:28:15 AM » |
|
Well, Cacatoes, for you I have a question about making sense, then. Almost, but I think the main problem of _w.c and _i.c are easily fixed, compared to the different and thereby missing entries from rnd.c, which results with the BotConstructChat error, mentioned in my documentation. My idea of solving that is just a workaround and it'll waste some of the character. I don't know if rnd.c has a character limit, also to solve it, Chaoticsoldier should be connected, since he works on the OA _t.c files.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
Cacatoes
Banned for leasing own account
Posts a lot
Cakes 73
Posts: 1427
also banned for baiting another to violate rules
|
|
« Reply #112 on: September 29, 2010, 05:41:12 AM » |
|
Okay I admit I didn't read thoroughly your text and only had an eye glimpse. The problem lies within the differences of the Quake 3 and OpenArena's fuzzy logic but it is easy to correct this. Hmm, maybe better if you don't even mention that fuzzy logic story. The problem isn't: we have to take logic courses and modify the A.I code of bots to solve the problem, right ? The problem rather is: because of a few variable names not corresponding. Right ? capslocked expression => expression in caps ? tabulators => tabulations Actually, the lines follow each other in the same line, this helps us Do you mean: the order of lines is the same between the files ? Also, in the OpenArena botfile, every line is commented which also aids us I even wonder if it's a mistake, but a french could have made that one. In french the verb "Aider" is to help, but in english AIDS refers to the HIV virus. So let's say, "helps" ? what you should rewrite to hat, Spelling ? Remove "to [t]hat" When you say "I usually set the proxlauncher near the grenade", we understand you, but more concretely it means: I usually assign a value to the proxlauncher which is near the grenade launcher's one. Right ? Otherwise we could think the matter is the order of the lines. Finished
|
|
|
Logged
|
Todo: Walk the cat.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #113 on: September 29, 2010, 07:09:37 AM » |
|
Okay I admit I didn't read thoroughly your text and only had an eye glimpse. The problem lies within the differences of the Quake 3 and OpenArena's fuzzy logic but it is easy to correct this. Hmm, maybe better if you don't even mention that fuzzy logic story. The problem isn't: we have to take logic courses and modify the A.I code of bots to solve the problem, right ? The problem rather is: because of a few variable names not corresponding. Right ? capslocked expression => expression in caps ? tabulators => tabulations True. Actually, the lines follow each other in the same line, this helps us Do you mean: the order of lines is the same between the files ? Yes. Also, in the OpenArena botfile, every line is commented which also aids us I even wonder if it's a mistake, but a french could have made that one. In french the verb "Aider" is to help, but in english AIDS refers to the HIV virus. So let's say, "helps" ? AFAIK, that verb is in English as well, and even the expression of "first aid" refers to it. what you should rewrite to hat, Spelling ? Remove "to [t]hat" Yep, spelling. Also, I saw a poosible just after I putted this up but I had to go. When you say "I usually set the proxlauncher near the grenade", we understand you, but more concretely it means: I usually assign a value to the proxlauncher which is near the grenade launcher's one. Right ? Otherwise we could think the matter is the order of the lines.
Oh, OK. Now this is why I wanted a read before I put it into the wiki.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
Gig
In the year 3000
Cakes 45
Posts: 4394
|
|
« Reply #114 on: October 01, 2010, 11:06:48 AM » |
|
I wrote to dmn_clown via email, to ask him about why the bot scripting was changed... His reply: f I remember correctly, you'll have to re-write the *_c.c and the *_i.c files because I redefined things due to the copyright concerns.
If you keep the weapon weights, etc. the same, the bots personality should not change.
My following reply, with his reply: => To be honest, that's not much. The source code of the game, thus, how to > "read" the bot files should be under GPLv2, and it seems a bit strange that > iD Software did not allow people to create their own bot files due to the > copyright of their original bot files...
ID's botfiles weren't included in the GPL code dump of quake 3. So without an official acknowledgment from them (i.e. a release of the specific files with a GPL header), they aren't GPL.
> Anyway, at that time, wasn't it possible to maintain double compatibility, > to read both the old Q3 format and the new OA format?
I don't believe it would be ethical to do that as it would have required copying chunks of code that you are not legally allowed to copy for distribution with anything that is not quake 3.
I further replied saying that I can imagine that those chunks of code (those to read the bot files) should have ever been in the source code of the game, unless they were stored in a separate file since the beginning or iD Software removed them when releasing the source code, like with the calls to Punkbuster... but it would seem strange. Clown has not answered to my latest mail yet. I'm still confused...
|
|
|
Logged
|
I never want to be aggressive, offensive or ironic with my posts. If you find something offending in my posts, read them again searching for a different mood there. If you still see something bad with them, please ask me infos. I can be wrong at times, but I never want to upset anyone.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #115 on: October 01, 2010, 11:30:57 AM » |
|
Well, I don't consider this as a huge issue because this is a point which differs Quake 3 and OpenArena.
About dual format, I think as well that it doesn't archiavable because in the original Team Arena, the original Q3 bots could not be used. So we should write an altered bot-reader code which would use only the pure Q3 things. I consider OA bots using TA stuff is a next step of evolution and if that needs a rewrite of two files per bot, I accept it gladly and rewrite them by hand. Since we're talking about a relatively easy method, which only needs a simple text editor, ten minutes and a bit brainwork, I think it's acceptable.
It's true that the bot-reading code is in the source code. And that's used in OpenArena as well. The changes were made in the weapon and the item selection part of the code... interstingly, these parts really had to be rewritten by scratch, because these are indeed missing.
Since I started playing with OA 0.7.0, I did numerous botconversions back and forth, and although Quake 3's variable names are easier to understand, I'd vote for the current specification, because if they'd use the same variable names, you would get that "^1Error: file fuzi.c, line 294: can't evaluate NGW, not defined / ^1Error: file fuzi.c, line 294: couldn't read expected token / ^1Fatal: couldn't load weights" error every time you'd use a bot designed for Quake 3.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
Gig
In the year 3000
Cakes 45
Posts: 4394
|
|
« Reply #116 on: October 01, 2010, 11:46:03 AM » |
|
Would it be possible to add some check that recognizes bot files for Q3A and, since they are not compatible, will prevent them from automatically joining the match with bot_minplayers active? So, one may put in his favourite q3a model and don't care about the related bot...
|
|
|
Logged
|
I never want to be aggressive, offensive or ironic with my posts. If you find something offending in my posts, read them again searching for a different mood there. If you still see something bad with them, please ask me infos. I can be wrong at times, but I never want to upset anyone.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #117 on: October 01, 2010, 11:53:48 AM » |
|
It'd be possible, but I don't know if it'd worth the effort. That should check for an Quake 3 variable from _ i.c or _w.c before putting the bot to the botselection screen... but I've got a better idea.
OA bots should use the extension .oabot instead of general .bot. That's easier to implement, and with that modification, an unmodified Q3 bot won't even turns up in the menu and thereby ingame.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
sago007
Posts a lot
Cakes 62
Posts: 1664
Open Arena Developer
|
|
« Reply #118 on: October 01, 2010, 11:59:59 AM » |
|
I further replied saying that I can imagine that those chunks of code (those to read the bot files) should have ever been in the source code of the game, unless they were stored in a separate file since the beginning
Since the beginning the bots fuzzy logic was stored in separate files outside the engine. One could possible recognize it in one of the main source files by doing something like: #ifnotdefined FPH #define FPH FS_HEALTH #define FPA FS_ARMOR /* The rest */ #endif
|
|
|
Logged
|
There are nothing offending in my posts.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #119 on: October 01, 2010, 12:15:53 PM » |
|
That's correct, and that's why I could learn Q3 botcode using simple logic. Then two years later, on my first C lesson I was shocked to see that it wasn't that new for me that I firstly thought...
Well, general Q3 bots tries to incorporate fw_weap.c and fw_items.c instead of fuzi.c and fuzw.c, maybe those two fw files should contain the ifdefs. But I'm not remember what is the loading order... also a value should be copied to the TA items as well.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #120 on: October 01, 2010, 01:54:32 PM » |
|
OK, new question:
Are the filenames fw_weap.c and fw_items.c are copyrighted, or can we use those filenames?
Because if we can, here's the answer for this bot-problem.
Note that standard OA bots never try to load these two files, while all Q3 bots do. So I hope the answer is yes, because this is the only thing came up my mind.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
fromhell
|
|
« Reply #121 on: October 01, 2010, 03:18:32 PM » |
|
Now, that is an interesting question. I can't find any references to those two files anywhere in the q3 source...
I guess it can't hurt, can't say i've heard of a lawsuit over a mere filename.
|
|
|
Logged
|
asking when OA3 will be done won't get OA3 done. Progress of OA3 currently occurs behind closed doors alone I do not provide technical support either.new code development on github
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #122 on: October 02, 2010, 03:54:34 AM » |
|
The original fw_weap.c and fw_items.c are part of Quake 3 and are in pak0.pk3/botfiles.
These two files are based upon Sago's idea and the fact, that Q3 bots' _w.c and _i.c calls them.
If you decide to accept them, should I write them a header, like dmn_clown did or it's fine having only pure code and no explanation?
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
fromhell
|
|
« Reply #123 on: October 02, 2010, 01:32:24 PM » |
|
Would simply making those files 'include' OA's equivelants work?
|
|
|
Logged
|
asking when OA3 will be done won't get OA3 done. Progress of OA3 currently occurs behind closed doors alone I do not provide technical support either.new code development on github
|
|
|
Graion Dilach
Member
Cakes 12
Posts: 403
|
|
« Reply #124 on: October 03, 2010, 02:16:11 AM » |
|
Well, the variable names are different and it needs modificating the bots' _i.c and _w.c, while the problem is that there's no support by default.
|
|
|
Logged
|
One shall remind what have he left behind... to actually realize that it's still cool.
|
|
|
|