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

OTS database manager by Gesior

Status
Not open for further replies.

Gesior.pl

Mega Noob&LOL 2012
Senator
Joined
Sep 18, 2007
Messages
2,987
Solutions
102
Reaction score
3,436
Location
Poland
GitHub
gesior
Before you ask..
1. What is it?
It is something like "phpmyadmin", but made specialy for OTS databases and work with SQLite and MySQL.
2. Is it safe?
It use POT (block stupid queries to database) and you must know password to database if you want to connect. It show errors when you try to do something stupid like set capacity 0 or letter as capacity.
3. With what databases it work?
Actually it work with (SQLite and MySQL):
TFS 0.3 (beta)
TFS 0.2.13
TFS 0.2.12
TFS 0.2.11
TFS 0.2.10
TFS 0.2.9
TFS 0.2.8
TFS 0.2.7
TFS 0.2.6
The Best War by Gesior
In future it will work with all SQL OTSes.

4. How to install it?
1. You need XAMPP 1.6.5 or new version.
2. If you use MySQL database go to step 6.
3. Open file ../xampp/apache/bin/php.ini
4. Find line with:
Code:
;extension=php_pdo_sqlite.dll
delete ; and save file
5. Stop Apache server (part of XAMPP) and start again. SQLite database should work with manager.
6. Copy folder databasemanager from .rar file from this thread to ../xampp/htdocs/
7. Open in internet browser page: http://127.0.0.1/databasemanager/
8. Answer for 2 stupid questions: "where are your server files?" , "what is your server version?"
9. OTS database manager installed! :)
10. Login with password to mysql database (even if you use SQLite database!)
5. "I can't login"
Password in config.lua (ots config file) can't be empty!
---------------------------------------

Features:
-account editor
----script try to block all your stupid actions
----when you change account number you can move/not move characters to new account number
-player editor
----script try to block all your stupid actions
----easy change outfit colors
----show vocations info
----show group info
----expierience calculator
----skill editor and skill tries for % calculator
-groups editor
----script try to block all your stupid actions
----flags calculator included
----custom flags (TFS 0.3) calcualtor included
-account list
----you can add filters, limits
----you can sort results
-search related accounts/players (help to find MCs and second characters)
----show players from account of XXX (name or GUID)
----show players with last IP == IP of XXX (name or GUID)

TODO:
-players list + filters

-------------------------------
SCREENS:
-accounts list

-edit player options, it show vocation and group description loaded from OTS

-when you edit player it automaticly load account

-when you edit account or player it show all players from this account, you can easy change color of outfit ;)



DOWNLOAD >>VERSION 2<< FROM SPEEDYSHARE

---------------------
POST BUGS AND SUGGESTIONS IN THIS THREAD
 
Last edited:

TODO:
-groups editor
-players list + filters
-groups list
-edit skills in player editor (with skill tries calculator)
-----------------------------------------------------
I need someone gooood in PHP who understand how work "DOM". Anyone? :)
I must get "multipliers" from vocations.xml file, but I don't know how :>
Actually I use:
PHP:
$ots_vocations = array();
$vocations_ids = array();
$vocations_names = array();
$vocations_dom = new DOMDocument();
$vocations_dom->load($config['site']['server_path'].$config['site']['vocationXML_file_subdir']);
foreach($vocations_dom->getElementsByTagName('vocation') as $vocation)
{
	$ots_vocations[$vocation->getAttribute('id')]['id'] = $vocation->getAttribute('id');
	$ots_vocations[$vocation->getAttribute('id')]['name'] = $vocation->getAttribute('name');
	$ots_vocations[$vocation->getAttribute('id')]['gaincap'] = $vocation->getAttribute('gaincap');
	$ots_vocations[$vocation->getAttribute('id')]['gainhp'] = $vocation->getAttribute('gainhp');
	$ots_vocations[$vocation->getAttribute('id')]['gainmana'] = $vocation->getAttribute('gainmana');
	$ots_vocations[$vocation->getAttribute('id')]['gainhpticks'] = $vocation->getAttribute('gainhpticks');
	$ots_vocations[$vocation->getAttribute('id')]['gainhpamount'] = $vocation->getAttribute('gainhpamount');
	$ots_vocations[$vocation->getAttribute('id')]['gainmanaticks'] = $vocation->getAttribute('gainmanaticks');
	$ots_vocations[$vocation->getAttribute('id')]['gainmanaamount'] = $vocation->getAttribute('gainmanaamount');
	$ots_vocations[$vocation->getAttribute('id')]['manamultiplier'] = $vocation->getAttribute('manamultiplier');
	$ots_vocations[$vocation->getAttribute('id')]['attackspeed'] = $vocation->getAttribute('attackspeed');
	$ots_vocations[$vocation->getAttribute('id')]['soulmax'] = $vocation->getAttribute('soulmax');
	$ots_vocations[$vocation->getAttribute('id')]['gainsoulticks'] = $vocation->getAttribute('gainsoulticks');
	$ots_vocations[$vocation->getAttribute('id')]['fromvoc'] = $vocation->getAttribute('fromvoc');
	$vocations_ids[] = $vocation->getAttribute('id');
	$vocations_names[$vocation->getAttribute('id')] = $vocation->getAttribute('name');
}
and load from file .xml like:
Code:
	<vocation id="2" name="Druid" description="druidem" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="5" gainmanaticks="2" gainmanaamount="5" manamultiplier="1.1" attackspeed="1500" soulmax="100" gainsoulticks="120" fromvoc="2">
		<formula meleeDamage="1.0" distDamage="1.0" defense="1.1" armor="1.1"/>
		<skill id="0" multiplier="1.5"/>
		<skill id="1" multiplier="1.8"/>
		<skill id="2" multiplier="1.8"/>
		<skill id="3" multiplier="1.8"/>
		<skill id="4" multiplier="1.8"/>
		<skill id="5" multiplier="1.5"/>
		<skill id="6" multiplier="1.1"/>
	</vocation>
