• 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] New quest counter!

Szysza

®oot
Joined
Aug 31, 2009
Messages
139
Reaction score
6
Location
Poland
Welcome again, I have for you something new, because a lot of people say that Gesior acc is old and not useful for working on the renewal of its appearance, I think you'll like it​

Step 1
Open your characters.php and find old quest counter and replace it with this code
PHP:
			//New Quest status//
			$id = $player->getCustomField("id");
			$number_of_quests = 0;
			$main_content .= '<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=4 WIDTH=100%><TR BGCOLOR='.$config['site']['vdarkborder'].'><TD align="left" COLSPAN=2 CLASS=white><B>Quests</B></TD></TD align="right"></TD></TR>';		
		$questCount = 0;
		foreach ($config["site"]["quests"] as $questName => $questData) {
			$backgroundColor = is_int($questCount / 2) ? $config["site"]["darkborder"] : $config["site"]["lightborder"];
			$questCount   = $questCount + 1; $questStatus = $SQL->query("SELECT * FROM `player_storage` WHERE `player_id` = ".$id." AND `key` = ".$questData["storageid"].";")->fetch();
			$questPercent = (($questStatus["value"] - $questData["startvalue"])/$questData["endvalue"]) * 100;
			$main_content 		.= "<tr bgcolor=\"".$backgroundColor."\"><td width=\"55%\">".$questName."</td><td width=\"45%\" style=\"text-align:center;\">".$questPercent."%<div style=\"background-color:white; margin-top:-14px; width: 100%; height: 12px; border: 1px solid #DDD;\"><div style=\"background: green; width: ".$questPercent."%; height: 12px;\"></div></div></td></tr>";		
		}
		//New Quest status//

Step 2
Open your config.php and paste this code(Here edit your quests here and type storage):
PHP:
	//New Quest status//
	$config["site"]["maxquests"] = 35; // maximum number of quests in site
	$config["site"]["quests"] = array(
		//Example: "Name Quest" 	=> array("storageid" => id, "startvalue" => start value quests(0), "endvalue"=> end value quests(1)),*
		"Anihilator Quest" 	=> array("storageid" => 5000, 	"startvalue" => 1, 	"endvalue" => 1),
		"Blue Legs Quest" 		=> array("storageid" => 36207, 	"startvalue" => 1, 	"endvalue" => 1),
		"Demon Helmet" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Paradox Quest" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Paradox Quest" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Poi Quest" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Yalahar Quest" 		=> array("storageid" => 102504, 	"startvalue" => 1, 	"endvalue" => 1),
		"Arena Warlord" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Arena Scrapper" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Arena Greenhorn" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Demon oak" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Necromancer Quest" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Banshee Quest" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Demon oak" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Tower Shield" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Dwarven ring" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Knight Axe" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1),
		"Inquisiton Quest" 		=> array("storageid" => 2645, 	"startvalue" => 0, 	"endvalue" => 1
)
	);
	//New Quest status//

The final result
quest.png

Please comment, rep++ and like's
 
Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1' in C:\xampp\htdocs\characters.php:234 Stack trace: #0 C:\xampp\htdocs\characters.php(234): PDO->query('SELECT * FROM `...') #1 C:\xampp\htdocs\index.php(99): include('C:\xampp\htdocs...') #2 {main} thrown in C:\xampp\htdocs\characters.php on line 234
 
Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1' in C:\xampp\htdocs\Blacklandg\characters.php:185 Stack trace: #0 C:\xampp\htdocs\Blacklandg\characters.php(185): PDO->query('SELECT * FROM `...') #1 C:\xampp\htdocs\Blacklandg\index.php(129): include('C:\xampp\htdocs...') #2 {main} thrown in C:\xampp\htdocs\Blacklandg\characters.php on line 185

?
 
Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1' in C:\xampp\htdocs\Blacklandg\characters.php:185 Stack trace: #0 C:\xampp\htdocs\Blacklandg\characters.php(185): PDO->query('SELECT * FROM `...') #1 C:\xampp\htdocs\Blacklandg\index.php(129): include('C:\xampp\htdocs...') #2 {main} thrown in C:\xampp\htdocs\Blacklandg\characters.php on line 185

?

bump?
 
Back
Top