Jump to content
XCOMUFO & Xenocide

Item.xml


Zombie

Recommended Posts

Hi everyone. :)

 

As my first project, I chose the task of updating all the stats in Item.xml. While going through the sheet, I noticed some values which need to be explained.

 

First is the damage dealt by craft weapons. The numbers in item.xml are all higher than those found in UFO: EU by a significant amount. Were these intentional changes by someone, or are the numbers inaccurate? For example, in EU the damage of the Fusion Ball is 230, while in item.xml the value for the Gaia is 2000.

 

Second is the weight and size of alien corpses. All have an item.xml size of xSize="2" ySize="3". This would mean that a soldier on the battlescape would be able to pick up every alien in Xenocide. To contrast this, in EU some terror units (Reaper, Cyberdisc and Sectopod) are too big to carry and don't show up in the inventory screen. Also, item.xml has all alien corpses listed as a weight of 80. Alien weights in EU are all different. Are these changes for a reason, or is it just incorrect values?

 

Next is the question about the normal pistol. In item.xml it has an auto-shot while in EU it doesn't. Why?

 

Finally is the size of the plasma weapon clips. They are listed as size xSize="1" ySize="2" in item.xml, while in EU all plasma clips are 1×1.

 

So what are mistakes and what are intentional changes? Any help would be appreciated. Thanks! :D

 

- Zombie

Link to comment
Share on other sites

  • Replies 147
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

I guess that I can let you correct sizes of plasma clips, cuz those aren't right, but as to the rest of changes, you'll have to wait for someone knowledgable in this area. IMHO there's not that much of a need to change entries in item.xml, since they aren't used atm except for prices and/or storage capacity.
Link to comment
Share on other sites

I guess that I can let you correct sizes of plasma clips, cuz those aren't right, but as to the rest of changes, you'll have to wait for someone knowledgable in this area. IMHO there's not that much of a need to change entries in item.xml, since they aren't used atm except for prices and/or storage capacity.

Actually I'd like to have item.xml done soon, agreed we don't need it ready now, but since Zombie is already working on it, it would be a shame to stop this work before it's done. I would love to have working statistics in the next release... :)

And I don't see a reason why these values would've been altered intentionally.

Link to comment
Share on other sites

Go on Zombie, correct them.

 

Greetings

Red Knight

From memory, Azreal is the one who put most of those statistics in item.xml. So he's the best person to ask. (I might be guilty of some as well, in which case I plead "human error".)

Link to comment
Share on other sites

From memory, Azreal is the one who put most of those statistics in item.xml.  So he's the best person to ask.  (I might be guilty of some as well, in which case I plead "human error".)

Ok, if that is the case, I think I can safely answer for Azrael, that he had no intention to use different values then in EU.

Link to comment
Share on other sites

All righty. We'll chalk it up to human error and nothing more. Thanks for the replies everyone! :)

 

[Late Edit: There, that wasn't so bad. item.xml is revised as far as it can be at the moment. We still need to discuss some things though. Let me pull those ideas together.] ;)

 

- Zombie

Edited by Zombie
Link to comment
Share on other sites

Guest Azrael
From memory, Azreal is the one who put most of those statistics in item.xml.  So he's the best person to ask.  (I might be guilty of some as well, in which case I plead "human error".)

Ok, if that is the case, I think I can safely answer for Azrael, that he had no intention to use different values then in EU.

Actually, the values I filled were weights and some attributes, but I didn't fill all damages because I couldn't find them all in one place and didn't have the time to go look for them in a dozen sites (got most of the ones correct from ufopaedia.org).

Link to comment
Share on other sites

All righty. We'll chalk it up to human error and nothing more. Thanks for the replies everyone! :)

 

[Late Edit: There, that wasn't so bad. item.xml is revised as far as it can be at the moment. We still need to discuss some things though. Let me pull those ideas together.] ;)

 

- Zombie

The updated file should be checked into the subversion repository. Mad, as leader of CTD, should probably have rights to do this. Failing that, send it my way, and I'll do it.

 

Edit: typo

Edited by dteviot
Link to comment
Share on other sites

The updated file should be checked into the subversion repository.  Mad, as leader of CTD, should probably have rights to do this.  Failing that, send it my way, and I'll do it.

I should, and I would do it, but mindstormmaster doesn't seem to be around. He hasn't answered to my PM until now. :( So I don't have SVN write access. :(

Link to comment
Share on other sites

When I see him online I will tell him to add you to the payroll ;). Start learning how to use Tortoise SVN.

Thanks.

Well, I already know how to use it. :) I always compile the latest revision for myself. :)

Edited by Mad
Link to comment
Share on other sites

Well, back to the task at hand. :)

 

Issue #1

Could someone please explain what "throw time" is? Item.xml gives values between 10 and 14 in this format: . I'm assuming it is a constant Time Unit usage, correct? If this is the case, the way EU handles a throw is percentage based: 25% of a units starting TU. If this is how Xenocide is going to accomplish throwing time, then a new format is needed.

Proposed format: .

 

Issue #2

Some items such as the Mind Probe, Stun Rod and Motion Scanner are "use" based. That is, they require a certain percentage of a units full TU to use one time - not a strict value such as 10 TU. The way item.xml accomplishes this is variable: for the Stun Baton, for the Motion Sensor and nothing for the Psionic Probe. I suggest we use a format which handles all these situations such as: , where x.xx is the percentage and (Variable) is dependant upon the device.

 

A couple items in the game use a constant amount of TU per use and does not depend on a units full TU. They are the Psionic Amplifier and Field Medical Kit. Nothing is listed for usage in item.xml, but we could reuse the old code for the Motion Sensor and just modify it somewhat:

for the Psionic Amplifier and

for the Field Medical Kit.

 

Ideas anyone? :wink1:

 

[Edit: added Medi-Kit]

 

- Zombie

Edited by Zombie
Link to comment
Share on other sites

Well, back to the task at hand. :)

 