How can I load value of multipliers?
Skill editor and java script to calculate tries is ready. Only things I need are multipliers for each vocation (now I use 1.1 for every vocation/skill) :(
 
Awesome job as always! Perhaps when you are looking for a new feature for your aac you could always add house auction system ;)

//Massen
 
Nice work congrats..
ill download it and test it =)
-Thanks
 
-----------------------------------------------------
I need someone gooood in PHP who understand how work "DOM". Anyone? :)
I must get "multipliers" from vocations.xml file, but I don't know how :>
Actually I use:
PHP:
$ots_vocations = array();
$vocations_ids = array();
$vocations_names = array();
$vocations_dom = new DOMDocument();
$vocations_dom->load($config['site']['server_path'].$config['site']['vocationXML_file_subdir']);
foreach($vocations_dom->getElementsByTagName('vocation') as $vocation)
{
	$ots_vocations[$vocation->getAttribute('id')]['id'] = $vocation->getAttribute('id');
	$ots_vocations[$vocation->getAttribute('id')]['name'] = $vocation->getAttribute('name');
	$ots_vocations[$vocation->getAttribute('id')]['gaincap'] = $vocation->getAttribute('gaincap');
	$ots_vocations[$vocation->getAttribute('id')]['gainhp'] = $vocation->getAttribute('gainhp');
	$ots_vocations[$vocation->getAttribute('id')]['gainmana'] = $vocation->getAttribute('gainmana');
	$ots_vocations[$vocation->getAttribute('id')]['gainhpticks'] = $vocation->getAttribute('gainhpticks');
	$ots_vocations[$vocation->getAttribute('id')]['gainhpamount'] = $vocation->getAttribute('gainhpamount');
	$ots_vocations[$vocation->getAttribute('id')]['gainmanaticks'] = $vocation->getAttribute('gainmanaticks');
	$ots_vocations[$vocation->getAttribute('id')]['gainmanaamount'] = $vocation->getAttribute('gainmanaamount');
	$ots_vocations[$vocation->getAttribute('id')]['manamultiplier'] = $vocation->getAttribute('manamultiplier');
	$ots_vocations[$vocation->getAttribute('id')]['attackspeed'] = $vocation->getAttribute('attackspeed');
	$ots_vocations[$vocation->getAttribute('id')]['soulmax'] = $vocation->getAttribute('soulmax');
	$ots_vocations[$vocation->getAttribute('id')]['gainsoulticks'] = $vocation->getAttribute('gainsoulticks');
	$ots_vocations[$vocation->getAttribute('id')]['fromvoc'] = $vocation->getAttribute('fromvoc');
	$vocations_ids[] = $vocation->getAttribute('id');
	$vocations_names[$vocation->getAttribute('id')] = $vocation->getAttribute('name');
}
and load from file .xml like:
Code:
	<vocation id="2" name="Druid" description="druidem" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="5" gainmanaticks="2" gainmanaamount="5" manamultiplier="1.1" attackspeed="1500" soulmax="100" gainsoulticks="120" fromvoc="2">
		<formula meleeDamage="1.0" distDamage="1.0" defense="1.1" armor="1.1"/>
		<skill id="0" multiplier="1.5"/>
		<skill id="1" multiplier="1.8"/>
		<skill id="2" multiplier="1.8"/>
		<skill id="3" multiplier="1.8"/>
		<skill id="4" multiplier="1.8"/>
		<skill id="5" multiplier="1.5"/>
		<skill id="6" multiplier="1.1"/>
	</vocation>
