#!/usr/bin/php -q <?php require_once "obdata.inc"; $cs = new OBData(); $cs->get_data(); $cs->set_pc_level(46); #$npc = $cs->get_item('BeggarICMarketSimplicia'); #$npc = $cs->get_item('ICMarketGuardPostDay01'); $npc = $cs->get_item('SchlerusSestius'); print $npc->get('marksman') . "\n"; if (0) { foreach (array('aggression', 'confidence', 'energy', 'responsibility', 'strength', 'intelligence', 'willpower', 'personality') as $attrib) { print "{$attrib} " . $npc->get($attrib) . "\n"; } $totals = $npc->persuasion_reactions(); foreach ($totals as $reaction => $value) { print "{$reaction} {$value}\n"; } }
<?php require_once "obdata.inc"; $cs = new OBData(); $cs->get_data(); $cs->set_pc_level($level); $npc = $cs->get_item($npc_name); ?> <table> <tr> </tr> </table>
#!/usr/bin/php -q <?php require_once "obdata.inc"; $cs = new OBData(); $cs->set_datamode(CSData::DATAMODE_READ); $csread = $cs->get_data(); $csread->set_doprint(); //$csread->set_filestoread('all'); $csread->request_data('RACE'); $csread->read(); $race = $cs->get_item('WoodElf'); print "Bosmer\n"; for ($i = 1; $i <= 7; $i++) { $skill = $race->get('skl' . $i); $bonus = $race->get('skbonus' . $i); print "{$skill} {$bonus}\n"; } $race = $cs->get_item('Breton'); print "Breton\n"; for ($i = 1; $i <= 7; $i++) { $skill = $race->get('skl' . $i); $bonus = $race->get('skbonus' . $i); print "{$skill} {$bonus}\n"; }
#!/usr/bin/php -q <?php require_once "obdata.inc"; $cs = new OBData(); $cs->get_data(); foreach (array("DLCBattlehornDragonswordPower3", "NDLpGreavesShieldOther", "NDBlessingOfTalos", "BSRitualBlessedWord", "VampireHuntersSight") as $edid) { $spell = $cs->get_item($edid); print "spell=" . $spell->get('name') . " spellcost=" . $spell->get('spellcost') . " autocost=" . $spell->get('auto_spellcost') . " spelllevel=" . $spell->get('spelllevel') . " autolevel=" . $spell->get('auto_spelllevel') . " autocalc=" . $spell->get('autocalc') . "\n"; } $spell = $cs->newitem('SPEL'); $spell->set_custom_spell(); $spell->add_custom_effect('Fire Damage', 5, 5, 10); $spell->add_custom_effect('Fire Damage', 70, 1, 20); print "custom spell\n"; foreach ($spell->indices('effect_id') as $index) { print $spell->magic_desc_line($index) . " cost=" . $spell->effect_cost($index) . "\n"; } print "Total cost=" . $spell->get('spellcost') . " spelllevel=" . $spell->get('spelllevel') . "\n";
<?php require_once "obdata.inc"; require_once "obsaveread.inc"; /*$str = pack('f', -4.); print $str."\n"; for ($i=0; $i<strlen($str); $i++) { $s = substr($str,$i,1); list($x, $n) = unpack('C', $s); printf("%d %3d 0x%02x\n", $i, $n, $n); }*/ $cs = new OBData(); // this should fill in all the lookups from obread.inc.... but is it still needed? $cs->get_data(); if ($argc > 1 && substr($argv[$argc - 1], -4) == '.ess') { $filename = $argv[$argc - 1]; } else { $filename = 'text2609.ess'; } //$save = new OBSaveRead('Save 2605 - Nenya - Arch-Mage\'s Tower Council Chambers, Level 6, Playing Time 41.28.20.ess', $cs); //$save = new OBSaveRead('xboxsave1313.ess', $cs); //$save = new OBSaveRead('xboxsave0451.ess', $cs); //$save = new OBSaveRead('textsave2606.ess', $cs); //$save = new OBSaveRead('xboxsave2427.ess', $cs); print "processing file {$filename}\n\n"; $save = new OBSaveRead($filename, $cs); $save->read(); /* what is update.esp? can I get it from xbox? .... and then, what is script at formid 0x010047af? need text version of 2617 or 2650 (flag 16 on ACHR); 2912 or 2950 (misc. flag 3 with data)