The bad hack the "work harder" cheat was using did not play well with the power code. It now just marks the research as finished instead of giving lots of power and research time.
parent
0c694a22b0
commit
af88a73dfc
|
@ -1357,13 +1357,11 @@ void kf_FinishResearch( void )
|
|||
{
|
||||
BASE_STATS *pSubject = NULL;
|
||||
|
||||
((RESEARCH_FACILITY *)psCurr->pFunctionality)->timeStarted = gameTime + 100000;
|
||||
//set power accrued to high value so that will trigger straight away
|
||||
((RESEARCH_FACILITY *)psCurr->pFunctionality)->powerAccrued = 10000;
|
||||
// find out what the heck we are researching
|
||||
// find out what we are researching here
|
||||
pSubject = ((RESEARCH_FACILITY *)psCurr->pFunctionality)->psSubject;
|
||||
if (pSubject)
|
||||
{
|
||||
researchResult((RESEARCH*)pSubject - asResearch, selectedPlayer, false, NULL);
|
||||
sasprintf((char**)&cmsg, _("(Player %u) is using cheat :%s %s"),
|
||||
selectedPlayer, _("Researched"), getName(pSubject->pName) );
|
||||
sendTextMessage(cmsg, true);
|
||||
|
|
|
@ -3209,6 +3209,7 @@ static void aiUpdateStructure(STRUCTURE *psStructure, bool mission)
|
|||
psResFacility->timeStarted = gameTime;
|
||||
}
|
||||
|
||||
ASSERT_OR_RETURN(, gameTime >= psResFacility->timeStarted, "research seems to have started in the future");
|
||||
pointsToAdd = (psResFacility->researchPoints * (gameTime -
|
||||
psResFacility->timeStarted)) / GAME_TICKS_PER_SEC;
|
||||
|
||||
|
|
Loading…
Reference in New Issue