Moderator: Diska
<?php
$phpraid_user = 'shard_user';
$phpraid_pass = 'my password';
$phpraid_host = 'localhost';
$phpraid_name = 'shard_raid';
$phpraid_prefix = 'phpraid_';
// location of phpRaid directory relative to roster
// DO NOT include a trailing slash
$phpraid_dir = '../raid';
?>
if ($char['clientLocale']=="enUS") {
}
if ($char['clientLocale']=="enUS") {
$sql = "UPDATE " . $phpraid_prefix . "chars
SET class='$class',gender='$gender',race='$race',lvl='$level',
arcane='$arcane',fire='$fire',frost='$frost',nature='$nature',shadow='$shadow'
WHERE name='$name'";
}
else {
$sql = "UPDATE " . $phpraid_prefix . "chars
SET lvl='$level', arcane='$arcane',fire='$fire',frost='$frost',nature='$nature',shadow='$shadow'
WHERE name='$name'";
}
if($wowdb->num_rows($result_char) > 0)
{
// found a player name match
// update the phpraid settings with this user
$char = $wowdb->fetch_array($result_char);
$name = $char['name'];
if ($char['clientLocale']=="enUS") {
$class = $char['class'];
$gender = $char['sex'];
$race = $char['race'];
}
$level = $char['level'];
$arcane = $char['max_res_arc'];
$fire = $char['max_res_fire'];
$frost = $char['max_res_fro'];
$nature = $char['max_res_nat'];
$shadow = $char['max_res_shad'];
if ($char['clientLocale']=="enUS") {
$sql = "UPDATE " . $phpraid_prefix . "chars
SET class='$class',gender='$gender',race='$race',lvl='$level',
arcane='$arcane',fire='$fire',frost='$frost',nature='$nature',shadow='$shadow'
WHERE name='$name'";
}
else {
$sql = "UPDATE " . $phpraid_prefix . "chars
SET lvl='$level', arcane='$arcane',fire='$fire',frost='$frost',nature='$nature',shadow='$shadow'
WHERE name='$name'";
}
$db_phpraid->sql_query($sql) or die(mysql_error());
WoW Roster -> phpRaid Guild/Character Synchronization
Attempting to synchronize guilds...
Guild synchronization complete...
Attempting to synchronize characters...
Character synchronization complete...
Data synchronization complete! phpRaid characters and guilds are now synchronized with WoW Roster
while($roster_guilds = $wowdb->fetch_row($result))
$guild_name = $roster_guilds['guild_name'];
Diska wrote:Ah, nice catch, thanks a lot! Uploaded a new version now
Is your roster configured for multiple guilds?
Return to phpRaid Synchronization
Users browsing this forum: No registered users and 1 guest