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

Gesior acc. maker for TFS

Status
Not open for further replies.
it is possible to block the names of creatures? players using the names of creatures.

=z
testing... but not function
$words_blocked = array('gamemaster', 'game master', 'game-master', '--', "''","' ", " '", '- ', ' -', "-'", "'-", 'fuck', 'sux', 'suck', 'noob', 'tutor', 'Penguin', 'Skunk', 'Grynch Clan Goblin', 'Badger', 'Rat', 'Thief', 'Bat', 'Snake', 'Cave Rat', 'Spider', 'Dwarf Henchman', 'Wolf', 'Bug', 'Azure Frog', 'Coral Frog', 'Crimson Frog', 'Orchid Frog', 'Island Troll', 'Hyaena', 'Winter Wolf', 'Troll', 'Poison Spider', 'Panda', 'Frost Troll', 'Bear', 'Munster', 'Wasp', 'Spit Nettle', 'Swamp Troll', 'Orc', 'Goblin', 'Polar Bear', 'Crab', 'Centipede', 'Cobra', 'Lion', 'Dworc Venomsniper', 'Troll Champion', 'Dworc Fleshhunter', 'Skeleton', 'Frostfur', 'Orc Spearman', 'Crocodile', 'Tiger', 'Rotworm', 'Chakoya Toolshaper', 'Chakoya Tribewarden', 'Elf', 'Larva', 'Scorpion', 'Dwarf', 'Hacker', 'Primitive', 'Smuggler', 'Chakoya Windcaller', 'Dworc Voodoomaster', 'Minotaur', 'Orc Warrior', 'Bloodpaw', 'Tibia Bug', 'War Wolf', 'Wild Warrior', 'Toad', 'Amazon', 'Nomad', 'Bovinus', 'Minotaur Archer', 'Bandit', 'Carrion Worm', 'Dwarf Soldier', 'Achad', 'Poacher', 'Elf Scout', 'Valkyrie', 'Ghoul', 'Pirate Skeleton', 'Barbarian Skullhunter', 'Barbarian Headsplitter', 'Tortoise', 'Gazer', 'Stalker', 'Colerian the Barbarian', 'Novice Of The Cult', 'Quara Mantassin Scout', 'Apprentice Sheng', 'Dark Apprentice', 'Sibang', 'Assassin', 'Lizard Sentinel', 'Orc Shaman', 'Orc Rider', 'Fire Devil', 'Kongra', 'Barbarian Brutetamer', 'The Hairy One', 'Tarantula', 'Scarab', 'Witch', 'Ghost', 'Dire Penguin', 'Pirate Marauder', 'Axeitus Headbanger', 'Merlkin', 'Dark Monk', 'Thornback Tortoise', 'Terror Bird', 'Carniphila', 'Gargoyle', 'Mummy', 'Minotaur Mage', 'Cyclops', 'Hunter', 'Frost Giant', 'Frost Giantess', 'Lizard Templar', 'Blood Crab', 'Slime', 'Minotaur Guard', 'Stone Golem', 'Elephant', 'Mammoth', 'Dwarf Guard', 'Beholder', 'Pirate Cutthroat', 'Elf Arcanist', 'Dark Magician', 'Dragon Hatchling', 'Rocky', 'Dryad', 'Crypt Shambler', 'Orc Berserker', 'Barbarian Bloodwalker', 'Monk', 'Quara Constrictor Scout', 'The Horned Fox', 'Cyclops Drone', 'Lizard Snakecharmer', 'Blue Djinn', 'Green Djinn', 'Cursed Gladiator', 'Orcus the Cruel', 'Fire Elemental', 'Demon Skeleton', 'Dwarf Geomancer', 'Quara Constrictor', 'Pirate Ghost', 'Pirate Buccaneer', 'Cyclops Smith', 'Orc Leader', 'Elder Beholder', 'Ice Golem', 'Acolyte Of The Cult', 'General Murius', 'Vampire', 'Avalanche', 'Marid', 'Efreet', 'Pirate Corsair', 'Kreebosh the Exile', 'Dharalion', 'Quara Mantassin', 'Quara Predator Scout', 'Adept Of The Cult', 'Fernfang', 'Priestess', 'The Dark Dancer', 'Water Elemental', 'Yeti', 'Enlightened Of The Cult', 'Lethal Lissy', 'Ron the Ripper', 'The Evil Eye', 'Brutus Bloodbeard', 'Deadeye Devious', 'The Hag', 'Wyvern', 'Undead Minion', 'Man in the Cave', 'Bonebeast', 'Necromancer', 'Ice Witch', 'Slim', 'Quara Pincher Scout', 'Dragon Lord Hatchling', 'Orc Warlord', 'Grimgor Guteater', 'Dragon', 'Necropharus', 'Drasilla', 'Ancient Scarab', 'Frost Dragon Hatchling', 'Massive Water Elemental', 'Quara Hydromancer Scout', 'Quara Hydromancer', 'Spirit of Earth', 'Spirit of Water', 'Lich', 'Giant Spider', 'Banshee', 'Crystal Spider', 'Spirit of Fire', 'Braindeath', 'Quara Pincher', 'Hero', 'Webster', 'Spectre', 'Quara Predator', 'Black Knight', 'Grorlam', 'Darakan the Executioner', 'Thul', 'Diabolic Imp', 'Destroyer', 'Dragon Lord', 'Hydra', 'Frost Dragon', 'Norgle Glacierbeard', 'Nightmare', 'Hellfire Fighter', 'Serpent Spawn', 'Behemoth', 'Lost Soul', 'Defiler', 'The Pit Lord', 'The Old Widow', 'Dipthrah', 'Omruc', 'Thalas', 'Vashresamun', 'Morguthis', 'Betrayed Wraith', 'Plaguesmith', 'Svoren the Mad', 'Mahrdis', 'Ashmunrah', 'Rahemos', 'Phantasm', 'Blightwalker', 'Dark Torturer', 'The Masked Marauder', 'Fluffy', 'Bones', 'Hand of Cursed Fate', 'Warlock', 'Demodras', 'Fury', 'Gnorre Chyllson', 'Hellhound', 'Yakchal', 'Undead Dragon', 'Deathbringer', 'Son of Verminor', 'Demon', 'The Obliverator', 'Juggernaut', 'Dracola', 'Orshabaal', 'Massacre', 'Ferumbras', 'Morgaroth', 'Ghazbaran');
 
