mirror of
https://github.com/1dot13/source.git
synced 2026-09-09 14:46:05 +02:00
fix: follow-up minievents properly wait for the specified time (by rftr)
fix: money income from rebel command displays properly in finances (by rftr) git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9188 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -1604,6 +1604,10 @@ void ProcessTransactionString(STR16 pString, FinanceUnitPtr pFinance)
|
|||||||
case MINI_EVENT:
|
case MINI_EVENT:
|
||||||
swprintf(pString, L"%s", pTransactionText[MINI_EVENT]);
|
swprintf(pString, L"%s", pTransactionText[MINI_EVENT]);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case REBEL_COMMAND:
|
||||||
|
swprintf(pString, L"%s", pTransactionText[REBEL_COMMAND]);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1511,7 +1511,7 @@ void CheckMiniEvents(UINT32 nextEventId)
|
|||||||
static void QueueNextMiniEvent(UINT32 nextEventId, UINT32 hoursToNextMiniEvent)
|
static void QueueNextMiniEvent(UINT32 nextEventId, UINT32 hoursToNextMiniEvent)
|
||||||
{
|
{
|
||||||
const UINT32 timestamp = GetWorldTotalMin() + gGameExternalOptions.fMiniEventsMinHoursBetweenEvents * 60 + Random((gGameExternalOptions.fMiniEventsMaxHoursBetweenEvents - gGameExternalOptions.fMiniEventsMinHoursBetweenEvents) * 60);
|
const UINT32 timestamp = GetWorldTotalMin() + gGameExternalOptions.fMiniEventsMinHoursBetweenEvents * 60 + Random((gGameExternalOptions.fMiniEventsMaxHoursBetweenEvents - gGameExternalOptions.fMiniEventsMinHoursBetweenEvents) * 60);
|
||||||
AddStrategicEvent(EVENT_MINIEVENT, hoursToNextMiniEvent > 0 ? hoursToNextMiniEvent : timestamp, nextEventId);
|
AddStrategicEvent(EVENT_MINIEVENT, hoursToNextMiniEvent > 0 ? GetWorldTotalMin() + 60 * hoursToNextMiniEvent : timestamp, nextEventId);
|
||||||
}
|
}
|
||||||
|
|
||||||
// LUA STUFF FOLLOWS
|
// LUA STUFF FOLLOWS
|
||||||
|
|||||||
Reference in New Issue
Block a user