src/ai/api/ai_accounting.cpp
author rubidium
Sun, 25 Mar 2007 13:50:19 +0000
branchnoai
changeset 9524 283d23931bb4
parent 9452 4c5eedbc3ba9
child 9833 89a64246458f
permissions -rw-r--r--
(svn r9444) [NoAI] -Codechange: allow all API-class-instances to be used as parameters in Squirrel.
/* $Id$ */

/** @file ai_accounting.cpp everything to handle AI accounting things */

#include "ai_accounting.hpp"

int32 AIAccounting::GetCosts()
{
	return this->GetDoCommandCosts();
}

void AIAccounting::ResetCosts()
{
	this->SetDoCommandCosts(0);
}

AIAccounting::AIAccounting()
{
	this->last_costs = this->GetDoCommandCosts();
	this->SetDoCommandCosts(0);
}

AIAccounting::~AIAccounting()
{
	this->SetDoCommandCosts(this->last_costs);
}