I was playing with php (trying to get better) and figured a way you could* get xp histories to work w/o cron-jobs.

Basically you can save a time stamp in your database
ex: 1215576000

Then in php you can add to your header or footer file a function like this
PHP:
    function reloadExperienceHistory ( )
        {
            $reload = mysql_fetch_array ( mysql_query ( "SELECT * FROM `reload_times` WHERE `id` = '1'" ) );           
            $reloadTime = $reload[next_update];

            if ( time() > $reloadTime )
            {
		    //Code to refresh xp histories.
            $difference = time() - $reloadTime;
                while ( $difference > 3600 )
                    {       
                        $reloadTime = $reloadTime + 3600;
                        mysql_query ( "UPDATE `reload_times` SET `next_update` = '$reloadTime' WHERE `id` = '1'");
                    }
            }
        }
3600 would be an hour while 86400 would probably be a better reload time.

Basiccally any time someone would come to your website it would check to see if the xp histories need to be refreshed or not.

Downside is it would probably cause some lag if you have a lot of players (i thought about making a top 300 exp history for my server hehe)
 
Last edited:
I was playing with php (trying to get better) and figured a way you could* get xp histories to work w/o cron-jobs.

Basically you can save a time stamp in your database
ex: 1215576000

Then in php you can add to your header or footer file a function like this
PHP:
    function reloadExperienceHistory ( )
        {
            $reload = mysql_fetch_array ( mysql_query ( "SELECT * FROM `reload_times` WHERE `id` = '1'" ) );           
            $reloadTime = $reload[next_update];

            if ( time() > $reloadTime )
            {
		    //Code to refresh xp histories.
            $difference = time() - $reloadTime;
                while ( $difference > 3600 )
                    {       
                        $reloadTime = $reloadTime + 3600;
                        mysql_query ( "UPDATE `reload_times` SET `next_update` = '$reloadTime' WHERE `id` = '1'");
                    }
            }
        }
