mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
- New xml: FoodOpinion.xml allows individual opinions on individual food items for each merc, the <bMoraleMod>-tag in Food.xml was removed.
- Maximum number of food items was increased to 500 (was 128). git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7454 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -52,7 +52,6 @@ foodStartElementHandle(void *userData, const XML_Char *name, const XML_Char **at
|
||||
strcmp(name, "bFoodPoints") == 0 ||
|
||||
strcmp(name, "bDrinkPoints") == 0 ||
|
||||
strcmp(name, "ubPortionSize") == 0 ||
|
||||
strcmp(name, "bMoraleMod") == 0 ||
|
||||
strcmp(name, "usDecayRate") == 0 ))
|
||||
{
|
||||
pData->curElement = ELEMENT_PROPERTY;
|
||||
@@ -126,11 +125,6 @@ foodEndElementHandle(void *userData, const XML_Char *name)
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curFood.ubPortionSize = (UINT16) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "bMoraleMod") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curFood.bMoraleMod = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usDecayRate") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
@@ -232,7 +226,6 @@ BOOLEAN WriteFoodStats()
|
||||
FilePrintf(hFile,"\t\t<bFoodPoints>%d</bFoodPoints>\r\n", Food[cnt].bFoodPoints );
|
||||
FilePrintf(hFile,"\t\t<bDrinkPoints>%d</bDrinkPoints>\r\n", Food[cnt].bDrinkPoints );
|
||||
FilePrintf(hFile,"\t\t<ubPortionSize>%d</ubPortionSize>\r\n", Food[cnt].ubPortionSize );
|
||||
FilePrintf(hFile,"\t\t<bMoraleMod>%d</bMoraleMod>\r\n", Food[cnt].bMoraleMod );
|
||||
FilePrintf(hFile,"\t\t<usDecayRate>%4.2f</usDecayRate>\r\n", Food[cnt].usDecayRate );
|
||||
|
||||
FilePrintf(hFile,"\t</FOOD>\r\n");
|
||||
|
||||
Reference in New Issue
Block a user