mirror of
https://github.com/1dot13/source.git
synced 2026-08-19 14:20:30 +02:00
- new feature: backgrounds allow more personalisation of mercenaries
- background feature replaces overheating on startup screen, moved overheating opion to ini WARNING: GameDir revision >= 1748 is required. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6353 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -179,8 +179,9 @@ profileStartElementHandle(void *userData, const XML_Char *name, const XML_Char *
|
||||
strcmp(name, "sSectorZ") == 0 ||
|
||||
strcmp(name, "ubCivilianGroup") == 0 ||
|
||||
strcmp(name, "bTown") == 0 ||
|
||||
strcmp(name, "bTownAttachment") == 0
|
||||
|
||||
strcmp(name, "bTownAttachment") == 0 ||
|
||||
strcmp(name, "usBackground") == 0
|
||||
|
||||
))
|
||||
{
|
||||
pData->curElement = ELEMENT_PROPERTY;
|
||||
@@ -335,6 +336,7 @@ profileEndElementHandle(void *userData, const XML_Char *name)
|
||||
tempProfiles[pData->curIndex].ubCivilianGroup = pData->curProfile.ubCivilianGroup;
|
||||
tempProfiles[pData->curIndex].bTown = pData->curProfile.bTown;
|
||||
tempProfiles[pData->curIndex].bTownAttachment = pData->curProfile.bTownAttachment;
|
||||
tempProfiles[pData->curIndex].usBackground = pData->curProfile.usBackground;
|
||||
|
||||
tempProfiles[pData->curIndex].fGoodGuy = pData->curProfile.fGoodGuy;
|
||||
memcpy( &(tempProfiles[pData->curIndex].usApproachFactor), &(pData->curProfile.usApproachFactor), 4 * sizeof (UINT16));
|
||||
@@ -975,6 +977,11 @@ profileEndElementHandle(void *userData, const XML_Char *name)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curProfile.bTownAttachment = (INT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usBackground") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curProfile.usBackground = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
|
||||
|
||||
@@ -1540,7 +1547,8 @@ BOOLEAN WriteMercProfiles()
|
||||
FilePrintf(hFile,"\t\t<ubCivilianGroup>%d</ubCivilianGroup>\r\n", gMercProfiles[ cnt ].ubCivilianGroup);
|
||||
FilePrintf(hFile,"\t\t<bTown>%d</bTown>\r\n", gMercProfiles[ cnt ].bTown);
|
||||
FilePrintf(hFile,"\t\t<bTownAttachment>%d</bTownAttachment>\r\n", gMercProfiles[ cnt ].bTownAttachment);
|
||||
|
||||
FilePrintf(hFile,"\t\t<usBackground>%d</usBackground>\r\n", gMercProfiles[ cnt ].usBackground);
|
||||
|
||||
|
||||
FilePrintf(hFile,"\t</PROFILE>\r\n");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user