• 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!

TFS 1.X+ Tibia day/night how change it??

roriscrave

Advanced OT User
Joined
Dec 7, 2011
Messages
1,188
Solutions
34
Reaction score
200
Hi, using tfs 1.3.
How can i put my game dont have 'night'? only 'day'?
I don't want it to be dark, for players to use 'utevo lux'
 
Solution
Game.cpp

Find void Game::checkLight()

change to this
Code:
void Game::checkLight()
{
    g_scheduler.addEvent(createSchedulerTask(EVENT_LIGHTINTERVAL, std::bind(&Game::checkLight, this)));

    lightLevel = LIGHT_LEVEL_DAY;
    LightInfo lightInfo = getWorldLightInfo();

    for (const auto& it : players) {
        it.second->sendWorldLight(lightInfo);
    }
}
Game.cpp

Find void Game::checkLight()

change to this
Code:
void Game::checkLight()
{
    g_scheduler.addEvent(createSchedulerTask(EVENT_LIGHTINTERVAL, std::bind(&Game::checkLight, this)));

    lightLevel = LIGHT_LEVEL_DAY;
    LightInfo lightInfo = getWorldLightInfo();

    for (const auto& it : players) {
        it.second->sendWorldLight(lightInfo);
    }
}
 
Last edited:
Solution
Game.cpp

Find void Game::checkLight()

change to this
Code:
void Game::checkLight()
{
    g_scheduler.addEvent(createSchedulerTask(EVENT_LIGHTINTERVAL, std::bind(&Game::checkLight, this)));

    lightLevel = LIGHT_LEVEL_DAY;
    LightInfo lightInfo = getWorldLightInfo();

    for (const auto& it : players) {
        it.second->sendWorldLight(lightInfo);
    }
}

i dont find the Game.cpp bro.. ? :S
 
The Sources file is those file you compile to build a console "that one you open your server with" and your console is theforgotten server.

i did see you use OTManager, so i guess you did download from the github the server? if yes there should be a Sources folder include with all the files you need to compile a console and there will you find a file called Game.cpp. This is what you did search for in the thread.
Hope you did understand me :)

 
Last edited:
The Sources file is those file you compile to build a console "that one you open your server with" and your console is theforgotten server.

i did see you use OTManager, so i guess you did download from the github the server? if yes there should be a Sources folder include with all the files you need to compile a console and there will you find a file called Game.cpp. This is what you did search for in the thread.
Hope you did understand me :)
I don't see the file named Sources folder? : S you can see in the picture also that it is not there
 
Back
Top