Thread: AllaClone 2.0
View Single Post
  #95  
Old 05-16-2014, 02:39 PM
Rhodan
Hill Giant
 
Join Date: Oct 2006
Posts: 179
Default

Well here's what I did to get the majority of the pages working. Still errors left over, particularly in zones by level which I haven't figured out at all.

Code:
Changes to AllaClone2

advnpcs.php
	replace action=$PHP_SELF with action=''
	
config.php
	add $MaxFactionsReturned=50;
	
constantes.php

	add $cfgversion="" around line 5. Cant find anyplace that sets cfgversion anyway.
	add $dbskills[74]='FRENZY';
		$dbskills[98]='UNKNOWN'; lots of test only spells with odd numbers in the db 
	Change
		
	Replace entire spell targets list - its easier than editing
	// spell targets
	$dbspelltargets=array();
	$dbspelltargets[0]="Rag'Zhezum Special";
	$dbspelltargets[1]="Line of Sight";
	$dbspelltargets[2]="";
	$dbspelltargets[3]="Group V1";
	$dbspelltargets[4]="Point Blank Area of effect";
	$dbspelltargets[5]="Single target";
	$dbspelltargets[6]="Self only";
	$dbspelltargets[8]="Targetted Area of effect";
	$dbspelltargets[9]="Animal";
	$dbspelltargets[10]="Undead only";
	$dbspelltargets[11]="Summoned beings";
	$dbspelltargets[13]="Life Tap";
	$dbspelltargets[14]="Caster's pet";
	$dbspelltargets[15]="Target's corpse";
	$dbspelltargets[16]="Plant";
	$dbspelltargets[17]="Giant";
	$dbspelltargets[18]="Dragon";
	$dbspelltargets[20]="Targetted Area of Effect Life Tap";
	$dbspelltargets[24]="Area of effect on undeads";
	$dbspelltargets[25]="Area of Effect Summoned";
	$dbspelltargets[32]="Area of Effect Caster";
	$dbspelltargets[33]="NPC Hate List";
	$dbspelltargets[34]="Dungeon Object";
	$dbspelltargets[35]="Muramite";
	$dbspelltargets[36]="Area - PC Only";
	$dbspelltargets[37]="Area - NPC Only";
	$dbspelltargets[38]="Summoned Pet";
	$dbspelltargets[39]="Group No Pets";
	$dbspelltargets[40]="Area of Effect PC V2";
	$dbspelltargets[41]="Group V2";
	$dbspelltargets[42]="Self (Directional)";
	$dbspelltargets[43]="Group with Pets";
	$dbspelltargets[44]="Beam";

item.php
	line 34 change 
		$name=$ItemRow["name"]; to
		$name=$ItemRow["Name"];
	
items.php 
	search and replace iavailevel with iavaillevel

	line 74 change 
	action='".$PHP_SELF."' to 
	action=''

faction.php

	for people not using peqeditor
	replace
		print "                  <a href='".$peqeditor_url."index.php?editor=faction&amp;fid=".$id."'><img src='".$images_url."/peq_faction.png' align='right'/></a>\n";
	with
		if (isset($peqeditor_url)) {
			print "                  <a href='".$peqeditor_url."index.php?editor=faction&amp;fid=".$id."'><img src='".$images_url."/peq_faction.png' align='right'/></a>\n";
		}


factions.php
	search and replace
		<form method='GET' action='".$PHP_SELF."'>\n";
		<form method='GET' action=''>\n";
	
functions.php 

	not all arguments supplied for function PrintQueryResults() so make the last three optional by
	supplying a value yourself, start at $ExtraField
	$NameAttribute, $ExtraField="", $ExtraFieldDescription="", $ExtraSkill="")

	v$ and $res not defined errors, add  $v=$res=""; in getslots(), getclasses() and gettraces()
	before loop starts. Also change $Result to $res in getslots() for consistency
	
	in function Price($price)
	change 
		$res=""; to
		$res=$p=$g=$s=$sep="";
	
	loreflag replaced by loregroup and values now range -1 - 1 with 0 being not lore so change
	if($item["loreflag"] == 1)   { $html_string .= "$v LORE ITEM";    $v = " "; } to
	if($item["loregroup"] != 0)   { $html_string .= "$v LORE ITEM";    $v = " "; }
	
	change 
		function GetItemStatsString($name,$stat,$stat2,$stat2color) { to
		function GetItemStatsString($name,$stat,$stat2=0,$stat2color=0) {
		This makes the last two arguments optional with defaults of 0
	in BuildItemStats()
		change 
			global $dbitypes, $dam2h, $dbbagtypes, $dbskills, $icons_url, $tbspells, $dbiaugrestrict, $dbiracenames;
			global $dbitypes, $dam2h, $dbbagtypes, $dbskills, $icons_url, $tbspells, $dbiaugrestrict, $dbiracenames, $dbelements, $dbbodytypes;
		and
			$html_string .= GetItemStatsString("Haste",$item["haste"."%"]); to
			$html_string .= GetItemStatsString("Haste",$item["haste"]);
			
npc.php
	wrap peqeditor_url stuff in isset thus:
	if (isset($peqeditor_url)) {
		print "<a href='".$peqeditor_url."index.php?editor=npc&amp;npcid=".$id."'><img src='".$images_url."/peq_npc.png' align='right'/></a>";
		print "<a href='".$peqeditor_url."index.php?editor=merchant&amp;npcid=".$id."'><img src='".$images_url."/peq_merchant.png' align='right'/></a>";
	}

npcs.php
	replace action='".$PHP_SELF."' 
	with action=''
		
pets.php
	replace href=$PHP_SELF
	with href=pets.php
		
	replace	$row["ac"]
	with $row["AC"]
	
recipies.php

	replace action=$PHP_SELF
	with action=''
		
spawngroup.php
	search and replace
		a href=$PHP_SELF?
		with
		a href=spawngroup.php?
spell.php
	change
	$dbspellresists[$spell["resist"]]
	$dbspellresists[$spell["resisttype"]]
	
zone.php
	search and replace "minimum_level" with "min_level"
	search and replace href=$PHP_SELF with href=zone.php
Reply With Quote