Issue #1

Could someone please explain what "throw time" is? Item.xml gives values between 10 and 14 in this format: . I'm assuming it is a constant Time Unit usage, correct? If this is the case, the way EU handles a throw is percentage based: 25% of a units starting TU. If this is how Xenocide is going to accomplish throwing time, then a new format is needed.

Proposed format: .

 

I assume you're referring to the line that goes:

<throw time="10" />

 

This translates as activity "throw" takes 10 TUs. "Throw" derives from action, which is defined as:

	<xs:complexType name="actionType" abstract="true">
 <xs:annotation>
	 <xs:documentation source="guyver">Abstract action type. If you want to define custom action, you have to specify it's type.</xs:documentation>
	 <xs:documentation source="centurion">Cost in either TUs or proportion of all TUs.</xs:documentation>
 </xs:annotation>
 <xs:attribute name="time" type="xs:nonNegativeInteger" use="optional"/>
 <xs:attribute name="percentage" use="optional">
	 <xs:simpleType>
   <xs:restriction base="xs:float">
  	 <xs:minInclusive value="0"/>
  	 <xs:maxInclusive value="1"/>
   </xs:restriction>
	 </xs:simpleType>
 </xs:attribute>
</xs:complexType>

 

As you can see, there are both time and percentage attributes which can be used to set the time required to perform an action.

I hope that's clear. All this stuff is in items.xsd. Should I send you a copy?

Link to comment
Share on other sites

... translates as activity "throw" takes 10 TUs.

That's what I thought. Okay, onward. :)

 

"Throw" derives from action, which is defined as:

 

	<xs:complexType name="actionType" abstract="true">
 <xs:annotation>
	 <xs:documentation source="guyver">Abstract action type. If you want to define custom action, you have to specify it's type.</xs:documentation>
	 <xs:documentation source="centurion">Cost in either TUs or proportion of all TUs.</xs:documentation>
 </xs:annotation>
 <xs:attribute name="time" type="xs:nonNegativeInteger" use="optional"/>
 <xs:attribute name="percentage" use="optional">
	 <xs:simpleType>
   <xs:restriction base="xs:float">
  	 <xs:minInclusive value="0"/>
  	 <xs:maxInclusive value="1"/>
   </xs:restriction>
	 </xs:simpleType>
 </xs:attribute>
</xs:complexType>

As you can see, there are both time and percentage attributes which can be used to set the time required to perform an action.

I hope that's clear.

From looking at the code and info in item.xml, its becomming more clear (I think). But can you explain how a throw time of 10 is derived? Is it calculated off of something or is the value of 10 (or 12 or 14) an assigned constant? It appears to me that those numbers are assigned constants.

 

Which brings up the second point: if Xenocide is going to follow the mechanics EU uses, we should be using a percentage, not a constant. The percentage attribute is defined in the code, so would it be correct for me to change the throw times in item.xml to percentages using this code: ?

 

All this stuff is in items.xsd.  Should I send you a copy?

Well, if my comprehension of the problem is correct, then by all means send it my way. :wink1:

 

Thanks for the reply. :)

 

- Zombie

Link to comment
Share on other sites

... translates as activity "throw" takes 10 TUs.

That's what I thought. Okay, onward. :)

 

"Throw" derives from action, which is defined as:

 

	<xs:complexType name="actionType" abstract="true">
 <xs:annotation>
	 <xs:documentation source="guyver">Abstract action type. If you want to define custom action, you have to specify it's type.</xs:documentation>
	 <xs:documentation source="centurion">Cost in either TUs or proportion of all TUs.</xs:documentation>
 </xs:annotation>
 <xs:attribute name="time" type="xs:nonNegativeInteger" use="optional"/>
 <xs:attribute name="percentage" use="optional">
	 <xs:simpleType>
   <xs:restriction base="xs:float">
  	 <xs:minInclusive value="0"/>
  	 <xs:maxInclusive value="1"/>
   </xs:restriction>
	 </xs:simpleType>
 </xs:attribute>
</xs:complexType>

As you can see, there are both time and percentage attributes which can be used to set the time required to perform an action.

I hope that's clear.

From looking at the code and info in item.xml, its becomming more clear (I think). But can you explain how a throw time of 10 is derived? Is it calculated off of something or is the value of 10 (or 12 or 14) an assigned constant? It appears to me that those numbers are assigned constants.

So far as I am aware, they're assigned constants. They were like that when I joined the project.

 

Which brings up the second point: if Xenocide is going to follow the mechanics EU uses, we should be using a percentage, not a constant. The percentage attribute is defined in the code, so would it be correct for me to change the throw times in item.xml to percentages using this code: ?

Yes, changing to percentage is perfectly legal.

Edited by dteviot
Link to comment
Share on other sites

So far as I am aware, they're assigned constants.  They were like that when I joined the project.

Hehe, understood. :P

 

Yes, changing to percentage is perfectly legal.

Great! I'll go through item.xml and change it accordingly. Oh, and thanks for sending me items.xsd. That helps tremendously. =b

 

- Zombie

Link to comment
Share on other sites

Guest Azrael
So far as I am aware, they're assigned constants.  They were like that when I joined the project.

Hehe, understood. :P

 

Yes, changing to percentage is perfectly legal.

Great! I'll go through item.xml and change it accordingly. Oh, and thanks for sending me items.xsd. That helps tremendously. =b

 

- Zombie

You can get any file you need from the SVN repository too, Zombie :)

Link to comment
Share on other sites

You can get any file you need from the SVN repository too, Zombie :)

From here? As a quick search, I tried looking for item.xml in Artwork, CTD or the Sound categories - nope. The only category left is Xenocide Identity which is password protected. :crazya:

 

Anyhow, back on task. Issue#1 is solved and completed. Now it's on to Issue#2. To refresh our memories:

 

Issue #2