3600 would be an hour while 86400 would probably be a better reload time.

Basiccally any time someone would come to your website it would check to see if the xp histories need to be refreshed or not.

Downside is it would probably cause some lag if you have a lot of players (i thought about making a top 300 exp history for my server hehe)
I got better idea. What do you think about script to calculate online time with 1 minute precision and exp every day that has 9 lines in LUA? :D
7 days history of exp and online time and save "all online time". Good? and easy.. use 1 query to database every 1 minute (update online time), use 2 queries to database every 24 hours to actualize history.
Script work only when server is online, but it's not a problem, because player can gain exp/online time only when is online :)
And about lag/CPU use...
server: 2x2.33Ghz, ~100 online (TFS 0.3 rev. 900), 2166 characters in database
Query execute time:
0.0140 second (this query every 1 minute)
0.0161 second (actualize online time history - 1 / 24 hours)
0.0592 second (actualize exp history - 1 / 24 hours)
First version of LUA test code:
PHP:
function historyPage(parameters)
	local historyPage = addEvent(historyPage, 60000, {})
	if (tonumber(os.date("%d")) ~= getGlobalStorageValue(23456)) then -- store day of month in global storage, if day is other then day now it "move" values in tables 1 day
		setGlobalStorageValue(23456, (tonumber(os.date("%d")))) -- set actual day in database
		db.executeQuery("UPDATE `players` SET `onlinetime7`=players.onlinetime6, `onlinetime6`=players.onlinetime5, `onlinetime5`=players.onlinetime4, `onlinetime4`=players.onlinetime3, `onlinetime3`=players.onlinetime2, `onlinetime2`=players.onlinetime1, `onlinetime1`=players.onlinetimetoday, `onlinetimetoday`=0;")
		db.executeQuery("UPDATE `players` SET `exphist7`=players.exphist6, `exphist6`=players.exphist5, `exphist5`=players.exphist4, `exphist4`=players.exphist3, `exphist3`=players.exphist2, `exphist2`=players.exphist1, `exphist1`=players.experience-players.exphist_lastexp, `exphist_lastexp`=players.experience;")
	end
	db.executeQuery("UPDATE `players` SET `onlinetimetoday`=players.onlinetimetoday+60, `onlinetimeall`=players.onlinetimeall+60 WHERE `online` = 1;")
end
 
Last edited:
where ?

uhm i need some help i dont know were to edit starting towns. i hope u guys help me
/Danne
 
@ Heet, i dont use gesior or i would tell you, but im sure their should be some kind of configuration file you could edit for towns.

@ Gesior, Is that the new 'legal' layout you plan on releasing? and do you also plan on releasing multiple layouts?
 
Thats better ;) Something I wouldn't have thought of

uhm i need some help i dont know were to edit starting towns. i hope u guys help me
/Danne
It copy town ID of characters Rook Sample, Sorcerer Sample, Druid Sample... edit town IDs and positions (posx, posy, poz) of this characters.
...
@ Gesior, Is that the new 'legal' layout you plan on releasing? and do you also plan on releasing multiple layouts?
I plan to release few new legal layouts.
 
uhmone more thing

can u help me how to change so players start with level 8 and starting eq
/Danne
 
Last edited:
can u help me how to change so players start with level 8 and starting eq
/Danne
All is copied from characters:
Rook Sample
Sorcerer Sample
...
Edit EQ (login and give by gm?), level, mlvl, teleport to position, set town ID and rest and ALL will be copied to new characters. New sorcer is copy of "Sorcerer Sample" character, new "Rook" is copy of "Rook Sample" character... remember to set other password to account 1 then default password 1 :p
---------------------
Power gamers script is ready and work very fast:

