phantasmal-world/5.7e07735073c967012346.js

1 line
27 KiB
JavaScript
Raw Normal View History

2020-01-17 05:50:19 +08:00
(window.webpackJsonp=window.webpackJsonp||[]).push([[5],{"/UnV":function(e,t,s){"use strict";s.d(t,"a",(function(){return c}));var i=s("rwco"),n=s("BAAx"),a=s("5cb6");const r=i.a.get("core/data_formats/parsing/afs"),o=5457473;function c(e){const t=Object(n.b)(r);if(e.bytes_left<8)return t.add_problem(a.b.Error,"AFS archive is corrupted.","Too small to be an AFS archive.").failure();if(e.u32()!==o)return t.add_problem(a.b.Error,"AFS archive is corrupted.","Magic bytes not present.").failure();const s=e.u16();e.seek(2);const i=[];for(let n=1;n<=s;n++){if(e.bytes_left<8){t.add_problem(a.b.Warning,`AFS file entry ${n} is invalid.`,`Couldn't read file entry ${n}, only ${e.bytes_left} bytes left.`);break}const s=e.u32(),r=e.u32();if(s>e.size)t.add_problem(a.b.Warning,`AFS file entry ${n} is invalid.`,`Invalid file offset ${s} for entry ${n}.`);else if(s+r>e.size)t.add_problem(a.b.Warning,`AFS file entry ${n} is invalid.`,`File size ${r} (offset: ${s}) of entry ${n} too large.`);else{const t=e.position;e.seek_start(s),i.push(e.array_buffer(r)),e.seek_start(t)}}return t.success(i)}},"68q7":function(e,t,s){"use strict";s.d(t,"a",(function(){return c}));var i=s("iUMt"),n=s("KVVN"),a=s("jJhE"),r=s("FXpb"),o=s("ouMO");class c extends i.a{constructor(e){const t=new n.a({text:"Dismiss"});super(Object.assign({footer:[t.element]},e));const s=Object(a.a)(e.result)?e.result:Object(o.e)(e.result);this.problems_message=Object(a.a)(e.problems_message)?e.problems_message:Object(o.e)(e.problems_message),this.error_message=Object(a.a)(e.error_message)?e.error_message:Object(o.e)(e.error_message),this.disposables(t,t.onclick.observe(e=>this._ondismiss.emit(e)),s.observe(({value:e})=>this.result_changed(e),{call_now:!0})),this.finalize_construction()}result_changed(e){e?(this.content.val=function(e){const t=Object(r.h)();t.style.overflow="auto",t.style.userSelect="text",t.style.height="100%",t.style.maxHeight="400px";const s=Object(r.B)(...e.problems.map(e=>Object(r.o)(e.ui_message)));return s.style.cursor="text",t.append(s),t}(e),e.success?e.problems.length&&(this.title.val="Problems",this.description.val=this.problems_message.val):(this.title.val="Error",this.description.val=this.error_message.val)):this.content.val=""}}},"9fJw":function(e,t,s){"use strict";s.d(t,"g",(function(){return n})),s.d(t,"h",(function(){return a})),s.d(t,"f",(function(){return r})),s.d(t,"e",(function(){return o})),s.d(t,"k",(function(){return c})),s.d(t,"l",(function(){return _})),s.d(t,"j",(function(){return l})),s.d(t,"i",(function(){return h})),s.d(t,"a",(function(){return u})),s.d(t,"b",(function(){return d})),s.d(t,"d",(function(){return m})),s.d(t,"c",(function(){return b}));class i{constructor(e){var t,s,i,n,a;this.name=e.name,this.body_style_count=null!=(t=e.body_style_count)?t:1,this.head_style_count=e.head_style_count,this.hair_style_count=e.hair_style_count,this.hair_styles_with_accessory=e.hair_styles_with_accessory,this.body_tex_ids=null!=(s=e.body_tex_ids)?s:[],this.head_tex_ids=null!=(i=e.head_tex_ids)?i:[],this.hair_tex_ids=null!=(n=e.hair_tex_ids)?n:[],this.accessory_tex_ids=null!=(a=e.accessory_tex_ids)?a:[]}}const n=new i({name:"HUmar",body_style_count:18,head_style_count:1,hair_style_count:10,hair_styles_with_accessory:new Set([6])}),a=new i({name:"HUnewearl",body_style_count:18,head_style_count:1,hair_style_count:10,hair_styles_with_accessory:new Set}),r=new i({name:"HUcast",body_style_count:25,head_style_count:5,hair_style_count:0,hair_styles_with_accessory:new Set}),o=new i({name:"HUcaseal",body_style_count:25,head_style_count:5,hair_style_count:0,hair_styles_with_accessory:new Set}),c=new i({name:"RAmar",body_style_count:18,head_style_count:1,hair_style_count:10,hair_styles_with_accessory:new Set([0,1,2,3,4,5,6,7,8,9])}),_=new i({name:"RAmarl",body_style_count:18,head_style_count:1,hair_style_count:10,hair_styles_with_accessory:new Set([0,1,2,3,4,5,6,7,8,9])}),l=new i({name:"RAcast",body_style_count:25,head_style_count:5,hair_style_count:0,hair_styles_with_accessory:new Set}),h=new i({name:"RAcaseal",body_style_count:25,head_style_count:5,hair