Some items such as the Mind Probe, Stun Rod and Motion Scanner are "use" based. That is, they require a certain percentage of a units full TU to use one time - not a strict value such as 10 TU. The way item.xml accomplishes this is variable: for the Stun Baton, for the Motion Sensor and nothing for the Psionic Probe.

Would I be correct in assuming that since the percentage is defined, that I am free to substitute that in place of time? For example, can I rename the Motion Sensor to:

, and the Stun Baton to:

?

 

- Zombie

Link to comment
Share on other sites

You can get any file you need from the SVN repository too, Zombie :)

From here? As a quick search, I tried looking for item.xml in Artwork, CTD or the Sound categories - nope. The only category left is Xenocide Identity which is password protected. :crazya:

Try

http://svn.projectxenocide.com/xenocide/trunk

 

Anyhow, back on task. Issue#1 is solved and completed. Now it's on to Issue#2. To refresh our memories:

 

Issue #2

Some items such as the Mind Probe, Stun Rod and Motion Scanner are "use" based. That is, they require a certain percentage of a units full TU to use one time - not a strict value such as 10 TU. The way item.xml accomplishes this is variable: for the Stun Baton, for the Motion Sensor and nothing for the Psionic Probe.

Would I be correct in assuming that since the percentage is defined, that I am free to substitute that in place of time? For example, can I rename the Motion Sensor to:

, and the Stun Baton to:

?

 

- Zombie

I believe you're correct, just replace time with percentage. Actually, as item.xsd is supposed to define exactly the format of item.xml, with the right tool, you can validate the change. Sorry, I can't send you my validator, home PC is dead. Azreal may be able to help.

Link to comment
Share on other sites

with the right tool, you can validate the change.  Sorry, I can't send you my validator, home PC is dead.  Azreal may be able to help.

check out Altova XMLSpy. The home edittion is free, but you'll need to register in order to get it. (Plus it requires a little digging on the website to find it. Sorry, I'm in a hurry, otherwise I would've posted a deep link.)

Link to comment
Share on other sites

Seeing as I probably have a good understanding of how to change things now (thanks dteviot), I did some major revisions to item.xml today. I think I actually fixed up most of my outstanding issues in the process. :)

 

There are still a couple which need to be addressed. First is the issue of 2×2 aliens in the Battlescape. Are the Artopod, Terror Disc and Raptor slated to be 2×2? If so, we need to either

  1. get rid of the sizes for them in item.xml since a 2×2 alien cannot be picked up/carried by a soldier, or
  2. set it to something unreasonable like 4×4 in the equipment screen.

I suggest the second approach because if the game does a check before adding items to the inventory screen during battle, it could be made to automatically ignore items which exceed the limit (x=3, y=3). Ideas? :wink1:

 

Edit: then again, if a size was undefined for a unit that could work too... :)

 

- Zombie

Edited by Zombie
Link to comment
Share on other sites

Guest Azrael
Seeing as I probably have a good understanding of how to change things now (thanks dteviot), I did some major revisions to item.xml today. I think I actually fixed up most of my outstanding issues in the process. :)

 

There are still a couple which need to be addressed. First is the issue of 2×2 aliens in the Battlescape. Are the Artopod, Terror Disc and Raptor slated to be 2×2? If so, we need to either

  1. get rid of the sizes for them in item.xml since a 2×2 alien cannot be picked up/carried by a soldier, or
     
  2. set it to something unreasonable like 4×4 in the equipment screen.

I suggest the second approach because if the game does a check before adding items to the inventory screen during battle, it could be made to automatically ignore items which exceed the limit (x=3, y=3). Ideas? :wink1:

 

Edit: then again, if a size was undefined for a unit that could work too... :)

 

- Zombie

Why not it be allowed to be picked up? Just put up a very large weight, the player will have the chance to pick it up but will never have a soldier with the strength to do it.