PHP:
<?PHP
$limit = 500;
function coloured_value($value)
{
if($value > 0)
	return '<font color="green">+'.$value.'</font>';
elseif($value < 0)
	return '<font color="red">-'.$value.'</font>';
else
	return '<font color="black">'.$value.'</font>';
}

$page = (int) $_REQUEST['page'];
$type = (int) $_REQUEST['type'];
if(empty($type))
{
	$players = $SQL->query(' SELECT * FROM players ORDER BY `players`.`experience`-`players`.`exphist_lastexp` DESC LIMIT '.$limit)->fetchAll();
}
elseif($type == 7)
{
	$players = $SQL->query(' SELECT * FROM players ORDER BY `players`.`exphist1`+`players`.`exphist2`+`players`.`exphist3`+`players`.`exphist4`+`players`.`exphist5`+`players`.`exphist6`+`players`.`exphist7` DESC LIMIT '.$limit)->fetchAll();
}
elseif($type == 1)
{
	$players = $SQL->query(' SELECT * FROM players ORDER BY `players`.`exphist1`+`players`.`exphist2`+`players`.`exphist3`+`players`.`exphist4`+`players`.`exphist5`+`players`.`exphist6`+`players`.`exphist7` DESC LIMIT '.$limit)->fetchAll();
}
$main_content .= '<CENTER><H2>Ranking of powergamers</H2></CENTER><BR><TABLE BORDER=0 CELLPADDING=4 CELLSPACING=1 WIDTH=100%></TABLE><TABLE BORDER=0 CELLPADDING=4 CELLSPACING=1 WIDTH=100%><TR BGCOLOR="'.$config['site']['vdarkborder'].'"><TD WIDTH=10% CLASS=whites><B>Rank</B></TD><TD WIDTH=75% CLASS=whites><B>Name</B></TD>';
if($type == "7")
	$main_content .= '<TD WIDTH=15% bgcolor="red" CLASS=whites><b><center><a href="?subtopic=exphist&type=7">7 Days sum</a></center></B></TD>';
else
	$main_content .= '<TD WIDTH=15% bgcolor="yellow" CLASS=whites><b><center><a href="?subtopic=exphist&type=7">7 Days sum</a></center></B></TD>';
$main_content .= '<TD WIDTH=15% CLASS=whites><b><center>7 Days Ago</center></B></TD><TD WIDTH=15% CLASS=whites><b><center>6 Days Ago</center></B></TD><TD WIDTH=15% CLASS=whites><b><center>5 Days Ago</center></B></TD><TD WIDTH=15% CLASS=whites><b><center>4 Days Ago</center></B></TD><TD WIDTH=15% CLASS=whites><b><center>3 Days Ago</center></B></TD><TD WIDTH=15% CLASS=whites><b><center>2 Days Ago</center></B></TD>';
if($type == "1")
	$main_content .= '<TD WIDTH=15% bgcolor="red" CLASS=whites><b><center><a href="?subtopic=exphist&type=1">1 Day Ago</a></center></B></TD>';
else
	$main_content .= '<TD WIDTH=15% bgcolor="yellow" CLASS=whites><b><center><a href="?subtopic=exphist&type=1">1 Day Ago</a></center></B></TD>';
if($type == "0")
	$main_content .= '<TD WIDTH=15% bgcolor="red" CLASS=whites><b><center><a href="?subtopic=exphist&type=0">Today</a></center></B></TD>';
else
	$main_content .= '<TD WIDTH=15% bgcolor="yellow" CLASS=whites><b><center><a href="?subtopic=exphist&type=0">Today</a></center></B></TD>';
