コード例 #1
0
ファイル: house.cpp プロジェクト: 081421/otxserver
void Houses::check()
{
	uint64_t start = OTSYS_TIME();
	std::clog << "> Checking houses..." << std::endl;

	time_t currentTime = time(NULL);
	for(HouseMap::iterator it = houseMap.begin(); it != houseMap.end(); ++it)
		payHouse(it->second, currentTime, 0);

	std::clog << "Houses checked in " << (OTSYS_TIME() - start) / (1000.) << " seconds." << std::endl;
}
コード例 #2
0
ファイル: house.cpp プロジェクト: OMARTINEZ210/server
bool Houses::payHouses()
{
  if(rentPeriod == RENTPERIOD_NEVER){
    return true;
  }

  time_t currentTime = std::time(NULL);
  for(HouseMap::iterator it = houseMap.begin(); it != houseMap.end(); ++it){
    payHouse(it->second, currentTime);
  }

  return true;
}
コード例 #3
0
ファイル: house.cpp プロジェクト: alexisjojo/darkkonia
void Houses::payHouses()
{
	if(rentPeriod == RENTPERIOD_NEVER)
		return;

	uint64_t start = OTSYS_TIME();
	std::clog << "> Paying houses..." << std::endl;

	time_t currentTime = time(NULL);
	for(HouseMap::iterator it = houseMap.begin(); it != houseMap.end(); ++it)
		payHouse(it->second, currentTime, 0);

	std::clog << "> Houses paid in " << (OTSYS_TIME() - start) / (1000.) << " seconds." << std::endl;
}