Doesn't really make any sense that any trooper can just pick up a body and keep shooting like nothing, I think we either make it that soldiers cannot walk around carryign a body, or that if they do, they can't carry weapons (what, you thought they'd put the bodies in their backpacks?)

Link to comment
Share on other sites

Obviously, you've never ran an alien base smash 'n grab before. I have my soldiers pick up unconscious/dead aliens and haul them back to the staging room and abort all the time.

 

Now, if a normal 1×1 alien is 3×2 (x=2, y=3) in the equipment screen, how big should a 2×2 alien be? By definition, it would be 6×4 (x=4, y=6). Can't really pick something up that large, correct? :wink1:

 

Besides, EU didn't allow it, so why should we? :P

 

- Zombie

Link to comment
Share on other sites

Guest Azrael
Obviously, you've never ran an alien base smash 'n grab before. I have my soldiers pick up unconscious/dead aliens and haul them back to the staging room and abort all the time.

 

Now, if a normal 1×1 alien is 3×2 (x=2, y=3) in the equipment screen, how big should a 2×2 alien be? By definition, it would be 6×4 (x=4, y=6). Can't really pick something up that large, correct? :wink1:

 

- Zombie

You're reading me wrong. I'm saying we either disallow grabbing corpses at all, or we disallow grabbing them but still allowing the trooper to hold his weapon normally. Come on, can you actually grab someone unconscious, put him in a small backpack, and then run around with a rifle? that just doesn't make sense, the corpse has to be dragged, or picked up in both arms. That's all I'm saying, why limit it to Artopod and TerrorDisc? (I know they are prob the heaviest, but the same would apply to the rest)

 

Besides, EU didn't allow it, so why should we?  :P

Cause we are not making neither EU nor a remake of it.

Link to comment
Share on other sites

You're reading me wrong. I'm saying we either disallow grabbing corpses at all, or we disallow grabbing them but still allowing the trooper to hold his weapon normally. Come on, can you actually grab someone unconscious, put him in a small backpack, and then run around with a rifle? that just doesn't make sense, the corpse has to be dragged, or picked up in both arms. That's all I'm saying, why limit it to Artopod and TerrorDisc? (I know they are prob the heaviest, but the same would apply to the rest).

I understand what you are saying. You are asking if it is realistic for a trooper to actually carry an alien in real life. Sure, in that respect a weakling soldier would need to drag a corpse/body. But what about a buff Arnold Schwarzenegger or Lou Ferrigno type soldier? Certainly, it is nothing for those individuals to tote around an 80 kilo weight. It's all a matter of abilities.

 

Normal EU recruits have a strength of 20-40. But they can improve to 71! That's an increase of between 176 and 355%! If you suddenly became this strong, you could probably tote someone around too. Is it sensible to assume someone could become more than twice as strong in a couple years without a constant weight training regimen? No. (Soldiers improve by going on missions, not over time) EU is totally unrealistic in a lot of areas. How far do we want to go is the question?

 

By disallowing the ability to grab a body, you would be removing an integral part of strategy. How would you be able to get an unconscious (or injured) trooper back to the transport? You would end up leaving that soldier behind. Do real soldiers leave their fallen comrades behind? Never.

 

Why prevent just the bigger units from being carried? In one word: proportionality.

  1. These aliens are too wide. 6×4 cannot fit in a 3×3 area without removing something. :P
  2. These aliens would be too heavy. Normal 1×1 aliens weigh between 20 and 40 units. Multiply that by 4 and we are up to 80-160 units.

- Zombie

Link to comment
Share on other sites

Guest Azrael
You're reading me wrong. I'm saying we either disallow grabbing corpses at all, or we disallow grabbing them but still allowing the trooper to hold his weapon normally. Come on, can you actually grab someone unconscious, put him in a small backpack, and then run around with a rifle? that just doesn't make sense, the corpse has to be dragged, or picked up in both arms. That's all I'm saying, why limit it to Artopod and TerrorDisc? (I know they are prob the heaviest, but the same would apply to the rest).

I understand what you are saying. You are asking if it is realistic for a trooper to actually carry an alien in real life. Sure, in that respect a weakling soldier would need to drag a corpse/body. But what about a buff Arnold Schwarzenegger or Lou Ferrigno type soldier? Certainly, it is nothing for those individuals to tote around an 80 kilo weight. It's all a matter of abilities.

 

Normal EU recruits have a strength of 20-40. But they can improve to 71! That's an increase of between 176 and 355%! If you suddenly became this strong, you could probably tote someone around too. Is it sensible to assume someone could become more than twice as strong in a couple years without a constant weight training regimen? No. (Soldiers improve by going on missions, not over time) EU is totally unrealistic in a lot of areas. How far do we want to go is the question?

 

By disallowing the ability to grab a body, you would be removing an integral part of strategy. How would you be able to get an unconscious (or injured) trooper back to the transport? You would end up leaving that soldier behind. Do real soldiers leave their fallen comrades behind? Never.

 

Why prevent just the bigger units from being carried? In one word: proportionality.

  1. These aliens are too wide. 6×4 cannot fit in a 3×3 area without removing something. :P
     
  2. These aliens would be too heavy. Normal 1×1 aliens weigh between 20 and 40 units. Multiply that by 4 and we are up to 80-160 units.

- Zombie

What I suggested was: if Soldier is carrying Alien, then Soldier cannot fire, any sort of weapon (maybe pistols).

But nevermind, was just a thought ^_^ good job with the xml.

Link to comment
Share on other sites

What I suggested was: if Soldier is carrying Alien, then Soldier cannot fire, any sort of weapon (maybe pistols).

To do that would require explicit coding. Ideally, we want to treat all "items" the same. Regardless of them being gun, ammo, equipment, corpse, whatever.

Link to comment
Share on other sites

:blush1: Sooo... I guess the idea of inventory size for the larger aliens is still up for discussion. For the moment I switched the weights of those aliens to the game value of 50. Did nothing to the size, pending either a resolution or a cease and desist order. :D

 

Issue #4

Armor. Vitals are as follows:

Is this for an "empty" or "full" suit of armor? By full I mean occupied by a soldier. I'd assume that because armors are listed in item.xml, they are meant to be found on the battlescape. If that is the case, then I'll switch those attributes to reflect game stats again.

 

Which brings up yet another point: dead soldiers (corpses) are not listed in item.xml either. :wink1:

 

- Zombie

Link to comment
Share on other sites

First of all: games are to be fun, not realistic. Ask first game designer if you don't believe. If carrying stuned alien from battle and flying away to survive is the only way the player can get needed research, then we should allow her to do so. It needs explicit coding? So be it. It is unrealistic? Who cares? I don't.

 

my $0.02 :)

Link to comment
Share on other sites

Guest Azrael
First of all: games are to be fun, not realistic. Ask first game designer if you don't believe. If carrying stuned alien from battle and flying away to survive is the only way the player can get needed research, then we should allow her to do so. It needs explicit coding? So be it. It is unrealistic? Who cares? I don't.

 

my $0.02 :)

I agree with you completely, but in some cases more realism can only make it more fun. For instance, if I recall correctly (I'm not sure I do), in UFO Aftermath, when you grabbed an unconscious Alien, you had to throw away your weapons, or store them in your backpack, and carry the Alien in both arms, it wouldn't allow you to put it in your backpack. I always thought that was very nice and realistic and gave it another spin in tactical strategy, after all, you'd have to provide fire support and protect the soldier carrying the ALien in his arms, that was real cool.

Link to comment
Share on other sites

Assorted rantings.

 

1. According to the description of the Raptor, it's 3 meters tall and 4 meters long. Which I estimate would give it a mass of 800 to 1000 kg. Think clydesdale. (Aside, should the weight be included in the X-NET entry?) I'm pretty sure no unaided human is going to be able to pick that up. Of course, with power armor, it may be possible. Although the sheer size would probably present difficulties.

 

So, the question really boils down to "How do we want to handle (forgive the pun) aliens?"

As we're basing Xenocide on X-COM, I think we have to allow for at least SOME aliens to be carried. If we decide that some can be carried, and some can't, then we need to have a way of specifying this. The obvious solutions are

a. Make them too heavy to be carried,

b. make them too big to fit in the "backpack" or

c. an explict flag. Note that while I say "backpack" this is an abstaction, and doesn't necessarily mean inside the backpack. It could also mean drapped across someone's back. Refer:

http://www.nd.edu/~nrotc/marines/fireman%20carry.jpg

 

My vote, for what it's worth, is we keep it simple. We treat bodies that are up to human size as just another object, and assign it a reasonable size and mass. As the values are trivial to change, we don't need to be total nazis about the exact numbers at this point in time, they can be tuned later. For the really big aliens, we assign them sizes and/or weights that are not possible to pick up. This means

(1) we can easily change it later if we want,

(2) minimal coding to support,

(3) Matches X-COM 1 behavior) and