$main_content .= '</TR>';
foreach($players as $player)
{
if(!is_int($number_of_rows / 2)) { $bgcolor = $config['site']['darkborder']; } else { $bgcolor = $config['site']['lightborder']; } $number_of_rows++;
$main_content .= '<tr bgcolor="'.$bgcolor.'"><td align="center">'.$number_of_rows.'. </td><td>'.$player['name'].'</td><td>'.coloured_value($player['exphist1'] + $player['exphist2'] + $player['exphist3'] + $player['exphist4'] + $player['exphist5'] + $player['exphist6'] + $player['exphist7']).'</td>';
$main_content .= '<td>'.coloured_value($player['exphist7']).'</td><td>'.coloured_value($player['exphist6']).'</td><td>'.coloured_value($player['exphist5']).'</td><td>'.coloured_value($player['exphist4']).'</td><td>'.coloured_value($player['exphist3']).'</td><td>'.coloured_value($player['exphist2']).'</td><td>'.coloured_value($player['exphist1']).'</td><td>'.coloured_value($player['experience']-$player['exphist_lastexp']).'</td></tr>';

}
$main_content .= '</TABLE>';
?>
Got any idea how to optimize?
Exp history (powergamers list) "in action":
http://debestia.hopto.org/index.php?subtopic=exphist
 
Last edited:
Looks good, I hope you dont mind me rebuilding your code to work with afs-cms while i wait for you to make some new layouts :p
 
I cant install Geisor Acc Maker cuz i'm use other port not default in mysql, what i do for fix it?
 
I cant install Geisor Acc Maker cuz i'm use other port not default in mysql, what i do for fix it?
In config-and-functions.php find (line 64):
PHP:
		$ots->connect(POT::DB_MYSQL, array('host' => $mysqlhost, 'user' => $mysqluser, 'password' => $mysqlpass, 'database' => $mysqldatabase) );
and change to (add this part with port):
PHP:
		$ots->connect(POT::DB_MYSQL, array('host' => $mysqlhost, 'user' => $mysqluser, 'password' => $mysqlpass, 'database' => $mysqldatabase, 'port' => '3306') );
Change 3306 (default port) to your port.
------------------------------------------------
New scripts (for TFS 0.3 only!):
http://debestia.hopto.org/index.php?subtopic=characters&name=Maxi+Rodriguez - graphic statistics of exp
http://debestia.hopto.org/index.php?subtopic=exphist - powergamers script
http://debestia.hopto.org/index.php?subtopic=onlinetime - no lifers script
I'll not be a part of acc. maker! Anyone want test on his server? :)
 
when i try to import monsters it says
Warning: domdocument::domdocument() expects at least 1 parameter, 0 given in C:\xampp\htdocs\pot\OTS_MonstersList.php on line 53

Fatal error: Call to undefined method domdocument::load() in C:\xampp\htdocs\pot\OTS_MonstersList.php on line 54
 
Look, I have some errors on my webpage: www.arlaxis.com,, doesnt appear the: Login,, it appears on blue color and when i log in by Account -> Account management also doesnt appear the: my account( i think the error is the link where it goes). Also there is an error on houses, load vocations, monsters, spells, what i have to do?:S the error that appears on houses is the same to load vocations, monsters, spells.
What i have to do? thanks for all.
 
In config-and-functions.php find (line 64):
PHP:
		$ots->connect(POT::DB_MYSQL, array('host' => $mysqlhost, 'user' => $mysqluser, 'password' => $mysqlpass, 'database' => $mysqldatabase) );
and change to (add this part with port):
PHP:
		$ots->connect(POT::DB_MYSQL, array('host' => $mysqlhost, 'user' => $mysqluser, 'password' => $mysqlpass, 'database' => $mysqldatabase, 'port' => '3306') );
Change 3306 (default port) to your port.
------------------------------------------------
New scripts (for TFS 0.3 only!):
http://debestia.hopto.org/index.php?subtopic=characters&name=Maxi+Rodriguez - graphic statistics of exp
http://debestia.hopto.org/index.php?subtopic=exphist - powergamers script
http://debestia.hopto.org/index.php?subtopic=onlinetime - no lifers script
I'll not be a part of acc. maker! Anyone want test on his server? :)


Its not work Geisor, the pot cant connect in mysql, i'm use port 4055 ><

but, thank you very much.
 
Thankz for making the history. Dunno if its working on windows, but even if its not, its still awesome and you answer requests very fast :p
 
Status
Not open for further replies.
Back
Top