How can I load value of multipliers?
Skill editor and java script to calculate tries is ready. Only things I need are multipliers for each vocation (now I use 1.1 for every vocation/skill) :(

why don't you just use SimpleXML? (simplexml_load_file & simplexml_load_string) They might only work in PHP 5, but it really simplifies reading XML files.
 
WoW!
I saw it and never thought that it works that nice.
Great Work.
 
why don't you just use SimpleXML? (simplexml_load_file & simplexml_load_string) They might only work in PHP 5, but it really simplifies reading XML files.
Goood idea, but now I must learn how to use it :)
EDIT:
I changed it to use SimpleXML, but I still don't know how to get multipliers :>
EDIT:
Now I know how it work :D

--------------------------------------------------------------------------------
I'll post new version tommorow with:
-groups editor (flag calculator for flags/TFS custom flags included! :) ) - 100% ready
screen6ca8.png

-skill/skill tries edit - 100% ready + tries calculator
screen5ft8.png

-"search other characters of XXX" (to find other account/characters of player with name XX by acc. number and IP) - 0% ready
--------------------------------
Changed:
PHP:
$vocations_ids = array();
$vocations_names = array();
$vocations_dom = new DOMDocument();
$vocations_dom->load($config['site']['server_path'].$config['site']['vocationXML_file_subdir']);
foreach($vocations_dom->getElementsByTagName('vocation') as $vocation)
{
    $ots_vocations[$vocation->getAttribute('id')]['id'] = $vocation->getAttribute('id');
    $ots_vocations[$vocation->getAttribute('id')]['name'] = $vocation->getAttribute('name');
    $ots_vocations[$vocation->getAttribute('id')]['gaincap'] = $vocation->getAttribute('gaincap');
    $ots_vocations[$vocation->getAttribute('id')]['gainhp'] = $vocation->getAttribute('gainhp');
    $ots_vocations[$vocation->getAttribute('id')]['gainmana'] = $vocation->getAttribute('gainmana');
    $ots_vocations[$vocation->getAttribute('id')]['gainhpticks'] = $vocation->getAttribute('gainhpticks');
    $ots_vocations[$vocation->getAttribute('id')]['gainhpamount'] = $vocation->getAttribute('gainhpamount');
    $ots_vocations[$vocation->getAttribute('id')]['gainmanaticks'] = $vocation->getAttribute('gainmanaticks');
    $ots_vocations[$vocation->getAttribute('id')]['gainmanaamount'] = $vocation->getAttribute('gainmanaamount');
    $ots_vocations[$vocation->getAttribute('id')]['manamultiplier'] = $vocation->getAttribute('manamultiplier');
    $ots_vocations[$vocation->getAttribute('id')]['attackspeed'] = $vocation->getAttribute('attackspeed');
    $ots_vocations[$vocation->getAttribute('id')]['soulmax'] = $vocation->getAttribute('soulmax');
    $ots_vocations[$vocation->getAttribute('id')]['gainsoulticks'] = $vocation->getAttribute('gainsoulticks');
    $ots_vocations[$vocation->getAttribute('id')]['fromvoc'] = $vocation->getAttribute('fromvoc');
    $vocations_ids[] = $vocation->getAttribute('id');
    $vocations_names[$vocation->getAttribute('id')] = $vocation->getAttribute('name');
}
To:
PHP:
$ots_vocations_xml = simplexml_load_file($config['site']['server_path'].$config['site']['vocationXML_file_subdir']);
$vocations_skills = array();
foreach($ots_vocations_xml as $vocationz)
{
	foreach($vocationz as $skill)
		$vocations_skills[(int) $vocationz['id']][(int) $skill['id']] =  $skill['multiplier'];
	$ots_vocations[(int) $vocationz['id']] = $vocationz;
}
And now I can calculate skill tires needed for X % to next skill :)
-------------------------------
>>VERSION 2<< IN FIRST POST
-------------------------------
New:
-groups editor
----script try to block all your stupid actions
----flags calculator included
----custom flags (TFS 0.3) calcualtor included
-search related accounts/players (help to find MCs and second characters)
----show players from account of XXX (name or GUID)
----show players with last IP == IP of XXX (name or GUID)
-player editor
----skill editor and skill tries for % calculator
 
Last edited:
6. Copy folder databasemanager from .rar file from this thread to ../xampp/htdocs/

I dont get that :S Can somone explain?
 
Hello :D do i need to use databasemanager V2 to get my real tibia account site to work ? cause i can't make account :s can someone help me ? :)

Anders
 
Status
Not open for further replies.
Back
Top