(4) we have the possibility to provide salvage gear. v1.0+ feature, equip the HWPs (or power armour) as mini trucks, for recovering the BIG aliens.

 

2. Armor.

Armor is a bit of a funny case.

In the first case, if a person is carrying armor, in general they will be WEARING it, which is a dedicated slot that can only be armor, and only one piece. Which suggests to me that it's not really an inventory item, but is an attribute of the soldier.

 

I have memories (which I don't completely trust) of finding pieces of armor lying around in Apoc battlescapes. I don't recall if it was able to be recovered from stunned/dead troops in X-COM. I do note that in UFO:Aftershock, you CAN'T recover armour from enemy bodies, even the human ones. (Which to be honest, really ticked me off.) Which pretty much answers my (and Zombie's) question.

1. Yes, we can recover armor from the battlescape.

2. The attributes are for the armor itself, not the occupier. (And they may need to change for the different armors.) I think we can probably also assume that a soldier CAN'T just pick up any old armor from the battlescape and wear it. Armor needs to be fitted to the individual at a base.

3. And 2. imples yes, we need a soldier stunned/corpse item.

 

Zombie

A final point, the items table doesn't currently include information on the costs (time and materials) of manufacturing the items you can't buy. The way I see this being done is adding a "cost" element similar to the one used in research.xml to indicate this information.

 

e.g.

<topic name="RES_HEAVY_PLASMA_RIFLE" time="800">
 <prerequisite>
 <itemref name="ITEM_HEAVY_PLASMA_RIFLE" /> 
 </prerequisite>
 <cost money="2000">
   <item type="ITEM_HEAVY_PLASMA_RIFLE" quantity="1" /> 
 </cost>
 <bonus>
 <topicref name="RES_PLASMA_PISTOL_CLIP" bonus="10" /> 
 <topicref name="RES_PLASMA_CANNON" bonus="15" /> 
 </bonus>
 <grants quantity="AllOf">
 <itemref name="ITEM_HEAVY_PLASMA_RIFLE" /> 
 <xnetref name="XNET_HEAVY_PLASMA_RIFLE" /> 
 </grants>
 </topic>

 

So if you'd like to add this, that would be appreciated. (It will be useful when I add manufacturing projects to the projects system.)

Additional notes.

1. The "cost" element for items would look like this:

<!-- 
<cost days="2000">
   <item type="ITEM_XENIUM_133" quantity="10" /> 
   <item type="ITEM_COMPOSITES" quantity="200" /> 
</cost>
-->

 

2. As the items.xsd schema doesn't define this element, you'd need to comment it out initially.

Link to comment
Share on other sites

Zombie

A final point, the items table doesn't currently include information on the costs (time and materials) of manufacturing the items you can't buy. The way I see this being done is adding a "cost" element similar to the one used in research.xml to indicate this information.

 

So if you'd like to add this, that would be appreciated.  (It will be useful when I add manufacturing projects to the projects system.)

Additional notes. 

1. The "cost" element for items would look like this:

<!-- 
<cost days="2000">
   <item type="ITEM_XENIUM_133" quantity="10" /> 
   <item type="ITEM_COMPOSITES" quantity="200" /> 
</cost>
-->

You know, I wondered about the manufacturing aspect since there is only sale costs for those items listed. And absolutely, I'd be happy to add that info in. :)

 

Edit: you list manufacturing time in days, when in-game it is in hours. And what about workspace and manufacture cost? Should't those be listed too? :wink1:

 

- Zombie

Edited by Zombie
Link to comment
Share on other sites

Assorted rantings.

 

1. According to the description of the Raptor, it's 3 meters tall and 4 meters long.  Which I estimate would give it a mass of 800 to 1000 kg. Think clydesdale.  (Aside, should the weight be included in the X-NET entry?) I'm pretty sure no unaided human is going to be able to pick that up.  Of course, with power armor, it may be possible. Although the sheer size would probably present difficulties.

 

 

 

This probably belongs in the labs, however the above got me thinking:

 

