• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Solved Config problem

pioncz

New Member
Joined
Dec 3, 2008
Messages
149
Reaction score
1
Hello,
What can i type here:
houseRentPeriod = "never"
In my config file. And from which place it will take money? I guess, depo is best idea.
Im using the newest forgotten server - mystic spirit.
 
Last edited:
Code:
Houses::Houses()
{
	rentPeriod = RENTPERIOD_NEVER;
	std::string strRentPeriod = asLowerCaseString(g_config.getString(ConfigManager::HOUSE_RENT_PERIOD));
	if(strRentPeriod == [B][COLOR="red"]"yearly"[/COLOR][/B])
		rentPeriod = RENTPERIOD_YEARLY;
	else if(strRentPeriod == [B][COLOR="red"]"weekly"[/COLOR][/B])
		rentPeriod = RENTPERIOD_WEEKLY;
	else if(strRentPeriod == [B][COLOR="red"]"monthly"[/COLOR][/B])
		rentPeriod = RENTPERIOD_MONTHLY;
	else if(strRentPeriod == [B][COLOR="red"]"daily"[/COLOR][/B])
		rentPeriod = RENTPERIOD_DAILY;
}

And yep, it can't take money from bank in TFS 0.2 since there is no built-in bank system with functions:
Code:
				//get money from depot
				[B][COLOR="red"]if(g_game.removeMoney(depot, housePrice, FLAG_NOLIMIT))[/COLOR][/B]
				{
					time_t paidUntil = currentTime;
					switch(rentPeriod)
					{
						case RENTPERIOD_DAILY:
							paidUntil += 24 * 60 * 60;
							break;
						case RENTPERIOD_WEEKLY:
							paidUntil += 24 * 60 * 60 * 7;
							break;
						case RENTPERIOD_MONTHLY:
							paidUntil += 24 * 60 * 60 * 30;
							break;
						case RENTPERIOD_YEARLY:
							paidUntil += 24 * 60 * 60 * 365;
							break;
						default:
							break;
					}
					house->setPaidUntil(paidUntil);
				}
 
Back
Top