centurion Posted September 3, 2004 Share Posted September 3, 2004 Just a conversion to xsd at the moment.config.research.nons.zip Link to comment Share on other sites More sharing options...
guyver6 Posted September 3, 2004 Share Posted September 3, 2004 Oh man :o This schema requires explanation. Definitely requires explanation. Guyver Link to comment Share on other sites More sharing options...
centurion Posted September 3, 2004 Author Share Posted September 3, 2004 (edited) Well, as explained in the docs, hopefully (if I managed to translate the DTD right ) Edited September 3, 2004 by centurion Link to comment Share on other sites More sharing options...
guyver6 Posted September 3, 2004 Share Posted September 3, 2004 Oh, that's link that I had to have . Thanks Guyver Link to comment Share on other sites More sharing options...
guyver6 Posted September 4, 2004 Share Posted September 4, 2004 (edited) As I looked thru the schema I found out that it can be done easier . By eliminating cross-references. In example: Blaster Bomb Launcher research topic needs Blaster Bomb Launcher item in inventory of base. After researching it, launcher becomes available to manufacture. The thing we don't need in research topic is that it's available for manufacturing after this has been research. We don't need info about what XNet entry becomes available after research. All we need is requirements of that research topic, since all other infos can be added to their places: to item's description. We just mark in items properties what researches need to be done to be able to use/produce that item. And to XNet entries goes what stuff is to be researched to show entry in XNet. That's all there is to it. So here goes my simple schema. Feel free to ignore it, change it, ignore me etc. research.xsdresearches.xml EDIT: this schema is based on what CptBoxershorts written and on schema by centurion. Oh, and I'm looking at items schema to add my idea in there also. EDIT2: In this schema you can also find simple type named "xenoId". That's my proposition for unifing identifiers. And no, I couldn't use xs:ID and xs:IDREF just becouse xs:IDREF (used by me to reference to another topics/items) requires that referenced xs:ID is in the same XML file, so when you reference in example "itm0001" as requirement for research topic to be available, then XML file doesn't validate right. And when I use xs:ID type in reference type, then there can't be more than one id's in file, so researches couldn't be referenced. BTW, there's no need for idType attribute anymore (in code type of referenced identifier could be recognized by prefix like "res" - resource, "itm" - item, "xnet" - selfexplanatory). Guyver Edited September 4, 2004 by guyver6 Link to comment Share on other sites More sharing options...
centurion Posted September 4, 2004 Author Share Posted September 4, 2004 (edited) Your implications hold in the original UFO, but might not hold in v1+; say, you could find plasma cannons from UFOs and produce/use them after you researched heavy plasma and at least one of the clips. This can easily be incorporated in the original schema, while not so in yours. I know, the example is forced, but I don't feel that the item production=its own research identification is general enough. Also, the bonus is forced to be in one specific form (same in the original DTD), I think using CNFs or DNFs could be better; wait a bit and I'll post those. edit: . . . done.normalforms.xsd Edited September 4, 2004 by centurion Link to comment Share on other sites More sharing options...
guyver6 Posted September 4, 2004 Share Posted September 4, 2004 (edited) I cannot agree with you, becouse it's possible to do with my schema and here's how: assume:res0001 - heavy plasma research topicres0002 - heavy plasma clip research topicres0003 - plasma rifle clip research topicres0004 - plasma pistol clip research topicres0005 - plasma cannon research topic now here's research entry for cannon: This gives you researchable plasma cannon, after you research heavy plasma and one of plasma clips. Have I understood your forced example correctly? EDIT: It's also easier to code that kind of relations, while searching forward and backward (like in your schema) could be more complicated (since looking for information if we can use/produce some item, we have to walk thru research tree to see if it's possible to use/produce that item while in my case you just look for particular research if it has been completed). Guyver Edited September 4, 2004 by guyver6 Link to comment Share on other sites More sharing options...
red knight Posted September 4, 2004 Share Posted September 4, 2004 I couldnt check the schemas yet, but dont worry about future additions, specify what we need, we dont know what we may do in V1+. GreetingsRed Knight Link to comment Share on other sites More sharing options...
centurion Posted September 4, 2004 Author Share Posted September 4, 2004 (edited) My point was the absence of a specific PLASMA_CANNON research topic; example: if research of heavy plasma gives you both the weapon and the clip production ability, you don't have a heavy plasma clip research topic, and you get the ability to manufacture clips without the need to research them. Oh well, if we're for v1 only ... edit: flaw: plasma hovertank is enabled w/o need for a hovertank;the XNet reference would have to be gathered from the items given?for v1 we only need whether the topic obsoletes itself, not a list. Edited September 4, 2004 by centurion Link to comment Share on other sites More sharing options...
guyver6 Posted September 4, 2004 Share Posted September 4, 2004 That's why we need information in item's data about what are research dependencies to use it and/or produce it. And i think we can assume that research topic obsoletes itself (becouse why we should research the same thing twice?). Exception are live aliens, but those aren't to be placed in research tree I think. This has to be solved within aliens data and XNet (xnet entry can be enabled by researching aliens, and becouse other researches can require xnet entry to be enabled, this solves the problem). Guyver Link to comment Share on other sites More sharing options...
red knight Posted September 4, 2004 Share Posted September 4, 2004 Always remember that Research entries requires (most of the time) that you have some item in posession, let it be dead alien, live alien, clip, or weapon. So in short that has to be explicit as you cannot code that in game logic. GreetingsRed Knight Link to comment Share on other sites More sharing options...
centurion Posted September 4, 2004 Author Share Posted September 4, 2004 And i think we can assume that research topic obsoletes itself (becouse why we should research the same thing twice?). Exception are live aliens, but those aren't to be placed in research tree I think. This has to be solved within aliens data and XNet (xnet entry can be enabled by researching aliens, and becouse other researches can require xnet entry to be enabled, this solves the problem).Live alien research is a research, it's not worth hardcoding special behaviour for this special case; you'll still have to get the same research after finishing it. Researching a grey medic may give you the cloak XNet entry, but will not give the other benefits of live cloak research. Btw, we should incorporate undeterministic research results. Ok, so research requirements go to items *scribbles mental note*; do the XNet entries behave in the same way? Link to comment Share on other sites More sharing options...
guyver6 Posted September 4, 2004 Share Posted September 4, 2004 (edited) Ok guys, I've came to a conclusion that neither my nor Centurion's schema aren't good enough. LONG (boring ) POST WARNING I want to specify requirements that research data has to meet. This are basic data/functions we want research xml file to give us:1. How long research of topic takes?2. We want topics to be dependant on possesing particular items in base storage.3. Same as above but for live aliens.4. Topics depend on completed researches of other topics.5. Research time bonus when completed similar research topics (see V1+ and CptBoxershorts docs).6. We want items to be usable depending on completed researches.7. We want items to be manufacturable depending on completed researches.8. Manufacturing items takes resources (another items) which makes dependancy between them.9. We don't want to overload other xml data files with unnecessary data (like items with data on required researches and ships on required researches etc.)10. We want to have it clear .11. Entries in XNet are dependant of researches.12. Accessing data have to be as quick as possible - thou simple....... add more please As you can see, this research thing takes all elements of the game under it's wings. This makes it complicated (Centurion's schema). From the other side any simplification of that schema ends up being not flexible. Here goes my propositions:1. Gather all that data mentioned above in one schema - this means having manufacturing and xnet with researches in one place (don't worry, my plan isn't so bad as it seams to be).2. Create lookup tables for items and xnet to connect them to researches.3. Name it all development (research and manufacturing ). Here's why lookup tables. Assume we have situation like we want (in program, in code) to check if Heavy Plasma can be used by a Soldier on field. If we have Centurion's schema, we first search for a research topic, that gives us (grants) access to Heavy Plasma. When we have it, then we check ingame (dynamic) data if it's researched. That's all. With my schema, we don't have to walk through all research topics, we just check items requirements for use (which isn't implemented in items schema yet, and won't be becouse of overhead). Then we have research topic name, and we only check dynamic data if this topic is researched. This solution removes the need of searching research tree for topic that grants access to heavy plasma (and with all our imaginary examples that heavy plasma use can depend on more researches and something else, we would need to search for all topics that grants heavy plasma, so we end up with traversing whole research tree, which could take some precious cpu time). Using my schema isn't good either, becouse it depends on out-of-research-xml-file data (which is more natural btw, becouse items have requirements of research to use/produce). This is where lookup tables could help keep data in one file, like manufacturing table could have manufaturable item name and then list of required researches and other items required to production (with amount). Use table could hold similar data but only for use. Or gather those in one table (ie. items table) and for each item name assign researches needed for production, ingredients and researches needed for use of it. Another table could be for live aliens. This could contain research name, and required alien/rank of alien. The same with xnet: xnet entry name and required research. This gives up forward lookup which is more natural than backward (search for a research that grants something). Feel free to kick me . Guyver PS. I know that when I'm tired I talk too much . EDIT: PS2. I'll try to show what I'm thinking of next time, not tell it, becouse it looks like I'm not a good writter (experience in english ain't so good ). Edited September 4, 2004 by guyver6 Link to comment Share on other sites More sharing options...
red knight Posted September 4, 2004 Share Posted September 4, 2004 (edited) I would restate those to the following. For Research Schema... 1. How long research of topic takes?2. We want topics to be dependant on a certain condition.2.1 Dependency over Item posession.2.2 Dependency over Research completed.2.3 Dependency over Logic Triggered condition (as for example time based).3. Research topics have a cost and it MAY involve special researchers abilities.4. A research topic can signal conditions on completion (unlock certain item, unlock ability, etc... all that logic dependant and handled by code)5. We don't want to overload other xml data files with unnecessary data (like items with data on required researches, ships on required researches, manufacturing with research data, etc.)6. We want to have it clear , simple, and easy to modify.7. Accessing data as quickly as possible is not a requirement, cause the runtime representation may not be a one to one mapping with the XML specification, information can be crossreferenced, other classes that handle interdependencies based on reference may appear, etc.8. All dependencies and condition have to be referenced by identifiers so they can be referenced in the runtime objects model. For Manufacturing Schema... 1. What condition must be met to have the item unlocked for manufacturing (Dependency on research)?2. Manufacturing items takes resources (another items) which makes dependancy between them.3. Manufacturing topics have a cost in money and time and it MAY involve special manufacturing facilities.4. We don't want to overload other xml data files with unnecessary data (like items with data on required researches, ships on required researches, research with manufacturing data, etc.)5. Accessing data as quickly as possible is not a requirement, cause the runtime representation may not be a one to one mapping with the XML specification, information can be crossreferenced, other classes that handle interdependencies based on reference may appear, etc.6. All dependencies and condition have to be referenced by identifiers so they can be referenced in the runtime objects model. The important difference is that we are specifing the items and stuff in here, the runtime implementation (after we load all of this) is another different thing, if we need to speed up (something that I bet there isnt going to be needed) we can do whatever we want to. The static model is a model that has to be easily modificable so that everyone can tamper with it to test inside Xenocide... changing the power of a Plasma weapon power, or rounds, or anything... or even the research scheme. The runtime model is generate from the XML DOM model, but after the loading process nothing of the XML DOM model remains in the runtime model. Runtime Model = Plain C++ Objects Static Data Model = Plain XML Schema objects Loading Process = XML DOM Model Well I hope this helps. Tell me what do you think. GreetingsRed Knight Edited September 4, 2004 by red knight Link to comment Share on other sites More sharing options...
guyver6 Posted September 5, 2004 Share Posted September 5, 2004 (edited) This only proves how code-oriented my thoughts are . Anyway, research schema requires modifications to meet this requirements, but I'm not the one who will undertake this task (/me looks at Centurion ). I can try to do manufacturing schema. The other thing is I'm looking forward on coding this static models as classes . Guyver PS. I'm curious what we will use to get data from xml files. I know that xerces's is being involved, but Yake also has some parsing stuff in there, and Yake's becoming more and more useful (as I'm following it all the time). EDIT: typos corrected Edited September 5, 2004 by guyver6 Link to comment Share on other sites More sharing options...
centurion Posted September 5, 2004 Author Share Posted September 5, 2004 Well, the research-item, research-craft, research-manufacturing links still have to be put somewhere; I think that having this information in the respective item/craft .xmls is appropriate. I'll do the research schema with that in mind, tell me if it shouldn't be so. Link to comment Share on other sites More sharing options...
guyver6 Posted September 5, 2004 Share Posted September 5, 2004 But I'm sure that those aren't necessary anymore, as RK explained, those links can be done ingame while loading xml data, and having this type of data in items/crafts/facilities xmls overloads them and makes harder to tweak researches. From what RK said I understand that we stay with your schema modifying it more or less to suit requirements that RK posted above Guyver Link to comment Share on other sites More sharing options...
centurion Posted September 5, 2004 Author Share Posted September 5, 2004 (edited) But I'm sure that those aren't necessary anymore, as RK explained, those links can be done ingame while loading xml data, and having this type of data in items/crafts/facilities xmls overloads them and makes harder to tweak researches.And how would that be done in-game? Read from a config file? Hard-coded? edit: anyways, attached is a modified schema. Eliminated names since ids determine them and they will get processed through the translator. Topic grants are cut out to have prerequisites handled as prerequisites only. Cost is added, IDs are put in; no spaces in IDs because they will be xsd:IDs in some other .xml, and those don't contain spaces.research.zip Edited September 5, 2004 by centurion Link to comment Share on other sites More sharing options...
guyver6 Posted September 7, 2004 Share Posted September 7, 2004 The only thing that makes me wonder is that there won't be any combatants static data (means no XCorp soldiers data - all generated dynamiclly in-game). There are going to be some aliens statistics thou, so maybe combatants schema has some sens... Another thing is to eliminate ids, since names will be used (see PM from Red Knight). Well, as a matter of fact it's only changing "id" attribute name to "name" but it has to be done to keep all schemas/xml files in the same "style" Guyver Link to comment Share on other sites More sharing options...
centurion Posted September 7, 2004 Author Share Posted September 7, 2004 The only thing that makes me wonder is that there won't be any combatants static data (means no XCorp soldiers data - all generated dynamiclly in-game). There are going to be some aliens statistics thou, so maybe combatants schema has some sens... Another thing is to eliminate ids, since names will be used (see PM from Red Knight). Well, as a matter of fact it's only changing "id" attribute name to "name" but it has to be done to keep all schemas/xml files in the same "style" GuyverGiven that the game should be more or less symmetric wrt the two sides, I think there will be human entries as well; the 'soldier' (or a special 'recruit') data could be used for units you recruit (human also have one, TU 40..50, etc). An asymmetric version could also work, with recruits being of a given type on the alien side. Oh, and there could even be an "alien training facility" at alien bases which would produce different rank aliens (with base values from the combatants schema) from the basic type.What PM? No prob, will browse through the xsds anyway. Link to comment Share on other sites More sharing options...
centurion Posted September 7, 2004 Author Share Posted September 7, 2004 Update.research.zip Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 7, 2005 Share Posted March 7, 2005 (edited) To pass the HTML Tech Tree I have to XML I'm afraid I'll need some help, as my XML knowledge is... null, I'll just toy with the research schema Centurion posted as much as I can , but I do need some clarifications please. Topic Names: All topics have a RES_* prefix, do all of them need to have this?, is there any other prefixes I should be aware of?+ <topic name="RES_PlasmaWeaponry"> Research Time: Do we know how many hours does it take to complete a certain topic?- <research> <time>400</time> Reference Itemids: I got this. <reference itemid="ITEM_item1028" /> - <!-- itemid references id in config.items.xml -->And, in Cpt. Boxershorts' folder, I found Item Configuration.rtf, so I got this from there.Due to the complexity of the layout, the uniqueidentifier codes for items have been divided into categories, as described below. item id 1 to 1000 'deadweight item id 1001 to 10000 'weapons item id 10001 to 15000 'equipment item id 15001 to 20000 'inert items item id 20001 to 25000 'heavy equipment item id 25001 to 40000 'invisible itemsNow, how do I know which item has which Id?, or should I just pick an Id myself?I could not find config.items.xml where they are supposed to be. Cost Type: Are cost types associated with research or with manufacturing? And also, how many types are there? <cost type="ITEM_Plasma_Pistol">1</cost> <cost type="money">2000</cost> It is under "prerequisites". Research Bonus Topic: <researchbonus topic="RES_Plasma_Pistol_Ammo">10</researchbonus> <researchbonus topic="RES_Plasma_Cannon">15</researchbonus>What is this?, is it a bonus to research a certain topic when you have already researched another? like a bonus for plasma pistol ammo when you research plasma pistol? Grants: - <grants> <reference itemid="ITEM_item1028" /> <reference xnetid="XNET_Plasma_Pistol" /> </grants>I assume "xnetid" means it gives you the x-net entry, but what about "itemid"? This is pretty much it for now, if someone feels like giving me further instructions into XML, feel free... PLEASE , though I can handle myself with few directions, but XML tutorials I found so far are chinese to me. I can't deny though that it's fun to learn by toying around Edited March 7, 2005 by Azrael Link to comment Share on other sites More sharing options...
rincewind Posted March 7, 2005 Share Posted March 7, 2005 Hi, I'll try to put down what I can gather from it. Looking at this thread, I think guiver6 played around with it, so maybe he can add something. Topic Names: All topics have a RES_* prefix, do all of them need to have this?, is there any other prefixes I should be aware of? XNET_* is for XNET entries, ITEM_* is for items you can have in your inventory. Don't know of anything else, yet. These symbolic names should always be all upper case and have underscores instead of spaces, so it would be RES_PLASMA_WEAPONRY Research Time: Do we know how many hours does it take to complete a certain topic?- <research> <time>400</time> If you don't have the right values yet, always put in a special value like 1234. This way they are easy to find and still validate as correct values for the schema. Reference Itemids: I got this. <reference itemid="ITEM_item1028" /> - <!-- itemid references id in config.items.xml -->And, in Cpt. Boxershorts' folder, I found Item Configuration.rtf, so I got this from there.Due to the complexity of the layout, the uniqueidentifier codes for items have been divided into categories, as described below. item id 1 to 1000 'deadweight item id 1001 to 10000 'weapons item id 10001 to 15000 'equipment item id 15001 to 20000 'inert items item id 20001 to 25000 'heavy equipment item id 25001 to 40000 'invisible itemsNow, how do I know which item has which Id?, or should I just pick an Id myself?I could not find config.items.xml where they are supposed to be. As far as I know, we no longer have numeric item-ids so for now, I would just leave it out. Cost Type: Are cost types associated with research or with manufacturing? And also, how many types are there? <cost type="ITEM_Plasma_Pistol">1</cost> <cost type="money">2000</cost> It is under "prerequisites". Costs are for manufacturing only Research Bonus Topic: <researchbonus topic="RES_Plasma_Pistol_Ammo">10</researchbonus> <researchbonus topic="RES_Plasma_Cannon">15</researchbonus>What is this?, is it a bonus to research a certain topic when you have already researched another? like a bonus for plasma pistol ammo when you research plasma pistol?I don't have the slightest clue... Guiver6? Centurion? Grants: - <grants> <reference itemid="ITEM_item1028" /> <reference xnetid="XNET_Plasma_Pistol" /> </grants>I assume "xnetid" means it gives you the x-net entry, but what about "itemid"? itemid is for stuff like ITEM_PLASMA_CANNON. This is what I thought I could add. Maybe one of the original authors can enlighten us further...Thanks Azrael for taking the effort. Code that has been lying around untouched always seems to get a bit dusty. :wink1: Greetings, Rincewind Link to comment Share on other sites More sharing options...
Beetle Posted March 7, 2005 Share Posted March 7, 2005 XNET_* is for XNET entries, ITEM_* is for items you can have in your inventory. Don't know of anything else, yet.Rincewind What about:- Base modules- Aircrafts- Ufos Greetings, Beetle Link to comment Share on other sites More sharing options...
centurion Posted March 8, 2005 Author Share Posted March 8, 2005 (edited) Cost Type: Are cost types associated with research or with manufacturing? And also, how many types are there? <cost type="ITEM_Plasma_Pistol">1</cost> <cost type="money">2000</cost> It is under "prerequisites". Costs are for manufacturing onlyActually, that is supposed to be the research's cost, that is, the research on Plasma Pistol will use up an instance of Plasma Pistol and 2k money (it's there just to show off the capability, actually).Research Bonus Topic: <researchbonus topic="RES_Plasma_Pistol_Ammo">10</researchbonus> <researchbonus topic="RES_Plasma_Cannon">15</researchbonus>What is this?, is it a bonus to research a certain topic when you have already researched another? like a bonus for plasma pistol ammo when you research plasma pistol?I don't have the slightest clue... Guiver6? Centurion?That'd be used to make the research progress more logically; if you research Plasma Pistol and research the ammo later, it'd take less time (-10 whatever, % or absolute value, we'll have to specify that later) than if you'd start Plasma Pistol Ammo research without having the Plasma Pistol researched; so, say, if we hardlink Plasma Cannon to Heavy Plasma only, having the lesser stuff researched would give you a bonus to that research and make you feel bad if you just jump to the important points in the tree Grants: - <grants> <reference itemid="ITEM_item1028" /> <reference xnetid="XNET_Plasma_Pistol" /> </grants>I assume "xnetid" means it gives you the x-net entry, but what about "itemid"?itemid is for stuff like ITEM_PLASMA_CANNON. This is what I thought I could add. Maybe one of the original authors can enlighten us further...This means the research grants you the ability to manufacture ITEM_item1028 (btw yes, we don't use any numeric coding, it would be something like ITEM_PLASMA_PISTOL Should I just add a readme to the schemas I co-wrote? edit: The prefixes used are in basic.xsdthat gets incorporated everywhere; those are ITEM_ (item, duh, including dead aliens), RES_ (research topic), XNET_ (XNet entry), FAC_ (facility), CRAFT_ (craft) and LIVE_ (live specimen). Edited March 8, 2005 by centurion Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 8, 2005 Share Posted March 8, 2005 Great, thanks , I'll post here if I have further problems Link to comment Share on other sites More sharing options...
rincewind Posted March 8, 2005 Share Posted March 8, 2005 Great, thanks , I'll post here if I have further problems You might also want to download XMLSpy if you don't have it already (just google for it). It's a pretty nice XML-Editor and it also validates the XML you write to see if it validates against the schema. Greetings, Rincewind Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 8, 2005 Share Posted March 8, 2005 (edited) Cost Type: Are cost types associated with research or with manufacturing? And also, how many types are there? <cost type="ITEM_Plasma_Pistol">1</cost> <cost type="money">2000</cost> It is under "prerequisites". Costs are for manufacturing only<{POST_SNAPBACK}>Actually, that is supposed to be the research's cost, that is, the research on Plasma Pistol will use up an instance of Plasma Pistol and 2k money (it's there just to show off the capability, actually).<{POST_SNAPBACK}>So, where do I get the costs from?, or should I just leave it blank for now? Edit: got a validation error with XMLSpy (great stuff btw )The file is not valid: Unable to load schema with target namespace " from basic.xsd'.What should I do about this? Edited March 8, 2005 by Azrael Link to comment Share on other sites More sharing options...
rincewind Posted March 8, 2005 Share Posted March 8, 2005 So, where do I get the costs from?, or should I just leave it blank for now? Just leave it blank for now, I would say. Edit: got a validation error with XMLSpy (great stuff btw )The file is not valid: Unable to load schema with target namespace " from basic.xsd'.What should I do about this?Try to put the basic.xsd from further up this thread in the same directory as you xml and research.xsd. Rincewind Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 8, 2005 Share Posted March 8, 2005 Thanks, that did it, but now I get this:This file is not valid: Cannot resolve declaration or definition 'craftREF' in namespace 'ResearchConfig'In basic.xsd there are listed a bunch of what the program calls simpleType, these are itemID researchID xnetID, etcI think the problem is that the items [...]REF are not defined. Maybe I'm completely wrong, I'm just pretty much guessing here. Maybe I should add them as simpleType as well?Sorry for all the stupid questions, there is so much about this I don't know :Blush: Link to comment Share on other sites More sharing options...
rincewind Posted March 8, 2005 Share Posted March 8, 2005 (edited) Thanks, that did it, but now I get this:This file is not valid: Cannot resolve declaration or definition 'craftREF' in namespace 'ResearchConfig'In basic.xsd there are listed a bunch of what the program calls simpleType, these are itemID researchID xnetID, etcI think the problem is that the items [...]REF are not defined. Maybe I'm completely wrong, I'm just pretty much guessing here. Maybe I should add them as simpleType as well?Sorry for all the stupid questions, there is so much about this I don't know :Blush: If the REF-stuff is not defined, you should probably really just add the simpleType definitions for them. Edit: I just saw that they are already in the basic.xsd, so it's probably something else. If you want, post all three files you are using (the .xml you have so far, the basic.xsd and research.xsd) I'll take a look at them, then. Rincewind Edited March 8, 2005 by rincewind Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 8, 2005 Share Posted March 8, 2005 Fixed, now I get thisThis file is not valid: Simple Type definition 'money_const' is already declared on schema document :\basic.xsdAnd highlights this <xsd:simpleType name="money_const"> Here, I'll post all three files.config.research.zip Link to comment Share on other sites More sharing options...
rincewind Posted March 8, 2005 Share Posted March 8, 2005 Fixed, now I get thisThis file is not valid: Simple Type definition 'money_const' is already declared on schema document :\basic.xsdAnd highlights this <xsd:simpleType name="money_const"> Here, I'll post all three files.Weird, it's validating perfectly here. Rincewind Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 8, 2005 Share Posted March 8, 2005 (edited) It is weird, I tried deleting all files and downloading it again, in different folders, nothing works, keeps giving me that, maybe I can work around it? Edit: If I delete the line about money_constant it validates fine... Edited March 8, 2005 by Azrael Link to comment Share on other sites More sharing options...
rincewind Posted March 8, 2005 Share Posted March 8, 2005 It is weird, I tried deleting all files and downloading it again, in different folders, nothing works, keeps giving me that, maybe I can work around it? Edit: If I delete the line about money_constant it validates fine...That line is in what file? Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 8, 2005 Share Posted March 8, 2005 This line <xsd:simpleType name="money_const">in basic.xsd Link to comment Share on other sites More sharing options...
rincewind Posted March 8, 2005 Share Posted March 8, 2005 This line <xsd:simpleType name="money_const">in basic.xsdReally, Really Weird Can someone else download the files, put then in a separate folder and see how they validate with XMLSpy? Link to comment Share on other sites More sharing options...
centurion Posted March 9, 2005 Author Share Posted March 9, 2005 No XMLSpy, checked with MSXML 4.0; and it's really a double definition, I'd rather remove the one in the research schema, since the type is (IIRC) needed in other places as well. Simply removing the bit from config.research.xsd was OK here. Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 9, 2005 Share Posted March 9, 2005 That did it, thanks Centurion Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 9, 2005 Share Posted March 9, 2005 (edited) Should I add entries which you have when you start the game?, like the XC-11 (Skyranger)? If so, what do I have to specify to make them "starting" and "free"?, assigning research time 0 I guess, is that enough?Edit 2: Can't assign time=0 Edit: also, to get Plasma Weaponry, you need a Plasma Weapon+Clip, how do I write that in the XML?, here's what's been written. <prerequisite> <either> <reference itemid="ITEM_PLASMA_PISTOL" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE" /> <reference itemid="ITEM_HEAVY_PLASMA" /> </either> </prerequisite>I suppose that means that having either one of those gives you the entry, but how do I specify that you need a pair? (weapon+that weapon's clip) Edited March 9, 2005 by Azrael Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 10, 2005 Share Posted March 10, 2005 Ok, converted nearly everything, I'll post here my progress just to keep a backup and so if someone wants to see and point any mistakes There are some issues I'll need help with still:- How to make a certain entry "free" (i.e. when you meet certain prerequisites, it just pops as completed, no research hours)- Do I have to make an entry for every single alien rank?, like an entry for a Grey Soldier, Squad Leader, Navigator, Leader, Commander?- Do I have to include the starting entries? like all the rest of the facilities and weapons?- The Plasma issue from my previous post.TechTree.zip Link to comment Share on other sites More sharing options...
Beetle Posted March 10, 2005 Share Posted March 10, 2005 - Do I have to include the starting entries? like all the rest of the facilities and weapons? I'm not sure, but propably no. I think that it will be enough if you make topic called "starting tech" or something like it and put there grants to all starting items/facilities/xnet entries... Beetle Link to comment Share on other sites More sharing options...
red knight Posted March 12, 2005 Share Posted March 12, 2005 Follow Beetle's advice create a dummy starting technology that grants an specific tech. And then we will code the special case GreetingsRed Knight Link to comment Share on other sites More sharing options...
centurion Posted March 12, 2005 Author Share Posted March 12, 2005 (edited) To get Plasma Weaponry, you need a Plasma Weapon+Clip, how do I write that in the XML? <prerequisite> <either> <reference itemid="ITEM_PLASMA_PISTOL" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE" /> <reference itemid="ITEM_HEAVY_PLASMA" /> </either> <either> <reference itemid="ITEM_PLASMA_PISTOL_CLIP" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE_CLIP" /> <reference itemid="ITEM_HEAVY_PLASMA_CLIP" /> </either> </prerequisite>or so I hope. edit: checked, works fine. However, it caught my eye that there are a lot of XNET_ prerequisites, and that seems wrong; yes, we probably won't get XNet entries for those items, but why introduce this potential bug source? Just require the appropriate RES_ instead. Edited March 12, 2005 by centurion Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 12, 2005 Share Posted March 12, 2005 To get Plasma Weaponry, you need a Plasma Weapon+Clip, how do I write that in the XML?<{POST_SNAPBACK}> <prerequisite> <either> <reference itemid="ITEM_PLASMA_PISTOL" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE" /> <reference itemid="ITEM_HEAVY_PLASMA" /> </either> <either> <reference itemid="ITEM_PLASMA_PISTOL_CLIP" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE_CLIP" /> <reference itemid="ITEM_HEAVY_PLASMA_CLIP" /> </either> </prerequisite>or so I hope. edit: checked, works fine. However, it caught my eye that there are a lot of XNET_ prerequisites, and that seems wrong; yes, we probably won't get XNet entries for those items, but why introduce this potential bug source? Just require the appropriate RES_ instead.<{POST_SNAPBACK}> That I wasn't sure of, having a RES prerequisite means that you have to research it first, right?, not just have it available for research? I used XNET as prerequisites since you obtain them when you finish the research, but I'll change it.So far we have xnet entries for all of them Thanks for the plasmas Link to comment Share on other sites More sharing options...
rincewind Posted March 12, 2005 Share Posted March 12, 2005 To get Plasma Weaponry, you need a Plasma Weapon+Clip, how do I write that in the XML? <prerequisite> <either> <reference itemid="ITEM_PLASMA_PISTOL" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE" /> <reference itemid="ITEM_HEAVY_PLASMA" /> </either> <either> <reference itemid="ITEM_PLASMA_PISTOL_CLIP" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE_CLIP" /> <reference itemid="ITEM_HEAVY_PLASMA_CLIP" /> </either> </prerequisite>or so I hope. edit: checked, works fine. However, it caught my eye that there are a lot of XNET_ prerequisites, and that seems wrong; yes, we probably won't get XNet entries for those items, but why introduce this potential bug source? Just require the appropriate RES_ instead. That I wasn't sure of, having a RES prerequisite means that you have to research it first, right?, not just have it available for research? I used XNET as prerequisites since you obtain them when you finish the research, but I'll change it.So far we have xnet entries for all of them Thanks for the plasmas RES prerequisites mean you have to have the RES_WHATEVER researched before you can start researching the entry. I think requisites should be limited to ITEM_, LIVE_ and RES_ (did I miss one?) Greetings, Rincewind Rincewind Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 16, 2005 Share Posted March 16, 2005 To get Plasma Weaponry, you need a Plasma Weapon+Clip, how do I write that in the XML?<{POST_SNAPBACK}> <prerequisite> <either> <reference itemid="ITEM_PLASMA_PISTOL" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE" /> <reference itemid="ITEM_HEAVY_PLASMA" /> </either> <either> <reference itemid="ITEM_PLASMA_PISTOL_CLIP" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE_CLIP" /> <reference itemid="ITEM_HEAVY_PLASMA_CLIP" /> </either> </prerequisite>or so I hope. edit: checked, works fine. However, it caught my eye that there are a lot of XNET_ prerequisites, and that seems wrong; yes, we probably won't get XNet entries for those items, but why introduce this potential bug source? Just require the appropriate RES_ instead.<{POST_SNAPBACK}> About that, to change the XNET prefix to RES, I need to change also the xnetid part, but change to what?<grants> <reference xnetid="XNET_ALIEN_INFILTRATION"/> </grants>this is an example, there is no resid or something like it. Which *id should I use? Link to comment Share on other sites More sharing options...
rincewind Posted March 17, 2005 Share Posted March 17, 2005 To get Plasma Weaponry, you need a Plasma Weapon+Clip, how do I write that in the XML? <prerequisite> <either> <reference itemid="ITEM_PLASMA_PISTOL" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE" /> <reference itemid="ITEM_HEAVY_PLASMA" /> </either> <either> <reference itemid="ITEM_PLASMA_PISTOL_CLIP" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE_CLIP" /> <reference itemid="ITEM_HEAVY_PLASMA_CLIP" /> </either> </prerequisite>or so I hope. edit: checked, works fine. However, it caught my eye that there are a lot of XNET_ prerequisites, and that seems wrong; yes, we probably won't get XNet entries for those items, but why introduce this potential bug source? Just require the appropriate RES_ instead. About that, to change the XNET prefix to RES, I need to change also the xnetid part, but change to what?<grants> <reference xnetid="XNET_ALIEN_INFILTRATION"/> </grants>this is an example, there is no resid or something like it. Which *id should I use?Actually, this is the only place where the XNET_ prefix has to stay. As this actually means, doing this research will grant you that XNet-Entry. Greetings, Rincewind Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 17, 2005 Share Posted March 17, 2005 (edited) To get Plasma Weaponry, you need a Plasma Weapon+Clip, how do I write that in the XML?<{POST_SNAPBACK}> <prerequisite> <either> <reference itemid="ITEM_PLASMA_PISTOL" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE" /> <reference itemid="ITEM_HEAVY_PLASMA" /> </either> <either> <reference itemid="ITEM_PLASMA_PISTOL_CLIP" /><!-- itemid references id in config.items.xml --> <reference itemid="ITEM_PLASMA_RIFLE_CLIP" /> <reference itemid="ITEM_HEAVY_PLASMA_CLIP" /> </either> </prerequisite>or so I hope. edit: checked, works fine. However, it caught my eye that there are a lot of XNET_ prerequisites, and that seems wrong; yes, we probably won't get XNet entries for those items, but why introduce this potential bug source? Just require the appropriate RES_ instead.<{POST_SNAPBACK}> About that, to change the XNET prefix to RES, I need to change also the xnetid part, but change to what?<grants> <reference xnetid="XNET_ALIEN_INFILTRATION"/> </grants>this is an example, there is no resid or something like it. Which *id should I use?<{POST_SNAPBACK}>Actually, this is the only place where the XNET_ prefix has to stay. As this actually means, doing this research will grant you that XNet-Entry. Greetings, Rincewind<{POST_SNAPBACK}> That's what I was thinking, we do have texts for every topic anyway (and if we don't, that can be fixed very easily )I just realised instead of making ONE dummy topic which grants all starting tech, I make one dummy topic for EVERY one of them (or do you want the starting tech to have different dummy topics?) Edited March 17, 2005 by Azrael Link to comment Share on other sites More sharing options...
Guest Azrael Posted March 19, 2005 Share Posted March 19, 2005 Added dummy topic. Updated names. Fixed plasma.I still need to add some Xenocide-specific topics, and think where there should be some research bonuses.Tech_Tree.zip Link to comment Share on other sites More sharing options...
Recommended Posts