Has anyone here read “Judas Unchained” by Peter F. Hamilton? It’s got some really cool powered armor. One of the comments in the book is that powered armor allows people to carry a lot more equipment. (So much so that the suits don't look much like people) And the suits have built in, deployable equipment. My point is, if someone is wearing power armor, then it could up their strength, and increase the size and type of equipment slots. e.g. handle a rocket launcher in each hand. Or even have “rapid change” slots in each arm, with weapons in each slot, to allow rapid switching of weapons. E.g. Have three slots in each arm, load with one with a weapon (rocket launcher, machine gun, plasma rifle) and be able to swap between them in a second or so.

Link to comment
Share on other sites

Well, I spent the better part of my last few evenings doing the 3rd major revision of item.xml. This time it dealt with the area of manufacturing. As this info is not defined anywhere yet (I think), the following code (thanks for the example, dteviot!) was to be added as a comment:

 

<!--
<cost hours="2000" money="1000">
  <facility type="FAC_ENGINEERING_FACILITY" space="10" />
  <item type="ITEM_XENIUM_133" quantity="10" />
  <item type="ITEM_COMPOSITES" quantity="200" />
</cost>
-->

 

After doing a few entries, I suddenly realized that there are two other materials that may be necessary to manufacture an item: Alien Navigation Systems and a Xenium Reactor (for craft). I added these in the code too.

 

Here is a question though: is it necessary to explicitly list special materials if the quantity is 0? For example, the Laser Pistol does not require any Xenium, so should we even list the code for that item type? I wasn't sure so the zero quantity was coded for all the entries. If we decide this code isn't necessary, I will happily remove it to reduce the clutter. :wink1:

 

And of course, while doing the revision I noticed that the XCAP's were not even close to being finished. Accuracies and TU percentage costs were added for all. Then came another problem: some tanks have "unlimited", "non-purchasable", "non-manufacturable" ammo which is automatically renewed after a mission (Laser and Plasma), while other tanks (Cannon, Rocket, Fusion) need to have ammo present in sufficient quantities to even work. Not only that, but those quantities are purchased as single units, while a tank requires a "clip" of a certain quantity of those units to be used. (Think of a Heavy Cannon. You purchase a clip of 6 rounds and it functions as usual. But pretend you had to purchase each of those 6 shells separately. See what I mean?)

 

The relationship can best be explained by a Venn diagram:

Venn_diagram.JPG

 

Where red is the tank, orange is the clip of shells and yellow is an individual shell within the clip.

 

We are going to have to code something new to explain this, as a simple tank "clip" will not work. Any ideas? ;)

 

- Zombie

 

[Edit: sweet, the attachment worked!]

Edited by Zombie
Link to comment
Share on other sites

Well, I spent the better part of my last few evenings doing the 3rd major revision of item.xml. This time it dealt with the area of manufacturing. As this info is not defined anywhere yet (I think), the following code (thanks for the example, dteviot!) was to be added as a comment:

 

<!--
<cost hours="2000" money="1000">
  <facility type="FAC_ENGINEERING_FACILITY" space="10" />
  <item type="ITEM_XENIUM_133" quantity="10" />
  <item type="ITEM_COMPOSITES" quantity="200" />
</cost>
-->

 

After doing a few entries, I suddenly realized that there are two other materials that may be necessary to manufacture an item: Alien Navigation Systems and a Xenium Reactor (for craft). I added these in the code too.

 

Here is a question though: is it necessary to explicitly list special materials if the quantity is 0? For example, the Laser Pistol does not require any Xenium, so should we even list the code for that item type?

 

I wasn't sure so the zero quantity was coded for all the entries. If we decide this code isn't necessary, I will happily remove it to reduce the clutter. :wink1:

You only need to provide an entry it the item is needed to produce the object. And you can use any valid item as the "type" attribute. FYI, the xsd describing cost is based on the one in the research schema will look something like this (I haven't added the facility element yet):

<xsd:element name="cost" minOccurs="0" maxOccurs="1">
   <xsd:complexType>
       <xsd:attribute name="days" type="xsd:nonNegativeInteger" /> 
       <xsd:attribute name="money" type="xsd:nonNegativeInteger" /> 
       <xsd:sequence minOccurs="1" maxOccurs="unbounded">
           <xsd:element name="item">
           <xsd:complexType>
               <xsd:attribute name="type" type="itemID" use="required" /> 
               <xsd:attribute name="quantity" type="xsd:positiveInteger" use="required" /> 
           </xsd:complexType>
           </xsd:element>
       </xsd:sequence>
   </xsd:complexType>
</xsd:element>

I hope that makes it clear.

 

And of course, while doing the revision I noticed that the XCAP's were not even close to being finished. Accuracies and TU percentage costs were added for all. Then came another problem: some tanks have "unlimited", "non-purchasable", "non-manufacturable" ammo which is automatically renewed after a mission (Laser and Plasma), while other tanks (Cannon, Rocket, Fusion) need to have ammo present in sufficient quantities to even work. Not only that, but those quantities are purchased as single units, while a tank requires a "clip" of a certain quantity of those units to be used. (Think of a Heavy Cannon. You purchase a clip of 6 rounds and it functions as usual. But pretend you had to purchase each of those 6 shells separately. See what I mean?)

 

The relationship can best be explained by a Venn diagram:

Venn_diagram.JPG

 

Where red is the tank, orange is the clip of shells and yellow is an individual shell within the clip. (

 

We are going to have to code something to explain this as a simple tank "clip" will not work. Any ideas? ;)

 

- Zombie

 

[Edit: sweet, the attachment worked!]

Why don't we provide clips for tanks? Just wave our hands and say tank ammo isn't compatible with normal ammo. So the tank takes a rocket clip that holds 6 shots, instead of the normal 1. Problem solved.

Link to comment
Share on other sites

Why don't we provide clips for tanks?  Just wave our hands and say tank ammo isn't compatible with normal ammo.  So the tank takes a rocket clip that holds 6 shots, instead of the normal 1.  Problem solved.

But how will those "clips" be purchased/manufactured? As a single unit, or a clip containing a quantity of shells? If we adopt the second convention, the 8 Fusion Bombs for the HWP/Launcher would need to be manufactured as a clip instead of a shell. What would happen after a mission in which you "spent" one shell in the clip? Would you need to manufacture another clip of 8 to replenish the one shell used?

 

Sure, it's easy to explain stuff away with a "simple" answer, but in reality, a minor change can have huge consequences. All the weapon stats for those XCAP's would need to be changed as would manufacturing times, quantities, workspace, special materials and cost. And then we would need to draw up a detailed plan on how ammo usage will be handled before/during/after a mission. Would seem easier to use all the original stats and add a little bit of code to handle the tank/clip/shell nested relationship, than to rewrite the XCAP book on ammo. I don't know how much programming work would be involved with the two scenarios, so this is just an opinion. :wink1:

 

- Zombie

Link to comment
Share on other sites

Why don't we provide clips for tanks?  Just wave our hands and say tank ammo isn't compatible with normal ammo.  So the tank takes a rocket clip that holds 6 shots, instead of the normal 1.  Problem solved.

But how will those "clips" be purchased/manufactured? As a single unit, or a clip containing a quantity of shells? If we adopt the second convention, the 8 Fusion Bombs for the HWP/Launcher would need to be manufactured as a clip instead of a shell. What would happen after a mission in which you "spent" one shell in the clip? Would you need to manufacture another clip of 8 to replenish the one shell used?

 

Currently the inventory system creates "clips", which are fully loaded at manufacture time. And at the end of a mission, a clip will have the unfired rounds remaining.

One of the things I hated about XCOM was if you fired even 1 round from a clip the whole clip was lost on return to base. That problem has been fixed in the current implementation.

 

Incidentally, if you have a look at the missile pods being used by craft you'll see they take clips. So we're just doing to HWPs the same thing we do to craft weapon pods.

 

 

Sure, it's easy to explain stuff away with a "simple" answer, but in reality, a minor change can have huge consequences. All the weapon stats for those XCAP's would need to be changed as would manufacturing times, quantities, workspace, special materials and cost. And then we would need to draw up a detailed plan on how ammo usage will be handled before/during/after a mission. Would seem easier to use all the original stats and add a little bit of code to handle the tank/clip/shell nested relationship, than to rewrite the XCAP book on ammo. I don't know how much programming work would be involved with the two scenarios, so this is just an opinion. :wink1:

 

- Zombie

I don't thinnk it requires a lot more effort, you just need to define clips for each of the HWPs, calculate construction costs and size (multiply standard size by clip size) and you're done.

 

Edit: fixed quoting

Edited by dteviot
Link to comment
Share on other sites

Currently the inventory system creates "clips", which are fully loaded at manufacture time.  And at the end of a mission, a clip will have the unfired rounds remaining.

One of the things I hated about XCOM was if you fired even 1 round from a clip the whole clip was lost on return to base.  That problem has been fixed in the current implementation.

 

Incidentally, if you have a look at the missile pods being used by craft you'll see they take clips.  So we're just doing to HWPs the same thing we do to craft weapon pods......

 

I don't thinnk it requires a lot more effort, you just need to define clips for each of the HWPs, calculate construction costs and size (multiply standard size by clip size) and you're done.

Ahh, I did not realize that. Will work on this next. Thanks again! :)

 

