Exemplo n.º 1
0
$data_buffer['body_map']['navel'][0] = $imageoptions['mainx'] + $map_node['navel']['X'];
$data_buffer['body_map']['navel'][1] = $imageoptions['mainy'] + $map_node['navel']['Y'];
if (DEBUGGING) {
    echo 'Did find map: navel ' . $data_buffer['body_map']['navel'][0] . ', ' . $data_buffer['body_map']['navel'][1] . ' > ' . $map_node['navel']['X'] . ' - ' . $map_node['navel']['Y'] . "\r\n";
}
// Check if main slots are used
ParseItem($skin);
ParseItem(10000 + $skin);
ParseItem(20000 + $face);
ParseItem(30000 + $hair);
// Sort equipment by ID
asort($options['slots']);
// Fix stand
foreach ($options['slots'] as $slot => $itemid) {
    $data = GetItemWZInfo($itemid, CURRENT_LOCALE);
    CheckStand(GetItemType($itemid), $data);
}
// Parse items..
foreach ($options['slots'] as $slot => $itemid) {
    if (floor($itemid / 100000) == 5) {
        RenderCashItem($itemid);
    } else {
        ParseItem($itemid);
    }
}
FindAndAddSetEffect();
FindAndAddItemEffect();
// --------------------------------------------------------------------------------------------------------------------------------
// Render items
krsort($data_buffer['zlayers']);
$im = imagecreatetruecolor($imageoptions['width'], $imageoptions['height']);
        } else {
            $shown_items[$slot] = $itemid;
        }
    } else {
        $shown_items[$slot] = $itemid;
    }
    if ($row2['slot'] == -11) {
        $standardWeapon = $itemid;
        $weaponThingType = $standardWeapon / 10000 % 100;
    } elseif ($row2['slot'] == -111) {
        // Cash weapon
        $cashWeapon = $itemid;
    }
}
if (isset($shown_items[11])) {
    CheckStand(GetItemType($standardWeapon), get_data($standardWeapon));
}
if (!isset($shown_items[5])) {
    if (DEBUGGING) {
        echo 'Missing slot 5 equip, setting shirt.' . "\r\n";
    }
    $shown_items[5] = $gender == 0 ? 1060026 : 1061039;
}
if (!isset($shown_items[6]) && GetItemType($shown_items[5]) != 105) {
    if (DEBUGGING) {
        echo 'Missing slot 6 equip, setting pants.' . "\r\n";
    }
    $shown_items[6] = $gender == 0 ? 1040036 : 1041046;
}
$character_equipment->free();
if ($char_stance == 'stand' || $char_stance == 'walk') {