- Zombie

Link to comment
Share on other sites

Okay, I added "clips" to the XCAP's which needed them. (Right now they are only comments as an XCAP clip is not defined in item.xsd yet). Question: How are the Laser and Plasma XCAP ammunition going to be added? Unlimited ammunition or a 255 shot limit like in EU? (I have the ammo listed as 255 at the moment).

 

Another question: do we need to list a buy price if it is 0? What about a sell price of 0? I'd assume no, but I just wanted to make sure those zeros are unnecessary. :)

 

I also did some more revisions to item again. This time it was the damage for the craft and XCAP cannons. The ammo is armor PIERCING, not EXPLOSIVE. ^_^ And of course, those zeros for special materials were removed to keep the document nice and tidy.

 

Manufacturing stats are about 90% finished right now. But what about researching? There are research stats for some of the items too. Do we need to add that info in item.xml or is it listed somewhere else?

 

- Zombie

Link to comment
Share on other sites

Okay, I added "clips" to the XCAP's which needed them. (Right now they are only comments as an XCAP clip is not defined in item.xsd yet). Question: How are the Laser and Plasma XCAP ammunition going to be added? Unlimited ammunition or a 255 shot limit like in EU? (I have the ammo listed as 255 at the moment).

For v1: yes, just like in EU.

Link to comment
Share on other sites

Okay, I added "clips" to the XCAP's which needed them. (Right now they are only comments as an XCAP clip is not defined in item.xsd yet). Question: How are the Laser and Plasma XCAP ammunition going to be added? Unlimited ammunition or a 255 shot limit like in EU? (I have the ammo listed as 255 at the moment).

 

Another question: do we need to list a buy price if it is 0? What about a sell price of 0? I'd assume no, but I just wanted to make sure those zeros are unnecessary.  :)

 

Well, item.xsd says:

<xs:element name="price">
   <xs:complexType>
         <xs:attribute name="buy" type="xs:nonNegativeInteger" use="required" /> 
         <xs:attribute name="sell" type="xs:nonNegativeInteger" use="required" /> 
   </xs:complexType>
/xs:element>

which means that both are required.

FWIW, parsing is simplified if ATTRIBUTES are mandatory, as the parser we have doesn't handle default values for absent attributes. (Or if it does, I haven't yet figured out how to do it.) Note, don't confuse ATTRIBUTES with ELEMENTS.

 

Manufacturing stats are about 90% finished right now. But what about researching? There are research stats for some of the items too. Do we need to add that info in item.xml or is it listed somewhere else?

- Zombie

Research is in research.xml, and is sort of done.

That is, we have research dependancies & times. What we don't have is 1. project costs - except for Plasma Rifle & Heavy Plasma Rifle, and 2. research bonuses. (again except for the two items above.)

 

Edit: While I'm about it, do we want to discuss construction bonuses? Seems to be something that XcomUtil offered, if you had the right aliens construction times were reduced. Azrael mentioned it here: http://www.xcomufo.com/forums/index.php?sh...42024476&st=50#

Edited by dteviot
Link to comment
Share on other sites

Well, item.xsd says:

<xs:element name="price">
   <xs:complexType>
         <xs:attribute name="buy" type="xs:nonNegativeInteger" use="required" /> 
         <xs:attribute name="sell" type="xs:nonNegativeInteger" use="required" /> 
   </xs:complexType>
/xs:element>

which means that both are required. 

FWIW, parsing is simplified if ATTRIBUTES are mandatory, as the parser we have doesn't handle default values for absent attributes.  (Or if it does, I haven't yet figured out how to do it.)  Note, don't confuse ATTRIBUTES with ELEMENTS.

Sorry. Can't believe I overlooked that fact. :blush1:

--------------------

Could someone please explain the range attribute for hand-held weapons? For instance, the normal pistol entry looks like this in item.xml:

 

    <item name="ITEM_PISTOL" xsi:type="rangedWeaponItemType">
       <storage type="STORAGE_GEAR" units="1" />
       <price buy="800" sell="600" />
       <size xSize="1" ySize="2" mass="5" />
       <clip name="ITEM_PISTOL_CLIP" />
       <shoot percentage="0.18" name="ACTION_SNAP_SHOT" accuracy="0.6" range="35.0" />
       <shoot percentage="0.30" name="ACTION_AIMED_SHOT" accuracy="0.78" range="35.0" />
       <throw percentage="0.25" />
   </item>

The value is either 30 or 35 depending on weapon and shot-type. What does this value stand for? I'd assume it is how far a shot will travel across the map (like in UFO: Aftermath). Reason I'm asking is because item.xsd claims range is required so the XCAP's probably need to have it listed. Any help? :P

 

- Zombie

Edited by Zombie
Link to comment
Share on other sites

Could someone please explain the range attribute for hand-held weapons? For instance, the normal pistol entry looks like this in item.xml:

 

    <item name="ITEM_PISTOL" xsi:type="rangedWeaponItemType">
       <storage type="STORAGE_GEAR" units="1" />
       <price buy="800" sell="600" />
       <size xSize="1" ySize="2" mass="5" />
       <clip name="ITEM_PISTOL_CLIP" />
       <shoot percentage="0.18" name="ACTION_SNAP_SHOT" accuracy="0.6" range="35.0" />
       <shoot percentage="0.30" name="ACTION_AIMED_SHOT" accuracy="0.78" range="35.0" />
       <throw percentage="0.25" />
   </item>

The value is either 30 or 35 depending on weapon and shot-type. What does this value stand for? I'd assume it is how far a shot will travel across the map (like in UFO: Aftermath). Reason I'm asking is because item.xsd claims range is required so the XCAP's probably need to have it listed. Any help?  :P

 

- Zombie

Afraid that's before my time.

This thread may be helpful.

http://www.xcomufo.com/forums/index.php?sh...408&hl=item.xsd

Afraid I can't do much more at the moment, I'm supposed to be working.

 

Edit: this may also be helpful.

http://www.projectxenocide.com/public/CTD/...nfig/documents/

Side note. I need to update these docs. (I Wasn't aware they existed.)

Edited by dteviot
Link to comment
Share on other sites

Afraid that's before my time.

This thread may be helpful.

http://www.xcomufo.com/forums/index.php?sh...408&hl=item.xsd

Afraid I can't do much more at the moment, I'm supposed to be working.

 

Edit: this may also be helpful.

http://www.projectxenocide.com/public/CTD/...nfig/documents/

Side note.  I need to update these docs.  (I Wasn't aware they existed.)

Thanks for all the great info. I think I found the answer in the Items_and_Weapons_Design_Doc_V0.0.2 which red knight posted.

 

Range Damage: This is the type of damage that is caused to a ranged extend (probably an sphere or radius range ;) ). Also known as splash damage.

Area effects? *chuckles* If this is the true definition, then only HE, I and Stun Bomb explosions apply, not AP, Laser, Plasma, melee etc. =b

 

Will need to research this closer to verify though. :)

 

Edit: nope, according to the XDD Items Configuration document, range is defined as this:

3.1. Weapon Actions

3.1.1.

This allows the weapon to fire a single, vaguely accurate round.  Usually faster than an , but slower than

 

Contains:

  How far the shot will travel accurately

  How likely the shot is to hit the target

  How many time units this action will cost

So by conventional definitions range is commonly referred to as "drift". :)

- Zombie

Edited by Zombie
Link to comment
Share on other sites

I have a dumb question on ITEM.XML.

 

The file is called ITEM.XML and all of the items listed

under the tag "item name" are actually prefixed

with the text "ITEM_"

 

For example, the first one is called "ITEM_XENIUM-122"

as opposed to "XENIUM-122". Maybe redundant?

 

Also, Should there be other tags in the file perhaps?

Such as a reference to the 3D Art model and

SFX Audio associated with the ITEM ?

 

Just wondering...

 

thanks,

Kelargo

Link to comment
Share on other sites

I have a dumb question on ITEM.XML.

 

The file is called ITEM.XML  and all of the items listed

under the tag "item name" are actually prefixed

with the text "ITEM_"

 

For example, the first one is called "ITEM_XENIUM-122"

as opposed to "XENIUM-122".  Maybe redundant?

I believe this has been done to make things a bit easier for the translation. That is, the identifier strings such as "ITEM_XENIUM-122" will be translated into the actual strings that will be shown to users. (This is currently done by lookup in english.xml) By using the ITEM prefix, we get two advantages.

1. strings that have not been converted are more obvious,

2. it's easier to know what the string is.

 

Also, Should there be other tags in the file perhaps?

Such as a reference to the 3D Art model and

SFX Audio associated with the ITEM ?

 

Just wondering...

 

thanks,

Kelargo

I believe the file graphics.xml holds the item to image mapping information.

Link to comment
Share on other sites

Edit: nope, according to the XDD Items Configuration document, range is defined as this:
3.1. Weapon Actions

3.1.1.

This allows the weapon to fire a single, vaguely accurate round.  Usually faster than an , but slower than

 

Contains:

  How far the shot will travel accurately

  How likely the shot is to hit the target

  How many time units this action will cost

So by conventional definitions range is commonly referred to as "drift". :)

Just to recap here: range in item.xml refers to shot accuracy per max distance.

 

So my question is now: "Who would know anything about how these values were assigned"? SupSuper perhaps? :wink1:

 

- Zombie

Link to comment
Share on other sites


×
×
  • Create New...