inner.xml 230 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262
  1. <krpano licznik="0" webvr_enabled="false" x_listflar="0" y_listflar="160">
  2. <krpano>
  3. </krpano>
  4. <krpano devices="html5">
  5. <style name="flara_box_end_css" css="color:#b70000; font-family: Arial, sans-serif; font-weight:normal; text-align:center; font-size:16px;"/>
  6. <style name="flara_potwierdzenie_css" css="color:#000000; font-family: Arial, sans-serif; font-weight:normal; text-align:center; font-size:16px;"/>
  7. <style name="flara_popup_bg" type="container" height="100%" width="100%" bgcapture="true" bgalpha="0.0" bgcolor="0x000000" align="lefttop" edge="lefttop" handcursor="false" zorder="220" keep="true"/>
  8. <style name="flara_box_bg" type="container" parent="flara_popup_bg" bgcapture="true" bgalpha="1.0" bgcolor="0xFFFFFF" align="center" edge="center" handcursor="false" zorder="3" keep="true" width="490" height="440" bgroundedge="3" bgshadow="0 29 77 -27 0x000000 1,0 -22 109 -59 0x000000 0.7 inset"/>
  9. <style name="flara_title_text" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" parent="flara_box_bg" handcursor="true" children="false" align="top" edge="top" height="30" width="-40" x="0" y="10" autowidth="false" vcenter="true" background="false" css="color:#064344; font-family: Arial, sans-serif; font-weight:normal; text-align:center; font-size:18px;" html="select lensflare style" keep="true"/>
  10. <style name="flara_box_end" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" parent="flara_box_bg" handcursor="true" align="righttop" edge="righttop" autoheight="false" autoalpha="true" width="50" height="30" padding="6" x="2" y="2" vcenter="true" background="false" html="close" border="false" zorder="10" onclick="close_popup_selectbox_flare()" keep="true"/>
  11. <style name="flara_thumb_id" parent="flara_box_bg" keep="true" zorder="10" align="lefttop" edge="lefttop" ox="10" oy="50" width="150" height="119"/>
  12. <style name="flara_thumb_id_aktyw" parent="flara_box_bg" type="container" width="150" height="119" bgcapture="false" bgalpha="0.3" bgcolor="0x00af10" align="lefttop" edge="lefttop" bordercolor="0x00af10" ox="10" oy="50" zorder="12" keep="true"/>
  13. <style name="flara_potwierdzenie_bg" type="container" parent="flara_box_bg" height="-50" width="100%" bgcapture="true" bgalpha="0.0" bgcolor="0xffffff" align="top" edge="top" oy="50" handcursor="false" zorder="20" maskchildren="true" keep="true"/>
  14. <style name="flara_potwierdzenie_minibox_bg" type="container" parent="flara_potwierdzenie_bg" bgcapture="true" bgalpha="1.0" bgcolor="0xFFFFFF" align="top" edge="bottom" handcursor="false" zorder="3" keep="true" width="460" height="150" bgroundedge="0 0 6 6" bgshadow="0 29 77 -27 0x000000 1,0 -22 109 -59 0x000000 0.7 inset"/>
  15. <style name="flara_potwierdzenie_title" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" parent="flara_potwierdzenie_minibox_bg" handcursor="true" children="false" align="top" edge="top" height="40" width="-20" x="0" y="20" autowidth="false" vcenter="true" background="false" css="color:#5a5a5a; font-family: Arial, sans-serif; font-weight:normal; text-align:center; font-size:15px;" html="confirm your choice" keep="true"/>
  16. <style name="flara_potwierdzenie_style" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" textshadow="1" textshadowrange="1" textshadowangle="90" textshadowalpha="0.6" textshadowcolor="0xffffff" handcursor="false" parent="flara_potwierdzenie_minibox_bg" align="bottom" edge="bottom" width="120" height="60" padding="0" y="20" vcenter="true" background="true" zorder="5" keep="true"/>
  17. <style name="flara_potwierdzenie_cancel" x="-150" backgroundcolor="0xff8989" html="CANCEL" onclick="close_popup_flara_potwierdzenie_cancel()"/>
  18. <style name="flara_potwierdzenie_ok" x="0" backgroundcolor="0x62d55f" html="OK" onclick="load_flare_dynamic(get(lensflares[obj].item.count),get(wybrany_styl_flary_to),false)"/>
  19. <style name="flara_potwierdzenie_ok_dust" x="150" backgroundcolor="0xe6e600" html="OK[br][small][i]with dust effect[/i][/small]" onclick="load_flare_dynamic(get(lensflares[obj].item.count),get(wybrany_styl_flary_to),true)"/>
  20. <action name="potwierdz_wybor_stylu_flary">
  21. set(layer[flara_box_end].alpha, 0);
  22. flayer(flara_potwierdzenie_bg,flara_potwierdzenie_bg);
  23. tween(layer[flara_potwierdzenie_bg].bgalpha, 0.7,0.2,,WAIT);
  24. flayer(flara_potwierdzenie_minibox_bg,flara_potwierdzenie_minibox_bg);
  25. flayer(flara_potwierdzenie_title,flara_potwierdzenie_title);
  26. flayer(flara_potwierdzenie_cancel,flara_potwierdzenie_style|flara_potwierdzenie_cancel|flara_potwierdzenie_css);
  27. flayer(flara_potwierdzenie_ok,flara_potwierdzenie_style|flara_potwierdzenie_ok|flara_potwierdzenie_css);
  28. flayer(flara_potwierdzenie_ok_dust,flara_potwierdzenie_style|flara_potwierdzenie_ok_dust|flara_potwierdzenie_css);
  29. tween(layer[flara_potwierdzenie_minibox_bg].y, 150,0.3,easeOutCubic);
  30. </action>
  31. <action name="close_popup_flara_potwierdzenie_cancel">
  32. set(layer[flara_box_end].alpha, 1);
  33. vonp(flara_potwierdzenie_ok);
  34. vonp(flara_potwierdzenie_ok_dust);
  35. vonp(flara_potwierdzenie_cancel);
  36. vonp(flara_potwierdzenie_title);
  37. vonp(flara_thumb_id_aktyw);
  38. tween(layer[flara_potwierdzenie_minibox_bg].y, 0,0.2,easeOutCubic,
  39. vonp(flara_potwierdzenie_minibox_bg);
  40. vonp(flara_potwierdzenie_bg);
  41. );
  42. </action>
  43. <lensthumb>
  44. <item name="blinkstyle1" x="0" y="0"/>
  45. <item name="blinkstyle2" x="160" y="0"/>
  46. <item name="blinkstyle3" x="320" y="0"/>
  47. <item name="blinkstyle4" x="0" y="130"/>
  48. <item name="blinkstyle5" x="160" y="130"/>
  49. <item name="blinkstyle6" x="320" y="130"/>
  50. <item name="blinkstyle7" x="0" y="260"/>
  51. <item name="blinkstyle8" x="160" y="260"/>
  52. <item name="blinkstyle9" x="320" y="260"/>
  53. </lensthumb>
  54. <action name="show_popup_flare_selectbox">
  55. flayer(flara_popup_bg,flara_popup_bg);
  56. flayer(flara_box_bg,flara_box_bg);
  57. flayer(flara_title_text,flara_title_text);
  58. flayer(flara_box_end,flara_box_end);
  59. set(height_scroll_minibox_left, 0);
  60. for(set(i,0), i LT lensthumb.item.count, inc(i),
  61. copy(n, lensthumb.item[get(i)].name);
  62. flayer(get(n),flara_thumb_id);
  63. txtadd(p.url, '%SWFPATH%/skin/lensflare/src/',get(n),'.jpg');
  64. copy(p.x, lensthumb.item[get(i)].x);
  65. copy(p.y, lensthumb.item[get(i)].y);
  66. set(p.onclick, zaznacz_wybrany_styl_flary(get(name)));
  67. inc(height_scroll_minibox_left, 130);
  68. );
  69. copy(layer[height_scroll_minibox_left].height, height_scroll_minibox_left);
  70. </action>
  71. <action name="zaznacz_wybrany_styl_flary">
  72. set(wybrany_styl_flary_to, %1);
  73. if(!layer[flara_thumb_id_aktyw].loaded,
  74. flayer(flara_thumb_id_aktyw,flara_thumb_id_aktyw);
  75. copy(layer[flara_thumb_id_aktyw].x, layer[%1].x);
  76. copy(layer[flara_thumb_id_aktyw].y, layer[%1].y);
  77. ,
  78. copy(layer[flara_thumb_id_aktyw].x, layer[%1].x);
  79. copy(layer[flara_thumb_id_aktyw].y, layer[%1].y);
  80. );
  81. delayedcall(0.7, potwierdz_wybor_stylu_flary());
  82. </action>
  83. <action name="close_popup_selectbox_flare">
  84. vonp(flara_thumb_id_aktyw);
  85. vonp(blinkstyle1);
  86. vonp(blinkstyle2);
  87. vonp(blinkstyle3);
  88. vonp(blinkstyle4);
  89. vonp(blinkstyle5);
  90. vonp(blinkstyle6);
  91. vonp(blinkstyle7);
  92. vonp(blinkstyle8);
  93. vonp(blinkstyle9);
  94. vonp(flara_box_end);
  95. vonp(flara_box_bg);
  96. vonp(flara_title_text);
  97. vonp(flara_popup_bg);
  98. </action>
  99. <style name="flara_on_scene_box_bg" type="container" bgcapture="true" bgalpha="1.0" bgcolor="0xFFFFFF" align="bottom" edge="bottom" handcursor="false" zorder="200" x="get:x_listflar" y="get:y_listflar" keep="false" ondown="draglayer_flareshow()" width="400" height="90" bgroundedge="3" bgshadow="0 29 77 -27 0x000000 1,0 -22 109 -59 0x000000 0.7 inset"/>
  100. <style name="flara_on_scene_box_mask" type="container" parent="flara_on_scene_box_bg" bgcapture="false" maskchildren="true" bgalpha="0.0" bgcolor="0x000000" align="center" edge="center" handcursor="false" zorder="1" keep="false" width="-40" y="0" height="-10"/>
  101. <style name="flara_on_scene_scroll" direction="h" width="1" height="100%" handcursor="false" parent="flara_on_scene_box_mask" y="0" x="0" onloaded="setcenter(0,0)" zorder="1" align="lefttop" edge="lefttop" keep="false"/>
  102. <style name="flara_on_scene_thumb_id" parent="flara_on_scene_scroll" keep="false" zorder="2" align="left" edge="left" y="0" width="110" height="90"/>
  103. <style name="flara_on_scene_thumb_dust_id" url="%SWFPATH%/skin/lensflare/dust/dust_true.png" keep="false" zorder="1" enabled="false" align="center" edge="center" x="0" y="0" width="100%" height="100%"/>
  104. <style name="flara_on_scene_lookto" crop="0|0|34|34" keep="false" zorder="2" align="leftbottom" edge="leftbottom" x="6" y="12" width="22" height="22"/>
  105. <style name="flara_on_scene_trash" crop="34|0|34|34" keep="false" zorder="2" align="leftbottom" edge="leftbottom" x="32" y="12" width="22" height="22"/>
  106. <style name="flara_on_add_mode_css" css="color:#000000; font-family: Arial, sans-serif; font-weight:bold; text-align:center; font-size:13px;"/>
  107. <style name="flara_on_add_mode" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" textshadow="1" textshadowrange="1" textshadowangle="90" textshadowalpha="0.6" textshadowcolor="0xffffff" handcursor="true" parent="flara_on_scene_box_bg" align="lefttop" edge="leftbottom" width="-270" height="30" padding="0" y="-10" roundedge="0" onclick="add_flare_cross()" vcenter="true" background="true" zorder="5" keep="false"/>
  108. <style name="flara_on_vr_mode" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" textshadow="1" textshadowrange="1" textshadowangle="90" textshadowalpha="0.6" textshadowcolor="0xffffff" handcursor="true" parent="flara_on_scene_box_bg" align="righttop" edge="rightbottom" width="-270" height="30" padding="0" y="-10" roundedge="0" onclick="switch_vr_mode()" vcenter="true" background="true" zorder="5" keep="false"/>
  109. <style name="flara_generate_code" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" textshadow="1" textshadowrange="1" textshadowangle="90" textshadowalpha="0.6" textshadowcolor="0xffffff" handcursor="true" parent="flara_on_scene_box_bg" align="top" edge="bottom" width="-280" height="50" padding="0" y="-10" roundedge="3" vcenter="true" background="true" zorder="5" backgroundcolor="0x1393aa" html="GET CODE" keep="false"/>
  110. <style name="flara_screen_cross_pion" type="container" bgalpha="1.0" bgcolor="0x0000ff" align="center" edge="center" bgcapture="false" zorder="10" keep="true" width="1" height="140"/>
  111. <style name="flara_screen_cross_poziom" type="container" bgalpha="1.0" bgcolor="0xff0000" align="center" edge="center" bgcapture="false" zorder="10" keep="true" width="140" height="1"/>
  112. <style name="flara_screen_addflare" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" shadow="1" shadowangle="90" textshadow="1" textshadowrange="1" textshadowangle="90" textshadowalpha="0.6" textshadowcolor="0xffffff" handcursor="true" parent="flara_screen_cross_pion" align="center" edge="rightbottom" width="130" height="40" padding="10" x="-20" y="-20" backgroundcolor="0x30aa13" roundedge="20 20 0 20" html="ADD LENSFLARE" onclick="show_popup_flare_selectbox(get(lang))" vcenter="true" background="true" zorder="5" keep="true"/>
  113. <action name="show_lensfrafe_aktyw_box">
  114. flayer(flara_on_scene_box_bg,flara_on_scene_box_bg);
  115. copy(p.x, x_listflar);
  116. copy(p.y, y_listflar);
  117. flayer(flara_on_scene_box_mask,flara_on_scene_box_mask);
  118. flayer(flara_on_scene_scroll,flara_on_scene_scroll);
  119. set(p.url, %SWFPATH%/plugins/scrollarea.js);
  120. flayer(flara_on_add_mode,flara_on_add_mode|flara_on_add_mode_css);
  121. if(flara_edit_mode,
  122. set(layer[flara_on_add_mode].backgroundcolor, 0x30aa13);
  123. set(layer[flara_on_add_mode].html, 'EDIT MODE ON');
  124. ,
  125. set(layer[flara_on_add_mode].backgroundcolor, 0xff8989);
  126. set(layer[flara_on_add_mode].html, 'EDIT MODE OFF');
  127. );
  128. flayer(flara_on_vr_mode,flara_on_vr_mode|flara_on_add_mode_css);
  129. if(!webvr_enabled,
  130. set(layer[flara_on_vr_mode].backgroundcolor, 0xff8989);
  131. set(layer[flara_on_vr_mode].html, 'VR DISABLED');
  132. ,
  133. set(layer[flara_on_vr_mode].backgroundcolor, 0x30aa13);
  134. set(layer[flara_on_vr_mode].html, 'VR ENABLED');
  135. );
  136. flayer(flara_generate_code,flara_generate_code|flara_on_add_mode_css);
  137. set(p.onclick, lensflare_is_build_so_generate(get(webvr_enabled)));
  138. set(xflpos, 0);
  139. for(set(i,0), i LT lensflares[obj].item.count, inc(i),
  140. if(lensflares[obj].item[get(i)].scene == '%1',
  141. txtadd(na, 'flt_%1_',get(lensflares[obj].item[get(i)].name));
  142. txtadd(look, 'lookto_%1_',get(lensflares[obj].item[get(i)].name));
  143. txtadd(tras, 'trash_%1_',get(lensflares[obj].item[get(i)].name));
  144. txtadd(dust, 'dust_%1_',get(lensflares[obj].item[get(i)].name));
  145. flayer(get(na),flara_on_scene_thumb_id);
  146. txtadd(p.url, '%SWFPATH%/skin/lensflare/src/',get(lensflares[obj].item[get(i)].typ),'.jpg');
  147. copy(p.x, xflpos);
  148. if(lensflares[obj].item[get(i)].dust_effect,
  149. flayer(get(dust),flara_on_scene_thumb_dust_id);
  150. copy(p.parent, na);
  151. );
  152. flayer(get(look),flara_on_scene_lookto);
  153. set(p.url, %SWFPATH%/skin/lensflare/src/ico.png);
  154. copy(p.parent, na);
  155. txtadd(p.onclick, 'lookto(get(lensflares[obj].item[',get(i),'].ath),get(lensflares[obj].item[',get(i),'].atv),100);');
  156. flayer(get(tras),flara_on_scene_trash);
  157. set(p.url, %SWFPATH%/skin/lensflare/src/ico.png);
  158. copy(p.parent, na);
  159. copy(p._na, na);
  160. copy(p._look, look);
  161. copy(p._tras, tras);
  162. copy(p._dust, dust);
  163. txtadd(p.onclick,
  164. '
  165. potwierdz_usuniecie_flary(get(lensflares[obj].item[',get(i),'].name),%1,get(_na),get(_look),get(_tras),get(_dust));
  166. '
  167. );
  168. inc(xflpos,126);
  169. copy(layer[flara_on_scene_scroll].width, xflpos);
  170. );
  171. sub(layer[flara_on_scene_scroll].width, 10);
  172. );
  173. </action>
  174. <action name="draglayer_flareshow">
  175. if('%1' != 'dragging',
  176. copy(drag_currentx, x);
  177. copy(drag_currenty, y);
  178. copy(drag_stagex, mouse.stagex);
  179. copy(drag_stagey, mouse.stagey);
  180. set(drag_sx, +1);
  181. set(drag_sy, +1);
  182. if(align == 'righttop', set(drag_sx,-1); );
  183. if(align == 'right', set(drag_sx,-1); );
  184. if(align == 'rightbottom', set(drag_sx,-1); set(drag_sy,-1); );
  185. if(align == 'bottom', set(drag_sy,-1); );
  186. if(align == 'leftbottom', set(drag_sy,-1); );
  187. draglayer_flareshow(dragging);
  188. ,
  189. if(pressed,
  190. sub(dx, mouse.stagex, drag_stagex);
  191. sub(dy, mouse.stagey, drag_stagey);
  192. mul(dx, drag_sx);
  193. mul(dy, drag_sy);
  194. add(x, drag_currentx, dx);
  195. add(y, drag_currenty, dy);
  196. copy(x_listflar, x);
  197. copy(y_listflar, y);
  198. delayedcall(0, draglayer_flareshow(dragging) );
  199. );
  200. );
  201. </action>
  202. <action name="switch_vr_mode">
  203. if(webvr_enabled,
  204. set(layer[flara_on_vr_mode].backgroundcolor, 0xff8989);
  205. set(layer[flara_on_vr_mode].html, 'WebVR OFF');
  206. set(webvr_enabled, false)
  207. ,
  208. set(layer[flara_on_vr_mode].backgroundcolor, 0x30aa13);
  209. set(layer[flara_on_vr_mode].html, 'WebVR ON');
  210. set(webvr_enabled, true)
  211. );
  212. </action>
  213. <action name="add_flare_cross">
  214. if(!flara_edit_mode,
  215. set(layer[flara_on_add_mode].backgroundcolor, 0x30aa13);
  216. set(layer[flara_on_add_mode].html, 'EDIT MODE ON');
  217. flayer(flara_screen_cross_pion,flara_screen_cross_pion);
  218. flayer(flara_screen_cross_poziom,flara_screen_cross_poziom);
  219. flayer(flara_screen_addflare,flara_screen_addflare);
  220. set(flara_edit_mode,true);
  221. ,
  222. set(layer[flara_on_add_mode].backgroundcolor, 0xff8989);
  223. set(layer[flara_on_add_mode].html, 'EDIT MODE OFF');
  224. vonp(flara_screen_cross_pion);
  225. vonp(flara_screen_cross_poziom);
  226. vonp(flara_screen_addflare);
  227. set(flara_edit_mode,false);
  228. )
  229. </action>
  230. <style name="vonflara_potwierdzenie_bg" type="container" height="100%" width="100%" bgcapture="true" bgalpha="0.3" bgcolor="0x000000" align="lefttop" edge="lefttop" handcursor="false" zorder="2000" keep="true"/>
  231. <style name="vonflara_potwierdzenie_minibox_bg" type="container" parent="vonflara_potwierdzenie_bg" bgcapture="true" bgalpha="1.0" bgcolor="0xFFFFFF" align="center" edge="center" handcursor="false" zorder="3" keep="true" width="400" height="150" bgroundedge="0 6 0 6" bgshadow="0 29 77 -27 0x000000 1,0 -22 109 -59 0x000000 0.7 inset"/>
  232. <style name="vonflara_potwierdzenie_title" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" parent="vonflara_potwierdzenie_minibox_bg" handcursor="true" children="false" align="top" edge="top" height="40" width="-20" x="0" y="20" autowidth="false" vcenter="true" background="false" css="color:#5a5a5a; font-family: Arial, sans-serif; font-weight:normal; text-align:center; font-size:15px;" html="ARE YOU SURE?" keep="true"/>
  233. <style name="vonflara_potwierdzenie_style" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" textshadow="1" textshadowrange="1" textshadowangle="90" textshadowalpha="0.6" textshadowcolor="0xffffff" handcursor="true" parent="vonflara_potwierdzenie_minibox_bg" align="bottom" edge="bottom" width="160" height="60" padding="0" y="20" vcenter="true" background="true" zorder="5" keep="true"/>
  234. <style name="vonflara_potwierdzenie_cancel" x="-100" backgroundcolor="0xff8989" html="CANCEL" onclick="usun_box_us_flary()"/>
  235. <style name="vonflara_potwierdzenie_ok" x="100" backgroundcolor="0x62d55f" html="OK"/>
  236. <action name="potwierdz_usuniecie_flary">
  237. flayer(vonflara_potwierdzenie_bg,vonflara_potwierdzenie_bg);
  238. flayer(vonflara_potwierdzenie_minibox_bg,vonflara_potwierdzenie_minibox_bg);
  239. flayer(vonflara_potwierdzenie_title,vonflara_potwierdzenie_title);
  240. flayer(vonflara_potwierdzenie_cancel,vonflara_potwierdzenie_cancel|vonflara_potwierdzenie_style|flara_potwierdzenie_css);
  241. flayer(vonflara_potwierdzenie_ok,vonflara_potwierdzenie_ok|vonflara_potwierdzenie_style|flara_potwierdzenie_css);
  242. set(p.onclick, remove_flare_dynamic(%1,%2,%3,%4,%5,%6,%7));
  243. </action>
  244. <action name="usun_box_us_flary">
  245. vonp(vonflara_potwierdzenie_ok);
  246. vonp(vonflara_potwierdzenie_cancel);
  247. vonp(vonflara_potwierdzenie_title);
  248. vonp(vonflara_potwierdzenie_minibox_bg);
  249. vonp(vonflara_potwierdzenie_bg);
  250. </action>
  251. <action name="load_flare_dynamic">
  252. close_popup_flara_potwierdzenie_cancel();
  253. close_popup_selectbox_flare();
  254. inc(suma_flar);
  255. copy(_view_hlookat, view.hlookat);roundval(_view_hlookat,2);
  256. copy(_view_vlookat, view.vlookat);roundval(_view_vlookat,2);
  257. copy(_suma_flar, timertick);roundval(_suma_flar);
  258. set(_dust_effect, %3);
  259. txtadd(nf, 'flarka',get(_suma_flar));
  260. set(lensflares[obj].item[get(nf)].name);
  261. copy(lensflares[obj].item[get(nf)].ath, _view_hlookat);
  262. copy(lensflares[obj].item[get(nf)].atv, _view_vlookat);
  263. copy(lensflares[obj].item[get(nf)].dust_effect, _dust_effect);
  264. copy(lensflares[obj].item[get(nf)].scene, xml.scene);
  265. set(lensflares[obj].item[get(nf)].typ, %2);
  266. set(load_gui_flar, false);
  267. for(set(i,0), i LT lensflares[obj].item.count, inc(i),
  268. copy(name_flare, lensflares[obj].item[get(i)].name);
  269. copy(blink_style, lensflares[obj].item[get(i)].typ);
  270. if(lensflares[obj].item[get(i)].scene == xml.scene,
  271. set(load_gui_flar, true);
  272. for(set(j,0), j LT flare_style[get(blink_style)].item.count, inc(j),
  273. txtadd(n, 'f1_',get(lensflares[obj].item[get(i)].name),'_',get(j));
  274. add_single_flare(get(n),get(i),get(j),get(blink_style),get(name_flare),get(flare_style[get(blink_style)].item[get(j)].move));
  275. );
  276. );
  277. );
  278. show_lensfrafe_aktyw_box(get(xml.scene),get(load_gui_flar));
  279. </action>
  280. <action name="remove_flare_dynamic">
  281. if(lensflares[obj].item[%1].scene == '%2',
  282. vonp(%3);
  283. vonp(%4);
  284. vonp(%5);
  285. vonp(%6);
  286. vonp(flara_on_scene_scroll);
  287. wait(0);
  288. vonh_all(tagmini, %1);
  289. lensflares[obj].item.removearrayitem(%1);
  290. usun_box_us_flary(%1);
  291. load_flare_content(%1);
  292. show_lensfrafe_aktyw_box(%1);
  293. );
  294. </action>
  295. <style name="lensflare_is_build_so_generate_bg" type="container" height="100%" width="100%" bgcapture="true" bgalpha="0.5" bgcolor="0x000000" align="lefttop" edge="lefttop" handcursor="false" zorder="2200" keep="true"/>
  296. <style name="lensflare_is_build_so_generate_box" type="container" height="450" width="610" bgcapture="true" y="-20" bgalpha="1" bgcolor="0x272822" align="center" edge="center" handcursor="false" parent="lensflare_is_build_so_generate_bg" zorder="2" bgshadow="0 29 77 -27 0x000000 1,0 -22 109 -59 0x000000 0.7 inset" keep="true"/>
  297. <style name="lensflare_is_build_so_generate_copy" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" parent="lensflare_is_build_so_generate_box" handcursor="true" align="lefttop" edge="lefttop" autoheight="false" autoalpha="true" autowidth="true" height="44" padding="6" x="5" y="0" vcenter="true" background="false" enabled="false" html="Select, copy and paste to [strong] skin/lensflare/lensflaresettings.xml[/strong]" border="false" zorder="2" keep="true"/>
  298. <style name="lensflare_is_build_so_generate_end" url="https://ssl-player2.720static.com/api/lensflare/textfield.swf" parent="lensflare_is_build_so_generate_box" handcursor="true" align="righttop" edge="righttop" autoheight="false" autoalpha="true" autowidth="true" height="44" padding="6 10 6 10" x="2" y="0" vcenter="true" background="false" html="close" zorder="10" onclick="close_lensflare_is_build_so_generate()" keep="true"/>
  299. <style name="lensflare_is_build_css" css="color:#ffffff; font-family: Arial, sans-serif; font-weight:normal; text-align:left; font-size:13px;"/>
  300. <action name="lensflare_is_build_so_generate">
  301. set(flare_data_dynamic,);
  302. txtadd(flare_data_dynamic, '<krpano>
  303. <br/>
  304. <lensflares name="obj" webvr_enabled="%1">
  305. <br/>
  306. ');
  307. for(set(i,0), i LT lensflares[obj].item.count, inc(i),
  308. copy(_n, lensflares[obj].item[get(i)].name);
  309. copy(_ath, lensflares[obj].item[get(i)].ath);
  310. copy(_atv, lensflares[obj].item[get(i)].atv);
  311. copy(_scene, lensflares[obj].item[get(i)].scene);
  312. copy(_typ, lensflares[obj].item[get(i)].typ);
  313. if(lensflares[obj].item[get(i)].dust_effect === null, set(lensflares[obj].item[get(i)].dust_effect, true));
  314. copy(_dust_effect, lensflares[obj].item[get(i)].dust_effect);
  315. txtadd(flare_data_dynamic,get(flare_data_dynamic),' <item name="',get(_n),'" ath="',get(_ath),'" atv="',get(_atv),'" scene="',get(_scene),'" typ="',get(_typ),'" dust_effect="',get(_dust_effect),'" />
  316. <br/>
  317. ');
  318. );
  319. txtadd(flare_data_dynamic, get(flare_data_dynamic), ' </lensflares>
  320. <br/>
  321. </krpano>');
  322. flayer(lensflare_is_build_so_generate_bg,lensflare_is_build_so_generate_bg);
  323. flayer(lensflare_is_build_so_generate_box,lensflare_is_build_so_generate_box);
  324. flayer(lensflare_is_build_so_generate_end,lensflare_is_build_so_generate_end|lensflare_is_build_css);
  325. flayer(lensflare_is_build_so_generate_copy,lensflare_is_build_so_generate_copy|lensflare_is_build_css);
  326. js(show_fl_textfield(get(flare_data_dynamic)));
  327. </action>
  328. <action name="close_lensflare_is_build_so_generate">
  329. vonp(lensflare_is_build_so_generate_bg);
  330. vonp(lensflare_is_build_so_generate_box);
  331. vonp(lensflare_is_build_so_generate_end);
  332. vonp(lensflare_is_build_so_generate_copy);
  333. js(remove_textfield());
  334. </action>
  335. </krpano>
  336. <style name="blink_fl_lt" url="https://ssl-player2.720static.com/api/lensflare/dust/d1.png" enabled="false" parent="STAGE" align="center" edge="rightbottom" x="0" y="0" width="prop" height="70%" keep="false" alpha="0" zorder="100"/>
  337. <style name="blink_fl_rt" url="https://ssl-player2.720static.com/api/lensflare/dust/d2.png" enabled="false" parent="STAGE" align="center" edge="leftbottom" x="0" y="0" width="prop" height="70%" keep="false" alpha="0" zorder="100"/>
  338. <style name="blink_fl_rb" url="https://ssl-player2.720static.com/api/lensflare/dust/d3.png" enabled="false" parent="STAGE" align="center" edge="lefttop" x="0" y="0" width="prop" height="70%" keep="false" alpha="0" zorder="100"/>
  339. <style name="blink_fl_lb" url="https://ssl-player2.720static.com/api/lensflare/dust/d4.png" enabled="false" parent="STAGE" align="center" edge="righttop" x="0" y="0" width="prop" height="70%" keep="false" alpha="0" zorder="100"/>
  340. <style name="blink_fl_ce" url="https://ssl-player2.720static.com/api/lensflare/dast4.png" enabled="false" parent="STAGE" rotate="180" align="center" edge="center" x="0" y="0" width="prop" height="50%" keep="false" alpha="0" zorder="100"/>
  341. <events name="loasflares" keep="true" onpreviewcomplete="load_flare_content()"/>
  342. <style name="flare" enabled="false" distorted="get:lensflares[obj].webvr_enabled" edge="center" ox="0" oy="0" width="440" height="440" keep="false"/>
  343. <flare_style name="blinkstyle1">
  344. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare7.png" move="0" scale="1.0" alpha="1.0" zorder="-1"/>
  345. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="2"/>
  346. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare2.png" move="-6" scale="0.2" alpha="0.2" zorder="-1"/>
  347. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-3" scale="0.3" alpha="0.4" zorder="-1"/>
  348. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare8.png" move="-0.8" scale="0.3" alpha="0.6" zorder="-1"/>
  349. <item name="flare6" url="https://ssl-player2.720static.com/api/lensflare/flare8.png" move="-0.3" scale="0.2" alpha="0.7" zorder="-1"/>
  350. <item name="flare7" url="https://ssl-player2.720static.com/api/lensflare/flare4.png" move="7" scale="0.8" alpha="0.2" zorder="-1"/>
  351. </flare_style>
  352. <flare_style name="blinkstyle2">
  353. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare7.png" move="0" scale="1.0" alpha="1.0" zorder="-1"/>
  354. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="2"/>
  355. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-5" scale="0.2" alpha="0.3" zorder="-1"/>
  356. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="-2" scale="0.1" alpha="0.6" zorder="-1"/>
  357. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-1.5" scale="0.1" alpha="0.4" zorder="-1"/>
  358. <item name="flare6" url="https://ssl-player2.720static.com/api/lensflare/flare4.png" move="-0.7" scale="0.8" alpha="0.2" zorder="-1"/>
  359. </flare_style>
  360. <flare_style name="blinkstyle3">
  361. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare7.png" move="0" scale="1.0" alpha="1.0" zorder="-1"/>
  362. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="2"/>
  363. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-4" scale="0.2" alpha="0.3" zorder="-1"/>
  364. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="-2" scale="0.1" alpha="0.6" zorder="-1"/>
  365. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-1.5" scale="0.1" alpha="0.4" zorder="-1"/>
  366. </flare_style>
  367. <flare_style name="blinkstyle4">
  368. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare7.png" move="0" scale="1.0" alpha="1.0" zorder="-1"/>
  369. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="2"/>
  370. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare4.png" move="7" scale="0.8" alpha="0.3" zorder="-1"/>
  371. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare1.png" move="0" scale="1" alpha="1" zorder="-1"/>
  372. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-2.5" scale="0.1" alpha="0.4" zorder="-1"/>
  373. </flare_style>
  374. <flare_style name="blinkstyle5">
  375. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare1.png" move="0" scale="1.0" alpha="1.0" zorder="-1"/>
  376. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="2"/>
  377. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="-6" scale="0.2" alpha="0.3" zorder="1"/>
  378. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare4.png" move="-3" scale="0.4" alpha="0.5" zorder="1"/>
  379. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare8.png" move="-2.5" scale="0.1" alpha="0.4" zorder="1"/>
  380. </flare_style>
  381. <flare_style name="blinkstyle6">
  382. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare7.png" move="0" scale="0.5" alpha="1.0" zorder="-1"/>
  383. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="2"/>
  384. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="-4" scale="0.1" alpha="0.4" zorder="-1"/>
  385. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-2" scale="0.1" alpha="0.4" zorder="-1"/>
  386. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare2.png" move="-1.5" scale="0.1" alpha="0.4" zorder="-1"/>
  387. <item name="flare6" url="https://ssl-player2.720static.com/api/lensflare/flare8.png" move="-1.0" scale="0.08" alpha="0.4" zorder="-1"/>
  388. </flare_style>
  389. <flare_style name="blinkstyle7">
  390. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare1.png" move="0" scale="1.0" alpha="1.0" zorder="2"/>
  391. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="3"/>
  392. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare8.png" move="-6" scale="0.2" alpha="0.2" zorder="2"/>
  393. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-3" scale="0.3" alpha="0.2" zorder="2"/>
  394. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-0.8" scale="0.2" alpha="0.6" zorder="2"/>
  395. <item name="flare6" url="https://ssl-player2.720static.com/api/lensflare/flare3.png" move="6" scale="0.6" alpha="0.1" zorder="1"/>
  396. <item name="flare7" url="https://ssl-player2.720static.com/api/lensflare/flare4.png" move="9" scale="0.8" alpha="0.2" zorder="1"/>
  397. </flare_style>
  398. <flare_style name="blinkstyle8">
  399. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare7.png" move="0" scale="0.7" alpha="1.0" zorder="-1"/>
  400. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="6.0" alpha="0.0" zorder="2"/>
  401. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare2.png" move="-4" scale="0.2" alpha="0.4" zorder="-1"/>
  402. <item name="flare4" url="https://ssl-player2.720static.com/api/lensflare/flare3.png" move="-3.5" scale="0.3" alpha="0.2" zorder="-1"/>
  403. <item name="flare5" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-2.8" scale="0.2" alpha="0.1" zorder="-1"/>
  404. <item name="flare6" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="-1.5" scale="0.1" alpha="0.5" zorder="-1"/>
  405. <item name="flare7" url="https://ssl-player2.720static.com/api/lensflare/flare4.png" move="-1" scale="0.8" alpha="0.2" zorder="-1"/>
  406. </flare_style>
  407. <flare_style name="blinkstyle9">
  408. <item name="flare1" url="https://ssl-player2.720static.com/api/lensflare/flare1.png" move="0" scale="0.3" alpha="1.0" zorder="-1"/>
  409. <item name="flare2" url="https://ssl-player2.720static.com/api/lensflare/flare5.png" move="0" scale="0.1" alpha="0.0" zorder="2"/>
  410. <item name="flare3" url="https://ssl-player2.720static.com/api/lensflare/flare6.png" move="-6" scale="0.03" alpha="0.4" zorder="-1"/>
  411. </flare_style>
  412. <action name="load_flare_content">
  413. if(!first_flare_settings,
  414. copy(suma_flar, lensflares[obj].item.count);
  415. set(first_flare_settings,true);
  416. );
  417. if(lensflares[obj].item.count GT 0 OR addflaremode == true,
  418. flayer(blink_fl_lt,blink_fl_lt);
  419. flayer(blink_fl_rt,blink_fl_rt);
  420. flayer(blink_fl_rb,blink_fl_rb);
  421. flayer(blink_fl_lb,blink_fl_lb);
  422. );
  423. set(load_gui_flar, false);
  424. for(set(i,0), i LT lensflares[obj].item.count, inc(i),
  425. copy(name_flare, lensflares[obj].item[get(i)].name);
  426. copy(blink_style, lensflares[obj].item[get(i)].typ);
  427. if(lensflares[obj].item[get(i)].scene == xml.scene,
  428. set(load_gui_flar, true);
  429. for(set(j,0), j LT flare_style[get(blink_style)].item.count, inc(j),
  430. txtadd(n, 'f1_',get(lensflares[obj].item[get(i)].name),'_',get(j));
  431. add_single_flare(get(n),get(i),get(j),get(blink_style),get(name_flare),get(flare_style[get(blink_style)].item[get(j)].move));
  432. );
  433. );
  434. );
  435. if(addflaremode,
  436. show_lensfrafe_aktyw_box(get(xml.scene),get(load_gui_flar));
  437. )
  438. </action>
  439. <action name="add_single_flare">
  440. fhotspot(%1,flare);
  441. copy(h.url, flare_style[%4].item[%3].url);
  442. copy(h.ath, lensflares[obj].item[%5].ath);
  443. copy(h.atv, lensflares[obj].item[%5].atv);
  444. if(lensflares[obj].item[%5].dust_effect === null, set(lensflares[obj].item[%5].dust_effect, true));
  445. copy(h.dust_effect, lensflares[obj].item[%5].dust_effect);
  446. set(h.tagmini, %5);
  447. copy(h.scale, flare_style[%4].item[%3].scale);
  448. copy(h.alpha, flare_style[%4].item[%3].alpha);
  449. copy(h.zorder, flare_style[%4].item[%3].zorder);
  450. set(h.onloaded,
  451. asyncloop(loaded,
  452. spheretoscreen(ath, atv, xposh_%1, yposh_%1);
  453. div(xpos_%1, stagewidth, 2);
  454. div(ypos_%1, stageheight, 2);
  455. sub(xposg_%1, xposh_%1, xpos_%1);
  456. sub(yposg_%1, yposh_%1, ypos_%1);
  457. div(ox, xposg_%1, %6);
  458. div(oy, yposg_%1, %6);
  459. if(%3 == '1',
  460. getlooktodistance(result_%1, view.hlookat, view.vlookat, ath, atv);
  461. div(result1_%1, result_%1, 10);
  462. clamp(result1_%1, 0.0, 1.0);
  463. mod(result2_%1, result1_%1, 100);
  464. sub(result2_%1,1);
  465. mul(result2_%1,-1);
  466. copy(alpha, result2_%1);
  467. sub(alpha, 0.3);
  468. if('%4' != 'blinkstyle9',
  469. if(result_%1 LT 7,
  470. migaj_kurzem(get(result2_%1),get(dust_effect));
  471. );
  472. if(result_%1 GT 7 AND result_%1 LT 20,
  473. migaj_kurzem(0,true);
  474. );
  475. );
  476. );
  477. testme(%1,get(xposh_%1),get(yposh_%1));
  478. );
  479. );
  480. </action>
  481. <action name="migaj_kurzem">
  482. if(%2,
  483. set(layer[blink_fl_lt].alpha, %1);
  484. set(layer[blink_fl_rt].alpha, %1);
  485. set(layer[blink_fl_rb].alpha, %1);
  486. set(layer[blink_fl_lb].alpha, %1);
  487. set(layer[blink_fl_ce].alpha, %1);
  488. );
  489. </action>
  490. <action name="testme">
  491. if(%3 LT 0 OR !%3,
  492. set(ukryj_gora_%1, true);
  493. ,
  494. set(ukryj_gora_%1, false);
  495. );
  496. if(%3 GT stageheight OR !%3,
  497. set(ukryj_dol_%1, true);
  498. ,
  499. set(ukryj_dol_%1, false);
  500. );
  501. if(%2 LT 0 OR !%2,
  502. set(ukryj_lewo_%1, true);
  503. ,
  504. set(ukryj_lewo_%1, false);
  505. );
  506. if(%2 GT stagewidth OR !%2,
  507. set(ukryj_prawo_%1, true);
  508. ,
  509. set(ukryj_prawo_%1, false);
  510. );
  511. if(!ukryj_gora_%1 AND !ukryj_dol_%1 AND !ukryj_lewo_%1 AND !ukryj_prawo_%1,
  512. set(visible, true);
  513. ,
  514. set(visible, false);
  515. );
  516. </action>
  517. <action name="reset_pano_lensflare"/>
  518. <action name="flayer">
  519. addlayer(%1);
  520. layer[%1].loadstyle(%2);
  521. copy(p, layer[%1]);
  522. </action>
  523. <action name="fhotspot">
  524. addhotspot(%1);
  525. hotspot[%1].loadstyle(%2);
  526. copy(h, hotspot[%1]);
  527. </action>
  528. <action name="vonp">
  529. if(layer[%1].loaded, removelayer(%1));
  530. </action>
  531. <action name="vonh">
  532. if(hotspot[%1].loaded, removehotspot(%1));
  533. </action>
  534. <action name="vonh_all">
  535. sub(i,hotspot.count,1);
  536. if(i GE 0,loop_vonh_all(get(i),%1,%2));
  537. </action>
  538. <action name="loop_vonh_all">
  539. if(%2 == null,
  540. vonh(%1);
  541. ,
  542. if(hotspot[%1].%2 == %3,
  543. vonh(%1);
  544. );
  545. );
  546. dec(i);
  547. if(i GE 0, loop_vonh_all(get(i),%2,%3));
  548. </action>
  549. </krpano>
  550. <krpano>
  551. <style name="skin_style" url="calc:settings.root_url + '/krp/skin/skin_v10.png'"/>
  552. <control mouse="moveto" keycodesin="16,65,107" keycodesout="17,89,90,109" bouncinglimits="true"/>
  553. <settings root_url="https://ssl-player2.720static.com/krp/%$playerDomain%" base_url="%HTMLPATH%/%$playerDomain%/krp/1.20.7/" skin_url="%HTMLPATH%/%$playerDomain%/krp/1.19-pr16/" domain="%HTMLPATH%/%$playerDomain%/" first_pano_inited="false" client="false" sound_play_id="play_sound_id" sound_playing="false" sound_on="true" voice_play_id="play_voice_id" voice_playing="false" voice_on="true" bottom_right_btn_width="55" menu_btn_width="70" pano_thumbs_width="80" pano_thumbs_height="80" pano_thumbs_padding_v="10" pano_thumbs_padding_h="20" category_thumbs_width="100" category_thumbs_height="100" category_thumbs_padding_v="10" category_thumbs_padding_h="30" category_thumbs_bg_crop="0|0|218|218" category_thumbs_bg_crop_selected="218|241|218|218" thumb_btn_url="calc:settings.skin_url + 'system/piclist.png'" start_image_desktop="calc:settings.skin_url + 'skin/mouseAlert.png'" start_image_mobile="calc:settings.skin_url + 'skin/touchAlert.png'" circle_mask="calc:settings.skin_url + 'skin/ground-logo.png'" rain_image="calc: settings.skin_url + 'skin/rain.png'" snow_image="calc: settings.skin_url + 'skin/snow.png'" map_zoom_image="calc:settings.skin_url + 'skin/mapZoom.png'" close_image="calc:settings.skin_url + 'skin/close.png'" embed_txt_image="calc:settings.skin_url + 'skin/embed_txt_bg.png'" embed_line_image="calc:settings.domain + 'krp/embed.png'" embed_txt_colored_image="calc:settings.skin_url + 'skin/hotspot_txt_arrow_color.png'" weather_image_1="calc:settings.skin_url + 'skin/hongbao.png'" weather_image_2="calc:settings.skin_url + 'skin/hongbao1.png'" weather_image_3="calc:settings.skin_url + 'skin/hongbao2.png'" comment_add_head_bg_image="calc:settings.skin_url + 'skin/comment_add_head_bg.png'" comment_edit_line_image="calc:settings.skin_url + 'skin/editLine.png'" comment_edit_bg_image="calc:settings.skin_url + 'skin/editBg.png'" custom_weather_image_4="calc:settings.skin_url + 'skin/hongbao.png'" custom_weather_image_5="calc:settings.skin_url + 'skin/hongbao1.png'" custom_weather_image_6="calc:settings.skin_url + 'skin/hongbao2.png'" feipai_logo_url="calc:settings.skin_url + 'source/720_feipai.png'" blank_music_url="calc:settings.root_url + '/krp/music/blank.mp3'"/>
  554. <plugin_url TEXT_SWF="calc:settings.base_url + 'plugins/textfield.swf'" GYRO="calc:settings.base_url + 'plugins/gyro2.js'" SOUND_SWF="calc:settings.base_url + 'plugins/soundinterface.swf'" SOUND_JS="calc:settings.skin_url + 'plugins/soundinterface.js'" SCROLL_SWF="calc:settings.base_url + 'plugins/scrollarea.swf'" SCROLL_JS="calc:settings.base_url + 'plugins/scrollarea.js'" RADAR_SWF="calc:settings.base_url + 'plugins/radar.swf'" RADAR_JS="calc:settings.base_url + 'plugins/radar.js'" SNOW_SWF="calc:settings.base_url + 'plugins/snow.swf'" SNOW_JS="calc:settings.base_url + 'plugins/snow.js'" PLUGINS_SUN_IMAGE="calc:settings.base_url + 'plugins/lensflareset/lensflares.jpg'" WEBVR_JS="calc:settings.base_url + 'plugins/webvr.js'" WEBVR_XML="calc:settings.base_url + 'plugins/webvr.xml'" VIDEO_JS="calc:settings.base_url + 'plugins/krp_video_player_4_pich.js'" TWEENTYPES_JS="calc:settings.base_url + 'plugins/moretweentypes.js'"/>
  555. <plugin url="calc:plugin_url.TWEENTYPES_JS" preload="true"/>
  556. <blendmodes name="blend0" blend="OPENBLEND(0.5, 0.0, 0.75, 0.05, linear)"/>
  557. <blendmodes name="blend1" blend="ZOOMBLEND(2.0, 2.0, easeInOutSine)"/>
  558. <blendmodes name="blend2" blend="COLORBLEND(2.0, 0x000000, easeOutSine)"/>
  559. <blendmodes name="blend3" blend="LIGHTBLEND(1.0, 0xFFFFFF, 2.0, linear)"/>
  560. <blendmodes name="blend4" blend="SLIDEBLEND(1.0, 0.0, 0.2, linear)"/>
  561. <blendmodes name="blend5" blend="SLIDEBLEND(1.0, 135.0, 0.4, linear)"/>
  562. <blendmodes name="blend6" blend="OPENBLEND(1.0, 0.0, 0.2, 0.0, linear)"/>
  563. <blendmodes name="blend7" blend="OPENBLEND(1.0, -1.0, 0.3, 0.0, linear)"/>
  564. <blendmodes name="blend8" blend="OPENBLEND(1.0, -0.5, 0.3, 0.8, linear)"/>
  565. <action name="showtext_install" autorun="preinit">
  566. set(showtext, action(showtext_xml,%%1,%%2) );
  567. set(showtext_style, DEFAULT);
  568. set(showtext_prevstyle, null);
  569. set(showtext_text, '');
  570. set(showtext_prevtext, '');
  571. set(showtext_timeout, 0.1);
  572. set(showtext_fadeout, 0.0);
  573. set(showtext_clipping, false);
  574. </action>
  575. <action name="showtext_xml">
  576. set(showtext_style, DEFAULT);
  577. if(%2 != null, ifnot(textstyle[%2], trace('textstyle "%2" not found'); , set(showtext_style,%2)); );
  578. set(showtext_text, %1);
  579. if(showtext_text != showtext_prevtext,
  580. copy(showtext_prevtext, showtext_text);
  581. showtext_createnewtext();
  582. ,
  583. delayedcall(showtext_timer, get(showtext_timeout), showtext_hide() );
  584. );
  585. </action>
  586. <action name="showtext_createnewtext">
  587. stopdelayedcall(showtext_mouseupdates);
  588. stoptween(layer[showtext_tf].alpha);
  589. if(showtext_style != showtext_prevstyle,
  590. copy(showtext_prevstyle, showtext_style);
  591. removelayer(showtext_tf);
  592. );
  593. addlayer(showtext_tf);
  594. copy(tf, layer[showtext_tf]);
  595. copy(ts, textstyle[get(showtext_style)]);
  596. if(ts.origin !== null, copy(ts_origin, ts.origin), set(ts_origin, 'cursor'));
  597. if(ts.edge !== null, copy(ts_edge, ts.edge), set(ts_edge, 'bottom'));
  598. if(ts.xoffset !== null, copy(ts_xoffset, ts.xoffset), set(ts_xoffset, 0));
  599. if(ts.yoffset !== null, copy(ts_yoffset, ts.yoffset), set(ts_yoffset, -3));
  600. if(ts_origin == 'cursor',
  601. set(tf.align, 'lefttop');
  602. showtext_movetomouse();
  603. ,
  604. copy(tf.align, ts_origin);
  605. );
  606. copy(tf.edge, ts_edge);
  607. copy(tf.ox, ts_xoffset);
  608. copy(tf.oy, ts_yoffset);
  609. if(ts.font !== null, copy(ts_font, ts.font), set(ts_font, 'Times'));
  610. if(ts.fontsize !== null, copy(ts_fontsize, ts.fontsize), set(ts_fontsize, 12.0));
  611. if(ts.bold !== null, copy(ts_bold, ts.bold), set(ts_bold, true));
  612. if(ts.italic !== null, copy(ts_italic, ts.italic), set(ts_italic, false));
  613. if(ts.textcolor !== null, copy(ts_textcolor, ts.textcolor), set(ts_textcolor, 0x000000));
  614. if(ts.textalign !== null, copy(ts_textalign, ts.textalign), set(ts_textalign, 'left'));
  615. set(tf_css, '');
  616. tohex(ts_textcolor, '#', 6);
  617. txtadd(tf_css, 'font-family:',get(ts_font),'; font-size:',get(ts_fontsize),'px; color:',get(ts_textcolor),'; ');
  618. if(ts_textalign != 'none', txtadd(tf_css, get(tf_css), 'text-align:',get(ts_textalign),'; '));
  619. if(ts_bold, txtadd(tf_css, 'font-weight:bold; '));
  620. if(ts_italic, txtadd(tf_css, 'font-style:italic; '));
  621. if(ts.css !== null, txtadd(tf_css, get(ts.css)));
  622. copy(tf.css, tf_css);
  623. if(ts.width !== null, copy(tf.width, ts.width));
  624. if(ts.height !== null, copy(tf.height, ts.height));
  625. if(ts.vcenter !== null, copy(tf.vcenter, ts.vcenter));
  626. if(ts.padding !== null, copy(tf.padding, ts.padding), set(tf.padding,1));
  627. if(ts.background !== null, copy(tf.background, ts.background));
  628. if(ts.backgroundcolor !== null, copy(tf.backgroundcolor, ts.backgroundcolor));
  629. if(ts.backgroundalpha !== null, copy(tf.backgroundalpha, ts.backgroundalpha));
  630. if(ts.border !== null, copy(tf.border, ts.border), set(tf.border,true));
  631. if(ts.bordercolor !== null, copy(tf.bordercolor, ts.bordercolor));
  632. if(ts.borderalpha !== null, copy(tf.borderalpha, ts.borderalpha));
  633. if(ts.borderwidth !== null, copy(tf.borderwidth, ts.borderwidth));
  634. if(ts.roundedge !== null, copy(tf.roundedge, ts.roundedge));
  635. if(ts.shadow !== null, copy(tf.shadow, ts.shadow));
  636. if(ts.shadowrange !== null, copy(tf.shadowrange, ts.shadowrange));
  637. if(ts.shadowangle !== null, copy(tf.shadowangle, ts.shadowangle));
  638. if(ts.shadowcolor !== null, copy(tf.shadowcolor, ts.shadowcolor));
  639. if(ts.shadowalpha !== null, copy(tf.shadowalpha, ts.shadowalpha));
  640. if(ts.textshadow !== null, copy(tf.textshadow, ts.textshadow));
  641. if(ts.textshadowrange !== null, copy(tf.textshadowrange, ts.textshadowrange));
  642. if(ts.textshadowangle !== null, copy(tf.textshadowangle, ts.textshadowangle));
  643. if(ts.textshadowcolor !== null, copy(tf.textshadowcolor, ts.textshadowcolor));
  644. if(ts.textshadowalpha !== null, copy(tf.textshadowalpha, ts.textshadowalpha));
  645. if(ts.alpha !== null, copy(ts_alpha, ts.alpha), set(ts_alpha, 1.0));
  646. if(ts.showtime !== null, copy(ts_showtime, ts.showtime), set(ts_showtime, 0.1));
  647. if(ts.fadetime !== null, copy(ts_fadetime, ts.fadetime), set(ts_fadetime, 0.0));
  648. if(ts.fadeintime !== null, copy(ts_fadeintime, ts.fadeintime), set(ts_fadeintime, 0.0));
  649. copy(showtext_timeout, ts_showtime);
  650. copy(showtext_fadeout, ts_fadetime);
  651. if(ts_fadeintime GT 0,
  652. set(tf.alpha, 0.0);
  653. tween(layer[showtext_tf].alpha, get(ts_alpha), get(ts_fadeintime), linear);
  654. ,
  655. copy(tf.alpha, ts_alpha);
  656. );
  657. if(ts.noclip !== null, copy(showtext_clipping,ts.noclip), set(showtext_clipping, true));
  658. if(showtext_clipping,
  659. set(tf.onloaded, showtext_do_clipping() );
  660. set(tf.onautosized, showtext_do_clipping() );
  661. );
  662. if(ts.embeddedfonts !== null, copy(tf.embeddedfonts, ts.embeddedfonts));
  663. if(ts.effect !== null, copy(tf.effect, ts.effect));
  664. if(ts.blendmode !== null, copy(tf.blendmode, ts.blendmode));
  665. copy(tf.html, showtext_text);
  666. set(tf.enabled, false);
  667. set(tf.zorder, 3000);
  668. if(ts.parent, copy(tf.parent, ts.parent) );
  669. set(tf.url,get(plugin_url.TEXT_SWF));
  670. delete(ts);
  671. delete(tf);
  672. delayedcall(showtext_timer, get(showtext_timeout), showtext_hide() );
  673. </action>
  674. <action name="showtext_do_clipping">
  675. if(showtext_clipping,
  676. layer[showtext_tf].updatepos();
  677. copy(tf_px, layer[showtext_tf].pixelx);
  678. copy(tf_py, layer[showtext_tf].pixely);
  679. if(tf_px LT 0,
  680. sub(layer[showtext_tf].x, tf_px);
  681. ,
  682. add(tf_rightedge, tf_px, layer[showtext_tf].pixelwidth);
  683. if(tf_rightedge GE stagewidth, sub(tf_rightedge,stagewidth); sub(layer[showtext_tf].x,tf_rightedge); );
  684. );
  685. if(tf_py LT 0,
  686. sub(layer[showtext_tf].y, tf_py);
  687. ,
  688. add(tf_bottomedge, tf_py, layer[showtext_tf].pixelheight);
  689. if(tf_bottomedge GE stageheight, sub(tf_bottomedge,stageheight); sub(layer[showtext_tf].y,tf_bottomedge); );
  690. );
  691. );
  692. </action>
  693. <action name="showtext_movetomouse">
  694. copy(layer[showtext_tf].x, mouse.stagex);
  695. copy(layer[showtext_tf].y, mouse.stagey);
  696. showtext_do_clipping();
  697. delayedcall(showtext_mouseupdates, 0, showtext_movetomouse() );
  698. </action>
  699. <action name="showtext_hide">
  700. if(layer[showtext_tf],
  701. tween(layer[showtext_tf].alpha, 0.0, get(showtext_fadeout), linear,
  702. stopdelayedcall(showtext_mouseupdates);
  703. removelayer(showtext_tf);
  704. set(showtext_text, '');
  705. set(showtext_prevtext, '');
  706. );
  707. );
  708. </action>
  709. <textstyle name="tooltipTextStyle" font="STXihei" fontsize.no-mobile="14" fontsize.mobile="18" bold="false" background="true" backgroundcolor="0x000000" backgroundalpha="0.667" border="true" borderwidth="2" bordercolor="0xFFFFFF" roundedge="5" textcolor="0xFFFFFF" padding="6 10" textalign="center" yoffset.no-touch="-5" yoffset.touch="-40"/>
  710. <events onsingleclick="on_single_click();" ondoubleclick="on_double_click();" onautorotateoneround="load_pano_loop();" onloadcomplete="on_load_complete();" onviewchange="on_view_changed();" onmouseup="on_mouse_up();" onclick="on_click();"/>
  711. <action name="on_click">
  712. if(useMarkMode == true,
  713. screentosphere(mouse.x,mouse.y, hclick,vclick);
  714. clickToAddFlag();
  715. );
  716. </action>
  717. <action name="on_single_click">
  718. js_playerClickCallback();
  719. </action>
  720. <action name="on_double_click">
  721. js_playerDoubleClickCallback();
  722. </action>
  723. <action name="on_mouse_up">
  724. set(js_command, 'interfaceObject.mouseUpCallback()');
  725. jscall(get(js_command));
  726. </action>
  727. <action name="on_view_changed">
  728. js_viewChangedCallback();
  729. </action>
  730. <action name="clickToAddFlag">
  731. krpAddSelfMark(get(hclick), get(vclick));
  732. set(js_command, '{\"type\":1, \"action\":0, \"to\":\"\", \"payload\":[\"krpAddMark(');
  733. txtadd(js_command, get(hclick));
  734. txtadd(js_command, ',');
  735. txtadd(js_command, get(vclick));
  736. txtadd(js_command, ',');
  737. txtadd(js_command, get(daikanAvatar));
  738. txtadd(js_command, ',');
  739. txtadd(js_command, get(daikanNickname));
  740. txtadd(js_command, ');\"]}');
  741. js_sendCommand(get(js_command));
  742. js_App('krpFlagClick', get(hclick), get(vclick));
  743. </action>
  744. <layer name="radar_container" keep="true" type="container" align="topleft" width="100%" height="100%" maskchildren="fasle" visible="true" bgcapture="false" zorder="10">
  745. <layer name="radar_layer" keep="true" type="container" align="topright" width="100%" height="100%" maskchildren="false" visible="true" bgcapture="false" zorder="10"/>
  746. </layer>
  747. <action name="show_UI">
  748. set(layer[radar_container].visible,true);
  749. set(layer[radarBtn].visible,true);
  750. if(%1 != 1,
  751. js_toggleUI(true);
  752. );
  753. </action>
  754. <action name="hide_UI">
  755. if(%1 != 1,
  756. set(layer[radar_container].visible,false);
  757. set(layer[radarBtn].visible,false);
  758. );
  759. if(%2 != 1,
  760. js_toggleUI(false);
  761. );
  762. </action>
  763. <action name="js_viewChangedCallback">
  764. set(js_command, 'interfaceObject.viewDidChangeCallback()');
  765. jscall(get(js_command));
  766. js_App('krpViewChange', get(view.hlookat), get(view.vlookat), get(view.fov));
  767. </action>
  768. <action name="js_showViewType">
  769. set(js_command, 'interfaceObject.showViewType()');
  770. jscall(get(js_command));
  771. </action>
  772. <action name="js_toggleLoading">
  773. set(js_command, calc('interfaceObject.toggleLoading(' + %1 + ')'));
  774. jscall(get(js_command));
  775. </action>
  776. <action name="js_playerReadyCallback">
  777. set(js_command, 'interfaceObject.playerDidReadyCallback()');
  778. </action>
  779. <action name="js_playerClickCallback">
  780. set(js_command, 'interfaceObject.playerDidClickCallback()');
  781. jscall(get(js_command));
  782. </action>
  783. <action name="js_playerDoubleClickCallback">
  784. set(js_command, 'interfaceObject.playerDidDoubleClickCallback()');
  785. jscall(get(js_command));
  786. </action>
  787. <action name="js_sceneReadyCallback">
  788. set(js_command, 'interfaceObject.sceneDidChangeCallback()');
  789. jscall(get(js_command));
  790. </action>
  791. <action name="js_sceneLoadedCallback">
  792. set(js_command, 'interfaceObject.sceneDidLoadedCallback()');
  793. jscall(get(js_command));
  794. </action>
  795. <action name="js_sceneChangeCallback">
  796. set(jscall_scene_id,%1);
  797. if(%2 === null,
  798. set(js_command, calc('interfaceObject.loadScene("' + jscall_scene_id + '")'));
  799. ,
  800. set(jscall_blend_mode,%2);
  801. set(js_command, calc('interfaceObject.loadScene("' + jscall_scene_id + '",' + jscall_blend_mode + ')'));
  802. );
  803. jscall(get(js_command));
  804. </action>
  805. <action name="js_panoChangeCallback">
  806. set(jscall_pano_id,%1);
  807. if(%2 === null,
  808. set(js_command, calc('interfaceObject.loadSceneByPanoID(' + jscall_pano_id + ')'));
  809. ,
  810. set(jscall_blend_mode,%2);
  811. set(js_command, calc('interfaceObject.loadSceneByPanoID(' + jscall_pano_id + ',' + jscall_blend_mode + ')'));
  812. );
  813. jscall(get(js_command));
  814. </action>
  815. <action name="js_hotspotClickCallback">
  816. set(jscall_hotspot_id,%1);
  817. js_App('krpHotspotClick', get(jscall_hotspot_id));
  818. set(js_command, calc('interfaceObject.hotspotDidClickCallback("' + jscall_hotspot_id + '")'));
  819. jscall(get(js_command));
  820. </action>
  821. <action name="js_toggleUI">
  822. set(js_command, calc('interfaceObject.toggleUI(' + %1 + ')'));
  823. jscall(get(js_command));
  824. </action>
  825. <action name="js_radarMapStatusDidChangeCallback">
  826. set(js_command, calc('interfaceObject.radarMapStatusDidChangeCallback(' + %1 + ')'));
  827. jscall(get(js_command));
  828. </action>
  829. <action name="js_radarMapFullscreenStatusDidChangeCallback">
  830. set(js_command, calc('interfaceObject.radarMapFullscreenStatusDidChangeCallback(' + %1 + ')'));
  831. jscall(get(js_command));
  832. </action>
  833. <action name="js_showAutoTourSubtitle">
  834. set(jscall_autotour_subtitle_text, %1);
  835. set(jscall_autotour_subtitle_position, %2);
  836. set(jscall_autotour_subtitle_size, %3);
  837. set(jscall_autotour_subtitle_background, %4);
  838. set(js_command, calc('interfaceObject.showAutoTourSubtitle("' + jscall_autotour_subtitle_text + '","' + jscall_autotour_subtitle_position + '",' + jscall_autotour_subtitle_size + ',"' + jscall_autotour_subtitle_background + '")'));
  839. jscall(get(js_command));
  840. </action>
  841. <action name="js_hideAutoTourSubtitle">
  842. set(js_command, 'interfaceObject.hideAutoTourSubtitle()');
  843. jscall(get(js_command));
  844. </action>
  845. <action name="js_toggleAutoTourUI">
  846. set(js_command, calc('interfaceObject.toggleAutoTourUI(' + %1 + ')'));
  847. jscall(get(js_command));
  848. </action>
  849. <action name="js_autoTourEndCallback">
  850. set(js_command, 'interfaceObject.autoTourEndCallback()');
  851. jscall(get(js_command));
  852. unmuted_embed_video();
  853. </action>
  854. <action name="js_vrUnavailableCallback">
  855. set(js_command, 'interfaceObject.unavailableCallback("vr")');
  856. jscall(get(js_command));
  857. </action>
  858. <action name="js_exitVRCallback">
  859. set(js_command, 'interfaceObject.vrDidExitCallback()');
  860. jscall(get(js_command));
  861. </action>
  862. <action name="js_playSound">
  863. set(jscall_id,%1);
  864. set(jscall_url,%2);
  865. set(js_command, calc('interfaceObject.playSound("' + jscall_id + '","' + jscall_url + '")'));
  866. jscall(get(js_command));
  867. </action>
  868. <action name="js_pauseSound">
  869. set(jscall_id,%1);
  870. set(js_command, calc('interfaceObject.pauseSound("' + jscall_id + '")'));
  871. jscall(get(js_command));
  872. </action>
  873. <action name="js_resumeSound">
  874. set(jscall_id,%1);
  875. set(js_command, calc('interfaceObject.resumeSound("' + jscall_id + '")'));
  876. jscall(get(js_command));
  877. </action>
  878. <action name="js_stopSound">
  879. set(jscall_id,%1);
  880. set(js_command, calc('interfaceObject.stopSound("' + jscall_id + '")'));
  881. jscall(get(js_command));
  882. </action>
  883. <action name="js_toggleBgMusic">
  884. set(js_command, calc('interfaceObject.toggleMusic(' + %1 + ')'));
  885. jscall(get(js_command));
  886. </action>
  887. <action name="js_toggleBgMusicEmbedVideo">
  888. set(js_command, calc('interfaceObject.toggleMusicEmbedVideo(' + %1 + ')'));
  889. jscall(get(js_command));
  890. </action>
  891. <action name="js_toggleBgVoice">
  892. set(js_command, calc('interfaceObject.toggleVoice(' + %1 + ')'));
  893. jscall(get(js_command));
  894. </action>
  895. <action name="js_toggleBgVoiceEmbedVideo">
  896. set(js_command, calc('interfaceObject.toggleVoiceEmbedVideo(' + %1 + ')'));
  897. jscall(get(js_command));
  898. </action>
  899. <action name="js_toggleFullscreen">
  900. if(fullscreen == true,
  901. set(js_command, false);
  902. ,
  903. set(js_command, true);
  904. );
  905. set(js_command, calc('interfaceObject.toggleFullscreen(' + js_command + ')'));
  906. jscall(get(js_command));
  907. </action>
  908. <action name="js_mouseControlChangedCallback">
  909. set(jscall_state,%1);
  910. set(js_command, calc('interfaceObject.mouseControlChangedCallback("' + jscall_state + '")'));
  911. jscall(get(js_command));
  912. </action>
  913. <action name="js_openReport">
  914. set(js_command, calc('interfaceObject.openReport()'));
  915. jscall(get(js_command));
  916. </action>
  917. <action name="js_sendCommand">
  918. set(js_command, 'interfaceObject.sendCommand("%1")');
  919. jscall(get(js_command));
  920. </action>
  921. <action name="js_closeOverlay">
  922. set(js_command, 'interfaceObject.toggleInfo(false)');
  923. jscall(get(js_command));
  924. </action>
  925. <action name="js_App">
  926. if(device.ios,
  927. js_iOS(%1,%2, %3, %4);
  928. );
  929. if(device.android,
  930. js_Android(%1,%2, %3, %4);
  931. );
  932. </action>
  933. <action name="js_Android">
  934. set(command_action, %1);
  935. set(command_arg1, %2);
  936. set(js_command, calc('window.androidInterface.' + command_action + '("' + command_arg1));
  937. if(%3 !== null,
  938. set(command_arg2, %3);
  939. txtadd(js_command, calc('","' + command_arg2));
  940. );
  941. if(%4 !== null,
  942. set(command_arg3, %4);
  943. txtadd(js_command, calc('","' + command_arg3));
  944. );
  945. txtadd(js_command, '")');
  946. jscall(get(js_command));
  947. </action>
  948. <action name="js_iOS">
  949. set(command_action, %1);
  950. set(command_arg1, %2);
  951. set(js_command, calc('window.webkit.messageHandlers.' + command_action + '.postMessage(["' + command_arg1));
  952. if(%3 !== null,
  953. set(command_arg2, %3);
  954. txtadd(js_command, calc('","' + command_arg2));
  955. );
  956. if(%4 !== null,
  957. set(command_arg3, %4);
  958. txtadd(js_command, calc('","' + command_arg3));
  959. );
  960. txtadd(js_command, '"])');
  961. jscall(get(js_command));
  962. </action>
  963. <action name="js_request_gyro_promission">
  964. </action>
  965. <action name="krpSceneChange">
  966. set(sceneChange_id, %1);
  967. set(sceneChange_effect, %2);
  968. set(sceneChange_keepView, %3);
  969. if(sceneChange_id != 's_NaN',
  970. load_pano_by_id(get(sceneChange_id), get(sceneChange_keepView), get(sceneChange_effect));
  971. js_App('krpSceneChange', get(sceneChange_id));
  972. ,
  973. js_toggleLoading(false);
  974. );
  975. </action>
  976. <action name="krpSphereToScreen">
  977. set(tmp_h,%1);
  978. set(tmp_v,%2);
  979. spheretoscreen(tmp_h,tmp_v,tmp_x,tmp_y);
  980. set(js_command, calc('interfaceObject.krpSphereToScreenCb(' + tmp_x + ', ' + tmp_y + ')'));
  981. jscall(get(js_command));
  982. </action>
  983. <action name="krpAddTextHotspot">
  984. add_text_hotspot(%1,%2,%3,%4,%5,%6,%7,%8);
  985. </action>
  986. <action name="krpRemoveTextHotspot">
  987. remove_text_hotspot(%1);
  988. </action>
  989. <action name="krpUpdateTextHotspotColor">
  990. update_text_hotspot_color(%1,%2,%3,%4,%5);
  991. </action>
  992. <action name="krpAddHotspot">
  993. add_hotspot(%1,%2,%3,%4,%5,%6,%7,%8,%9,%10,%11,%12);
  994. </action>
  995. <action name="krpAddPolygonalHotspot">
  996. add_polygon(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10, %11, %12, %13, %14);
  997. </action>
  998. <action name="krpAddComment">
  999. addComment(%1,%2,%3,%4,%5);
  1000. </action>
  1001. <action name="krpToggleComments">
  1002. if(%1 == true,
  1003. showComments();
  1004. ,
  1005. hideComments();
  1006. );
  1007. </action>
  1008. <action name="krpBeginNewComment">
  1009. enterEditComment(%1);
  1010. </action>
  1011. <action name="krpEndNewComment">
  1012. exitEditComment();
  1013. </action>
  1014. <action name="krpUpdateNewComment">
  1015. updateInputComment(%1);
  1016. </action>
  1017. <action name="krpRemoveComments">
  1018. removeComments();
  1019. </action>
  1020. <action name="krpStartAutoTour">
  1021. autoTourStart();
  1022. muted_embed_video();
  1023. </action>
  1024. <action name="krpPauseAutoTour">
  1025. autoTourPause();
  1026. </action>
  1027. <action name="krpResumeAutoTour">
  1028. autoTourResume();
  1029. </action>
  1030. <action name="krpStopAutoTour">
  1031. autoTourEndAction(true);
  1032. </action>
  1033. <action name="krpToggleRadarMap">
  1034. if(%1 == true AND radarIsShow != true,
  1035. toggleRadar()
  1036. );
  1037. if(%1 == false AND radarIsShow == true,
  1038. toggleRadar()
  1039. );
  1040. </action>
  1041. <action name="krpToggleUI">
  1042. if(%1 == true
  1043. show_UI(1);
  1044. ,
  1045. hide_UI(null, 1);
  1046. );
  1047. </action>
  1048. <action name="krpToggleVR">
  1049. js_request_gyro_promission();
  1050. if(%1 == true,
  1051. turn_on_vr();
  1052. pause_embed_video();
  1053. ,
  1054. turn_off_vr();
  1055. resume_embed_video();
  1056. );
  1057. </action>
  1058. <action name="krpChangeViewType">
  1059. change_multi_view(%1);
  1060. </action>
  1061. <action name="krpToggleGyro">
  1062. js_request_gyro_promission();
  1063. if(%1 == true,
  1064. start_gyro();
  1065. ,
  1066. stop_gyro();
  1067. );
  1068. </action>
  1069. <action name="krpToggleHD">
  1070. if(%1 == true,
  1071. switch_to_multires();
  1072. ,
  1073. switch_to_mobile();
  1074. );
  1075. </action>
  1076. <action name="krpToggleCopyright">
  1077. set(contextmenu.item["copyright"].visible, %1);
  1078. </action>
  1079. <action name="krpToggleAgreement">
  1080. set(contextmenu.item["ccagreement"].visible, true);
  1081. </action>
  1082. <action name="krpToggleAutoPlay">
  1083. if(config.panos.pano[get(scene_name)].autoplay.enabled == 1,
  1084. if(%1 == true,
  1085. resume_autoplay();
  1086. ,
  1087. pause_autoplay();
  1088. );
  1089. );
  1090. </action>
  1091. <action name="krpResetAutoPlay">
  1092. set(autorotate.enabled, %1);
  1093. set(autorotate.accel,10);
  1094. set(autorotate.waittime, 0);
  1095. if(%2 !== null,
  1096. set(temp_speed,360.0);
  1097. div(temp_speed, %2);
  1098. copy(autorotate.speed, temp_speed);
  1099. );
  1100. </action>
  1101. <action name="krpLookTo">
  1102. set(targetHLookAt, %1);
  1103. set(targetVLookAt, %2);
  1104. set(targetFov, %3);
  1105. set(lookToType, %4);
  1106. if(lookToType == 1,
  1107. lookto(get(view.hlookat),get(view.vlookat),120,smooth(720,-720,720), true, true,
  1108. lookto(get(targetHLookAt),get(targetVLookAt),120,smooth(720,-720,720), true, true,
  1109. lookto(get(targetHLookAt),get(targetVLookAt), get(targetFov));
  1110. );
  1111. );
  1112. ,
  1113. lookto(get(targetHLookAt),get(targetVLookAt), get(targetFov));
  1114. );
  1115. </action>
  1116. <action name="krpMutedEmbedVideo">
  1117. muted_embed_video();
  1118. </action>
  1119. <action name="krpUnmutedEmbedVideo">
  1120. unmuted_embed_video();
  1121. </action>
  1122. <action name="krpPauseEmbedVideo">
  1123. pause_embed_video();
  1124. </action>
  1125. <action name="krpResumeEmbedVideo">
  1126. resume_embed_video();
  1127. </action>
  1128. <action name="krpOverlayDidShowCallback">
  1129. if(%1 == VIDEO_MODAL OR %1 == MIX_MODAL OR %1 == ARTICLE_MODAL,
  1130. if(hotspot[get(embed_video_name)].ispaused == false,
  1131. pause_embed_video();
  1132. );
  1133. );
  1134. </action>
  1135. <action name="krpOverlayDidHideCallback">
  1136. if(%1 == VIDEO_MODAL OR %1 == MIX_MODAL OR %1 == ARTICLE_MODAL,
  1137. if(hotspot[get(embed_video_name)].ispaused == true AND hotspot[get(embed_video_name)].need_resume == true,
  1138. resume_embed_video();
  1139. );
  1140. );
  1141. js_App('krpOverlayDidHide',true);
  1142. </action>
  1143. <action name="krpHotspotMusicStopedCallback">
  1144. unmuted_embed_video();
  1145. </action>
  1146. <action name="krpChangeMouseControl">
  1147. if(%1 == 'moveto',
  1148. set(control.mouse, 'moveto');
  1149. set(contextmenu.item['controldrag'].visible,false);
  1150. set(contextmenu.item['controlmoveto'].visible,true);
  1151. );
  1152. if(%1 == 'drag',
  1153. set(control.mouse, 'drag');
  1154. set(contextmenu.item['controldrag'].visible,true);
  1155. set(contextmenu.item['controlmoveto'].visible,false);
  1156. );
  1157. </action>
  1158. <action name="krpAddBottomMask">
  1159. add_bottom_mask(%1, %2);
  1160. </action>
  1161. <action name="krpSetLanguage">
  1162. if(%1 == 'en',
  1163. set(contextmenu.item['fullscreen'].caption, 'Toggle Fullscreen');
  1164. set(contextmenu.item['viewtype'].caption, 'View type');
  1165. set(contextmenu.item['controlmoveto'].caption, 'Switch to MoveTo');
  1166. set(contextmenu.item['controldrag'].caption, 'Switch to Drag');
  1167. set(contextmenu.item['openReport'].caption, 'Report');
  1168. set(layer[webvr_exitbutton].html, 'Exit VR');
  1169. set(layer[webvr_setupbutton].html, 'VR Setup');
  1170. set(mobilevr_presets.headset["nodt"].caption,'No Distortion');
  1171. set(webvr_text_noDistortion, 'No Distortion');
  1172. set(webvr_text_webvrSetup, 'WebVR Setup');
  1173. set(webvr_text_mobilevrSetup, 'MobileVR Setup');
  1174. set(webvr_text_screensize, 'Screensize (inch):');
  1175. set(webvr_text_vrheadset, 'VR Headset Preset:');
  1176. set(webvr_text_customizeHeadset, 'Customize Headset');
  1177. set(webvr_text_adjustmentInVR, 'Interactive Adjustment in VR');
  1178. set(webvr_text_close, 'CLOSE');
  1179. set(webvr_text_preset, 'Preset:');
  1180. set(webvr_text_fov, 'Lens-Field-of-View:');
  1181. set(webvr_text_interLensDistance, 'Inter-Lens-Distance(mm):');
  1182. set(webvr_text_screenToLensDistance, 'Screen-toLens-Distance(mm):');
  1183. set(webvr_text_trayToLensCenterDistance, 'Tray-to-Lens-Center-Distance(mm):');
  1184. set(webvr_text_lensDistortion, 'Lens-Distortion Coefficients:');
  1185. set(webvr_text_oversampling, 'Oversampling:');
  1186. );
  1187. if(%1 == 'cn',
  1188. set(contextmenu.item['fullscreen'].caption, '全屏切换');
  1189. set(contextmenu.item['viewtype'].caption, '视角切换');
  1190. set(contextmenu.item['controlmoveto'].caption, '切换拖拽方式为正向');
  1191. set(contextmenu.item['controldrag'].caption, '切换拖拽方式为反向');
  1192. set(contextmenu.item['openReport'].caption, '举报');
  1193. set(layer[webvr_exitbutton].html, '退出 VR');
  1194. set(layer[webvr_setupbutton].html, 'VR 设置');
  1195. set(mobilevr_presets.headset["nodt"].caption,'无畸变');
  1196. set(webvr_text_noDistortion, '无畸变');
  1197. set(webvr_text_webvrSetup, 'WebVR 设置');
  1198. set(webvr_text_mobilevrSetup, 'MobileVR 设置');
  1199. set(webvr_text_screensize, '屏幕尺寸(英寸):');
  1200. set(webvr_text_vrheadset, 'VR 头显预设');
  1201. set(webvr_text_customizeHeadset, '自定义头显');
  1202. set(webvr_text_adjustmentInVR, '在 VR 中进行调整');
  1203. set(webvr_text_close, '关闭');
  1204. set(webvr_text_preset, '预设:');
  1205. set(webvr_text_fov, 'FOV');
  1206. set(webvr_text_interLensDistance, '内镜距离(mm):');
  1207. set(webvr_text_screenToLensDistance, '屏幕到镜头距离(mm):');
  1208. set(webvr_text_trayToLensCenterDistance, '头显到镜头中央的距离(mm):');
  1209. set(webvr_text_lensDistortion, '镜头畸变系数:');
  1210. set(webvr_text_oversampling, '过采样:');
  1211. );
  1212. </action>
  1213. <action name="krpEnterMarkMode">
  1214. set(useMarkMode, true);
  1215. </action>
  1216. <action name="krpExitMarkMode">
  1217. set(useMarkMode, false);
  1218. </action>
  1219. <action name="krpAddSelfMark">
  1220. krpAddMark(%1,%2,get(daikanAvatar),get(daikanNickname));
  1221. </action>
  1222. <action name="krpAddMark">
  1223. set(flag_name, '_flagImage');
  1224. txtadd(flag_name, get(timertick));
  1225. addhotspot(get(flag_name));
  1226. set(hotspot[get(flag_name)].alpha, 1);
  1227. set(hotspot[get(flag_name)].ath,%1);
  1228. set(hotspot[get(flag_name)].atv,%2);
  1229. set(hotspot[get(flag_name)].edge,center);
  1230. set(hotspot[get(flag_name)].width,40);
  1231. set(hotspot[get(flag_name)].height,40);
  1232. set(hotspot[get(flag_name)].roundedge,20);
  1233. set(avatarURL, %3);
  1234. if(avatarURL === null || avatarURL == '',
  1235. delete(avatarURL);
  1236. );
  1237. set(avatarNickname, %4);
  1238. if(avatarNickname === null || avatarNickname == '',
  1239. delete(avatarNickname);
  1240. );
  1241. if(avatarURL === null AND avatarNickname !== null,
  1242. set(hotspot[get(flag_name)].url,get(plugin_url.TEXT_SWF));
  1243. copy(hotspot[get(flag_name)].html, avatarNickname);
  1244. set(hotspot[get(flag_name)].backgroundcolor,0x000000);
  1245. set(hotspot[get(flag_name)].backgroundalpha,0.6);
  1246. set(hotspot[get(flag_name)].css, 'text-align:center; line-height: 36px; font-size:12px; color:#FFFFFF;');
  1247. );
  1248. if(avatarURL !== null,
  1249. copy(hotspot[get(flag_name)].url,avatarURL);
  1250. );
  1251. set(hotspot[get(flag_name)].onloaded,
  1252. delayedcall(0.5,
  1253. tween(hotspot[get(name)].alpha, 0, 0.5, easeOutQuad,
  1254. removehotspot(get(name));
  1255. );
  1256. );
  1257. );
  1258. </action>
  1259. <action name="krpRemoveMark">
  1260. set(flag_name, '_flagImage');
  1261. removehotspot(get(flag_name));
  1262. </action>
  1263. <action name="krpAddContextMenu">
  1264. set(menuURL, %2);
  1265. if(add_content_menu_count === null,
  1266. set(add_content_menu_count,1);
  1267. set(contextmenu.item[custom1].visible, true);
  1268. set(contextmenu.item[custom1].caption, %1);
  1269. if(menuURL != "" AND menuURL !== null,
  1270. set(contextmenu.item[custom1].url, get(menuURL));
  1271. set(contextmenu.item[custom1].enabled, true);
  1272. ,
  1273. set(contextmenu.item[custom1].enabled, true);
  1274. set(contextmenu.item[custom1].onclick, );
  1275. );
  1276. ,
  1277. if(add_content_menu_count == 1,
  1278. inc(add_content_menu_count);
  1279. set(contextmenu.item[custom2].visible, true);
  1280. set(contextmenu.item[custom2].caption, %1);
  1281. if(menuURL != "" AND menuURL !== null,
  1282. set(contextmenu.item[custom2].url, get(menuURL));
  1283. set(contextmenu.item[custom2].enabled, true);
  1284. ,
  1285. set(contextmenu.item[custom2].enabled, true);
  1286. set(contextmenu.item[custom2].onclick, );
  1287. );
  1288. ,
  1289. if(add_content_menu_count == 2,
  1290. inc(add_content_menu_count);
  1291. set(contextmenu.item[custom3].visible, true);
  1292. set(contextmenu.item[custom3].caption, %1);
  1293. if(menuURL != "" AND menuURL !== null,
  1294. set(contextmenu.item[custom3].url, get(menuURL));
  1295. set(contextmenu.item[custom3].enabled, true);
  1296. ,
  1297. set(contextmenu.item[custom3].enabled, true);
  1298. set(contextmenu.item[custom3].onclick, );
  1299. );
  1300. );
  1301. );
  1302. );
  1303. </action>
  1304. <action name="startup" autorun="onstart">
  1305. setup_startup_vars();
  1306. js_playerReadyCallback();
  1307. </action>
  1308. <action name="setup_startup_vars">
  1309. if(device.mobile,
  1310. set(customScale, 1);
  1311. if(stagewidth LT stageheight,
  1312. div(customScale, stagewidth,540);
  1313. ,
  1314. div(customScale, stageheight,360);
  1315. );
  1316. if(customScale LT 0.5,
  1317. set(customScale,0.7);
  1318. );
  1319. if(customScale GT 0.8,
  1320. set(customScale, 0.75);
  1321. );
  1322. copy(stagescale,customScale);
  1323. );
  1324. set(display.autofullscreen, false);
  1325. if((sceneType == 1 OR sceneType == 3) AND (config.panos.pano[get(scene_name)].radar.enabled == 1 OR config.panos.pano[get(scene_name)].radar.enable == 1),
  1326. set(radarEnabled, true);
  1327. );
  1328. set(view_type,0);
  1329. if(sceneType == 2,
  1330. set(enableLittleplanet, 0);
  1331. hide_UI(0,1);
  1332. );
  1333. if(sceneType == 3,
  1334. );
  1335. if(sceneType == 4,
  1336. hide_UI(0,1);
  1337. );
  1338. setup_hotspot();
  1339. set(events.onpreviewcomplete,on_preview_complete());
  1340. set(events.onloadcomplete,on_load_complete());
  1341. </action>
  1342. <action name="setup_start_pano">
  1343. set(view.fovtype, MFOV);
  1344. if(enableLittleplanet != 0,
  1345. setup_littleplanet_view();
  1346. );
  1347. </action>
  1348. <action name="on_load_complete">
  1349. if(preview_load_inited != true,
  1350. on_preview_complete(true);
  1351. );
  1352. if(webvr.isenabled,
  1353. delayedcall(2,
  1354. set(have_vr_controllers, false);
  1355. webvr_load_vr_controller_hs();
  1356. );
  1357. );
  1358. </action>
  1359. <action name="on_preview_complete">
  1360. if(xml.scene !== null,
  1361. js_toggleLoading(false);
  1362. set(preview_load_inited, true);
  1363. if(enableLittleplanet != 0 AND %1 === null,
  1364. setup_weather();
  1365. setup_littleplanet();
  1366. delayedcall(0.2,
  1367. setup_bottom_mask();
  1368. );
  1369. ,
  1370. if(xml.scene === null,
  1371. delayedcall(0.2,
  1372. setup_pano_settings();
  1373. if(settings.first_pano_inited == false,
  1374. setup_global_settings();
  1375. );
  1376. js_sceneReadyCallback();
  1377. setup_autoplay();
  1378. );
  1379. ,
  1380. setup_pano_settings();
  1381. if(settings.first_pano_inited == false,
  1382. setup_global_settings();
  1383. );
  1384. js_sceneReadyCallback();
  1385. setup_autoplay();
  1386. );
  1387. );
  1388. if(isAutoTouring AND isAutoTourPause == false,
  1389. pause_autoplay();
  1390. delayedcall(0.5,autoTourPlay(););
  1391. );
  1392. if(webvr.isenabled,
  1393. hide_UI();
  1394. );
  1395. );
  1396. </action>
  1397. <action name="setup_pano_settings">
  1398. setup_top_mask();
  1399. setup_contextmenu();
  1400. setup_view();
  1401. if(is_clean != 1,
  1402. setup_embed();
  1403. if(enableLittleplanet == 0,
  1404. setup_bottom_mask();
  1405. setup_weather();
  1406. );
  1407. if(isAutoTouring == true,
  1408. hide_UI();
  1409. );
  1410. ,
  1411. if(enableLittleplanet == 0,
  1412. setup_bottom_mask();
  1413. setup_weather();
  1414. );
  1415. );
  1416. </action>
  1417. <action name="setup_global_settings">
  1418. delayedcall(0.5,
  1419. setup_gyro();
  1420. setup_vr();
  1421. setup_autotour();
  1422. set(settings.first_pano_inited, true);
  1423. set(enableLittleplanet, 0);
  1424. );
  1425. </action>
  1426. <action name="change_multi_view">
  1427. set(view_type,%1);
  1428. if(view_type_changing != true,
  1429. set(view_type_changing,true);
  1430. if(%1 == 4,
  1431. skin_view_flat();
  1432. );
  1433. if(%1 == 3,
  1434. skin_view_ball();
  1435. ,
  1436. if(%1 == 2,
  1437. skin_view_fisheye();
  1438. ,
  1439. if(%1 == 1,
  1440. cm_littleplanet_view();
  1441. ,
  1442. cm_normal_view();
  1443. );
  1444. );
  1445. );
  1446. delete(multi_view_type);
  1447. ,
  1448. set(multi_view_type,%1);
  1449. );
  1450. </action>
  1451. <action name="cancel_view_limit">
  1452. set(view.limitview, off);
  1453. set(view.fovmin, 1);
  1454. set(view.fovmax, 179);
  1455. </action>
  1456. <action name="recover_view_limit">
  1457. set(control.bouncinglimits, true);
  1458. if(config.panos.pano[get(scene_name)].view.vlookatmin != -90 OR config.panos.pano[get(scene_name)].view.vlookatmax != 90,
  1459. set(view.limitview, lookat);
  1460. copy(view.vlookatmin, config.panos.pano[get(scene_name)].view.vlookatmin);
  1461. copy(view.vlookatmax, config.panos.pano[get(scene_name)].view.vlookatmax);
  1462. set(control.bouncinglimits, false);
  1463. );
  1464. if((config.panos.pano[get(scene_name)].view.hlookatmin != -180 AND config.panos.pano[get(scene_name)].view.hlookatmin !== null) OR (config.panos.pano[get(scene_name)].view.hlookatmax != 180 AND config.panos.pano[get(scene_name)].view.hlookatmax !== null),
  1465. set(view.limitview, lookat);
  1466. copy(view.hlookatmin, config.panos.pano[get(scene_name)].view.hlookatmin);
  1467. copy(view.hlookatmax, config.panos.pano[get(scene_name)].view.hlookatmax);
  1468. set(control.bouncinglimits, false);
  1469. );
  1470. if(config.panos.pano[get(scene_name)].view.fovmin == "" OR config.panos.pano[get(scene_name)].view.fovmin === null,
  1471. set(config.panos.pano[get(scene_name)].view.fovmin,70);
  1472. );
  1473. copy(view.fovmin, config.panos.pano[get(scene_name)].view.fovmin);
  1474. if(config.panos.pano[get(scene_name)].view.fovmax == "" OR config.panos.pano[get(scene_name)].view.fovmax === null,
  1475. set(config.panos.pano[get(scene_name)].view.fovmax,120);
  1476. );
  1477. copy(view.fovmax, config.panos.pano[get(scene_name)].view.fovmax);
  1478. if(config.panos.pano[get(scene_name)].view.vlookatmin !== null AND config.panos.pano[get(scene_name)].view.vlookatmin != "",
  1479. copy(view.vlookatmin, config.panos.pano[get(scene_name)].view.vlookatmin);
  1480. );
  1481. if(config.panos.pano[get(scene_name)].view.vlookatmax !== null AND config.panos.pano[get(scene_name)].view.vlookatmax != "",
  1482. copy(view.vlookatmax, config.panos.pano[get(scene_name)].view.vlookatmax);
  1483. );
  1484. if(config.panos.pano[get(scene_name)].view.hlookatmin !== null AND config.panos.pano[get(scene_name)].view.hlookatmin != "",
  1485. copy(view.hlookatmin, config.panos.pano[get(scene_name)].view.hlookatmin);
  1486. );
  1487. if(config.panos.pano[get(scene_name)].view.hlookatmax !== null AND config.panos.pano[get(scene_name)].view.hlookatmax != "",
  1488. copy(view.hlookatmax, config.panos.pano[get(scene_name)].view.hlookatmax);
  1489. );
  1490. copy(view.limitview, viewLimitState);
  1491. </action>
  1492. <action name="setup_view">
  1493. if(forceFov !== null,
  1494. copy(view.hlookat, config.panos.pano[get(scene_name)].view.hlookat);
  1495. copy(view.vlookat, config.panos.pano[get(scene_name)].view.vlookat);
  1496. copy(view.fov, forceFov);
  1497. copy(view.fovmin, forceFovmin);
  1498. copy(view.fovmax, forceFovmax);
  1499. ,
  1500. if((view_type == 0 OR view_type === null) AND webvr.isenabled != true AND isAutoTouring != true,
  1501. copy(view.hlookat, config.panos.pano[get(scene_name)].view.hlookat);
  1502. copy(view.vlookat, config.panos.pano[get(scene_name)].view.vlookat);
  1503. set(control.bouncinglimits, true);
  1504. if(config.panos.pano[get(scene_name)].view.vlookatmin != -90 OR config.panos.pano[get(scene_name)].view.vlookatmax != 90,
  1505. set(view.limitview, lookat);
  1506. copy(view.vlookatmin, config.panos.pano[get(scene_name)].view.vlookatmin);
  1507. copy(view.vlookatmax, config.panos.pano[get(scene_name)].view.vlookatmax);
  1508. set(control.bouncinglimits, false);
  1509. );
  1510. if((config.panos.pano[get(scene_name)].view.hlookatmin != -180 AND config.panos.pano[get(scene_name)].view.hlookatmin !== null) OR (config.panos.pano[get(scene_name)].view.hlookatmax != 180 AND config.panos.pano[get(scene_name)].view.hlookatmax !== null),
  1511. set(view.limitview, lookat);
  1512. copy(view.hlookatmin, config.panos.pano[get(scene_name)].view.hlookatmin);
  1513. copy(view.hlookatmax, config.panos.pano[get(scene_name)].view.hlookatmax);
  1514. set(control.bouncinglimits, false);
  1515. );
  1516. if(config.panos.pano[get(scene_name)].view.fovmin == "" OR config.panos.pano[get(scene_name)].view.fovmin === null,
  1517. set(config.panos.pano[get(scene_name)].view.fovmin,70);
  1518. );
  1519. copy(view.fovmin, config.panos.pano[get(scene_name)].view.fovmin);
  1520. if(config.panos.pano[get(scene_name)].view.fovmax == "" OR config.panos.pano[get(scene_name)].view.fovmax === null,
  1521. set(config.panos.pano[get(scene_name)].view.fovmax,120);
  1522. );
  1523. copy(view.fovmax, config.panos.pano[get(scene_name)].view.fovmax);
  1524. if(config.panos.pano[get(scene_name)].view.fov != 0 AND config.panos.pano[get(scene_name)].view.fov != "" AND config.panos.pano[get(scene_name)].view.fov !== null,
  1525. copy(view.fov, config.panos.pano[get(scene_name)].view.fov);
  1526. ,
  1527. set(view.fov, 95);
  1528. );
  1529. if(config.panos.pano[get(scene_name)].view.vlookatmin !== null AND config.panos.pano[get(scene_name)].view.vlookatmin != "",
  1530. copy(view.vlookatmin, config.panos.pano[get(scene_name)].view.vlookatmin);
  1531. );
  1532. if(config.panos.pano[get(scene_name)].view.vlookatmax !== null AND config.panos.pano[get(scene_name)].view.vlookatmax != "",
  1533. copy(view.vlookatmax, config.panos.pano[get(scene_name)].view.vlookatmax);
  1534. );
  1535. if(config.panos.pano[get(scene_name)].view.hlookatmin !== null AND config.panos.pano[get(scene_name)].view.hlookatmin != "",
  1536. copy(view.hlookatmin, config.panos.pano[get(scene_name)].view.hlookatmin);
  1537. );
  1538. if(config.panos.pano[get(scene_name)].view.hlookatmax !== null AND config.panos.pano[get(scene_name)].view.hlookatmax != "",
  1539. copy(view.hlookatmax, config.panos.pano[get(scene_name)].view.hlookatmax);
  1540. );
  1541. if(needKeepview == true,
  1542. copy(view.hlookat, needKeepviewHlookat);
  1543. copy(view.vlookat, needKeepviewVlookat);
  1544. copy(view.fov, needKeepviewFov);
  1545. );
  1546. );
  1547. );
  1548. </action>
  1549. <action name="setup_view_limit">
  1550. set(control.bouncinglimits, true);
  1551. if(config.panos.pano[get(scene_name)].view.vlookatmin != -90 OR config.panos.pano[get(scene_name)].view.vlookatmax != 90,
  1552. set(view.limitview, lookat);
  1553. copy(view.vlookatmin, config.panos.pano[get(scene_name)].view.vlookatmin);
  1554. copy(view.vlookatmax, config.panos.pano[get(scene_name)].view.vlookatmax);
  1555. set(control.bouncinglimits, false);
  1556. );
  1557. if((config.panos.pano[get(scene_name)].view.hlookatmin != -180 AND config.panos.pano[get(scene_name)].view.hlookatmin !== null) OR (config.panos.pano[get(scene_name)].view.hlookatmax != 180 AND config.panos.pano[get(scene_name)].view.hlookatmax !== null),
  1558. set(view.limitview, lookat);
  1559. copy(view.hlookatmin, config.panos.pano[get(scene_name)].view.hlookatmin);
  1560. copy(view.hlookatmax, config.panos.pano[get(scene_name)].view.hlookatmax);
  1561. set(control.bouncinglimits, false);
  1562. );
  1563. if(config.panos.pano[get(scene_name)].view.fovmin == "" OR config.panos.pano[get(scene_name)].view.fovmin === null,
  1564. set(config.panos.pano[get(scene_name)].view.fovmin,70);
  1565. );
  1566. copy(view.fovmin, config.panos.pano[get(scene_name)].view.fovmin);
  1567. if(config.panos.pano[get(scene_name)].view.fovmax == "" OR config.panos.pano[get(scene_name)].view.fovmax === null,
  1568. set(config.panos.pano[get(scene_name)].view.fovmax,120);
  1569. );
  1570. copy(view.fovmax, config.panos.pano[get(scene_name)].view.fovmax);
  1571. if(config.panos.pano[get(scene_name)].view.vlookatmin !== null AND config.panos.pano[get(scene_name)].view.vlookatmin != "",
  1572. copy(view.vlookatmin, config.panos.pano[get(scene_name)].view.vlookatmin);
  1573. );
  1574. if(config.panos.pano[get(scene_name)].view.vlookatmax !== null AND config.panos.pano[get(scene_name)].view.vlookatmax != "",
  1575. copy(view.vlookatmax, config.panos.pano[get(scene_name)].view.vlookatmax);
  1576. );
  1577. if(config.panos.pano[get(scene_name)].view.hlookatmin !== null AND config.panos.pano[get(scene_name)].view.hlookatmin != "",
  1578. copy(view.hlookatmin, config.panos.pano[get(scene_name)].view.hlookatmin);
  1579. );
  1580. if(config.panos.pano[get(scene_name)].view.hlookatmax !== null AND config.panos.pano[get(scene_name)].view.hlookatmax != "",
  1581. copy(view.hlookatmax, config.panos.pano[get(scene_name)].view.hlookatmax);
  1582. );
  1583. </action>
  1584. <action name="skin_view_look_straight">
  1585. set(view.fovmax, get(config.panos.pano[get(scene_name)].view.fovmax));
  1586. set(view.fovmin, get(config.panos.pano[get(scene_name)].view.fovmin));
  1587. set(view.limitview,auto);
  1588. </action>
  1589. <action name="cm_normal_view">
  1590. tween(view.architectural, 0.0, 0.5);
  1591. tween(view.pannini, 0.0, 0.5);
  1592. tween(view.fisheye, 0.0, 0.5);
  1593. tween(view.fov, get(config.panos.pano[get(scene_name)].view.fov), 0.5);
  1594. tween(view.vlookat, get(config.panos.pano[get(scene_name)].view.vlookat), 0.5,easeOutQuad,
  1595. skin_view_look_straight();
  1596. set(view_type_changing,false);
  1597. if(multi_view_type !== null,
  1598. delayedcall(0.1,change_multi_view(multi_view_type));
  1599. ,
  1600. setup_view_limit();
  1601. );
  1602. );
  1603. </action>
  1604. <action name="skin_view_fisheye">
  1605. tween(view.architectural, 0.0, distance(1.0,0.5));
  1606. tween(view.pannini, 0.0, distance(1.0,0.5));
  1607. tween(view.fisheye, 1.0, distance(1.0,0.5));
  1608. tween(view.vlookat, get(config.panos.pano[get(scene_name)].view.vlookat), 0.5);
  1609. tween(view.fov, 115, 0.5);
  1610. tween(view.distortion, 1.0, distance(1.0,0.5),easeOutQuad,
  1611. skin_view_look_straight();
  1612. set(view_type_changing,false);
  1613. if(multi_view_type !== null,
  1614. delayedcall(0.1,change_multi_view(multi_view_type));
  1615. );
  1616. );
  1617. </action>
  1618. <action name="skin_view_ball">
  1619. tween(view.architectural, 0.0, distance(1.0,0.5));
  1620. tween(view.pannini, 0.0, distance(1.0,0.5));
  1621. tween(view.distortion, 2.8, distance(1.0,0.5),easeOutQuad,
  1622. skin_view_look_straight();
  1623. set(view_type_changing,false);
  1624. if(multi_view_type !== null,
  1625. delayedcall(0.1,change_multi_view(multi_view_type));
  1626. );
  1627. );
  1628. </action>
  1629. <action name="skin_view_architectural">
  1630. skin_view_look_straight();
  1631. tween(view.architectural, 1.0, distance(1.0,0.5));
  1632. tween(view.pannini, 0.0, distance(1.0,0.5));
  1633. tween(view.distortion, 0.0, distance(1.0,0.5));
  1634. </action>
  1635. <action name="skin_view_stereographic">
  1636. skin_view_look_straight();
  1637. tween(view.architectural, 0.0, distance(1.0,0.5));
  1638. tween(view.pannini, 0.0, distance(1.0,0.5));
  1639. tween(view.distortion, 1.0, distance(1.0,0.8));
  1640. </action>
  1641. <action name="skin_view_pannini">
  1642. skin_view_look_straight();
  1643. tween(view.architectural, 0.0, distance(1.0,0.5));
  1644. tween(view.pannini, 1.0, distance(1.0,0.8));
  1645. if(view.distortion LT 0.1,
  1646. tween(view.distortion, 1.0, distance(1.0,0.8));
  1647. );
  1648. </action>
  1649. <action name="cm_littleplanet_view">
  1650. tween(view.architectural, 0.0, 0.25);
  1651. tween(view.vlookat, 90, distance(179, 1.50), easeoutquad);
  1652. set(backtonormalfirst,false);
  1653. if(view.pannini == true, set(backtonormalfirst,true) );
  1654. if(view.stereographic == false, set(backtonormalfirst,true) );
  1655. if(backtonormalfirst, tween(view.fisheye, 0.0 ,distance(1.0, 0.25), easeoutquad, WAIT); );
  1656. set(view.pannini, false);
  1657. set(view.stereographic, true);
  1658. set(view.fovmax, 150);
  1659. tween(view.fov, 150, distance(179, 0.75),easeoutquad);
  1660. tween(view.fisheye, 1.0, distance(1.0, 0.75), easeoutquad,
  1661. set(view_type_changing,false);
  1662. if(multi_view_type !== null,
  1663. delayedcall(0.1,change_multi_view(multi_view_type));
  1664. );
  1665. );
  1666. </action>
  1667. <action name="skin_view_flat">
  1668. set(plugin[skin_gyro].enabled, false);
  1669. skin_update_view_menu(1);
  1670. if(videointerface_isflat !== true,
  1671. set(videointerface_isflat, true);
  1672. stoptween(view.fov);
  1673. mod(view.hlookat, 360);
  1674. set(view.limitview, off);
  1675. set(view.maxpixelzoom, 0);
  1676. copy(videointerface_backup_fovmin, view.fovmin);
  1677. set(view.fovmin, 0.01);
  1678. set(control.usercontrol, off);
  1679. copy(videointerface_backup_mouse, control.mouse);
  1680. set(control.mouse, drag);
  1681. copy(current_fov, view.fov);
  1682. copy(videointerface_backup_fovtype, view.fovtype);
  1683. remapfovtype(current_fov, get(view.fovtype), HFOV);
  1684. set(view.fovtype, HFOV);
  1685. copy(view.fov, current_fov);
  1686. copy(startfov, current_fov);
  1687. copy(image_hfov, image.hfov);
  1688. tween(image_hfov, 1.0, 3.0, linear,
  1689. set(control.usercontrol,all);
  1690. set(view.fovmin, 0.25);
  1691. set(view.hlookatmin, -2);
  1692. set(view.hlookatmax, +2);
  1693. set(view.vlookatmin, -1);
  1694. set(view.vlookatmax, +1);
  1695. set(view.limitview, range);
  1696. ,
  1697. if(image_hfov LT 90,
  1698. mul(view.fov, image_hfov, 1.1);
  1699. ,
  1700. sub(hr, image_hfov, 90);
  1701. div(hr, 270);
  1702. sub(hr2, 1, hr);
  1703. mul(a, startfov, hr);
  1704. mul(b, 99, hr2);
  1705. add(view.fov, a,b);
  1706. );
  1707. copy(image.hfov, image_hfov);
  1708. set(image.vfov, 0);
  1709. updateobject(true, true);
  1710. if(multi_view_type !== null,
  1711. delayedcall(0.1,change_multi_view(multi_view_type));
  1712. );
  1713. );
  1714. adjusthlookat(0);
  1715. tween(view.hlookat, 0, 1.5);
  1716. tween(view.vlookat, 0, 1.5);
  1717. );
  1718. </action>
  1719. <action name="setup_autoplay">
  1720. if(config.panos.pano[get(scene_name)].autoplay.enabled == 1 OR forceAutoplay == 1,
  1721. set(autorotate.waittime, 6);
  1722. set(autorotate.accel, 0);
  1723. if(config.panos.pano[get(scene_name)].autoplay.duration !== null,
  1724. set(temp_speed,360.0);
  1725. div(temp_speed,config.panos.pano[get(scene_name)].autoplay.duration);
  1726. copy(autorotate.speed, temp_speed);
  1727. ,
  1728. set(autorotate.speed, 2);
  1729. );
  1730. set(autorotate.accel,10);
  1731. set(autorotate.enabled, true);
  1732. if(config.panos.pano[get(scene_name)].view.autorotatekeepview == 1,
  1733. set(autorotate.horizon, 'off');
  1734. ,
  1735. set(autorotate.horizon, 0.0);
  1736. );
  1737. if(config.panos.pano[get(scene_name)].autoplay.keep_originview == 1,
  1738. copy(autorotate.horizon, config.panos.pano[get(scene_name)].view.vlookat);
  1739. ,
  1740. set(autorotate.horizon, 0.0);
  1741. );
  1742. set(hlookatmax, get(config.panos.pano[get(scene_name)].view.hlookatmax));
  1743. set(hlookatmin, get(config.panos.pano[get(scene_name)].view.hlookatmin));
  1744. sub(range,hlookatmax,hlookatmin);
  1745. set(autorotate.oneroundrange, get(range));
  1746. if(autoplayWaitPause,
  1747. delayedcall(0.5,
  1748. pause_autoplay();
  1749. set(autoplayWaitPause,false);
  1750. );
  1751. );
  1752. );
  1753. </action>
  1754. <action name="resume_autoplay">
  1755. set(autoplayWaitPause,false);
  1756. if(isAutoTouring != true AND config.panos.pano[get(scene_name)].autoplay.enabled == 1 OR forceAutoplay == 1,
  1757. set(autorotate.enabled, true);
  1758. autorotate.interrupt();
  1759. );
  1760. </action>
  1761. <action name="pause_autoplay">
  1762. set(autoplayWaitPause,true);
  1763. set(autorotate.enabled, false);
  1764. </action>
  1765. <action name="load_pano_loop">
  1766. if(is_looping != true AND config.panos.pano[get(scene_name)].autoplay.enter_next != 0 AND isAutoTouring != true,
  1767. set(loop_flag,false);
  1768. set(js_command, calc('interfaceObject.switchToNextScene("' + config.panos.pano[get(scene_name)].autoplay.hiddenscene_noenter + '")'));
  1769. jscall(get(js_command));
  1770. delayedcall(1,
  1771. set(is_looping,false);
  1772. );
  1773. );
  1774. </action>
  1775. <action name="setup_autotour">
  1776. if(config.autoTours.tour.point.count GT 0 ,
  1777. set(autoTourPointIndex,0);
  1778. js_toggleAutoTourUI(true);
  1779. addplugin(soundinterface);
  1780. if(device.html5 == true ,
  1781. copy(plugin[soundinterface].url,plugin_url.SOUND_JS);
  1782. if(device.ios,
  1783. if(plugin[soundinterface].loaded,
  1784. set(autoTourSoundName,'auto_tour_sound_id');
  1785. playsound(get(autoTourSoundName),get(settings.blank_music_url),1);
  1786. ,
  1787. set(plugin[soundinterface].onloaded,
  1788. set(autoTourSoundName,'auto_tour_sound_id');
  1789. playsound(get(autoTourSoundName),get(settings.blank_music_url),1);
  1790. );
  1791. );
  1792. );
  1793. ,
  1794. copy(plugin[soundinterface].url,plugin_url.SOUND_SWF);
  1795. );
  1796. set(plugin[soundinterface].preload,true);
  1797. if(config.autoTours.tour.startImage !== null AND config.autoTours.tour.startImage != "" ,
  1798. set(autoTourShowButtonDelay,4);
  1799. ,
  1800. set(autoTourShowButtonDelay,0);
  1801. );
  1802. );
  1803. </action>
  1804. <action name="autoTourStart">
  1805. hide_UI();
  1806. cancel_view_limit();
  1807. set(isAutoTourPause,false);
  1808. set(isAutoTouring,true);
  1809. set(autorotateEnabledForAutoTour,get(autorotate.enabled));
  1810. set(usercontrolEnabledForAutoTour,get(control.usercontrol));
  1811. if(config.autoTours.tour.startImage !== null AND config.autoTours.tour.startImage != "" ,
  1812. addlayer(autoTourStartAlert);
  1813. copy(autoTour_startImage,config.autoTours.tour.startImage);
  1814. txtadd(autoTour_startImage,'?imageView2/0/w/2000/h/2000');
  1815. set(layer[autoTourStartAlert].url,get(autoTour_startImage));
  1816. set(layer[autoTourStartAlert].align,center);
  1817. set(layer[autoTourStartAlert].scale,0.5);
  1818. set(layer[autoTourStartAlert].background,false);
  1819. set(layer[autoTourStartAlert].autoalpha,true);
  1820. set(layer[autoTourStartAlert].enable,false);
  1821. set(layer[autoTourStartAlert].y,0);
  1822. set(layer[autoTourStartAlert].keep,true);
  1823. set(layer[autoTourStartAlert].alpha,0.0);
  1824. tween(layer[autoTourStartAlert].alpha,1.0,0.5);
  1825. delayedcall(3,tween(layer[autoTourStartAlert].alpha,0.0,0.5););
  1826. set(hasAutoTourStartAlert,true);
  1827. ,
  1828. set(hasAutoTourStartAlert,false);
  1829. );
  1830. pause_autoplay();
  1831. set(control.usercontrol,off);
  1832. if(%1 != true,
  1833. js_toggleBgVoice(false);
  1834. if(config.autoTours.tour.disableMusic == true,
  1835. js_toggleBgMusic(false);
  1836. );
  1837. );
  1838. if(config.autoTours.tour.hideHotspots == true,
  1839. hide_hotspots();
  1840. copy(auto_tour_comments_state,config.feature.show_comment);
  1841. );
  1842. if(pano_id == config.autoTours.tour.point[get(autoTourPointIndex)].targetPano || scene[get(pano_id)].pano_id == config.autoTours.tour.point[get(autoTourPointIndex)].targetPano,
  1843. set(view.hlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startath));
  1844. set(view.vlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startatv));
  1845. set(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].startfov));
  1846. if(hasAutoTourStartAlert == true ,
  1847. delayedcall(autoTourDelayedCallID, 4,autoTourPlay(););
  1848. set(hasAutoTourStartAlert, null);
  1849. ,
  1850. delayedcall(autoTourDelayedCallID, 1,autoTourPlay(););
  1851. );
  1852. ,
  1853. set(waitAutoTourContinue, true);
  1854. stoptween(view.hlookat,view.vlookat,view.fov);
  1855. if(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode !== null,
  1856. copy(blend_mode,blendmodes[get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode)].blend);
  1857. );
  1858. if(config.autoTours.tour.point[get(autoTourPointIndex)].targetScene !== null AND config.autoTours.tour.point[get(autoTourPointIndex)].targetScene != "",
  1859. set(targetScene, get(scene[get(config.autoTours.tour.point[get(autoTourPointIndex)].targetScene)].scene_id));
  1860. js_sceneChangeCallback(get(targetScene), get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode));
  1861. ,
  1862. js_panoChangeCallback(get(config.autoTours.tour.point[get(autoTourPointIndex)].targetPano), get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode));
  1863. );
  1864. set(view.hlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startath));
  1865. set(view.vlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startatv));
  1866. set(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].startfov));
  1867. );
  1868. </action>
  1869. <action name="autoTourResume">
  1870. set(isAutoTourPause,false);
  1871. dec(autoTourPointIndex);
  1872. set(control.usercontrol,off);
  1873. cancel_view_limit();
  1874. tween(layer[autoTourResumeBtnContainer].alpha,0.0,0.2,default,set(ayer[autoTourResumeBtnContainer].enable.false););
  1875. set(layer[autoTourPauseBtnContainer].enable,false);
  1876. tween(layer[autoTourPauseBtnContainer].alpha,1.0,0.2,default,set(ayer[autoTourPauseBtnContainer].enable.true););
  1877. if(pano_id == config.autoTours.tour.point[get(autoTourPointIndex)].targetScene || scene[get(pano_id)].pano_id == config.autoTours.tour.point[get(autoTourPointIndex)].targetPano,
  1878. set(view.hlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startath));
  1879. set(view.vlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startatv));
  1880. set(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].startfov));
  1881. delayedcall(autoTourDelayedCallID, 1,autoTourPlay(););
  1882. ,
  1883. stoptween(view.hlookat,view.vlookat,view.fov);
  1884. if(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode !== null,
  1885. copy(blend_mode,blendmodes[get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode)].blend);
  1886. );
  1887. if (config.autoTours.tour.point[get(autoTourPointIndex)].targetScene !== null AND config.autoTours.tour.point[get(autoTourPointIndex)].targetScene != "",
  1888. set(targetScene, get(scene[get(config.autoTours.tour.point[get(autoTourPointIndex)].targetScene)].scene_id));
  1889. js_sceneChangeCallback(get(targetScene),get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode));
  1890. ,
  1891. js_panoChangeCallback(get(config.autoTours.tour.point[get(autoTourPointIndex)].targetPano), get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode));
  1892. );
  1893. set(view.hlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startath));
  1894. set(view.vlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startatv));
  1895. set(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].startfov));
  1896. );
  1897. </action>
  1898. <action name="autoTourPlay">
  1899. if(waitAutoTourContinue == true,
  1900. set(view.hlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startath));
  1901. set(view.vlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].startatv));
  1902. set(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].startfov));
  1903. set(waitAutoTourContinue, null);
  1904. if(hasAutoTourStartAlert == true ,
  1905. delayedcall(autoTourDelayedCallID, 4,autoTourPlay(););
  1906. set(hasAutoTourStartAlert, null);
  1907. ,
  1908. delayedcall(autoTourDelayedCallID, 1,autoTourPlay(););
  1909. );
  1910. ,
  1911. copy(preAutoTourSoundName,autoTourSoundName);
  1912. set(layer[autoTourPauseBtnContainer].enable,false);
  1913. tween(layer[autoTourPauseBtnContainer].alpha,1.0,0.2,default,set(ayer[autoTourPauseBtnContainer].enable.true););
  1914. set(layer[autoTourStopBtnContainer].enable,false);
  1915. tween(layer[autoTourStopBtnContainer].alpha,1.0,0.2,default,set(ayer[autoTourStopBtnContainer].enable.true););
  1916. set(autoTourSoundName,'auto_tour_sound_id');
  1917. set(tempAutoTourIndex,get(config.autoTours.tour.point.count));
  1918. dec(tempAutoTourIndex);
  1919. copy(preAutoTourPointIndex,autoTourPointIndex);
  1920. sub(preAutoTourPointIndex,1);
  1921. if(config.autoTours.tour.point[get(autoTourPointIndex)].music != config.autoTours.tour.point[get(preAutoTourPointIndex)].music,
  1922. stopsound(get(preAutoTourSoundName));
  1923. ,
  1924. copy(autoTourSoundName, preAutoTourSoundName);
  1925. );
  1926. if(autoTourPointIndex == tempAutoTourIndex,
  1927. autoTourEnd();
  1928. ,
  1929. if(config.autoTours.tour.point[get(autoTourPointIndex)].playMode == 3,
  1930. copy(tempAutoTourPointIndex,autoTourPointIndex);
  1931. inc(tempAutoTourPointIndex);
  1932. stoptween(view.hlookat,view.vlookat,view.fov);
  1933. if(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode !== null,
  1934. copy(blend_mode,blendmodes[get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode)].blend);
  1935. );
  1936. if (config.autoTours.tour.point[get(tempAutoTourPointIndex)].targetScene !== null AND config.autoTours.tour.point[get(tempAutoTourPointIndex)].targetScene != "",
  1937. set(targetScene, get(scene[get(config.autoTours.tour.point[get(tempAutoTourPointIndex)].targetScene)].scene_id));
  1938. js_sceneChangeCallback(get(targetScene),get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode));
  1939. ,
  1940. js_panoChangeCallback(get(config.autoTours.tour.point[get(tempAutoTourPointIndex)].targetPano), get(config.autoTours.tour.point[get(autoTourPointIndex)].blendMode));
  1941. );
  1942. set(view.hlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].endath));
  1943. set(view.vlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].endatv));
  1944. set(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].endfov));
  1945. inc(autoTourPointIndex);
  1946. ,
  1947. showSubtitle();
  1948. tween(view.hlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].endath),get(config.autoTours.tour.point[get(autoTourPointIndex)].moveTime));
  1949. tween(view.vlookat,get(config.autoTours.tour.point[get(autoTourPointIndex)].endatv),get(config.autoTours.tour.point[get(autoTourPointIndex)].moveTime));
  1950. if(config.autoTours.tour.point[get(autoTourPointIndex)].music !== null AND config.autoTours.tour.point[get(autoTourPointIndex)].music != '',
  1951. if(config.autoTours.tour.point[get(autoTourPointIndex)].playMode == 0,
  1952. set(plugin[soundinterface].volume, get(config.autoTours.tour.point[get(autoTourPointIndex)].volume));
  1953. playsound(get(autoTourSoundName),get(config.autoTours.tour.point[get(autoTourPointIndex)].music),1,autoTourPlay(););
  1954. set(autoTourSoundIsPause, false);
  1955. tween(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].endfov),get(config.autoTours.tour.point[get(autoTourPointIndex)].moveTime));
  1956. ,
  1957. if(config.autoTours.tour.point[get(autoTourPointIndex)].music != config.autoTours.tour.point[get(preAutoTourPointIndex)].music,
  1958. set(plugin[soundinterface].volume, get(config.autoTours.tour.point[get(autoTourPointIndex)].volume));
  1959. playsound(get(autoTourSoundName),get(config.autoTours.tour.point[get(autoTourPointIndex)].music),1);
  1960. ,
  1961. copy(autoTourSoundName,preAutoTourSoundName);
  1962. set(plugin[soundinterface].volume, get(config.autoTours.tour.point[get(autoTourPointIndex)].volume));
  1963. if(autoTourSoundIsPause == true,
  1964. playsound(get(autoTourSoundName),get(config.autoTours.tour.point[get(autoTourPointIndex)].music),1);
  1965. set(autoTourSoundIsPause, false);
  1966. );
  1967. );
  1968. tween(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].endfov),get(config.autoTours.tour.point[get(autoTourPointIndex)].moveTime),null,autoTourPlay(););
  1969. );
  1970. ,
  1971. stopsound(get(autoTourSoundName));
  1972. set(sound[get(autoTourSoundName)].oncomplete,null);
  1973. tween(view.fov,get(config.autoTours.tour.point[get(autoTourPointIndex)].endfov),get(config.autoTours.tour.point[get(autoTourPointIndex)].moveTime),null,autoTourPlay(););
  1974. );
  1975. inc(autoTourPointIndex);
  1976. );
  1977. );
  1978. );
  1979. </action>
  1980. <action name="autoTourPause">
  1981. set(isAutoTourPause,true);
  1982. stopdelayedcall('delayedStopAutoTour');
  1983. if(autoTourPointIndex == 0,
  1984. set(autoTourPointIndex, 1);
  1985. stopdelayedcall(autoTourDelayedCallID);
  1986. );
  1987. set(layer[autoTourResumeBtnContainer].enable,false);
  1988. pausesound(get(autoTourSoundName));
  1989. stoptween(view.hlookat);
  1990. stoptween(view.vlookat);
  1991. stoptween(view.fov);
  1992. set(autoTourSoundIsPause,true);
  1993. set(control.usercontrol,all);
  1994. recover_view_limit();
  1995. </action>
  1996. <action name="autoTourEnd">
  1997. if(config.autoTours.tour.stopImage !== null AND config.autoTours.tour.stopImage != "" ,
  1998. addlayer(autoTourStopAlert);
  1999. copy(autoTour_stopImage,config.autoTours.tour.stopImage);
  2000. txtadd(autoTour_stopImage,'?imageView2/0/w/2000/h/2000');
  2001. set(layer[autoTourStopAlert].url,get(autoTour_stopImage));
  2002. set(layer[autoTourStopAlert].align,center);
  2003. set(layer[autoTourStopAlert].scale,0.5);
  2004. set(layer[autoTourStopAlert].background,false);
  2005. set(layer[autoTourStopAlert].autoalpha,true);
  2006. set(layer[autoTourStopAlert].enable,false);
  2007. set(layer[autoTourStopAlert].y,0);
  2008. set(layer[autoTourStopAlert].keep,true);
  2009. set(layer[autoTourStopAlert].alpha,0.0);
  2010. tween(layer[autoTourStopAlert].alpha,1.0,0.5);
  2011. delayedcall(3,tween(layer[autoTourStopAlert].alpha,0.0,0.5););
  2012. delayedcall('delayedStopAutoTour',3,autoTourEndAction(););
  2013. hideSubtitle();
  2014. ,
  2015. autoTourEndAction();
  2016. );
  2017. </action>
  2018. <action name="autoTourEndAction">
  2019. set(isAutoTourPause,false);
  2020. set(autoTourPointIndex,0);
  2021. stopsound(get(autoTourSoundName));
  2022. stoptween(view.hlookat);
  2023. stoptween(view.vlookat);
  2024. stoptween(view.fov);
  2025. set(layer[autoTourPauseBtnContainer].enable,false);
  2026. tween(layer[autoTourPauseBtnContainer].alpha,0.0,0.2);
  2027. set(layer[autoTourResumeBtnContainer].enable,false);
  2028. tween(layer[autoTourResumeBtnContainer].alpha,0.0,0.2);
  2029. set(layer[autoTourStopBtnContainer].enable,false);
  2030. tween(layer[autoTourStopBtnContainer].alpha,0.0,0.2);
  2031. set(isAutoTouring,false);
  2032. set(waitAutoTourContinue, null);
  2033. if(config.autoTours.tour.loop == true AND %1 != true,
  2034. autoTourStart(true);
  2035. ,
  2036. stopdelayedcall('delayedStopAutoTour');
  2037. set(control.usercontrol,all);
  2038. if(autorotateEnabledForAutoTour == true,
  2039. resume_autoplay();
  2040. );
  2041. if(config.autoTours.tour.disableMusic == true,
  2042. js_toggleBgMusic(true);
  2043. );
  2044. js_toggleBgVoice(true);
  2045. show_UI();
  2046. recover_view_limit();
  2047. stopdelayedcall(autoTourDelayedCallID);
  2048. tween(layer[autoTourStartAlert].alpha,0.0,0.01);
  2049. if(config.autoTours.tour.hideHotspots == true,
  2050. show_hotspots();
  2051. if(auto_tour_comments_state == 1,
  2052. );
  2053. );
  2054. hideSubtitle();
  2055. js_autoTourEndCallback();
  2056. js_toggleAutoTourUI(true);
  2057. );
  2058. </action>
  2059. <action name="showSubtitle">
  2060. if(config.autoTours.tour.point[get(autoTourPointIndex)].subtitle !== null AND config.autoTours.tour.point[get(autoTourPointIndex)].subtitle != '',
  2061. copy(subtitle_txt,config.autoTours.tour.point[get(autoTourPointIndex)].subtitle);
  2062. copy(subtitle_position,config.autoTours.tour.subtitlePosition);
  2063. copy(subtitle_size,config.autoTours.tour.subtitleSize);
  2064. copy(subtitle_background,config.autoTours.tour.subtitleBackground);
  2065. escape(subtitle_txt);
  2066. js_showAutoTourSubtitle(get(subtitle_txt), get(subtitle_position), get(subtitle_size), get(subtitle_background));
  2067. ,
  2068. hideSubtitle();
  2069. );
  2070. </action>
  2071. <action name="hideSubtitle">
  2072. js_hideAutoTourSubtitle();
  2073. </action>
  2074. <action name="showComments">
  2075. for(set(i,0),i LT hotspot.count,inc(i),
  2076. if(hotspot[get(i)].isComment,
  2077. set(hotspot[get(i)].visible,true);
  2078. );
  2079. );
  2080. for(set(i,0),i LT layer.count,inc(i),
  2081. if(layer[get(i)].isComment,
  2082. set(layer[get(i)].visible,true);
  2083. );
  2084. );
  2085. set(commentVisibled,true);
  2086. if(config.feature.enable_comment == 0,
  2087. set(modify_comment_cmd,get(js_modify_comment));
  2088. txtadd(modify_comment_cmd,"('");
  2089. txtadd(modify_comment_cmd,get(config.info.id));
  2090. txtadd(modify_comment_cmd,"','");
  2091. txtadd(modify_comment_cmd,get(pano_id));
  2092. txtadd(modify_comment_cmd,"')");
  2093. jscall(get(modify_comment_cmd));
  2094. set(config.feature.enable_comment ,1);
  2095. set(config.feature.show_comment,1);
  2096. jscall(get(js_show_comments));
  2097. );
  2098. set(layer[comment_btn].crop,0|734|80|81);
  2099. set(config.feature.show_comment,1);
  2100. if(isAutoTouring == true AND config.autoTours.tour.hideHotspots == true,
  2101. hide_hotspots();
  2102. );
  2103. hide_vr_hotspot();
  2104. </action>
  2105. <action name="hideComments">
  2106. for(set(i,0),i LT hotspot.count,inc(i),
  2107. if(hotspot[get(i)].isComment,
  2108. set(hotspot[get(i)].visible,false);
  2109. );
  2110. );
  2111. for(set(i,0),i LT layer.count,inc(i),
  2112. if(layer[get(i)].isComment,
  2113. set(layer[get(i)].visible,false);
  2114. );
  2115. );
  2116. set(layer[comment_btn].crop,0|814|80|80);
  2117. jscall(get(js_hide_comments));
  2118. set(config.feature.show_comment,0);
  2119. </action>
  2120. <action name="addComment">
  2121. set(avatarUrl,%3);
  2122. if( avatarUrl !== null,
  2123. if(plugin[commentsContainer] === null,
  2124. addplugin(commentsContainer);
  2125. set(plugin[commentsContainer].zorder,50);
  2126. set(plugin[commentsContainer].keep,true);
  2127. );
  2128. set(newCommentContainer,'new_comment_container');
  2129. txtadd(newCommentContainer,%1);
  2130. addhotspot(get(newCommentContainer));
  2131. set(hotspot[get(newCommentContainer)].isComment,true);
  2132. set(hotspot[get(newCommentContainer)].keep,true);
  2133. set(hotspot[get(newCommentContainer)].isActiveHotspot,true);
  2134. set(hotspot[get(newCommentContainer)].ath,%4);
  2135. set(hotspot[get(newCommentContainer)].atv,%5);
  2136. set(hotspot[get(newCommentContainer)].width,32);
  2137. set(hotspot[get(newCommentContainer)].height,48);
  2138. if(device.desktop,
  2139. set(hotspot[get(newCommentContainer)].scale,1);
  2140. ,
  2141. set(hotspot[get(newCommentContainer)].scale,1.5);
  2142. );
  2143. hotspot[get(newCommentContainer)].loadstyle(skin_style);
  2144. set(hotspot[get(newCommentContainer)].crop,200|203|64|96);
  2145. set(hotspot[get(newCommentContainer)].edge,bottom);
  2146. set(hotspot[get(newCommentContainer)].enabled,false);
  2147. set(hotspot[get(newCommentContainer)].zorder,get(hotspot.count));
  2148. set(hotspot[get(newCommentContainer)].handcursor,false);
  2149. set(hotspot[get(newCommentContainer)].visible,get(commentVisibled));
  2150. set(hotspot[get(newCommentContainer)].parent,commentsContainer);
  2151. set(newCommentHeadMask,'new_comment_mask');
  2152. txtadd(newCommentHeadMask,%1);
  2153. addlayer(get(newCommentHeadMask));
  2154. set(layer[get(newCommentHeadMask)].isComment,true);
  2155. set(layer[get(newCommentHeadMask)].visible,get(commentVisibled));
  2156. set(layer[get(newCommentHeadMask)].type,container);
  2157. if(device.desktop,
  2158. set(layer[get(newCommentHeadMask)].scale,1);
  2159. ,
  2160. set(layer[get(newCommentHeadMask)].scale,1.5);
  2161. );
  2162. set(layer[get(newCommentHeadMask)].keep,true);
  2163. set(layer[get(newCommentHeadMask)].x,1);
  2164. set(layer[get(newCommentHeadMask)].width,30);
  2165. set(layer[get(newCommentHeadMask)].height,30);
  2166. set(layer[get(newCommentHeadMask)].bgcolor,0xffffff);
  2167. set(layer[get(newCommentHeadMask)].bgalpha,1);
  2168. set(layer[get(newCommentHeadMask)].maskchildren,true);
  2169. set(addCommentHotspotName,'hotspot[');
  2170. txtadd(addCommentHotspotName,get(newCommentContainer));
  2171. txtadd(addCommentHotspotName,']');
  2172. set(layer[get(newCommentHeadMask)].parent,get(addCommentHotspotName));
  2173. set(layer[get(newCommentHeadMask)].handcursor,false);
  2174. set(layer[get(newCommentHeadMask)].enabled,false);
  2175. set(layer[get(newCommentHeadMask)].zorder,get(layer.count));
  2176. set(layer[get(newCommentHeadMask)].bgroundedge,5);
  2177. set(layer[get(newCommentHeadMask)].capture,false);
  2178. set(layer[get(newCommentHeadMask)].isActiveHotspot,true);
  2179. set(newCommentHead,'new_comment_avatar');
  2180. txtadd(newCommentHead,%1);
  2181. addlayer(get(newCommentHead));
  2182. set(layer[get(newCommentHead)].isComment,true);
  2183. set(layer[get(newCommentHead)].isActiveHotspot,true);
  2184. set(layer[get(newCommentHead)].visible,get(commentVisibled));
  2185. set(layer[get(newCommentHead)].keep,true);
  2186. if(device.desktop,
  2187. set(layer[get(newCommentHead)].scale,1);
  2188. ,
  2189. set(layer[get(newCommentHead)].scale,1.5);
  2190. );
  2191. set(layer[get(newCommentHead)].width,30);
  2192. set(layer[get(newCommentHead)].height,"prop");
  2193. set(newCommentHeadUrl,%3);
  2194. if(newCommentHeadUrl.length GT 0,
  2195. txtadd(newCommentHeadUrl,?imageMogr2/thumbnail/60x60!);
  2196. set(layer[get(newCommentHead)].url,get(newCommentHeadUrl));
  2197. );
  2198. set(addCommentMaskName,'layer[');
  2199. txtadd(addCommentMaskName,get(newCommentHeadMask));
  2200. txtadd(addCommentMaskName,']');
  2201. set(layer[get(newCommentHead)].parent,get(addCommentMaskName));
  2202. set(layer[get(newCommentHead)].handcursor,false);
  2203. set(layer[get(newCommentHead)].enabled,false);
  2204. set(layer[get(newCommentHead)].zorder,get(layer.count));
  2205. set(layer[get(newCommentHead)].capture,false);
  2206. set(layer[get(newCommentHead)].isActiveHotspot,true);
  2207. set(newCommentPointTextName,'new_comment_point_text_container');
  2208. txtadd(newCommentPointTextName,%1);
  2209. addhotspot(get(newCommentPointTextName));
  2210. set(hotspot[get(newCommentPointTextName)].keep,true);
  2211. set(hotspot[get(newCommentPointTextName)].isActiveHotspot,true);
  2212. set(hotspot[get(newCommentPointTextName)].isComment,true);
  2213. set(hotspot[get(newCommentPointTextName)].ath,%4);
  2214. set(hotspot[get(newCommentPointTextName)].atv,%5);
  2215. set(hotspot[get(newCommentPointTextName)].visible,get(commentVisibled));
  2216. set(hotspot[get(newCommentPointTextName)].type,container);
  2217. set(hotspot[get(newCommentPointTextName)].url,get(plugin_url.TEXT_SWF));
  2218. set(hotspot[get(newCommentPointTextName)].backgroundcolor,0x000000);
  2219. set(hotspot[get(newCommentPointTextName)].backgroundalpha,0.6);
  2220. if(device.flash,
  2221. set(hotspot[get(newCommentPointTextName)].backgroundalpha,0.0);
  2222. );
  2223. set(hotspot[get(newCommentPointTextName)].enabled,false);
  2224. set(hotspot[get(newCommentPointTextName)].handcursor,false);
  2225. set(hotspot[get(newCommentPointTextName)].edge,topleft);
  2226. set(hotspot[get(newCommentPointTextName)].parent,get(addCommentHotspotName));
  2227. if(device.desktop,
  2228. set(hotspot[get(newCommentPointTextName)].css,font-family:STXihei; font-size:12px; color:#FFFFFF;letter-spacing:1px;);
  2229. set(hotspot[get(newCommentPointTextName)].padding,8);
  2230. set(hotspot[get(newCommentPointTextName)].oy,-48);
  2231. set(hotspot[get(newCommentPointTextName)].ox,18);
  2232. set(hotspot[get(newCommentPointTextName)].roundedge,5);
  2233. set(hotspot[get(newCommentPointTextName)].parent,get(addCommentHotspotName));
  2234. ,
  2235. set(hotspot[get(newCommentPointTextName)].css,font-family:STXihei; font-size:14px; color:#FFFFFF;letter-spacing:1px;);
  2236. set(hotspot[get(newCommentPointTextName)].padding,10);
  2237. set(hotspot[get(newCommentPointTextName)].oy,-74);
  2238. set(hotspot[get(newCommentPointTextName)].ox,26);
  2239. set(hotspot[get(newCommentPointTextName)].roundedge,5);
  2240. );
  2241. set(hotspot[get(newCommentPointTextName)].zorder,get(hotspot.count));
  2242. set(hotspot[get(newCommentPointTextName)].html,'%2');
  2243. set(hotspot[get(newCommentPointTextName)].renderer,"css3d");
  2244. set(hotspot[get(newCommentPointTextName)].parent,get(addCommentHotspotName));
  2245. );
  2246. </action>
  2247. <action name="removeComments">
  2248. for(set(i,0),i LT hotspot.count,inc(i),
  2249. if(hotspot[get(i)].isComment,
  2250. removehotspot(get(hotspot[get(i)].name));
  2251. dec(i);
  2252. );
  2253. );
  2254. for(set(i,0),i LT layer.count,inc(i),
  2255. if(layer[get(i)].isComment,
  2256. removelayer(get(layer[get(i)].name));
  2257. dec(i);
  2258. );
  2259. );
  2260. set(config.feature.show_comment,0);
  2261. </action>
  2262. <action name="enterEditComment">
  2263. set(modify_comment_cmd,get(js_modify_comment));
  2264. txtadd(modify_comment_cmd,"('");
  2265. txtadd(modify_comment_cmd,get(config.info.id));
  2266. txtadd(modify_comment_cmd,"','");
  2267. txtadd(modify_comment_cmd,get(pano_id));
  2268. txtadd(modify_comment_cmd,"')");
  2269. set(config.feature.show_comment, 1);
  2270. jscall(get(modify_comment_cmd));
  2271. pause_autoplay();
  2272. hide_ui();
  2273. copy(commentAddAnimationUrl,settings.comment_add_head_bg_image);
  2274. addhotspot(add_hotspot_comment_bg_container);
  2275. set(hotspot[add_hotspot_comment_bg_container].ath,get(view.hlookat));
  2276. set(hotspot[add_hotspot_comment_bg_container].atv,get(view.vlookat));
  2277. set(hotspot[add_hotspot_comment_bg_container].width,32);
  2278. set(hotspot[add_hotspot_comment_bg_container].height,48);
  2279. if(device.desktop,
  2280. set(hotspot[add_hotspot_comment_bg_container].scale,1.5);
  2281. ,
  2282. set(hotspot[add_hotspot_comment_bg_container].scale,2);
  2283. );
  2284. copy(hotspot[add_hotspot_comment_bg_container].url,settings.comment_edit_line_image);
  2285. set(hotspot[add_hotspot_comment_bg_container].keep,false);
  2286. set(hotspot[add_hotspot_comment_bg_container].edge,bottom);
  2287. set(hotspot[add_hotspot_comment_bg_container].handcursor,true);
  2288. set(hotspot[add_hotspot_comment_bg_container].enabled,true);
  2289. set(hotspot[add_hotspot_comment_bg_container].zorder,3600);
  2290. set(hotspot[add_hotspot_comment_bg_container].ondown,dragAddHotspot());
  2291. addlayer(add_hotspot_comment_mask);
  2292. set(layer[add_hotspot_comment_mask].type,"container");
  2293. if(device.desktop,
  2294. set(layer[add_hotspot_comment_mask].scale,1.5);
  2295. ,
  2296. set(layer[add_hotspot_comment_mask].scale,2.0);
  2297. );
  2298. set(layer[add_hotspot_comment_mask].keep,false);
  2299. set(layer[add_hotspot_comment_mask].x,1);
  2300. set(layer[add_hotspot_comment_mask].width,30);
  2301. set(layer[add_hotspot_comment_mask].height,30);
  2302. set(layer[add_hotspot_comment_mask].bgcolor,0xffffff);
  2303. set(layer[add_hotspot_comment_mask].bgalpha,1);
  2304. set(layer[add_hotspot_comment_mask].maskchildren,true);
  2305. set(addCommentHotspotName,'hotspot[');
  2306. txtadd(addCommentHotspotName,add_hotspot_comment_bg_container);
  2307. txtadd(addCommentHotspotName,']');
  2308. set(layer[add_hotspot_comment_mask].parent,get(addCommentHotspotName));
  2309. set(layer[add_hotspot_comment_mask].handcursor,false);
  2310. set(layer[add_hotspot_comment_mask].enabled,false);
  2311. set(layer[add_hotspot_comment_mask].zorder,3601);
  2312. set(layer[add_hotspot_comment_mask].bgroundedge,6);
  2313. set(layer[add_hotspot_comment_mask].capture,false);
  2314. addlayer(add_hotspot_comment_avatar);
  2315. if(device.desktop,
  2316. set(layer[add_hotspot_comment_avatar].scale,1.5);
  2317. ,
  2318. set(layer[add_hotspot_comment_avatar].scale,2);
  2319. );
  2320. set(layer[add_hotspot_comment_avatar].width,30);
  2321. set(layer[add_hotspot_comment_avatar].height,"prop");
  2322. set(newEditCommentHeadUrl,%1);
  2323. if(newEditCommentHeadUrl.length GT 0,
  2324. txtadd(newEditCommentHeadUrl,?imageMogr2/thumbnail/60x60!);
  2325. set(layer[add_hotspot_comment_avatar].url,get(newEditCommentHeadUrl));
  2326. );
  2327. set(addCommentMaskName,'layer[');
  2328. txtadd(addCommentMaskName,add_hotspot_comment_mask);
  2329. txtadd(addCommentMaskName,']');
  2330. set(layer[add_hotspot_comment_avatar].parent,get(addCommentMaskName));
  2331. set(layer[add_hotspot_comment_avatar].handcursor,false);
  2332. set(layer[add_hotspot_comment_avatar].enabled,false);
  2333. set(layer[add_hotspot_comment_avatar].zorder,2602);
  2334. set(layer[add_hotspot_comment_avatar].capture,false);
  2335. addhotspot(add_comment_point_text_container);
  2336. set(hotspot[add_comment_point_text_container].ath,get(view.hlookat));
  2337. set(hotspot[add_comment_point_text_container].atv,get(view.vlookat));
  2338. set(hotspot[add_comment_point_text_container].visible,true);
  2339. set(hotspot[add_comment_point_text_container].scale,1);
  2340. copy(hotspot[add_comment_point_text_container].url,settings.comment_edit_bg_image);
  2341. set(hotspot[add_comment_point_text_container].css,font-family:STXihei; font-size:14px; color:#FFFFFF;letter-spacing:1px;);
  2342. set(hotspot[add_comment_point_text_container].backgroundcolor,0xFF7F00);
  2343. set(hotspot[add_comment_point_text_container].backgroundalpha,1);
  2344. set(hotspot[add_comment_point_text_container].padding,10);
  2345. set(hotspot[add_comment_point_text_container].keep,false);
  2346. set(hotspot[add_comment_point_text_container].edge,topleft);
  2347. set(hotspot[add_comment_point_text_container].handcursor,true);
  2348. set(hotspot[add_comment_point_text_container].enabled,true);
  2349. set(hotspot[add_comment_point_text_container].ondown,dragAddHotspot());
  2350. if(device.desktop,
  2351. set(hotspot[add_comment_point_text_container].width,178);
  2352. set(hotspot[add_comment_point_text_container].height,52);
  2353. set(hotspot[add_comment_point_text_container].oy,-75);
  2354. set(hotspot[add_comment_point_text_container].ox,-26);
  2355. set(hotspot[add_comment_point_text_container].roundedge,10);
  2356. ,
  2357. set(hotspot[add_comment_point_text_container].width,232);
  2358. set(hotspot[add_comment_point_text_container].height,68);
  2359. if(device.ios,
  2360. set(hotspot[add_comment_point_text_container].oy,-100);
  2361. set(hotspot[add_comment_point_text_container].ox,-35);
  2362. ,
  2363. set(hotspot[add_comment_point_text_container].oy,-100);
  2364. set(hotspot[add_comment_point_text_container].ox,-35);
  2365. );
  2366. set(hotspot[add_comment_point_text_container].roundedge,18);
  2367. set(hotspot[add_comment_point_text_container].enable,true);
  2368. );
  2369. set(hotspot[add_comment_point_text_container].zorder,2499);
  2370. addlayer(add_comment_text);
  2371. if(device.desktop,
  2372. set(layer[add_comment_text].x,45);
  2373. ,
  2374. set(layer[add_comment_text].x,65);
  2375. );
  2376. set(layer[add_comment_text].y,-15);
  2377. set(layer[add_comment_text].visible,true);
  2378. set(layer[add_comment_text].scale,1);
  2379. set(layer[add_comment_text].align,left);
  2380. set(layer[add_comment_text].url,get(plugin_url.TEXT_SWF));
  2381. set(layer[add_comment_text].css,font-family:STXihei; font-size:12px; color:#ffffff;letter-spacing:1px;);
  2382. set(layer[add_comment_text].backgroundcolor,#000000);
  2383. set(layer[add_comment_text].backgroundalpha,0);
  2384. set(layer[add_comment_text].padding,8);
  2385. set(layer[add_comment_text].keep,false);
  2386. set(layer[add_comment_text].enabled,false);
  2387. set(layer[add_comment_text].handcursor,false);
  2388. set(layer[add_comment_text].alpha,0);
  2389. set(layer[add_comment_text].zorder,2604);
  2390. set(layer[add_comment_text].ondown,dragAddHotspot());
  2391. set(layer[add_comment_text].parent,get(addCommentHotspotName)); if(auto_rotate==1,stopAutoRotate());
  2392. txtadd(addCommentTextContent,'');
  2393. set(newCommentAth,get(view.hlookat));
  2394. set(newCommentAtv,get(view.vlookat));
  2395. </action>
  2396. <action name="dragAddHotspot">
  2397. if(%1 != dragging,
  2398. spheretoscreen(ath, atv, hotspotcenterx, hotspotcentery);
  2399. sub(drag_adjustx, mouse.stagex, hotspotcenterx);
  2400. sub(drag_adjusty, mouse.stagey, hotspotcentery);
  2401. dragAddHotspot(dragging);
  2402. ,
  2403. if(pressed,
  2404. sub(dx, mouse.stagex, drag_adjustx);
  2405. sub(dy, mouse.stagey, drag_adjusty);
  2406. screentosphere(dx, dy, ath, atv);
  2407. copy(print_ath, ath);
  2408. copy(print_atv, atv);
  2409. roundval(print_ath, 3);
  2410. roundval(print_atv, 3);
  2411. set(hotspot[add_hotspot_comment_bg_container].ath,get(print_ath));
  2412. set(hotspot[add_hotspot_comment_bg_container].atv,get(print_atv));
  2413. set(hotspot[add_comment_text].ath,get(print_ath));
  2414. set(hotspot[add_comment_text].atv,get(print_atv));
  2415. set(hotspot[add_comment_point_text_container].ath,get(print_ath));
  2416. set(hotspot[add_comment_point_text_container].atv,get(print_atv));
  2417. delayedcall(0, dragAddHotspot(dragging) );
  2418. set(newCommentAth,get(print_ath));
  2419. set(newCommentAtv,get(print_atv));
  2420. );
  2421. );
  2422. </action>
  2423. <action name="updateInputComment">
  2424. set(comment_content, %1); if(addCommentTextName!=null AND comment_content!=null,
  2425. set(layer[add_comment_text].html,%1);
  2426. txtadd(comment_tooltip_width_search, %1,'_countend');
  2427. indexoftxt(number_of_characters,get(comment_tooltip_width_search), '_countend',0);
  2428. if(number_of_characters LT 8 ,
  2429. set(layer[add_comment_text].width,auto);
  2430. ,
  2431. set(layer[add_comment_text].width,140);
  2432. );
  2433. set(layer[add_comment_text].height,auto);
  2434. delayedcall(0.2,
  2435. set(layer[add_comment_text].alpha,1);
  2436. );
  2437. ,
  2438. set(layer[add_comment_text].html,'');
  2439. );
  2440. </action>
  2441. <action name="exitEditComment">
  2442. removehotspot(add_hotspot_comment_bg_container);
  2443. removelayer(add_hotspot_comment_mask);
  2444. removelayer(add_hotspot_comment_avatar);
  2445. removehotspot(add_comment_point_text_container);
  2446. removelayer(add_comment_text);
  2447. resume_autoplay();
  2448. show_UI();
  2449. </action>
  2450. <action name="setup_contextmenu">
  2451. if(sceneType != 3,
  2452. if(device.desktop,
  2453. set(contextmenu.item['fullscreen'].visible, true);
  2454. );
  2455. if(enableReport == true,
  2456. set(contextmenu.item['openReport'].visible, true);
  2457. );
  2458. );
  2459. </action>
  2460. <contextmenu keep="true" fullscreen="false">
  2461. <item name="custom1" caption="1" enabled="false" visible="false" separator="false" onclick="openurl(get(contextmenu.item[custom1].url));"/>
  2462. <item name="custom2" caption="2" enabled="false" visible="false" separator="false" onclick="openurl(get(contextmenu.item[custom2].url));"/>
  2463. <item name="custom3" caption="3" enabled="false" visible="false" separator="false" onclick="openurl(get(contextmenu.item[custom3].url));"/>
  2464. <item name="copyright" caption="720yun.com" enabled="true" visible="true" separator="true" onclick="openurl(https://720yun.com);"/>
  2465. <item name="fullscreen" caption="全屏切换" enabled="true" visible="false" separator="true" onclick="js_toggleFullscreen();"/>
  2466. <item name="viewtype" caption="视角切换" enabled="true" visible="true" separator="false" onclick="js_showViewType();"/>
  2467. <item name="controlmoveto" caption="切换拖拽方式为正向" enabled="true" visible="true" separator="false" showif="device.desktop" onclick="krpChangeMouseControl('drag');js_mouseControlChangedCallback('drag');"/>
  2468. <item name="controldrag" caption="切换拖拽方式为反向" enabled="true" visible="false" separator="true" showif="device.desktop" onclick="krpChangeMouseControl('moveto');js_mouseControlChangedCallback('moveto');"/>
  2469. <item name="openReport" caption="举报" enabled="true" visible="false" separator="true" onclick="js_openReport();"/>
  2470. </contextmenu>
  2471. <action name="setup_embed">
  2472. if(forceDisableEmbed != 1,
  2473. if(plugin[embed_container] === null,
  2474. addplugin(embed_container);
  2475. set(plugin[embed_container].zorder,0);
  2476. );
  2477. delete(embed_video_name);
  2478. set(embed_count,get(config.panos.pano[get(xml.scene)].embeds.embed.count));
  2479. for(set(i,0),i LT embed_count,inc(i),
  2480. set(embed_name,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].name));
  2481. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].embed_type == 2,
  2482. copy(embed_name_bk, embed_name);
  2483. txtadd(embed_name_bk,'_bk');
  2484. addhotspot(get(embed_name_bk));
  2485. set(hotspot[get(embed_name_bk)].keep,false);
  2486. set(hotspot[get(embed_name_bk)].scale,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].scale));
  2487. set(hotspot[get(embed_name_bk)].ath,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].ath));
  2488. set(hotspot[get(embed_name_bk)].atv,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].atv));
  2489. set(hotspot[get(embed_name_bk)].edge,center);
  2490. set(hotspot[get(embed_name_bk)].distorted,true);
  2491. set(hotspot[get(embed_name_bk)].zoom,true);
  2492. set(hotspot[get(embed_name_bk)].renderer,css3d);
  2493. set(hotspot[get(embed_name_bk)].handcursor, false);
  2494. set(hotspot[get(embed_name_bk)].enabled, false);
  2495. set(hotspot[get(embed_name_bk)].visible, false);
  2496. set(hotspot[get(embed_name_bk)].parent,'embed_container');
  2497. addhotspot(get(embed_name));
  2498. set(hotspot[get(embed_name)].keep,false);
  2499. copy(embed_image_url,config.panos.pano[get(xml.scene)].embeds.embed[get(i)].image[0].url);
  2500. txtadd(embed_image_url,'?imageView2/0/w/2000/h/2000');
  2501. copy(hotspot[get(embed_name)].url,embed_image_url);
  2502. set(hotspot[get(embed_name)].scale,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].scale));
  2503. set(hotspot[get(embed_name)].ath,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].ath));
  2504. set(hotspot[get(embed_name)].atv,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].atv));
  2505. set(hotspot[get(embed_name)].rx,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_x));
  2506. set(hotspot[get(embed_name)].ry,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_y));
  2507. set(hotspot[get(embed_name)].rz,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_z));
  2508. set(hotspot[get(embed_name)].edge,center);
  2509. set(hotspot[get(embed_name)].distorted,true);
  2510. set(hotspot[get(embed_name)].zoom,true);
  2511. set(hotspot[get(embed_name)].renderer,css3d);
  2512. set(hotspot[get(embed_name)].image_count, get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].image.count));
  2513. set(hotspot[get(embed_name)].image_index, 0);
  2514. set(hotspot[get(embed_name)].parent,'embed_container');
  2515. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].play_type == 0 ,
  2516. set(hotspot[get(embed_name)].handcursor, false);
  2517. set(hotspot[get(embed_name)].enabled, false);
  2518. set(hotspot[get(embed_name)].playInterval,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].interval));
  2519. set(hotspot[get(embed_name)].onloaded,
  2520. if(image_count GT 1,
  2521. switch_embed_image();
  2522. );
  2523. );
  2524. ,
  2525. set(hotspot[get(embed_name)].handcursor, true);
  2526. set(hotspot[get(embed_name)].enabled, true);
  2527. set(hotspot[get(embed_name)].capture, false);
  2528. set(hotspot[get(embed_name)].playInterval,0);
  2529. set(hotspot[get(embed_name)].onclick,
  2530. if(image_count GT 1,
  2531. switch_embed_image_click();
  2532. );
  2533. );
  2534. );
  2535. );
  2536. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].embed_type == 3,
  2537. addhotspot(get(embed_name));
  2538. set(hotspot[get(embed_name)].keep,false);
  2539. copy(embed_image_url,config.panos.pano[get(xml.scene)].embeds.embed[get(i)].image_url);
  2540. txtadd(embed_image_url,'?imageView2/2/w/2000/');
  2541. copy(hotspot[get(embed_name)].url,embed_image_url);
  2542. set(hotspot[get(embed_name)].scale,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].scale));
  2543. set(hotspot[get(embed_name)].ath,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].ath));
  2544. set(hotspot[get(embed_name)].atv,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].atv));
  2545. set(hotspot[get(embed_name)].rx,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_x));
  2546. set(hotspot[get(embed_name)].ry,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_y));
  2547. set(hotspot[get(embed_name)].rz,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_z));
  2548. set(hotspot[get(embed_name)].looptype,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].loop_type));
  2549. set(hotspot[get(embed_name)].frame,0);
  2550. set(hotspot[get(embed_name)].framewidth,1);
  2551. set(hotspot[get(embed_name)].frameheight,1);
  2552. set(hotspot[get(embed_name)].framespeed,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].frame_speed));
  2553. set(hotspot[get(embed_name)].lastframe,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].frame_number));
  2554. set(hotspot[get(embed_name)].edge,center);
  2555. set(hotspot[get(embed_name)].distorted,true);
  2556. set(hotspot[get(embed_name)].zoom,true);
  2557. set(hotspot[get(embed_name)].renderer,css3d);
  2558. set(hotspot[get(embed_name)].image_count, get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].image.count));
  2559. set(hotspot[get(embed_name)].image_index, 0);
  2560. set(hotspot[get(embed_name)].parent,'embed_container');
  2561. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].play_type == 0 ,
  2562. set(hotspot[get(embed_name)].handcursor, false);
  2563. set(hotspot[get(embed_name)].enabled, false);
  2564. set(hotspot[get(embed_name)].playing, true);
  2565. set(hotspot[get(embed_name)].onloaded,
  2566. copy(framewidth,width);
  2567. copy(frameheight,height);
  2568. div(frameheight,lastframe);
  2569. txtadd(crop,'0|0|',get(framewidth),'|',get(frameheight));
  2570. embed_animate();
  2571. );
  2572. ,
  2573. set(hotspot[get(embed_name)].handcursor, true);
  2574. set(hotspot[get(embed_name)].enabled, true);
  2575. set(hotspot[get(embed_name)].capture, false);
  2576. set(hotspot[get(embed_name)].playing, false);
  2577. set(hotspot[get(embed_name)].onloaded,
  2578. copy(framewidth,width);
  2579. copy(frameheight,height);
  2580. div(frameheight,lastframe);
  2581. txtadd(crop,'0|0|',get(framewidth),'|',get(frameheight));
  2582. );
  2583. set(hotspot[get(embed_name)].onclick,
  2584. toggle(playing);
  2585. embed_animate();
  2586. );
  2587. );
  2588. );
  2589. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].embed_type == 5,
  2590. add_linear_polygon(
  2591. get(embed_name),
  2592. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].point[image_0].ath),
  2593. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].point[image_0].atv),
  2594. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].point[image_1].ath),
  2595. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].point[image_1].atv),
  2596. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].thickness),
  2597. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].color),
  2598. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].alpha),
  2599. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].title),
  2600. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].ath),
  2601. get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].atv)
  2602. );
  2603. );
  2604. jsget(isVip, 'window.interfaceObject.isVip()');
  2605. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].embed_type == 4 AND device.ie != true AND isVip == true,
  2606. set(need_pause_bg_music_sound, true);
  2607. set(embed_video_name, get(embed_name));
  2608. addhotspot(get(embed_name));
  2609. set(hotspot[get(embed_name)].keep, false);
  2610. set(hotspot[get(embed_name)].posterurl, get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].cover_url));
  2611. set(hotspot[get(embed_name)].videourl, get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].video_url));
  2612. set(hotspot[get(embed_name)].music_pause, get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].music_pause));
  2613. set(hotspot[get(embed_name)].sound_pause, get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].sound_pause));
  2614. set(hotspot[get(embed_name)].edge,center);
  2615. set(hotspot[get(embed_name)].distorted,true);
  2616. set(hotspot[get(embed_name)].embed_type,4);
  2617. copy(hotspot[get(embed_name)].url, plugin_url.VIDEO_JS);
  2618. copy(embed_name_play, embed_name);
  2619. txtadd(embed_name_play,'_play');
  2620. addhotspot(get(embed_name_play));
  2621. set(hotspot[get(embed_name_play)].keep,false);
  2622. set(hotspot[get(embed_name_play)].scale, 0.5);
  2623. set(hotspot[get(embed_name_play)].url, calc(settings.skin_url + 'skin/embed_video_play.png'));
  2624. set(hotspot[get(embed_name_play)].edge,center);
  2625. set(hotspot[get(embed_name_play)].distorted,true);
  2626. copy(hotspot[get(embed_name_play)].target_video,embed_name);
  2627. set(hotspot[get(embed_name_play)].handcursor, true);
  2628. set(hotspot[get(embed_name_play)].visible, false);
  2629. set(hotspot[get(embed_name_play)].onclick, toggle_embed_video(););
  2630. set(hotspot[get(embed_name_play)].hotspot_id, get(embed_name));
  2631. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].position_type == 0,
  2632. set(hotspot[get(embed_name)].rotate,0);
  2633. set(hotspot[get(embed_name)].scale,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].scale));
  2634. set(hotspot[get(embed_name)].ath,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].ath));
  2635. set(hotspot[get(embed_name)].atv,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].atv));
  2636. set(hotspot[get(embed_name)].rx,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_x));
  2637. set(hotspot[get(embed_name)].ry,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_y));
  2638. set(hotspot[get(embed_name)].rz,get(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].rotation_z));
  2639. copy(hotspot[get(embed_name_play)].ath, hotspot[get(embed_name)].ath);
  2640. copy(hotspot[get(embed_name_play)].atv, hotspot[get(embed_name)].atv);
  2641. copy(hotspot[get(embed_name_play)].rx, hotspot[get(embed_name)].rx);
  2642. copy(hotspot[get(embed_name_play)].ry, hotspot[get(embed_name)].ry);
  2643. copy(hotspot[get(embed_name_play)].rz, hotspot[get(embed_name)].rz);
  2644. ,
  2645. set(hotspot[get(embed_name)].scale,1);
  2646. set(hotspot[get(embed_name)].ath,0);
  2647. set(hotspot[get(embed_name)].atv,0);
  2648. set(hotspot[get(embed_name)].rx,0);
  2649. set(hotspot[get(embed_name)].ry,0);
  2650. set(hotspot[get(embed_name)].rz,0);
  2651. set(hotspot[get(embed_name)].ox,0);
  2652. set(hotspot[get(embed_name)].oy,0);
  2653. set(hotspot[get(embed_name)].touchworkarounds, true);
  2654. set(hotspot[get(embed_name)].playsinline, true);
  2655. copy(hotspot[get(embed_name)].hfov, config.panos.pano[get(xml.scene)].embeds.embed[get(i)].hfov);
  2656. copy(hotspot[get(embed_name)].yaw, config.panos.pano[get(xml.scene)].embeds.embed[get(i)].yaw);
  2657. copy(hotspot[get(embed_name)].pitch, config.panos.pano[get(xml.scene)].embeds.embed[get(i)].pitch);
  2658. copy(hotspot[get(embed_name)].roll, config.panos.pano[get(xml.scene)].embeds.embed[get(i)].roll);
  2659. set(hotspot[get(embed_name)].onloaded, calc_pos_from_hfov_yaw_pitch_roll());
  2660. );
  2661. set(hotspot[get(embed_name)].capture, false);
  2662. set(hotspot[get(embed_name)].onclick, toggle_embed_video(););
  2663. set(hotspot[get(embed_name)].hotspot_id, get(embed_name));
  2664. set(hotspot[get(embed_name)].handcursor, true);
  2665. set(hotspot[get(embed_name)].pausedonstart, true);
  2666. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].loop_type == 0,
  2667. set(hotspot[get(embed_name)].loop, true);
  2668. ,
  2669. set(hotspot[get(embed_name)].loop, false);
  2670. );
  2671. if(config.panos.pano[get(xml.scene)].embeds.embed[get(i)].muted == 0,
  2672. if(isAutoTouring == true,
  2673. set(hotspot[get(embed_name)].muted, true);
  2674. ,
  2675. set(hotspot[get(embed_name)].muted, false);
  2676. );
  2677. set(hotspot[get(embed_name)].muted_enabled, false);
  2678. ,
  2679. set(hotspot[get(embed_name)].muted, true);
  2680. set(hotspot[get(embed_name)].muted_enabled, true);
  2681. );
  2682. set(hotspot[get(embed_name)].onvideoready,
  2683. set(js_command, calc('interfaceObject.onKrpEmbedVideoReady("' + get(name) + '")'));
  2684. jscall(get(js_command));
  2685. if(webvr.isenabled == true,
  2686. set(hotspot[calc(name + '_play')].visible, false);
  2687. ,
  2688. set(hotspot[calc(name + '_play')].visible, true);
  2689. );
  2690. set(hotspot[get(embed_name)].onclick, );
  2691. set(hotspot[get(embed_name)].handcursor, false);
  2692. );
  2693. set(hotspot[get(embed_name)].onvideoplay,
  2694. set(hotspot[calc(name + '_play')].visible, false);
  2695. set(hotspot[get(name)].handcursor, true);
  2696. if(hotspot[get(name)].music_pause == 1,
  2697. js_toggleBgMusicEmbedVideo(false);
  2698. );
  2699. if(hotspot[get(name)].sound_pause == 1,
  2700. js_toggleBgVoiceEmbedVideo(false);
  2701. );
  2702. set(need_pause_bg_music_sound, false);
  2703. );
  2704. set(hotspot[get(embed_name)].onvideopaused,
  2705. if(need_show_play != false,
  2706. set(hotspot[calc(name + '_play')].visible, true);
  2707. );
  2708. set(hotspot[get(name)].handcursor, false);
  2709. if(hotspot[get(name)].music_pause == 1,
  2710. js_toggleBgMusicEmbedVideo(true);
  2711. );
  2712. if(hotspot[get(name)].sound_pause == 1,
  2713. js_toggleBgVoiceEmbedVideo(true);
  2714. );
  2715. );
  2716. );
  2717. );
  2718. delete(embed_name);
  2719. hide_vr_hotspot();
  2720. );
  2721. </action>
  2722. <action name="calc_pos_from_hfov_yaw_pitch_roll">
  2723. div(hfov,57.295779);
  2724. div(yaw,-57.295779);
  2725. div(pitch,57.295779);
  2726. div(roll,-57.295779);
  2727. mul(hfov,0.5);Math.tan(hfov);mul(width,hfov,1000);set(height,'prop');
  2728. Math.cos(ch,yaw);Math.sin(sh,yaw);
  2729. Math.cos(ca,pitch);Math.sin(sa,pitch);
  2730. Math.cos(cb,roll);Math.sin(sb,roll);
  2731. mul(m0,ca,ch);
  2732. mul(tmp,cb,sa);mul(tmp,ch);mul(tmp2,sb,sh);add(m3,tmp,tmp2);
  2733. mul(m4,cb,ca);
  2734. mul(tmp,cb,sa);mul(tmp,sh);mul(tmp2,sb,ch);sub(m5n,tmp,tmp2);mul(m5n,-1);
  2735. mul(tmp,sb,sa);mul(tmp,ch);mul(tmp2,cb,sh);sub(m6n,tmp,tmp2);mul(m6n,-1);
  2736. Math.atan2(yaw,m6n,m0);
  2737. Math.atan2(roll,m5n,m4);
  2738. Math.asin(pitch,m3);
  2739. mul(ath,yaw,57.295779);
  2740. mul(atv,pitch,57.295779);
  2741. mul(rotate,roll,57.295779);
  2742. copy(hotspot[calc(name + '_play')].ath, ath);
  2743. copy(hotspot[calc(name + '_play')].atv, atv);
  2744. copy(hotspot[calc(name + '_play')].rotate, rotate);
  2745. </action>
  2746. <action name="embed_animate">
  2747. if(looptype == 1 AND frame == lastframe,
  2748. set(frame, 0);
  2749. mul(ypos,frame,frameheight);
  2750. txtadd(crop,'0|',get(ypos),'|',get(framewidth),'|',get(frameheight));
  2751. set(playing, false);
  2752. ,
  2753. inc(frame,1,get(lastframe),0);
  2754. mul(ypos,frame,frameheight);
  2755. txtadd(crop,'0|',get(ypos),'|',get(framewidth),'|',get(frameheight));
  2756. if(playing == true,
  2757. delayedcall(get(framespeed), embed_animate());
  2758. );
  2759. );
  2760. </action>
  2761. <action name="switch_embed_image">
  2762. if(webvr.isenabled != true,
  2763. set(onloaded,);
  2764. copy(switch_embed_name_bk, name);
  2765. txtadd(switch_embed_name_bk,'_bk');
  2766. set(hotspot[calc(name)].bk,calc(name + '_bk'));
  2767. copy(hotspot[calc(name + '_bk')].target,name);
  2768. copy(hotspot[calc(name + '_bk')].rx, rx);
  2769. copy(hotspot[calc(name + '_bk')].ry, ry);
  2770. copy(hotspot[calc(name + '_bk')].rz, rz);
  2771. delayedcall(get(playInterval),
  2772. set(hotspot[calc(name + '_bk')].onloaded,
  2773. set(alpha,1);
  2774. set(visible,true);
  2775. add(hotspot[calc(target)].image_index,1);
  2776. if(hotspot[calc(target)].image_index == hotspot[calc(target)].image_count,
  2777. set(hotspot[calc(target)].image_index,0);
  2778. );
  2779. set(hotspot[calc(target)].onloaded,
  2780. set(visible,true);
  2781. set(alpha,0);
  2782. tween(alpha,1.0,0.2,linear,
  2783. set(hotspot[calc(bk)].visible,false);
  2784. switch_embed_image();
  2785. );
  2786. delayedcall(0.1,
  2787. tween(hotspot[calc(bk)].alpha,0.0,0.2,linear,
  2788. set(hotspot[calc(bk)].visible,false);
  2789. );
  2790. );
  2791. );
  2792. copy(embed_image_url,config.panos.pano[get(xml.scene)].embeds.embed[calc(target)].image[get(hotspot[calc(target)].image_index)].url);
  2793. txtadd(embed_image_url,'?imageView2/0/w/2000/h/2000');
  2794. set(hotspot[calc(target)].url,get(embed_image_url));
  2795. );
  2796. copy(hotspot[calc(name + '_bk')].url,url);
  2797. );
  2798. );
  2799. </action>
  2800. <action name="switch_embed_image_click">
  2801. set(onloaded,);
  2802. copy(switch_embed_name_bk, name);
  2803. txtadd(switch_embed_name_bk,'_bk');
  2804. set(hotspot[calc(name)].bk,calc(name + '_bk'));
  2805. copy(hotspot[calc(name + '_bk')].target,name);
  2806. copy(hotspot[calc(name + '_bk')].rx, rx);
  2807. copy(hotspot[calc(name + '_bk')].ry, ry);
  2808. copy(hotspot[calc(name + '_bk')].rz, rz);
  2809. set(hotspot[calc(name + '_bk')].onloaded,
  2810. set(alpha,1);
  2811. set(visible,true);
  2812. add(hotspot[calc(target)].image_index,1);
  2813. if(hotspot[calc(target)].image_index == hotspot[calc(target)].image_count,
  2814. set(hotspot[calc(target)].image_index,0);
  2815. );
  2816. set(hotspot[calc(target)].onloaded,
  2817. set(visible,true);
  2818. set(alpha,0);
  2819. tween(alpha,1.0,0.2,linear,
  2820. set(hotspot[calc(bk)].visible,false);
  2821. );
  2822. delayedcall(0.1,
  2823. tween(hotspot[calc(bk)].alpha,0.0,0.2,linear,
  2824. set(hotspot[calc(bk)].visible,false);
  2825. );
  2826. );
  2827. );
  2828. copy(embed_image_url,config.panos.pano[get(xml.scene)].embeds.embed[calc(target)].image[get(hotspot[calc(target)].image_index)].url);
  2829. txtadd(embed_image_url,'?imageView2/0/w/2000/h/2000');
  2830. set(hotspot[calc(target)].url,get(embed_image_url));
  2831. );
  2832. copy(hotspot[calc(name + '_bk')].url,url);
  2833. </action>
  2834. <action name="muted_embed_video">
  2835. if(embed_video_name !== null AND hotspot[get(embed_video_name)].muted_enabled == false,
  2836. set(hotspot[get(embed_video_name)].muted, true);
  2837. );
  2838. </action>
  2839. <action name="unmuted_embed_video">
  2840. if(embed_video_name !== null AND hotspot[get(embed_video_name)].muted_enabled == false,
  2841. set(hotspot[get(embed_video_name)].muted, false);
  2842. );
  2843. </action>
  2844. <action name="pause_embed_video">
  2845. if(embed_video_name !== null AND hotspot[get(embed_video_name)].ispaused == true,
  2846. copy(embed_name_play, embed_video_name);
  2847. txtadd(embed_name_play,'_play');
  2848. if(hotspot[get(embed_name_play)] !== null AND hotspot[get(embed_name_play)].visible,
  2849. set(hotspot[get(embed_name_play)].visible, false);
  2850. set(need_resume_play_button, true);
  2851. );
  2852. );
  2853. if(embed_video_name !== null AND hotspot[get(embed_video_name)].ispaused == false,
  2854. hotspot[get(embed_video_name)].pause();
  2855. set(hotspot[get(embed_video_name)].need_resume, true);
  2856. set(hotspot[get(embed_video_name)].need_show_play, false);
  2857. );
  2858. </action>
  2859. <action name="resume_embed_video">
  2860. if(embed_video_name !== null AND hotspot[get(embed_video_name)].ispaused == true,
  2861. copy(embed_name_play, embed_video_name);
  2862. txtadd(embed_name_play,'_play');
  2863. if(hotspot[get(embed_name_play)] !== null AND need_resume_play_button,
  2864. set(hotspot[get(embed_name_play)].visible, true);
  2865. set(need_resume_play_button, false);
  2866. );
  2867. );
  2868. if(embed_video_name !== null AND hotspot[get(embed_video_name)].need_resume == true,
  2869. hotspot[get(embed_video_name)].resume();
  2870. set(hotspot[get(embed_video_name)].need_show_play, true);
  2871. set(hotspot[get(embed_video_name)].need_resume, false);
  2872. );
  2873. </action>
  2874. <action name="toggle_embed_video">
  2875. set(js_command, calc('interfaceObject.onKrpEmbedVideoClick("' + get(hotspot_id) + '", ' + hotspot[get(hotspot_id)].ispaused + ')'));
  2876. jscall(get(js_command));
  2877. for(set(i,0),i LT hotspot.count,inc(i),
  2878. if(hotspot[get(i)].embed_type == '4',
  2879. if(hotspot[get(i)].hotspot_id == get(hotspot_id),
  2880. hotspot[get(hotspot_id)].togglepause();
  2881. ,
  2882. hotspot[get(i)].pause();
  2883. );
  2884. );
  2885. );
  2886. </action>
  2887. <action name="add_linear_polygon">
  2888. update_linear_polygon_title(%1,%9,%10,%11);
  2889. addhotspot(%1);
  2890. set(hotspot[%1].enabled, fasle);
  2891. set(hotspot[%1].capture,false);
  2892. set(hotspot[%1].renderer,'css3d');
  2893. set(hotspot[%1].onclick,
  2894. if(editing_linear_polygon_name != name,
  2895. jscall(calc('window.onKrpEmbedClick("'+ name + '")'));
  2896. );
  2897. );
  2898. update_linear_polygon_position(%1,%2,%3,%4,%5);
  2899. update_linear_polygon_style(%1,%6,%7,%8);
  2900. updatescreen();
  2901. </action>
  2902. <action name="remove_linear_polygon">
  2903. end_edit_linear_polygon();
  2904. if(%1 != null,
  2905. removehotspot(%1);
  2906. set(linear_polygon_txt_name, %1);
  2907. txtadd(linear_polygon_txt_name, '_txt');
  2908. removehotspot(get(linear_polygon_txt_name));
  2909. );
  2910. </action>
  2911. <action name="update_linear_polygon_position">
  2912. if(%1 != null AND %2 !== null AND %3 !== null,
  2913. set(hotspot[%1].point[0].ath, %2);
  2914. set(hotspot[%1].point[0].atv, %3);
  2915. );
  2916. if(%1 != null AND %4 !== null AND %5 !== null,
  2917. set(hotspot[%1].point[1].ath, %4);
  2918. set(hotspot[%1].point[1].atv, %5);
  2919. );
  2920. </action>
  2921. <action name="update_linear_polygon_style">
  2922. if(%2 !== null,
  2923. set(linear_polygon_default_width, %2);
  2924. copy(hotspot[%1].borderwidth, linear_polygon_default_width);
  2925. );
  2926. if(%3 != null,
  2927. set(linear_polygon_default_color, %3);
  2928. txtreplace(linear_polygon_default_color, '#', '0x');
  2929. copy(hotspot[%1].bordercolor, linear_polygon_default_color);
  2930. );
  2931. if(%4 !== null,
  2932. set(linear_polygon_default_alpha, %4);
  2933. copy(hotspot[%1].borderalpha, linear_polygon_default_alpha);
  2934. );
  2935. </action>
  2936. <action name="update_linear_polygon_title">
  2937. if(%1 != null,
  2938. set(linear_polygon_txt_name, %1);
  2939. txtadd(linear_polygon_txt_name, '_txt');
  2940. if(hotspot[get(linear_polygon_txt_name)] === null,
  2941. addhotspot(get(linear_polygon_txt_name));
  2942. );
  2943. set(hotspot[get(linear_polygon_txt_name)].target_hotspot_name,%1);
  2944. set(hotspot[get(linear_polygon_txt_name)].scale,1);
  2945. set(hotspot[get(linear_polygon_txt_name)].capture,false);
  2946. set(hotspot[get(linear_polygon_txt_name)].enabled, false);
  2947. set(hotspot[get(linear_polygon_txt_name)].keep,false);
  2948. set(hotspot[get(linear_polygon_txt_name)].url,'https://ssl-player2.720static.com/@/krp/1.19-pr8/plugins/textfield.swf');
  2949. set(hotspot[get(linear_polygon_txt_name)].backgroundcolor,#000000);
  2950. set(hotspot[get(linear_polygon_txt_name)].backgroundalpha,0.5);
  2951. set(hotspot[get(linear_polygon_txt_name)].roundedge,5);
  2952. set(hotspot[get(linear_polygon_txt_name)].padding,5);
  2953. set(hotspot[get(linear_polygon_txt_name)].css,font-family:STXihei; font-size:12px; color:#ffffff;letter-spacing:1px;textAlign:center;);
  2954. set(hotspot[get(linear_polygon_txt_name)].edge,center);
  2955. set(hotspot[get(linear_polygon_txt_name)].renderer,"css3d");
  2956. set(hotspot[get(linear_polygon_txt_name)].zorder2, 1.0);
  2957. set(hotspot[get(linear_polygon_txt_name)].visible,true);
  2958. set(hotspot[get(linear_polygon_txt_name)].onclick,
  2959. if(editing_linear_polygon_name != target_hotspot_name,
  2960. jscall(calc('window.onKrpEmbedClick("'+ target_hotspot_name + '")'));
  2961. );
  2962. );
  2963. if(%3 != null,
  2964. set(hotspot[get(linear_polygon_txt_name)].ath, %3);
  2965. );
  2966. if(%4 != null,
  2967. set(hotspot[get(linear_polygon_txt_name)].atv, %4);
  2968. );
  2969. set(linear_txt,%2);
  2970. if(linear_txt != null,
  2971. set(hotspot[get(linear_polygon_txt_name)].html, %2);
  2972. txtreplace(hotspot[get(linear_polygon_txt_name)].html,'
  2973. ','[br]');
  2974. set(hotspot[get(linear_polygon_txt_name)].visible, true);
  2975. ,
  2976. set(hotspot[get(linear_polygon_txt_name)].html, );
  2977. set(hotspot[get(linear_polygon_txt_name)].visible, false);
  2978. );
  2979. );
  2980. </action>
  2981. <plugin name="gyro_plugin" keep="true" url="" devices="html5" enabled="false"/>
  2982. <action name="setup_gyro">
  2983. if(!device.desktop AND device.html5,
  2984. copy(plugin[gyro_plugin].url, plugin_url.GYRO);
  2985. );
  2986. </action>
  2987. <action name="toggle_gyro">
  2988. js_request_gyro_promission();
  2989. switch(plugin[gyro_plugin].enabled);
  2990. </action>
  2991. <action name="start_gyro">
  2992. js_request_gyro_promission();
  2993. if(isAutoTouring != true,
  2994. set(plugin[gyro_plugin].enabled, true);
  2995. );
  2996. </action>
  2997. <action name="stop_gyro">
  2998. set(plugin[gyro_plugin].enabled, false);
  2999. </action>
  3000. <action name="setup_hotspot">
  3001. if(plugin[hotspot_container] === null,
  3002. addplugin(hotspot_container);
  3003. set(plugin[hotspot_container].zorder,90);
  3004. set(plugin[hotspot_container].keep,true);
  3005. set(hotspot[hotspot_container].handcursor, true);
  3006. );
  3007. </action>
  3008. <action name="add_hotspot">
  3009. set(hotspot_name,%1);
  3010. ifnot(%3 == 0,
  3011. addhotspot(get(hotspot_name));
  3012. set(hotspot[get(hotspot_name)].isActiveHotspot,true);
  3013. set(hotspot[get(hotspot_name)].hotspot_type,%6);
  3014. set(hotspot[get(hotspot_name)].hotspot_id,%1);
  3015. set(hotspot[get(hotspot_name)].ath,%4);
  3016. set(hotspot[get(hotspot_name)].atv,%5);
  3017. if(displayMode === null,
  3018. add(hotspot[get(hotspot_name)].atv,5);
  3019. );
  3020. set(scale,%12);
  3021. if(scale == null || scale == 'undefined',set(scale,1));
  3022. if(%3 == "1",
  3023. mul(scale,0.5);
  3024. set(hotspot[get(hotspot_name)].scale, get(scale));
  3025. ,
  3026. mul(scale,0.75);
  3027. set(hotspot[get(hotspot_name)].scale, get(scale));
  3028. );
  3029. if(%8 == "1",
  3030. set(hotspot[get(hotspot_name)].frame,0);
  3031. set(hotspot[get(hotspot_name)].framewidth,100);
  3032. set(hotspot[get(hotspot_name)].frameheight,100);
  3033. set(hotspot[get(hotspot_name)].isframe,%8);
  3034. set(hotspot[get(hotspot_name)].framespeed,%10);
  3035. set(hotspot[get(hotspot_name)].lastframe,%9);
  3036. dec(hotspot[get(hotspot_name)].lastframe);
  3037. );
  3038. set(hotspot[get(hotspot_name)].capture, false);
  3039. set(hotspot[get(hotspot_name)].keep, false);
  3040. set(hotspot[get(hotspot_name)].handcursor, true);
  3041. set(hotspot[get(hotspot_name)].edge, center);
  3042. set(hotspot[get(hotspot_name)].zorder, 1000);
  3043. set(hotspot[get(hotspot_name)].onclick, hotspot_action(););
  3044. set(hotspot[get(hotspot_name)].parent,plugin[hotspot_container]);
  3045. set(hotspot_name_URL,%2);
  3046. if(%3 == "2",
  3047. if(%8 == "1",
  3048. txtadd(hotspot_name_URL,'?imageView2/2/w/300/');
  3049. ,
  3050. txtadd(hotspot_name_URL,'?imageView2/0/w/300/');
  3051. );
  3052. set(hotspot[get(hotspot_name)].renderer, css3d);
  3053. set(hotspot[get(hotspot_name)].image_type, 2);
  3054. ,
  3055. set(hotspot[get(hotspot_name)].crop,0|0|128|128);
  3056. indexoftxt(gif_index,%2,'_gif');
  3057. if(gif_index GT -1,
  3058. if(device.flash,
  3059. set(hotspot[get(hotspot_name)].framewidth,64);
  3060. set(hotspot[get(hotspot_name)].frameheight,64);
  3061. txtadd(hotspot_name_URL,'?imageView2/0/w/1600');
  3062. ,
  3063. set(hotspot[get(hotspot_name)].framewidth,128);
  3064. set(hotspot[get(hotspot_name)].frameheight,128);
  3065. );
  3066. set(hotspot[get(hotspot_name)].frame,0);
  3067. indexoftxt(new_index,%2,'new_');
  3068. if(new_index GT -1,
  3069. set(hotspot[get(hotspot_name)].lastframe,24);
  3070. ,
  3071. set(hotspot[get(hotspot_name)].lastframe,9);
  3072. );
  3073. set(hotspot[get(hotspot_name)].onloaded,hotspot_animate(););
  3074. ,
  3075. if(device.flash,
  3076. txtadd(hotspot_name_URL,'?imageView2/0/w/64');
  3077. set(hotspot[get(hotspot_name)].crop,0|0|64|64);
  3078. );
  3079. );
  3080. );
  3081. set(hotspot[get(hotspot_name)].url,get(hotspot_name_URL));
  3082. );
  3083. if(%8 == "1",
  3084. set(hotspot[get(hotspot_name)].renderer, css3d);
  3085. set(hotspot[get(hotspot_name)].onloaded,
  3086. copy(framewidth,width);
  3087. copy(frameheight,height);
  3088. copy(framecount,lastframe);
  3089. inc(framecount);
  3090. div(frameheight,framecount);
  3091. txtadd(crop,'0|0|',get(framewidth),'|',get(frameheight));
  3092. custom_hotspot_animate();
  3093. );
  3094. );
  3095. set(hotspot_txt_string, %7);
  3096. if(hotspot_txt_string !== null AND hotspot_txt_string != undefined AND (hotspot_txt_string != '' OR calc(%7 == '0')),
  3097. set(hotspot_txt_name,get(hotspot_name));
  3098. txtadd(hotspot_txt_name,"_txt");
  3099. addhotspot(get(hotspot_txt_name));
  3100. set(hotspot[get(hotspot_txt_name)].isActiveHotspot,true);
  3101. set(hotspot[get(hotspot_txt_name)].hotspot_id,%1);
  3102. set(hotspot[get(hotspot_txt_name)].hotspot_type,%6);
  3103. set(hotspot[get(hotspot_txt_name)].is_hotspot_txt,true);
  3104. set(hotspot[get(hotspot_txt_name)].image_type, get(hotspot[get(hotspot_name)].image_type));
  3105. set(hotspot[get(hotspot_txt_name)].html,get(hotspot_txt_string));
  3106. set(hotspot[get(hotspot_txt_name)].ath,%4);
  3107. set(hotspot[get(hotspot_txt_name)].atv,get(hotspot[get(hotspot_name)].atv));
  3108. set(hotspot[get(hotspot_txt_name)].scale,1);
  3109. set(hotspot[get(hotspot_txt_name)].url,get(plugin_url.TEXT_SWF));
  3110. set(hotspot[get(hotspot_txt_name)].capture,false);
  3111. set(hotspot[get(hotspot_txt_name)].keep,false);
  3112. set(hotspot[get(hotspot_txt_name)].renderer,"css3d");
  3113. if(hotspot[get(hotspot_name)].height === null ,
  3114. set(hotspot[get(hotspot_name)].onloaded,
  3115. if(%8 == "1",
  3116. copy(framewidth,width);
  3117. copy(frameheight,height);
  3118. copy(framecount, lastframe);
  3119. inc(framecount);
  3120. div(frameheight,framecount);
  3121. txtadd(crop,'0|0|',get(framewidth),'|',get(frameheight));
  3122. custom_hotspot_animate();
  3123. );
  3124. adjust_hotspot_position();
  3125. );
  3126. ,
  3127. set(hotspot[get(hotspot_txt_name)].oy,get(hotspot[get(hotspot_name)].height));
  3128. mul(hotspot[get(hotspot_txt_name)].oy,get(hotspot[get(hotspot_name)].scale));
  3129. mul(hotspot[get(hotspot_txt_name)].oy,-0.5);
  3130. sub(hotspot[get(hotspot_txt_name)].oy,6);
  3131. );
  3132. set(hotspot[get(hotspot_txt_name)].backgroundcolor,#000000);
  3133. set(hotspot[get(hotspot_txt_name)].backgroundalpha,0.5);
  3134. set(hotspot[get(hotspot_txt_name)].roundedge,5);
  3135. set(hotspot[get(hotspot_txt_name)].padding,5);
  3136. if(%11 === null,
  3137. set(hotspot[get(hotspot_txt_name)].css,font-family:STXihei; font-size:12px; color:#ffffff;letter-spacing:1px;text-align:center;);
  3138. ,
  3139. set(hotspot[get(hotspot_txt_name)].css,'font-family:STXihei; font-size:');
  3140. txtadd(hotspot[get(hotspot_txt_name)].css,%11);
  3141. txtadd(hotspot[get(hotspot_txt_name)].css,'px; color:#ffffff;letter-spacing:1px;text-align:center;');
  3142. );
  3143. set(hotspot[get(hotspot_txt_name)].edge,center);
  3144. set(hotspot[get(hotspot_txt_name)].show_txt,get(config.panos.pano[get(xml.scene)].hotspots.hotspot[get(i)].show_txt));
  3145. set(hotspot[get(hotspot_txt_name)].onclick,hotspot_action(););
  3146. set(hotspot[get(hotspot_txt_name)].parent, plugin[hotspot_container]);
  3147. );
  3148. if(webvr.isenabled,
  3149. hide_vr_hotspot();
  3150. );
  3151. if(isAutoTouring == true AND config.autoTours.tour.hideHotspots == true,
  3152. hide_hotspots();
  3153. );
  3154. </action>
  3155. <action name="add_text_hotspot">
  3156. addhotspot(%1);
  3157. set(hotspot[%1].hotspot_id, %1);
  3158. set(hotspot[%1].ath,%3);
  3159. set(hotspot[%1].atv,%4);
  3160. set(hotspot[%1].scale,1);
  3161. set(hotspot[%1].keep,false);
  3162. set(hotspot[%1].url,get(plugin_url.TEXT_SWF));
  3163. set(hotspot[%1].html,%2);
  3164. txtreplace(hotspot[%1].html,'
  3165. ','[br]');
  3166. set(hotspot[%1].bgshadow, "0 2 4 0x000000 0.3");
  3167. set(hotspot_css,'font-size:12px; letter-spacing:1px;textAlign:center;');
  3168. if(%5 != null,
  3169. txtadd(hotspot_css, 'color:');
  3170. txtadd(hotspot_css, %5);
  3171. txtadd(hotspot_css, ';');
  3172. ,
  3173. txtadd(hotspot_css, 'color:#ffffff;');
  3174. );
  3175. if(%6 != null,
  3176. txtadd(hotspot_css, '');
  3177. ,
  3178. txtadd(hotspot_css, '');
  3179. );
  3180. if(%7 !== null,
  3181. set(hotspot[%1].backgroundcolor,%7);
  3182. ,
  3183. set(hotspot[%1].backgroundcolor,#000000);
  3184. set(hotspot[%1].bgborder, 0);
  3185. );
  3186. if(%8 !== null,
  3187. set(hotspot[%1].backgroundalpha,%8);
  3188. ,
  3189. set(hotspot[%1].backgroundalpha,0.5);
  3190. );
  3191. set(hotspot[%1].roundedge,2);
  3192. set(hotspot[%1].padding,'2 6');
  3193. set(hotspot[%1].multiline,true);
  3194. set(hotspot[%1].oy,-9);
  3195. set(hotspot[%1].edge,bottom);
  3196. copy(hotspot[%1].css,hotspot_css);
  3197. set(hotspot[%1].handcursor, true);
  3198. set(hotspot[%1].enabled, true);
  3199. set(hotspot[%1].renderer,"css3d");
  3200. set(hotspot[%1].zorder2, 1.0);
  3201. set(hotspot[%1].parent,plugin[hotspot_container]);
  3202. set(hotspot[%1].zorder, 1000);
  3203. set(hotspot[%1].onclick, hotspot_action(););
  3204. set(embed_txt_bg_name,%1);
  3205. txtadd(embed_txt_bg_name,"_bg");
  3206. addhotspot(get(embed_txt_bg_name));
  3207. if(%7 !== null,
  3208. set(textbgcolor,%7);
  3209. txtreplace(textbgcolor,'#','');
  3210. txtreplace(textbgcolor,'0x','');
  3211. toupper(textbgcolor);
  3212. copy(hotspot[get(embed_txt_bg_name)].url, settings.embed_txt_colored_image);
  3213. txtreplace(hotspot[get(embed_txt_bg_name)].url,'color',get(textbgcolor));
  3214. if(textbgcolor == '24A566',
  3215. set(hotspot[%1].bgborder, '1 0x31c27a 1');
  3216. ,
  3217. if(textbgcolor == 'ADADAD',
  3218. set(hotspot[%1].bgborder, '1 0xbec0cd 1');
  3219. ,
  3220. if(textbgcolor == 'DB4437',
  3221. set(hotspot[%1].bgborder, '1 0xF36264 1');
  3222. ,
  3223. if(textbgcolor == 'F5A623',
  3224. set(hotspot[%1].bgborder, '1 0xffbb0f 1');
  3225. ,
  3226. if(textbgcolor == 'FFFFFF',
  3227. set(hotspot[%1].bgborder, '1 0xc6c6c6 1');
  3228. );
  3229. );
  3230. );
  3231. );
  3232. );
  3233. ,
  3234. copy(hotspot[get(embed_txt_bg_name)].url, settings.embed_txt_image);
  3235. );
  3236. copy(hotspot[get(embed_txt_bg_name)].ath,hotspot[%1].ath);
  3237. copy(hotspot[get(embed_txt_bg_name)].atv,hotspot[%1].atv);
  3238. sub(hotspot[get(embed_txt_bg_name)].atv,0.02);
  3239. set(hotspot[get(embed_txt_bg_name)].keep,false);
  3240. set(hotspot[get(embed_txt_bg_name)].scale,0.5);
  3241. set(hotspot[get(embed_txt_bg_name)].edge,top);
  3242. if(device.mobile == true,
  3243. set(hotspot[get(embed_txt_bg_name)].oy,-6);
  3244. ,
  3245. set(hotspot[get(embed_txt_bg_name)].oy,-9);
  3246. );
  3247. set(hotspot[get(embed_txt_bg_name)].handcursor, true);
  3248. set(hotspot[get(embed_txt_bg_name)].enabled, true);
  3249. set(hotspot[get(embed_txt_bg_name)].renderer, 'css3d');
  3250. copy(hotspot[get(embed_txt_bg_name)].zorder, hotspot[%1].zorder);
  3251. add(hotspot[get(embed_txt_bg_name)].zorder, 1);
  3252. set(hotspot[get(embed_txt_bg_name)].parent,plugin[hotspot_container]);
  3253. if(webvr.isenabled,
  3254. hide_vr_hotspot();
  3255. );
  3256. </action>
  3257. <action name="remove_text_hotspot">
  3258. removehotspot(%1);
  3259. set(embed_txt_bg_name,%1);
  3260. txtadd(embed_txt_bg_name,"_bg");
  3261. removehotspot(get(embed_txt_bg_name));
  3262. </action>
  3263. <action name="update_text_hotspot_color">
  3264. if(%2 != null,
  3265. set(hotspot_css,'font-size:12px; letter-spacing:1px;textAlign:center;');
  3266. txtadd(hotspot_css, 'color:');
  3267. txtadd(hotspot_css, %2);
  3268. txtadd(hotspot_css, ';');
  3269. copy(hotspot[%1].css, hotspot_css);
  3270. );
  3271. if(%3 != null,
  3272. );
  3273. if(%4 !== null,
  3274. set(embed_txt_bg_name,%1);
  3275. txtadd(embed_txt_bg_name,"_bg");
  3276. set(hotspot[%1].backgroundcolor,%4);
  3277. set(textbgcolor,%4);
  3278. txtreplace(textbgcolor,'#','');
  3279. txtreplace(textbgcolor,'0x','');
  3280. toupper(textbgcolor);
  3281. copy(hotspot[get(embed_txt_bg_name)].url, settings.embed_txt_colored_image);
  3282. txtreplace(hotspot[get(embed_txt_bg_name)].url,'color',get(textbgcolor));
  3283. if(textbgcolor == '24A566',
  3284. set(hotspot[%1].bgborder, '1 0x31c27a 1');
  3285. ,
  3286. if(textbgcolor == 'ADADAD',
  3287. set(hotspot[%1].bgborder, '1 0xbec0cd 1');
  3288. ,
  3289. if(textbgcolor == 'DB4437',
  3290. set(hotspot[%1].bgborder, '1 0xF36264 1');
  3291. ,
  3292. if(textbgcolor == 'F5A623',
  3293. set(hotspot[%1].bgborder, '1 0xffbb0f 1');
  3294. ,
  3295. if(textbgcolor == 'FFFFFF',
  3296. set(hotspot[%1].bgborder, '1 0xc6c6c6 1');
  3297. );
  3298. );
  3299. );
  3300. );
  3301. );
  3302. );
  3303. if(%5 !== null,
  3304. set(hotspot[%1].backgroundalpha,%5);
  3305. );
  3306. </action>
  3307. <action name="adjust_frame_hotspot">
  3308. </action>
  3309. <action name="adjust_hotspot_position">
  3310. delayedcall(0.1,
  3311. set(hotspot_loaded_txt_name,get(name));
  3312. txtadd(hotspot_loaded_txt_name,"_txt");
  3313. set(hotspot[get(hotspot_loaded_txt_name)].oy,get(hotspot[get(name)].height));
  3314. mul(hotspot[get(hotspot_loaded_txt_name)].oy,get(hotspot[get(name)].scale));
  3315. mul(hotspot[get(hotspot_loaded_txt_name)].oy,-0.5);
  3316. sub(hotspot[get(hotspot_loaded_txt_name)].oy,11);
  3317. sub(hotspot[get(hotspot_loaded_txt_name)].oy,5);
  3318. );
  3319. </action>
  3320. <action name="hotspot_action">
  3321. js_hotspotClickCallback(get(hotspot_id));
  3322. if(hotspot_type == 5,
  3323. muted_embed_video();
  3324. );
  3325. </action>
  3326. <action name="hotspot_animate">
  3327. inc(frame,1,get(lastframe),0);
  3328. mul(ypos,frame,frameheight);
  3329. txtadd(crop,'0|',get(ypos),'|',get(framewidth),'|',get(frameheight));
  3330. delayedcall(0.03, hotspot_animate());
  3331. </action>
  3332. <action name="custom_hotspot_animate">
  3333. inc(frame,1,get(lastframe),0);
  3334. mul(ypos,frame,frameheight);
  3335. txtadd(crop,'0|',get(ypos),'|',get(framewidth),'|',get(frameheight));
  3336. delayedcall(get(framespeed), custom_hotspot_animate());
  3337. </action>
  3338. <action name="show_hotspots">
  3339. set(plugin[hotspot_container].visible , true);
  3340. for(set(i,0),i LT hotspot.count,inc(i),
  3341. if(hotspot[get(i)].hide_action == 'hide_hotspots',
  3342. set(hotspot[get(i)].visible,true);
  3343. set(hotspot[get(i)].hide_action,'');
  3344. );
  3345. );
  3346. </action>
  3347. <action name="hide_hotspots">
  3348. set(plugin[hotspot_container].visible , false);
  3349. for(set(i,0),i LT hotspot.count,inc(i),
  3350. if(hotspot[get(i)].isActiveHotspot AND hotspot[get(i)].visible,
  3351. set(hotspot[get(i)].visible,false);
  3352. set(hotspot[get(i)].hide_action,'hide_hotspots');
  3353. );
  3354. );
  3355. </action>
  3356. <polygon_swap_data>
  3357. <point name="p0" ath="0" atv="0"/>
  3358. <point name="p1" ath="5" atv="0"/>
  3359. <point name="p2" ath="0" atv="5"/>
  3360. <point name="p3" ath="5" atv="5"/>
  3361. </polygon_swap_data>
  3362. <action name="add_polygon">
  3363. if(%1 != null,
  3364. addhotspot(%1);
  3365. for(set(i,0),i LT polygon_swap_data.point.count,inc(i),
  3366. copy(hotspot[%1].point[get(i)].ath, polygon_swap_data.point[get(i)].ath);
  3367. copy(hotspot[%1].point[get(i)].atv, polygon_swap_data.point[get(i)].atv);
  3368. );
  3369. set(hotspot[%1].title, %13);
  3370. set(hotspot[%1].isActiveHotspot,true);
  3371. set(hotspot[%1].hotspot_type,%12);
  3372. set(hotspot[%1].hotspot_id, %1);
  3373. set(hotspot[%1].capture, false);
  3374. set(hotspot[%1].zorder, 1000);
  3375. set(hotspot[%1].onclick, hotspot_action(););
  3376. update_polygon_style(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10, %11);
  3377. update_polygon_title(%1, %13, %14);
  3378. );
  3379. </action>
  3380. <action name="update_polygon_title">
  3381. if(%1 != null,
  3382. set(polygon_txt_name, %1);
  3383. txtadd(polygon_txt_name, '_txt');
  3384. set(hotspot[%1].title, %2);
  3385. if(hotspot[get(polygon_txt_name)] === null,
  3386. addhotspot(get(polygon_txt_name));
  3387. );
  3388. if(hotspot[%1].title !== null AND hotspot[%1].title != '' AND hotspot[%1].title != undefined AND hotspot[%1].point.count GT 0,
  3389. set(hotspot[get(polygon_txt_name)].target_hotspot_name,%1);
  3390. set(hotspot[get(polygon_txt_name)].scale,1);
  3391. set(hotspot[get(polygon_txt_name)].capture,false);
  3392. set(hotspot[get(polygon_txt_name)].isActiveHotspot,true);
  3393. set(hotspot[get(polygon_txt_name)].hotspot_id,%1);
  3394. copy(hotspot[get(polygon_txt_name)].hotspot_type,hotspot[%1].hotspot_type);
  3395. set(hotspot[get(polygon_txt_name)].keep,false);
  3396. set(hotspot[get(polygon_txt_name)].renderer, "css3d");
  3397. set(hotspot[get(polygon_txt_name)].url,'https://ssl-player2.720static.com/@/krp/1.19-pr8/plugins/textfield.swf');
  3398. set(hotspot[get(polygon_txt_name)].backgroundcolor,#000000);
  3399. set(hotspot[get(polygon_txt_name)].backgroundalpha,0.5);
  3400. set(hotspot[get(polygon_txt_name)].roundedge,5);
  3401. set(hotspot[get(polygon_txt_name)].padding,5);
  3402. if(%3 === null,
  3403. set(hotspot[get(polygon_txt_name)].css, font-family:STXihei; font-size:12px; color:#ffffff;letter-spacing:1px;text-align:center;);
  3404. ,
  3405. set(hotspot[get(polygon_txt_name)].css,'font-family:STXihei; font-size:');
  3406. txtadd(hotspot[get(polygon_txt_name)].css,%3);
  3407. txtadd(hotspot[get(polygon_txt_name)].css,'px; color:#ffffff;letter-spacing:1px;text-align:center;');
  3408. );
  3409. set(hotspot[get(polygon_txt_name)].edge,center);
  3410. set(hotspot[get(polygon_txt_name)].visible,true);
  3411. copy(hotspot[get(polygon_txt_name)].html,hotspot[%1].title);
  3412. set(hotspot[get(polygon_txt_name)].onclick,
  3413. if(target_hotspot_name != editing_polygon_name,
  3414. hotspot_action();
  3415. );
  3416. );
  3417. update_polygon_title_postion(%1);
  3418. ,
  3419. set(hotspot[get(polygon_txt_name)].visible,false);
  3420. );
  3421. );
  3422. if(webvr.isenabled,
  3423. hide_vr_hotspot();
  3424. );
  3425. </action>
  3426. <action name="update_polygon_title_postion">
  3427. copy(toAth,hotspot[%1].point[0].ath);
  3428. copy(toAtv,hotspot[%1].point[0].atv);
  3429. for(set(i,1),i LT hotspot[%1].point.count,inc(i),
  3430. if(hotspot[%1].point[get(i)].atv LT toAtv,
  3431. copy(toAth, hotspot[%1].point[get(i)].ath);
  3432. copy(toAtv, hotspot[%1].point[get(i)].atv);
  3433. );
  3434. );
  3435. copy(hotspot[get(polygon_txt_name)].ath, toAth);
  3436. copy(hotspot[get(polygon_txt_name)].atv, toAtv);
  3437. sub(hotspot[get(polygon_txt_name)].atv, 2);
  3438. </action>
  3439. <action name="remove_polygon">
  3440. if(%1 != null,
  3441. set(polygon_txt_name, %1);
  3442. txtadd(polygon_txt_name, '_txt');
  3443. removehotspot(%1);
  3444. removehotspot(get(polygon_txt_name));
  3445. );
  3446. </action>
  3447. <action name="update_polygon_style">
  3448. if(%1 != null,
  3449. if(%2 !== null,
  3450. set(hotspot[%1].fillcolor, %2);
  3451. set(hotspot[%1].normal_color, %2);
  3452. );
  3453. if(%3 !== null,
  3454. set(hotspot[%1].normal_alpha, %3);
  3455. set(hotspot[%1].fillalpha, %3);
  3456. );
  3457. if(%4 !== null,
  3458. set(hotspot[%1].normal_border_width, %4);
  3459. set(hotspot[%1].borderwidth, %4);
  3460. );
  3461. if(%5 !== null,
  3462. set(hotspot[%1].normal_border_color, %5);
  3463. set(hotspot[%1].bordercolor, %5);
  3464. );
  3465. if(%6 !== null,
  3466. set(hotspot[%1].normal_border_alpha, %6);
  3467. set(hotspot[%1].borderalpha, %6);
  3468. );
  3469. set(hotspot[%1].over_color, %7);
  3470. set(hotspot[%1].over_alpha, %8);
  3471. set(hotspot[%1].over_border_width, %9);
  3472. set(hotspot[%1].over_border_color, %10);
  3473. set(hotspot[%1].over_border_alpha, %11);
  3474. if(%7 !== null OR %8 !== null OR %9 !== null OR %10 !== null OR %11 !== null,
  3475. set(hotspot[%1].onover,
  3476. if(over_color !== null,
  3477. tween(fillcolor, get(over_color));
  3478. );
  3479. if(over_alpha !== null,
  3480. tween(fillalpha, get(over_alpha));
  3481. );
  3482. if(over_border_width !== null,
  3483. tween(borderwidth, get(over_border_width));
  3484. );
  3485. if(over_border_color !== null,
  3486. tween(bordercolor, get(over_border_color));
  3487. );
  3488. if(over_border_alpha !== null,
  3489. tween(borderalpha, get(over_border_alpha));
  3490. );
  3491. );
  3492. set(hotspot[%1].onout,
  3493. if(normal_color !== null,
  3494. tween(fillcolor, get(normal_color));
  3495. );
  3496. if(normal_alpha !== null,
  3497. tween(fillalpha, get(normal_alpha));
  3498. );
  3499. if(normal_border_width !== null,
  3500. tween(borderwidth, get(normal_border_width));
  3501. );
  3502. if(normal_border_color !== null,
  3503. tween(bordercolor, get(normal_border_color));
  3504. );
  3505. if(normal_border_alpha !== null,
  3506. tween(borderalpha, get(normal_border_alpha));
  3507. );
  3508. );
  3509. if(device.mouse == false,
  3510. set(hotspot[%1].ondown,
  3511. if(over_color !== null,
  3512. tween(fillcolor, get(over_color));
  3513. );
  3514. if(over_alpha !== null,
  3515. tween(fillalpha, get(over_alpha));
  3516. );
  3517. if(over_border_width !== null,
  3518. tween(borderwidth, get(over_border_width));
  3519. );
  3520. if(over_border_color !== null,
  3521. tween(bordercolor, get(over_border_color));
  3522. );
  3523. if(over_border_alpha !== null,
  3524. tween(borderalpha, get(over_border_alpha));
  3525. );
  3526. );
  3527. set(hotspot[%1].onup,
  3528. if(normal_color !== null,
  3529. tween(fillcolor, get(normal_color));
  3530. );
  3531. if(normal_alpha !== null,
  3532. tween(fillalpha, get(normal_alpha));
  3533. );
  3534. if(normal_border_width !== null,
  3535. tween(borderwidth, get(normal_border_width));
  3536. );
  3537. if(normal_border_color !== null,
  3538. tween(bordercolor, get(normal_border_color));
  3539. );
  3540. if(normal_border_alpha !== null,
  3541. tween(borderalpha, get(normal_border_alpha));
  3542. );
  3543. );
  3544. );
  3545. ,
  3546. set(hotspot[%1].onover,null);
  3547. set(hotspot[%1].onout,null);
  3548. );
  3549. );
  3550. </action>
  3551. <action name="setup_littleplanet_view">
  3552. if(config.panos.pano[get(scene_name)].view.fovmin == "" OR config.panos.pano[get(scene_name)].view.fovmin === null,
  3553. set(config.panos.pano[get(scene_name)].view.fovmin,70);
  3554. );
  3555. if(config.panos.pano[get(scene_name)].view.fovmax == "" OR config.panos.pano[get(scene_name)].view.fovmax === null,
  3556. set(config.panos.pano[get(scene_name)].view.fovmax,120);
  3557. );
  3558. if(forceFov !== null,
  3559. copy(config.panos.pano[get(scene_name)].view.fov, forceFov);
  3560. copy(config.panos.pano[get(scene_name)].view.fovmin, forceFovmin);
  3561. copy(config.panos.pano[get(scene_name)].view.fovmax, forceFovmax);
  3562. );
  3563. if(enableLittleplanet == 1,
  3564. set(view.fovmax, 170);
  3565. set(view.limitview, lookat);
  3566. set(view.vlookatmin, 90);
  3567. set(view.vlookatmax, 90);
  3568. lookat(calc(lp_hlookat + 180), 90, 150, 1, 0, 0);
  3569. ,
  3570. if(enableLittleplanet == 2,
  3571. copy(view.hlookat, config.panos.pano[get(xml.scene)].view.hlookat);
  3572. copy(view.vlookat, config.panos.pano[get(xml.scene)].view.vlookat);
  3573. copy(view.fov, config.panos.pano[get(xml.scene)].view.fov);
  3574. copy(view.fovmax, config.panos.pano[get(xml.scene)].view.fovmax);
  3575. copy(view.limitview, config.panos.pano[get(xml.scene)].view.limitview);
  3576. add(view.hlookat, 360);
  3577. ,
  3578. if(enableLittleplanet == 3,
  3579. set(view.fisheye, 1.0);
  3580. set(view.fov, 150);
  3581. set(view.vlookat, -65);
  3582. set(view.hlookat, get(config.panos.pano[get(xml.scene)].hlookat));
  3583. ,
  3584. if(enableLittleplanet == 4,
  3585. set(view.fov, 110);
  3586. set(view.architectural, 0.0);
  3587. set(view.pannini, 0.0);
  3588. set(view.distortion, 2.8);
  3589. ,
  3590. if(enableLittleplanet == 5,
  3591. set(view.architectural, 0.0);
  3592. set(view.fovmax, 150);
  3593. set(view.fov, 150);
  3594. set(view.fisheye, 1.0);
  3595. );
  3596. );
  3597. );
  3598. );
  3599. );
  3600. </action>
  3601. <action name="setup_littleplanet">
  3602. set(control.usercontrol, off);
  3603. copy(lp_scene, xml.scene);
  3604. copy(lp_hlookat, config.panos.pano[get(xml.scene)].view.hlookat);
  3605. copy(lp_vlookat, config.panos.pano[get(xml.scene)].view.vlookat);
  3606. copy(lp_fov, config.panos.pano[get(xml.scene)].view.fov);
  3607. copy(lp_fovmax, config.panos.pano[get(xml.scene)].view.fovmax);
  3608. copy(lp_limitview, config.panos.pano[get(xml.scene)].view.limitview);
  3609. if(enableLittleplanet == 1,
  3610. startViewAnimation1();
  3611. ,
  3612. if(enableLittleplanet == 2,
  3613. startViewAnimation2();
  3614. ,
  3615. if(enableLittleplanet == 3,
  3616. startViewAnimation3();
  3617. ,
  3618. if(enableLittleplanet == 4,
  3619. startViewAnimation4();
  3620. ,
  3621. if(enableLittleplanet == 5,
  3622. startViewAnimation5();
  3623. );
  3624. );
  3625. );
  3626. );
  3627. );
  3628. autorotate.stop();
  3629. </action>
  3630. <action name="startViewAnimation1">
  3631. set(view.fovmax, 170);
  3632. set(view.limitview, lookat);
  3633. set(view.vlookatmin, 90);
  3634. set(view.vlookatmax, 90);
  3635. lookat(calc(lp_hlookat + 180), 90, 150, 1, 0, 0);
  3636. set(events[lp_events].onpreviewcomplete,
  3637. delayedcall(2,
  3638. if(lp_scene === xml.scene,
  3639. set(control.usercontrol, off);
  3640. copy(view.limitview, lp_limitview);
  3641. set(view.vlookatmin, null);
  3642. set(view.vlookatmax, null);
  3643. tween(view.hlookat|view.vlookat|view.fov|view.distortion, calc('' + lp_hlookat + '|' + lp_vlookat + '|' + lp_fov + '|' + 0.0),
  3644. 3.0, easeOutQuad,
  3645. animationComplete();
  3646. );
  3647. );
  3648. );
  3649. );
  3650. </action>
  3651. <action name="startViewAnimation2">
  3652. copy(view.hlookat, config.panos.pano[get(xml.scene)].view.hlookat);
  3653. sub(view.hlookat, 360);
  3654. set(events[lp_events].onpreviewcomplete,
  3655. delayedcall(1,
  3656. if(lp_scene === xml.scene,
  3657. set(control.usercontrol, off);
  3658. tween(view.hlookat, get(lp_hlookat),
  3659. 12.0, easeInOutSine,
  3660. animationComplete();
  3661. );
  3662. );
  3663. );
  3664. );
  3665. </action>
  3666. <action name="startViewAnimation3">
  3667. set(view.fov, 70);
  3668. set(view.vlookat, -40);
  3669. set(view.hlookat, get(config.panos.pano[get(xml.scene)].view.hlookat));
  3670. sub(view.hlookat, 360);
  3671. tween(view.vlookat, 90, 9, easeInOutSine);
  3672. delayedcall(animation2_0,2,
  3673. tween(view.hlookat, get(config.panos.pano[get(xml.scene)].view.hlookat), 7.5, easeInOutSine);
  3674. tween(view.fov, 150.0, 7.5, easeInOutSine);
  3675. delayedcall(animation2_1,7.6,
  3676. tween(view.fisheye, 0.0,3);
  3677. tween(view.vlookat, get(config.panos.pano[get(xml.scene)].view.vlookat), 3, easeInOutSine);
  3678. tween(view.fov, get(config.panos.pano[get(xml.scene)].view.fov), 3, easeInOutSine,
  3679. animationComplete();
  3680. );
  3681. );
  3682. );
  3683. </action>
  3684. <action name="startViewAnimation4">
  3685. set(view.fov, 110);
  3686. set(view.hlookat, get(config.panos.pano[get(xml.scene)].view.hlookat));
  3687. sub(view.hlookat, 360);
  3688. tween(view.hlookat, get(config.panos.pano[get(xml.scene)].view.hlookat), 7.5, easeInOutSine);
  3689. tween(view.vlookat, get(config.panos.pano[get(xml.scene)].view.vlookat), 7.5, easeInOutSine);
  3690. delayedcall(3.5, tween(view.distortion, 0, 4, easeInOutSine););
  3691. tween(view.fov, get(config.panos.pano[get(xml.scene)].view.fov), 7.5, easeInOutSine,
  3692. animationComplete();
  3693. );
  3694. </action>
  3695. <action name="startViewAnimation5">
  3696. set(view.fov, 150);
  3697. set(view.vlookat, -65);
  3698. set(view.hlookat, get(config.panos.pano[get(xml.scene)].view.hlookat));
  3699. add(view.hlookat, 360);
  3700. tween(view.vlookat, 90.0, 9.5, easeInOutSine);
  3701. tween(view.hlookat, get(config.panos.pano[get(xml.scene)].view.hlookat), 9.5, easeInOutSine);
  3702. delayedcall(animation3_0,9.6,
  3703. tween(view.fisheye, 0.0,3);
  3704. tween(view.fov, get(config.panos.pano[get(xml.scene)].view.fov), 3, easeInOutSine,
  3705. animationComplete();
  3706. );
  3707. delayedcall(0.5, tween(view.vlookat, get(config.panos.pano[get(xml.scene)].view.vlookat), 2.5, easeInOutSine););
  3708. );
  3709. </action>
  3710. <action name="animationComplete">
  3711. set(control.usercontrol, all);
  3712. setup_pano_settings();
  3713. setup_global_settings();
  3714. js_sceneReadyCallback();
  3715. setup_autoplay();
  3716. autorotate.interrupt();
  3717. </action>
  3718. <action name="setup_top_mask">
  3719. if(config.panos.pano[get(scene_name)].top_circle !== null AND config.panos.pano[get(scene_name)].top_circle.type != 1 AND forceDisableMask != 1,
  3720. addhotspot(top_mask_layer);
  3721. set(hotspot[top_mask_layer].ath,0);
  3722. set(hotspot[top_mask_layer].isMask,true);
  3723. set(hotspot[top_mask_layer].atv,-90);
  3724. if(config.panos.pano[get(scene_name)].top_circle.scale !== null,
  3725. set(hotspot[top_mask_layer].scale, get(config.panos.pano[get(scene_name)].top_circle.scale));
  3726. );
  3727. set(hotspot[top_mask_layer].rotate,0.0);
  3728. set(hotspot[top_mask_layer].distorted,true);
  3729. set(hotspot[top_mask_layer].enabled,false);
  3730. set(hotspot[top_mask_layer].handcursor,false);
  3731. set(hotspot[top_mask_layer].visible,true);
  3732. set(hotspot[top_mask_layer].keep,false);
  3733. if(config.panos.pano[get(scene_name)].top_circle.is_float == 1,
  3734. set(hotspot[top_mask_layer].distorted,false);
  3735. set(hotspot[top_mask_layer].zoom,true);
  3736. );
  3737. if(config.panos.pano[get(scene_name)].top_circle.type == 0,
  3738. copy(hotspot[top_mask_layer].url, settings.circle_mask);
  3739. ,
  3740. copy(top_circle_url,config.panos.pano[get(scene_name)].top_circle.url);
  3741. txtadd(top_circle_url,'?imageView2/0/w/1024/h/1024');
  3742. copy(hotspot[top_mask_layer].url,top_circle_url);
  3743. );
  3744. );
  3745. </action>
  3746. <action name="setup_bottom_mask">
  3747. if(config.panos.pano[get(scene_name)].bottom_circle !== null AND config.panos.pano[get(scene_name)].bottom_circle.type != 1 AND forceDisableMask != 1,
  3748. addhotspot(bottom_mask_layer);
  3749. if(config.panos.pano[get(scene_name)].bottom_circle.scale !== null,
  3750. set(hotspot[bottom_mask_layer].scale, get(config.panos.pano[get(scene_name)].bottom_circle.scale));
  3751. );
  3752. set(hotspot[bottom_mask_layer].ath,0);
  3753. set(hotspot[bottom_mask_layer].isMask,true);
  3754. set(hotspot[bottom_mask_layer].atv,90);
  3755. set(hotspot[bottom_mask_layer].rotate,0.0);
  3756. set(hotspot[bottom_mask_layer].distorted,true);
  3757. set(hotspot[bottom_mask_layer].enabled,false);
  3758. set(hotspot[bottom_mask_layer].handcursor,false);
  3759. set(hotspot[bottom_mask_layer].visible,true);
  3760. set(hotspot[bottom_mask_layer].keep,false);
  3761. set(hotspot[bottom_mask_layer].zorder,0);
  3762. if(config.panos.pano[get(scene_name)].bottom_circle.is_float == 1,
  3763. set(hotspot[bottom_mask_layer].distorted,false);
  3764. set(hotspot[bottom_mask_layer].zoom,true);
  3765. );
  3766. if(config.panos.pano[get(scene_name)].bottom_circle.type == 0,
  3767. copy(hotspot[bottom_mask_layer].url, settings.circle_mask);
  3768. ,
  3769. copy(bottom_circle_url,config.panos.pano[get(scene_name)].bottom_circle.url);
  3770. txtadd(bottom_circle_url,'?imageView2/0/w/1024/h/1024');
  3771. copy(hotspot[bottom_mask_layer].url,bottom_circle_url);
  3772. );
  3773. );
  3774. </action>
  3775. <action name="setup_radar">
  3776. set(radarEnabled, false);
  3777. if((sceneType == 1 OR sceneType == 3) AND (config.panos.pano[get(scene_name)].radar.enabled == 1 OR config.panos.pano[get(scene_name)].radar.enable == 1),
  3778. set(radarEnabled, true);
  3779. set(layer[radar_layer].type,container);
  3780. set(layer[radar_layer].align,topright);
  3781. set(layer[radar_layer].width,200);
  3782. set(layer[radar_layer].height,200);
  3783. set(layer[radar_layer].bgcapture, true);
  3784. set(layer[radar_layer].handcursor, false);
  3785. set(layer[radar_layer].onclick,toggleRadar();set(layer[radarImageClose].visible,false);js_radarMapFullscreenStatusDidChangeCallback(false););
  3786. if(device.html5 ,
  3787. add(layer[radar_layer].width,4);
  3788. add(layer[radar_layer].height,4);
  3789. );
  3790. if(device.desktop,
  3791. set(layer[radar_layer].y,55);
  3792. set(layer[radar_layer].x,-313);
  3793. ,
  3794. set(layer[radar_layer].y,60);
  3795. set(layer[radar_layer].x,-313);
  3796. );
  3797. set(layer[radar_layer].bgalpha,0);
  3798. set(layer[radar_layer].zorder,5);
  3799. set(destpos1,-313);
  3800. set(destpos2,-100);
  3801. addlayer(radarBtn);
  3802. set(layer[radarBtn].parent,feature_container);
  3803. set(layer[radarBtn].align,centerright);
  3804. set(layer[radarBtn].scale,0.5);
  3805. set(layer[radarBtn].x,0);
  3806. set(layer[radarBtn].y,0);
  3807. if(sceneType == 1,
  3808. set(layer[radarBtn].crop,2|107|108|192);
  3809. layer[radarBtn].loadstyle(skin_style);
  3810. set(layer[radarBtn].title, '沙盘开关');
  3811. set(layer[radarBtn].onclick,
  3812. toggleRadar();
  3813. );
  3814. ,
  3815. set(layer[radarBtn].scale,0);
  3816. set(layer[radarBtn].width,0);
  3817. set(layer[radarBtn].height,0);
  3818. );
  3819. addlayer(mapImage);
  3820. set(layer[mapImage].parent,radar_layer);
  3821. set(layer[mapImage].align,center);
  3822. set(layer[mapImage].x,0);
  3823. set(layer[mapImage].y,0);
  3824. set(map_url,get(config.panos.pano[get(scene_name)].radar.map_url));
  3825. txtadd(map_url,'?imageMogr2/thumbnail/480x');
  3826. set(layer[mapImage].url,get(map_url));
  3827. set(layer[mapImage].zorder,9);
  3828. set(layer[mapImage].handcursor,false);
  3829. set(layer[mapImage].onloaded,set(radarImageWidth,get(width));set(radarImageHeight,get(height));set(layer[mapImage].width,200);set(layer[mapImage].height,200););
  3830. addlayer(mapImageLoading);
  3831. set(layer[mapImageLoading].parent,radar_layer);
  3832. set(layer[mapImageLoading].align,center);
  3833. set(layer[mapImageLoading].x,0);
  3834. set(layer[mapImageLoading].y,0);
  3835. set(layer[mapImageLoading].zorder,7);
  3836. set(layer[mapImageLoading].handcursor,false);
  3837. addlayer(radarMask);
  3838. set(layer[radarMask].parent,mapImage);
  3839. set(layer[radarMask].type,container);
  3840. set(layer[radarMask].align,lefttop);
  3841. set(layer[radarMask].width,100%);
  3842. set(layer[radarMask].height,100%);
  3843. set(layer[radarMask].maskchildren,true);
  3844. addlayer(mapZoomBtn);
  3845. set(layer[mapZoomBtn].parent,radar_layer);
  3846. set(layer[mapZoomBtn].align,bottomcenter);
  3847. set(layer[mapZoomBtn].width,120);
  3848. set(layer[mapZoomBtn].height,50);
  3849. set(layer[mapZoomBtn].scale,0.75);
  3850. set(layer[mapZoomBtn].x,0);
  3851. set(layer[mapZoomBtn].y,-35);
  3852. copy(layer[mapZoomBtn].url,settings.map_zoom_image);
  3853. set(layer[mapZoomBtn].zorder,10);
  3854. set(layer[mapZoomBtn].handcursor,true);
  3855. set(layer[mapZoomBtn].onclick,zoomRadar(););
  3856. txtadd(radarActiveSpotName,'radarActiveSpot');
  3857. txtadd(radarSpotTitle,'',get(config.panos.pano[get(scene_name)].info.title));
  3858. addlayer(get(radarActiveSpotName));
  3859. set(layer[get(radarActiveSpotName)].parent,radarMask);
  3860. set(layer[get(radarActiveSpotName)].crop,279|109|49|49);
  3861. layer[get(radarActiveSpotName)].loadstyle(skin_style);
  3862. set(layer[get(radarActiveSpotName)].align,lefttop);
  3863. set(layer[get(radarActiveSpotName)].edge,center);
  3864. set(layer[get(radarActiveSpotName)].visible,false);
  3865. if(config.panos.pano[get(scene_name)].radar.heading_offset !== null,
  3866. set(layer[get(radarActiveSpotName)].visible,true);
  3867. if(config.panos.pano[get(scene_name)].radar.scale === null,
  3868. set(layer[get(radarActiveSpotName)].scale,0.5);
  3869. ,
  3870. set(layer[get(radarActiveSpotName)].scale,get(config.panos.pano[get(scene_name)].radar.scale));
  3871. );
  3872. set(radarx,get(config.panos.pano[get(scene_name)].radar.x));
  3873. set(radary,get(config.panos.pano[get(scene_name)].radar.y));
  3874. div(radarx,2.4);
  3875. set(layer[get(radarActiveSpotName)].x,get(radarx));
  3876. div(radary,2.4);
  3877. set(layer[get(radarActiveSpotName)].y,get(radary));
  3878. set(layer[get(radarActiveSpotName)].zorder,10);
  3879. set(layer[get(radarActiveSpotName)].linkedSceneTitle,get(config.panos.pano[get(scene_name)].info.title));
  3880. set(layer[get(radarActiveSpotName)].onhover,showtext(get(linkedSceneTitle),tooltipTextStyle););
  3881. );
  3882. addlayer(radarImageClose);
  3883. copy(layer[radarImageClose].url,settings.close_image);
  3884. set(layer[radarImageClose].align,topright);
  3885. set(layer[radarImageClose].x,0);
  3886. set(layer[radarImageClose].y,0); if(config.panos.pano[get(scene_name)].inner=="1" AND device.mobile==true,
  3887. set(layer[radarImageClose].y,61);
  3888. );
  3889. set(layer[radarImageClose].visible,false);
  3890. set(layer[radarImageClose].scale,0.5);
  3891. set(layer[radarImageClose].autowidth,true);
  3892. set(layer[radarImageClose].autoheight,true);
  3893. set(layer[radarImageClose].background,false);
  3894. set(layer[radarImageClose].zorder,101);
  3895. set(layer[radarImageClose].border,false);
  3896. set(layer[radarImageClose].onclick,toggleRadar();set(layer[radarImageClose].visible,false);js_radarMapFullscreenStatusDidChangeCallback(false););
  3897. set(layer[radarImageClose].parent,layer[radar_layer]);
  3898. if(config.panos.pano[get(scene_name)].radar.heading_offset !== null,
  3899. addlayer(radar);
  3900. set(layer[radar].parent,radarMask);
  3901. if(device.flash,
  3902. set(layer[radar].url,get(plugin_url.RADAR_SWF));
  3903. ,
  3904. set(layer[radar].url,get(plugin_url.RADAR_JS));
  3905. );
  3906. set(layer[radar].align,lefttop);
  3907. set(layer[radar].edge,center);
  3908. set(layer[radar].scale,0.5);
  3909. set(layer[radar].zorder,9);
  3910. set(layer[radar].fillcolor,0xFFFFFF);
  3911. set(layer[radar].fillalpha,0.4);
  3912. set(layer[radar].linecolor,0xFF0000);
  3913. set(layer[radar].linewidth,1.0);
  3914. set(layer[radar].linealpha,0.5);
  3915. set(layer[radar].headingoffset,get(config.panos.pano[get(scene_name)].radar.heading_offset));
  3916. set(layer[radar].x,get(layer[get(radarActiveSpotName)].x));
  3917. set(layer[radar].y,get(layer[get(radarActiveSpotName)].y));
  3918. );
  3919. for(set(i,0),i LT config.panos.pano[get(scene_name)].radar.radarspot.count,inc(i),
  3920. txtadd(radarSpotName,'radarSpot',get(i));
  3921. txtadd(radarSpotTitle,'',get(config.panos.pano[get(scene_name)].info.title));
  3922. addlayer(get(radarSpotName));
  3923. set(layer[get(radarSpotName)].parent,radarMask);
  3924. set(layer[get(radarSpotName)].crop,195|109|80|80);
  3925. layer[get(radarSpotName)].loadstyle(skin_style);
  3926. set(layer[get(radarSpotName)].align,lefttop);
  3927. set(layer[get(radarSpotName)].edge,center);
  3928. if(config.panos.pano[get(scene_name)].radar.scale === null,
  3929. set(layer[get(radarSpotName)].scale,0.35);
  3930. ,
  3931. set(layer[get(radarSpotName)].scale,get(config.panos.pano[get(scene_name)].radar.scale));
  3932. );
  3933. set(radarx,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].x));
  3934. set(radary,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].y));
  3935. div(radarx,2.4);
  3936. set(layer[get(radarSpotName)].x,get(radarx));
  3937. div(radary,2.4);
  3938. set(layer[get(radarSpotName)].y,get(radary));
  3939. set(layer[get(radarSpotName)].zorder,2);
  3940. set(layer[get(radarSpotName)].linkedScene,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].linkedscene));
  3941. set(layer[get(radarSpotName)].linkedSceneTitle,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].title));
  3942. set(layer[get(radarSpotName)].onhover,showtext(get(linkedSceneTitle),tooltipTextStyle););
  3943. set(layer[get(radarSpotName)].onclick,
  3944. js_sceneChangeCallback(get(scene[get(linkedscene)].scene_id));
  3945. );
  3946. );
  3947. set(radarOldStatus,true);
  3948. ); if(config.panos.pano[get(scene_name)].radar.opened=="1" AND radarIsShow === null,
  3949. set(radarIsShow,false);
  3950. toggleRadar();
  3951. , if(radarIsShow==true AND vrmode!=true,
  3952. set(radarIsShow,false);
  3953. toggleRadar();
  3954. ,
  3955. if(radarEnabled == true,
  3956. js_radarMapStatusDidChangeCallback(false);
  3957. );
  3958. set(layer[radarBtn].crop,98|107|108|192);
  3959. );
  3960. );
  3961. if(webvr.isenabled == true,
  3962. hide_UI(0,1);
  3963. );
  3964. </action>
  3965. <action name="zoomRadar">
  3966. set(layer[radar_layer].bgalpha,0.5);
  3967. set(layer[radarBtn].visible,false);
  3968. set(layer[radarImageClose].visible,true);
  3969. set(radarOldPosX,get(layer[radar_layer].x));
  3970. set(radarOldPosY,get(layer[radar_layer].y));
  3971. set(layer[radar_layer].height,100%);
  3972. set(layer[radar_layer].width,100%);
  3973. set(layer[radar_layer].x,0);
  3974. set(layer[radar_layer].y,0);
  3975. set(radarImageScale,get(radarImageWidth));
  3976. div(radarImageScale,get(radarImageHeight));
  3977. set(radarStageScale,get(stagewidth));
  3978. mul(radarStageScale,0.8);
  3979. div(radarStageScale,get(stageheight));
  3980. div(radarImageScale,0.8);
  3981. if(radarImageWidth LT stagewidth AND radarImageHeight LT stageheight,
  3982. set(layer[mapImage].width,get(radarImageWidth));
  3983. set(layer[mapImage].height,get(radarImageHeight));
  3984. ,
  3985. if(radarImageScale GT radarStageScale,
  3986. set(layer[mapImage].width,get(stagewidth));
  3987. mul(layer[mapImage].width,0.8);
  3988. set(layer[mapImage].height,get(radarImageHeight));
  3989. mul(layer[mapImage].height,get(layer[mapImage].width));
  3990. div(layer[mapImage].height,get(radarImageWidth));
  3991. ,
  3992. set(layer[mapImage].height,get(stageheight));
  3993. mul(layer[mapImage].height,0.8);
  3994. set(layer[mapImage].width,get(radarImageWidth));
  3995. mul(layer[mapImage].width,get(layer[mapImage].height));
  3996. div(layer[mapImage].width,get(radarImageHeight));
  3997. );
  3998. );
  3999. set(layer[get(radarActiveSpotName)].x,get(config.panos.pano[get(scene_name)].radar.x));
  4000. mul(layer[get(radarActiveSpotName)].x,get(layer[mapImage].width));
  4001. div(layer[get(radarActiveSpotName)].x,480);
  4002. set(layer[get(radarActiveSpotName)].y,get(config.panos.pano[get(scene_name)].radar.y));
  4003. mul(layer[get(radarActiveSpotName)].y,get(layer[mapImage].height));
  4004. div(layer[get(radarActiveSpotName)].y,480);
  4005. set(layer[radar].x,get(layer[get(radarActiveSpotName)].x));
  4006. set(layer[radar].y,get(layer[get(radarActiveSpotName)].y));
  4007. for(set(i,0),i LT config.panos.pano[get(scene_name)].radar.radarspot.count,inc(i),
  4008. txtadd(radarSpotName,'radarSpot',get(i));
  4009. txtadd(radarSpotTitle,'',get(config.panos.pano[get(scene_name)].info.title));
  4010. set(layer[get(radarSpotName)].x,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].x));
  4011. mul(layer[get(radarSpotName)].x,get(layer[mapImage].width));
  4012. div(layer[get(radarSpotName)].x,480);
  4013. set(layer[get(radarSpotName)].y,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].y));
  4014. mul(layer[get(radarSpotName)].y,get(layer[mapImage].width));
  4015. div(layer[get(radarSpotName)].y,480);
  4016. );
  4017. pause_autoplay();
  4018. hide_UI(1);
  4019. js_radarMapFullscreenStatusDidChangeCallback(true);
  4020. </action>
  4021. <action name="toggleRadar">
  4022. set(layer[radar_layer].bgalpha,0);
  4023. set(layer[radarImageClose].visible,false);
  4024. set(layer[radarBtn].visible,true);
  4025. if(layer[radar_layer].height == 100%,
  4026. set(layer[radar_layer].width,200);
  4027. set(layer[radar_layer].height,200);
  4028. set(layer[mapImage].width,200);
  4029. set(layer[mapImage].height,200);
  4030. set(layer[radar_layer].x,get(radarOldPosX));
  4031. set(layer[radar_layer].y,get(radarOldPosY));
  4032. set(radarx,get(config.panos.pano[get(scene_name)].radar.x));
  4033. set(radary,get(config.panos.pano[get(scene_name)].radar.y));
  4034. div(radarx,2.4);
  4035. set(layer[get(radarActiveSpotName)].x,get(radarx));
  4036. div(radary,2.4);
  4037. set(layer[get(radarActiveSpotName)].y,get(radary));
  4038. set(layer[radar].x,get(layer[get(radarActiveSpotName)].x));
  4039. set(layer[radar].y,get(layer[get(radarActiveSpotName)].y));
  4040. for(set(i,0),i LT config.panos.pano[get(scene_name)].radar.radarspot.count,inc(i),
  4041. txtadd(radarSpotName,'radarSpot',get(i));
  4042. txtadd(radarSpotTitle,'',get(config.panos.pano[get(scene_name)].info.title));
  4043. set(radarx,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].x));
  4044. set(radary,get(config.panos.pano[get(scene_name)].radar.radarspot[get(i)].y));
  4045. div(radarx,2.4);
  4046. set(layer[get(radarSpotName)].x,get(radarx));
  4047. div(radary,2.4);
  4048. set(layer[get(radarSpotName)].y,get(radary));
  4049. );
  4050. ,
  4051. if(radarIsShow == true,
  4052. if(device.mobile,
  4053. set(destpos1, -313);
  4054. ,
  4055. set(destpos1, -313);
  4056. );
  4057. set(layer[radarBtn].crop,98|107|108|192);
  4058. set(radarIsShow,false);
  4059. ,
  4060. if(device.mobile,
  4061. set(destpos1, 50);
  4062. ,
  4063. set(destpos1, 66);
  4064. );
  4065. set(layer[radarBtn].crop,2|107|108|192);
  4066. set(radarIsShow,true);
  4067. );
  4068. tween(layer[radar_layer].x,get(destpos1));
  4069. if(radarEnabled == true,
  4070. js_radarMapStatusDidChangeCallback(get(radarIsShow));
  4071. );
  4072. );
  4073. if(isAutoTouring OR webvr.isenabled,
  4074. hide_UI();
  4075. ,
  4076. show_UI();
  4077. );
  4078. </action>
  4079. <action name="switch_to_multires">
  4080. for(set(i,0), i LT scene.count, inc(i),
  4081. txtreplace(scene[get(i)].content, "webvr.isenabled AND device.desktop", "webvr.isenabled OR device.desktop");
  4082. );
  4083. ifnot(xml.scene === null,
  4084. loadscene(get(xml.scene),null,KEEPVIEW|MERGE,BLEND(0.5, easeInCubic));
  4085. );
  4086. </action>
  4087. <action name="switch_to_mobile">
  4088. for(set(i,0), i LT scene.count, inc(i),
  4089. txtreplace(scene[get(i)].content, "webvr.isenabled OR device.desktop", "webvr.isenabled AND device.desktop");
  4090. );
  4091. ifnot(xml.scene === null,
  4092. loadscene(get(xml.scene),null,KEEPVIEW|MERGE,BLEND(0.5, easeInCubic));
  4093. );
  4094. </action>
  4095. <action name="load_pano_by_id">
  4096. if(pano_id != %1,
  4097. if(autorotate.enabled == true,
  4098. set(autorotate.enabled, false);
  4099. );
  4100. if(hotspot[get(embed_video_name)].music_pause == 1 AND hotspot[get(embed_video_name)].ispaused == false AND need_pause_bg_music_sound == false,
  4101. js_toggleBgMusic(true);
  4102. );
  4103. if(hotspot[get(embed_video_name)].sound_pause == 1 AND hotspot[get(embed_video_name)].ispaused == false AND need_pause_bg_music_sound == false,
  4104. js_toggleBgVoice(true);
  4105. );
  4106. set(pano_id,%1);
  4107. copy(scene_name, pano_id);
  4108. set(blend_mode_name, 'blend');
  4109. txtadd(blend_mode_name, %3);
  4110. set(blend_mode, get(blendmodes[get(blend_mode_name)].blend));
  4111. if(blend_mode === null,
  4112. copy(blend_mode,blendmodes[blend0].blend);
  4113. );
  4114. if(%2 == 1 ,
  4115. set(needKeepview, true);
  4116. copy(needKeepviewHlookat, view.hlookat);
  4117. copy(needKeepviewVlookat, view.vlookat);
  4118. copy(needKeepviewFov, view.fov);
  4119. loadscene(get(pano_id),null,KEEPVIEW|MERGE,get(blend_mode));
  4120. ,
  4121. set(needKeepview, false);
  4122. loadscene(get(pano_id),null,MERGE,get(blend_mode));
  4123. set(view.hlookat,get(config.panos.pano[get(xml.scene)].view.hlookat));
  4124. set(view.vlookat,get(config.panos.pano[get(xml.scene)].view.vlookat));
  4125. set(view.fov,get(config.panos.pano[get(xml.scene)].view.fov));
  4126. );
  4127. copy(blend_mode,blendmodes[blend0].blend);
  4128. ,
  4129. lookto(get(config.panos.pano[get(xml.scene)].view.hlookat), get(config.panos.pano[get(xml.scene)].view.vlookat), get(config.panos.pano[get(xml.scene)].view.fov));
  4130. );
  4131. if(is_setup_start_pano === null,
  4132. setup_start_pano();
  4133. set(is_setup_start_pano, true);
  4134. );
  4135. if(webvr.isenabled,
  4136. webvr_load_vr_cursor_hs();
  4137. );
  4138. </action>
  4139. <action name="setup_vr">
  4140. copy(vr_plugin_url,plugin_url.WEBVR_JS);
  4141. copy(plugin[WebVR].url, vr_plugin_url);
  4142. set(webvr_text_noDistortion, '无畸变');
  4143. set(webvr_text_webvrSetup, 'WebVR 设置');
  4144. set(webvr_text_mobilevrSetup, 'MobileVR 设置');
  4145. set(webvr_text_screensize, '屏幕尺寸(英寸):');
  4146. set(webvr_text_vrheadset, 'VR 头显预设');
  4147. set(webvr_text_customizeHeadset, '自定义头显');
  4148. set(webvr_text_adjustmentInVR, '在 VR 中进行调整');
  4149. set(webvr_text_close, '关闭');
  4150. set(webvr_text_preset, '预设:');
  4151. set(webvr_text_fov, 'FOV');
  4152. set(webvr_text_interLensDistance, '内镜距离(mm):');
  4153. set(webvr_text_screenToLensDistance, '屏幕到镜头距离(mm):');
  4154. set(webvr_text_trayToLensCenterDistance, '头显到镜头中央的距离(mm):');
  4155. set(webvr_text_lensDistortion, '镜头畸变系数:');
  4156. set(webvr_text_oversampling, '过采样:');
  4157. </action>
  4158. <action name="disable_vr">
  4159. set(layer[vr_layer].visible,false);
  4160. js_vrUnavailableCallback();
  4161. </action>
  4162. <action name="turn_on_vr">
  4163. webvr.entervr();
  4164. </action>
  4165. <action name="turn_off_vr">
  4166. webvr.exitvr();
  4167. </action>
  4168. <action name="hide_vr_hotspot">
  4169. if(webvr.isenabled == true,
  4170. pause_embed_video();
  4171. copy(hotspotCount,hotspot.count);
  4172. for(set(i,0),i LT hotspotCount,inc(i),
  4173. if(hotspot[get(i)].image_type == 2 AND hotspot[get(i)].isActiveHotspot == true,
  4174. set(hotspot[get(i)].renderer,webgl);
  4175. );
  4176. if(hotspot[get(i)].isMask == true,
  4177. ,
  4178. if(hotspot[get(i)].hotspot_type == 0 AND hotspot[get(i)].is_hotspot_txt != true,
  4179. if(device.mobilevr ,
  4180. set(hotspot[get(i)].scale,0.25);
  4181. );
  4182. );
  4183. if(hotspot[get(i)].hotspot_type == 0,
  4184. if(device.mobilevr,
  4185. set(hotspot[get(i)].scale,0.5);
  4186. );
  4187. );
  4188. if(hotspot[get(i)].hotspot_type != 0 AND hotspot[get(i)].hotspot_type != 4,
  4189. set(hotspot[get(i)].visible,false);
  4190. set(hotspot[get(i)].hide_action,'hide_vr_hotspot');
  4191. );
  4192. );
  4193. if(hotspot[get(i)].html !== null,
  4194. if(webvr.isenabled == true,
  4195. set(hotspot[get(i)].renderer, 'webgl');
  4196. ,
  4197. set(hotspot[get(i)].renderer, 'css3d');
  4198. );
  4199. copy(texthtml, hotspot[get(i)].html);
  4200. set(hotspot[get(i)].html, '');
  4201. copy(hotspot[get(i)].html, texthtml);
  4202. );
  4203. );
  4204. );
  4205. </action>
  4206. <action name="show_vr_hotspot">
  4207. copy(hotspotCount,hotspot.count);
  4208. for(set(i,0),i LT hotspotCount,inc(i),
  4209. if(hotspot[get(i)].image_type == 2 AND hotspot[get(i)].html === null,
  4210. set(hotspot[get(i)].renderer,"css3d");
  4211. );
  4212. if(hotspot[get(i)].isMask,
  4213. ,
  4214. if(hotspot[get(i)].hotspot_type == 0 AND hotspot[get(i)].is_hotspot_txt != true,
  4215. if(device.mobilevr ,
  4216. set(hotspot[get(i)].scale,0.5)
  4217. );
  4218. );
  4219. if(hotspot[get(i)].hotspot_type == 0 AND hotspot[get(i)].is_hotspot_txt == true,
  4220. if(device.mobilevr,
  4221. set(hotspot[get(i)].scale,1);
  4222. );
  4223. );
  4224. if(hotspot[get(i)].hotspot_type != 0 AND hotspot[get(i)].hide_action == 'hide_vr_hotspot',
  4225. set(hotspot[get(i)].visible,true);
  4226. set(hotspot[get(i)].hide_action,'');
  4227. );
  4228. );
  4229. if(hotspot[get(i)].html !== null,
  4230. if(webvr.isenabled == true,
  4231. set(hotspot[get(i)].renderer, 'webgl');
  4232. ,
  4233. set(hotspot[get(i)].renderer, 'css3d');
  4234. );
  4235. copy(texthtml, hotspot[get(i)].html);
  4236. set(hotspot[get(i)].html, '');
  4237. copy(hotspot[get(i)].html, texthtml);
  4238. );
  4239. );
  4240. </action>
  4241. <plugin name="webvr" devices="html5" keep="true" url="" mobilevr_support="true" mobilevr_touch_support="true" mobilevr_fake_support="true" mobilevr_profile.normal="90|60|42|0|0|0" mobilevr_profile.mobile="80|60|42|35|0.441|0.156" mobilevr_wakelock="true" fullscreen_mirroring="false" mouse_pointerlock="true" vr_cursor_onover="if(handcursor, tween(hotspot[vr_cursor].scale,0.4,0.1); vr_auto_click(get(vr_timeout)); );" vr_cursor_onout="tween(hotspot[vr_cursor].scale,0.3,0.1);" onavailable="webvr_onavailable();" onunavailable="" onunknowndevice="webvr_onunknowndevice();" onvrcontrollers="webvr_onvrcontrollers();" onentervr="webvr_onentervr();" onexitvr="webvr_onexitvr();" onloaded="copy(webvr, plugin[WebVR]);"/>
  4242. <style name="vr_cursor_style" url="calc:settings.skin_url + 'skin/webvr_cursor_80x80_17f.png'" visible="false" enabled="false" distorted="true" crop="0|0|80|80" scale="0.3" depth="120"/>
  4243. <action name="webvr_load_vr_cursor_hs" scope="local">
  4244. addhotspot('vr_cursor', hs);
  4245. hs.loadstyle(vr_cursor_style);
  4246. set(hs.keep, true);
  4247. set(webvr.vr_cursor, 'hotspot[vr_cursor]');
  4248. </action>
  4249. <action name="webvr_load_vr_controller_hs" scope="private:VRCONTROLLERS" args="controllerstyle">
  4250. removehotspot('vr_controller_l');
  4251. removehotspot('vr_controller_r');
  4252. addhotspot('vr_controller_l', vr_ctrl_l);
  4253. addhotspot('vr_controller_r', vr_ctrl_r);
  4254. set(vr_ctrl_l.keep, true);
  4255. set(vr_ctrl_r.keep, true);
  4256. vr_ctrl_l.loadstyle(calc(controllerstyle ? controllerstyle : 'vrcontroller_light_and_point'));
  4257. vr_ctrl_r.loadstyle(calc(controllerstyle ? controllerstyle : 'vrcontroller_light_and_point'));
  4258. vr_ctrl_l.addevent('onvrcontrollerbutton', 'if(vrbuttonindex == 3 AND vrbuttonstate == "up", vrsetup_open(); );' );
  4259. vr_ctrl_r.addevent('onvrcontrollerbutton', 'if(vrbuttonindex == 3 AND vrbuttonstate == "up", vrsetup_open(); );' );
  4260. set(global.webvr.vr_controller, 'vr_controller_l,vr_controller_r');
  4261. set(global.have_vr_controllers, true);
  4262. if(global.webvr.isvrbrowser AND global.webvr.vrcontrollers[0].buttons.length LE 2,
  4263. addhotspot('webvr_vrsetup', vr_setup_hs);
  4264. vr_setup_hs.loadstyle('webvr_button_style');
  4265. set(vr_setup_hs, keep=true, ath=0, atv=90, depth=160, zorder=999, torigin=view, html='VR SETUP', oversampling=3, scale=0.2, onclick='vrsetup_open();', onloaded='renderloop( copy(ath,view.hlookat); );');
  4266. );
  4267. </action>
  4268. <action name="webvr_onvrcontrollers" scope="private:VRCONTROLLERS">
  4269. if(!global.have_vr_controllers, webvr_load_vr_controller_hs(); );
  4270. </action>
  4271. <style name="vrcontroller_laser" url="calc:settings.skin_url + 'skin/webvr_laser.png'" distorted="true" enabled="false" visible="false" width="0.5" height="1000" edge="bottom" oref="1" oy="0" torigin="world" tx="0" ty="0" tz="0" depth="0" zorder="99999" depthbuffer="true" onloaded="asyncloop(loaded, calc(height, (target AND target.hitd GT 0 ? target.hitd : 1000) / display.hotspotworldscale); );"/>
  4272. <style name="vrcontroller_light_and_point" url="calc:settings.skin_url + 'skin/webvr_light.png'" distorted="true" enabled="false" visible="false" width="0.5" height="18" edge="bottom" oref="1" oy="0" torigin="world" tx="0" ty="0" tz="0" depth="0" zorder="99999" depthbuffer="true" onloaded="vrcontroller_target_point();"/>
  4273. <style name="vrcontroller_handcursor_and_point" url="calc:settings.skin_url + 'skin/webvr_handcursor.png'" distorted="true" enabled="false" visible="false" width="10" height="10" edge="center" oref="1" oy="-1" torigin="world" tx="0" ty="0" tz="0" depth="0" zorder="99999" depthbuffer="true" onloaded="vrcontroller_target_point();"/>
  4274. <action name="vrcontroller_target_point" scope="localonly">
  4275. addhotspot(auto, hs);
  4276. set(hs, keep=true, type=text, bgcolor=0xFFFFFF, bgalpha=1.0, width=10, height=10, bgroundedge=5, bgborder='1 0x000000 1.0', oversampling=2, scale=0.4, torigin=world, depth=0, distorted=false, zoom=true, zorder=99998, enabled=false
  4277. );
  4278. renderloop(
  4279. if(!caller.loaded,
  4280. removehotspot(get(hs.name));
  4281. stoprenderloop();
  4282. ,
  4283. if(global.display.havedepthmap,
  4284. removehotspot(get(hs.name));
  4285. stoprenderloop();
  4286. webvr_load_vr_controller_hs('vrcontroller_laser');
  4287. ,
  4288. calc(hs.bgcolor, caller.pressed ? 0x049AFF : (caller.hovering ? 0x00FF00 : 0xFFFFFF));
  4289. calc(distance, (caller.target AND caller.target.hitd GT 0 ? caller.target.hitd : 1000));
  4290. calc(hs.scale, 0.4 * (distance GT 1000 ? distance / 1000 : (distance LT 200 ? 0.25 : (0.25 + (distance - 200)/800 * 0.75))));
  4291. calc(hs.tx, caller.tx + caller.dx * distance);
  4292. calc(hs.ty, caller.ty + caller.dy * distance);
  4293. calc(hs.tz, caller.tz + caller.dz * distance);
  4294. );
  4295. );
  4296. );
  4297. </action>
  4298. <action name="vr_auto_click" scope="local" args="vr_aclk_timeout">
  4299. if(webvr.isenabled,
  4300. if(vr_aclk_timeout == null, set(vr_aclk_timeout, 2000));
  4301. copy(vr_aclk_t1, timertick);
  4302. set(vr_aclk_waiting, true);
  4303. copy(webvr.vr_aclk_hotspot, caller.name);
  4304. set(hotspot[vr_cursor].crop,'0|0|80|80');
  4305. asyncloop(vr_aclk_waiting AND webvr.vr_aclk_hotspot == caller.name,
  4306. sub(dt, timertick, vr_aclk_t1);
  4307. if(!caller.hovering,
  4308. set(vr_aclk_waiting, false);
  4309. set(hotspot[vr_cursor].crop,'0|0|80|80');
  4310. ,
  4311. div(f, dt, vr_aclk_timeout);
  4312. mul(f, 16);
  4313. roundval(f);
  4314. Math.min(f, 16);
  4315. mul(f, 80);
  4316. txtadd(hotspot[vr_cursor].crop,get(f),'|0|80|80');
  4317. sub(dt, 100);
  4318. if(dt GT vr_aclk_timeout,
  4319. set(vr_aclk_waiting,false);
  4320. set(hotspot[vr_cursor].crop,'0|0|80|80');
  4321. callwith(caller, scope(global, ondown();onup();onclick(); ); );
  4322. );
  4323. );
  4324. );
  4325. );
  4326. </action>
  4327. <events name="webvr_events" devices="html5" keep="true" onmousedown="if(webvr AND webvr.isenabled, webvr_showbuttons() );"/>
  4328. <action name="webvr_onavailable">
  4329. webvr.loadsettings();
  4330. jsget(needUpdateVRSettings,'krpCallbackObject');
  4331. if(needUpdateVRSettings !== null,
  4332. delayedcall(3,
  4333. jscall('krpCallbackObject.krpUpdateVRSettingCallback();');
  4334. );
  4335. );
  4336. </action>
  4337. <action name="webvr_onunknowndevice">
  4338. if(webvr.isfake AND device.desktop AND webvr.havesettings == false,
  4339. set(webvr.mobilevr_lens_overlap, 1.0);
  4340. set(webvr.mobilevr_lens_fov, 96.0);
  4341. set(webvr.mobilevr_lens_dist, 0.0);
  4342. set(webvr.mobilevr_lens_dist2, '1|0|0|0');
  4343. set(webvr.mobilevr_lens_ca, 0.0);
  4344. set(webvr.mobilevr_lens_vign, 100);
  4345. );
  4346. </action>
  4347. <action name="webvr_onentervr">
  4348. webvr_showbuttons();
  4349. webvr_hide_all_non_vr_layers();
  4350. if(webvr.isfake, webvr_show_fakemode_info(true); );
  4351. webvr_load_vr_cursor_hs();
  4352. hide_UI();
  4353. hide_vr_hotspot();
  4354. </action>
  4355. <action name="webvr_onexitvr">
  4356. removehotspot('vr_cursor');
  4357. removehotspot('vr_controller_l');
  4358. removehotspot('vr_controller_r');
  4359. set(have_vr_controllers, false);
  4360. stopdelayedcall(vr_button_fadeout);
  4361. tween(layer[webvr_exitbutton].alpha,0);
  4362. tween(layer[webvr_setupbutton].alpha,0);
  4363. webvr_show_fakemode_info(false);
  4364. webvr_restore_layers();
  4365. show_vr_hotspot();
  4366. show_UI();
  4367. if(plugin[snow] !== null,
  4368. set(plugin[snow].visible, true);
  4369. );
  4370. resume_embed_video();
  4371. js_exitVRCallback();
  4372. </action>
  4373. <action name="webvr_hide_all_non_vr_layers" scope="local">
  4374. for(set(i,0), i LT layer.count, inc(i),
  4375. copy(lr, layer[get(i)]);
  4376. if(lr.vr !== true,
  4377. copy(lr.vr_backup_visible, lr.visible);
  4378. set(lr.visible, false);
  4379. );
  4380. );
  4381. </action>
  4382. <action name="webvr_restore_layers" scope="local">
  4383. for(set(i,0), i LT layer.count, inc(i),
  4384. copy(lr, layer[get(i)]);
  4385. if(lr.vr_backup_visible,
  4386. copy(lr.visible, lr.vr_backup_visible);
  4387. delete(lr.vr_backup_visible);
  4388. );
  4389. );
  4390. </action>
  4391. <action name="webvr_show_fakemode_info" scope="local" args="show">
  4392. if(show == true, addlayer(webvr_fakemode_info); set(layer[webvr_fakemode_info], type='text', keep=true, align='bottom', y=80, bg=false, css='color:#FFFFFF;text-align:center;', html='[i][u]Simulated WebVR Mode![/u][br]For real WebVR with headset tracking use a [a href="http://webvr.info" target="_blank" style="color:#FFFFFF;"]WebVR-capable[/a] browser or a mobile device and a VR headset.[/i]'
  4393. );
  4394. ,
  4395. removelayer(webvr_fakemode_info);
  4396. );
  4397. </action>
  4398. <krpano webvr_setup_scale="calc:(1.0 + 1.0*(device.mobile AND stagescale LT 1.0)) / (1.0 + 1.0*device.mobile)" webvr_button_scale.normal="1.0" webvr_button_scale.mobile="1.6"/>
  4399. <style name="webvr_button_style" type="text" bgcolor="0x000000" bgalpha="0.5" bgroundedge="0" css="calc:'color:#FFFFFF;font-size:' + 20*webvr_setup_scale*webvr_button_scale + 'px;'" padding="calc:6*webvr_setup_scale*webvr_button_scale + ' ' + 10*webvr_setup_scale*webvr_button_scale"/>
  4400. <layer name="webvr_exitbutton" keep="true" vr="true" style="webvr_button_style" html="退出 VR" align="top" y="24" autoalpha="true" alpha="0.0" onclick="webvr.exitVR();"/>
  4401. <layer name="webvr_setupbutton" keep="true" vr="true" style="webvr_button_style" html="VR 设置" align="bottom" y="110" autoalpha="true" alpha="0.0" onclick="vrsetup_open();"/>
  4402. <action name="webvr_showbuttons">
  4403. stopdelayedcall(vr_button_fadeout);
  4404. tween(layer[webvr_exitbutton].alpha|layer[webvr_setupbutton].alpha, 1.0|1.0, 0.25);
  4405. delayedcall(vr_button_fadeout, 3.0, tween(layer[webvr_exitbutton].alpha|layer[webvr_setupbutton].alpha, 0.0|0.0, 1.0); );
  4406. </action>
  4407. <mobilevr_presets>
  4408. <headset name="cbv1" caption="Cardboard V1" profile="80|60|42|35|0.441|0.156"/>
  4409. <headset name="cbv2" caption="Cardboard V2" profile="120|64|39|35|0.34|0.55"/>
  4410. <headset name="dydm" caption="Daydream" profile="104|60|41|35|0.42|0.51"/>
  4411. <headset name="nodt" caption="无畸变" profile="90|60|42|0|0|0"/>
  4412. <headset name="pico" caption="Pico" profile="92|62.5|42|0|0|0"/>
  4413. </mobilevr_presets>
  4414. <action name="vrsetup_open">
  4415. if(!vrsetup_open_js, vrsetup_init(); );
  4416. vrsetup_open_js();
  4417. </action>
  4418. <action name="vrsetup_init" type="Javascript"><![CDATA[
  4419. var webvr = krpano.webvr;
  4420. var padding = 20;
  4421. function vrsetup_dlg_create(type)
  4422. {
  4423. var dlg = {type:type, bg:null, y:0, scale:1, elements:[]};
  4424. if (type == 'layer')
  4425. {
  4426. dlg.bg = krpano.addlayer();
  4427. dlg.bg.keep = true;
  4428. dlg.bg.type = 'container';
  4429. dlg.bg.align = 'center';
  4430. }
  4431. else // 'hotspot'
  4432. {
  4433. dlg.scale = 0.15;
  4434. dlg.bg = krpano.addhotspot();
  4435. dlg.bg.keep = true;
  4436. dlg.bg.type = 'text';
  4437. dlg.bg.distorted = true;
  4438. dlg.bg.ath = krpano.view.hlookat;
  4439. dlg.bg.atv = 0;
  4440. dlg.bg.depth = 150;
  4441. dlg.bg.torigin = 'world';
  4442. dlg.bg.tx = krpano.view.tx;
  4443. dlg.bg.ty = krpano.view.ty;
  4444. dlg.bg.tz = krpano.view.tz;
  4445. }
  4446. dlg.bg.bgcolor = 0x000000;
  4447. dlg.bg.bgalpha = 0.5;
  4448. dlg.bg.bgcapture = true;
  4449. dlg.bg.handcursor = false;
  4450. dlg.bg.capture = false;
  4451. dlg.bg.zorder = 100;
  4452. dlg.bg.visible = false;
  4453. dlg.y = 0;
  4454. return dlg;
  4455. }
  4456. function vrsetup_dlg_addline(dlg, linetext, customcss, onclick)
  4457. {
  4458. var txt;
  4459. if (dlg.type == 'layer')
  4460. {
  4461. txt = krpano.addlayer();
  4462. txt.keep = true;
  4463. txt.type = 'text';
  4464. txt.align = 'center';
  4465. txt.zorder = 101;
  4466. }
  4467. else // 'hotspot'
  4468. {
  4469. txt = krpano.addhotspot();
  4470. txt.keep = true;
  4471. txt.type = 'text';
  4472. txt.distorted = true;
  4473. txt.zorder = 101;
  4474. txt.ath = dlg.bg.ath;
  4475. txt.atv = dlg.bg.atv;
  4476. txt.depth = dlg.bg.depth - 1;
  4477. txt.oversampling = 2;
  4478. txt.scale = dlg.scale;
  4479. txt.torigin = dlg.bg.torigin;
  4480. txt.tx = dlg.bg.tx;
  4481. txt.ty = dlg.bg.ty;
  4482. txt.tz = dlg.bg.tz;
  4483. }
  4484. txt.onautosized = function()
  4485. {
  4486. txt.havesize = true;
  4487. }
  4488. txt.edge = 'top';
  4489. txt.visible = false;
  4490. txt.bg = false;
  4491. txt.html = "" + linetext;
  4492. txt.css = 'font-size:32px;font-weight:bold;color:#FFFFFF; line-height:90%;' + (customcss || '');
  4493. if (onclick)
  4494. {
  4495. txt.onclick = onclick;
  4496. }
  4497. else
  4498. {
  4499. txt.enabled = false;
  4500. }
  4501. dlg.elements.push( txt );
  4502. return txt;
  4503. }
  4504. function vrsetup_dlg_addctrl(dlg, changedelay, callback)
  4505. {
  4506. var txt = vrsetup_dlg_addline(dlg, callback(0) );
  4507. var inc;
  4508. var dec;
  4509. if(dlg.type == 'layer')
  4510. {
  4511. inc = krpano.addlayer();
  4512. inc.keep = true;
  4513. inc.type = 'text';
  4514. inc.align = 'center';
  4515. inc.zorder = 101;
  4516. dec = krpano.addlayer();
  4517. dec.keep = true;
  4518. dec.type = 'text';
  4519. dec.align = 'center';
  4520. dec.zorder = 101;
  4521. }
  4522. else // 'hotspot'
  4523. {
  4524. inc = krpano.addhotspot();
  4525. inc.keep = true;
  4526. inc.type = 'text';
  4527. inc.distorted = true;
  4528. inc.zorder = 101;
  4529. inc.ath = dlg.bg.ath;
  4530. inc.atv = dlg.bg.atv;
  4531. inc.depth = dlg.bg.depth - 1;
  4532. inc.oversampling = 2;
  4533. inc.scale = dlg.scale;
  4534. inc.torigin = dlg.bg.torigin;
  4535. inc.tx = dlg.bg.tx;
  4536. inc.ty = dlg.bg.ty;
  4537. inc.tz = dlg.bg.tz;
  4538. dec = krpano.addhotspot();
  4539. dec.keep = true;
  4540. dec.type = 'text';
  4541. dec.distorted = true;
  4542. dec.zorder = 101;
  4543. dec.ath = dlg.bg.ath;
  4544. dec.atv = dlg.bg.atv;
  4545. dec.depth = dlg.bg.depth - 1;
  4546. dec.oversampling = 2;
  4547. dec.scale = dlg.scale;
  4548. dec.torigin = dlg.bg.torigin;
  4549. dec.tx = dlg.bg.tx;
  4550. dec.ty = dlg.bg.ty;
  4551. dec.tz = dlg.bg.tz;
  4552. }
  4553. inc.edge = 'top';
  4554. inc.visible = false;
  4555. inc.bg = false;
  4556. inc.html = '>';
  4557. inc.css = 'font-size:32px;font-weight:bold;color:#FFFFFF; line-height:90%;';
  4558. inc.padding = '0 10';
  4559. dec.edge = 'top';
  4560. dec.visible = false;
  4561. dec.bg = false;
  4562. dec.html = '<';
  4563. dec.css = 'font-size:32px;font-weight:bold;color:#FFFFFF; line-height:90%;';
  4564. dec.padding = '0 10';
  4565. inc.vr_timeout = changedelay * 1000;
  4566. dec.vr_timeout = changedelay * 1000;
  4567. inc.ondown = function(){ txt.html = ""+callback(+1); inc.enabled = false; setTimeout(function(){ inc.enabled = true; },0); };
  4568. dec.ondown = function(){ txt.html = ""+callback(-1); dec.enabled = false; setTimeout(function(){ dec.enabled = true; },0); };
  4569. txt.ctrlchilds = [inc,dec];
  4570. txt.updateControl = function()
  4571. {
  4572. txt.html = callback(0);
  4573. }
  4574. return txt;
  4575. }
  4576. function vrsetup_dlg_addspace(dlg, customspace)
  4577. {
  4578. dlg.elements.push(customspace|| padding);
  4579. }
  4580. function vrsetup_dlg_finish(dlg)
  4581. {
  4582. var i, w=0, h=0;
  4583. var waitforsizes=false;
  4584. for (i=0; i < dlg.elements.length; i++)
  4585. {
  4586. var e = dlg.elements[i];
  4587. if ( isNaN(e) )
  4588. {
  4589. if ( e.havesize )
  4590. {
  4591. w = Math.max( w, e.width * 1);
  4592. h += e.height * 1;
  4593. }
  4594. else
  4595. {
  4596. waitforsizes = true;
  4597. break;
  4598. }
  4599. }
  4600. else
  4601. {
  4602. h += e;
  4603. }
  4604. }
  4605. if (waitforsizes)
  4606. {
  4607. setTimeout( function(){ vrsetup_dlg_finish(dlg); }, 16 );
  4608. }
  4609. else
  4610. {
  4611. var y = 0;
  4612. dlg.bg.width = Math.ceil((w + padding*2)*dlg.scale);
  4613. dlg.bg.height = Math.ceil((h + padding*2)*dlg.scale);
  4614. for (i=0; i < dlg.elements.length; i++)
  4615. {
  4616. var e = dlg.elements[i];
  4617. if ( isNaN(e) )
  4618. {
  4619. e.oy = Math.round((-h/2 + y) * dlg.scale);
  4620. e.visible = true;
  4621. y += e.height * 1;
  4622. if (e.ctrlchilds )
  4623. {
  4624. for (var j=0; j < e.ctrlchilds.length; j++)
  4625. {
  4626. var sube = e.ctrlchilds[j];
  4627. sube.ox = Math.round(((j&1)-0.5) * (-w) * dlg.scale);
  4628. sube.oy = e.oy;
  4629. sube.visible = true;
  4630. }
  4631. }
  4632. }
  4633. else
  4634. {
  4635. y += e;
  4636. }
  4637. }
  4638. dlg.bg.visible = true;
  4639. }
  4640. }
  4641. function vrsetup_dlg_remove(dlg)
  4642. {
  4643. var removefu = dlg.type == 'layer' ? krpano.removelayer : krpano.removehotspot;
  4644. var i,j;
  4645. for (i=0; i < dlg.elements.length; i++)
  4646. {
  4647. var e = dlg.elements[i];
  4648. if ( isNaN(e) )
  4649. {
  4650. if (e.ctrlchilds )
  4651. {
  4652. for (j=0; j < e.ctrlchilds.length; j++)
  4653. {
  4654. var sube = e.ctrlchilds[j];
  4655. removefu(sube.name);
  4656. }
  4657. }
  4658. removefu(e.name);
  4659. }
  4660. }
  4661. removefu(dlg.bg.name);
  4662. }
  4663. function vrsetup_webvr_dialog()
  4664. {
  4665. // WebVR API rendering
  4666. var dlg = vrsetup_dlg_create('hotspot');
  4667. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_webvrSetup"));
  4668. vrsetup_dlg_addspace(dlg);
  4669. vrsetup_dlg_addline(dlg, 'Oversampling:', 'font-size:16px;')
  4670. var ctrl_ss = vrsetup_dlg_addctrl(dlg, 1.0, function(change)
  4671. {
  4672. var p = webvr.oversampling;
  4673. if (change < 0) { p = Math.max(0.2, Number(p) - 0.1); webvr.oversampling = p; } else
  4674. if (change > 0) { p = Math.min(4.0, Number(p) + 0.1); webvr.oversampling = p; }
  4675. krpano.actions.delayedcall(0, function()
  4676. {
  4677. var gl = krpano.webGL.context;
  4678. var gl_width = gl.drawingBufferWidth | 0;
  4679. var gl_height = gl.drawingBufferHeight | 0;
  4680. renderres.html = gl_width + "x" + gl_height;
  4681. });
  4682. return p.toFixed(1);
  4683. });
  4684. vrsetup_dlg_addspace(dlg,8);
  4685. vrsetup_dlg_addline(dlg, 'Rendering Resolution:', 'font-size:16px;');
  4686. var renderres = vrsetup_dlg_addline(dlg, '');
  4687. vrsetup_dlg_addspace(dlg);
  4688. vrsetup_dlg_addline(dlg, 'CLOSE', '', vrsetup_close);
  4689. vrsetup_dlg_finish(dlg);
  4690. return dlg;
  4691. }
  4692. function vrsetup_mobilevr_dialog()
  4693. {
  4694. // MobileVR / Cardboard rendering
  4695. var dlg = vrsetup_dlg_create(0 ? 'hotspot' : 'layer');
  4696. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_mobilevrSetup"));
  4697. vrsetup_dlg_addspace(dlg);
  4698. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_screensize"), 'font-size:16px;')
  4699. vrsetup_dlg_addctrl(dlg, 1.0, function(change){ var ss = Number(webvr.mobilevr_screensize); if (isNaN(ss)) ss = 5.0; if (change < 0) { ss = Math.max(4.0, ss - 0.1); webvr.mobilevr_screensize = ss; } else if (change > 0) { ss = Math.min(10.0, ss + 0.1); webvr.mobilevr_screensize = ss; } return ss.toFixed(1); });
  4700. vrsetup_dlg_addspace(dlg);
  4701. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_vrheadset"), 'font-size:16px;')
  4702. var ctrl_ps = vrsetup_dlg_addctrl(dlg, 1.0, function(change)
  4703. {
  4704. var preset_index = -1;
  4705. var i;
  4706. var profile = webvr.mobilevr_profile;
  4707. var presets = krpano.get("mobilevr_presets.headset");
  4708. if (presets)
  4709. {
  4710. presets = presets.getArray();
  4711. for (i=0; i < presets.length; i++)
  4712. {
  4713. if ( profile == presets[i].profile )
  4714. {
  4715. preset_index = i;
  4716. break;
  4717. }
  4718. }
  4719. if (change < 0)
  4720. {
  4721. preset_index--;
  4722. if (preset_index < 0)
  4723. preset_index = presets.length - 1;
  4724. webvr.mobilevr_profile = presets[preset_index].profile;
  4725. }
  4726. else if (change > 0)
  4727. {
  4728. preset_index++;
  4729. if (preset_index >= presets.length)
  4730. preset_index = 0;
  4731. webvr.mobilevr_profile = presets[preset_index].profile;
  4732. }
  4733. }
  4734. if (preset_index >= 0)
  4735. {
  4736. return presets[preset_index].caption;
  4737. }
  4738. return 'Custom';
  4739. });
  4740. vrsetup_dlg_addspace(dlg);
  4741. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_customizeHeadset"), 'font-size:25px;', function()
  4742. {
  4743. vrsetup_dlg_remove(dlg);
  4744. dlg=null;
  4745. vrsetup_dialog = vrsetup_mobilevr_interactive_dialog();
  4746. });
  4747. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_adjustmentInVR"), 'font-size:12px;');
  4748. vrsetup_dlg_addspace(dlg);
  4749. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_close"), '', vrsetup_close);
  4750. vrsetup_dlg_finish(dlg);
  4751. return dlg;
  4752. }
  4753. function vrsetup_mobilevr_interactive_dialog()
  4754. {
  4755. // MobileVR / Cardboard rendering
  4756. var ctrl_preset, ctrl_fov, ctrl_ild, ctrl_stl, ctrl_ttl, ctrl_k1, ctrl_k2, ctrl_os;
  4757. var dlg = vrsetup_dlg_create('hotspot');
  4758. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_mobilevrSetup"));
  4759. vrsetup_dlg_addspace(dlg);
  4760. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_preset"), 'font-size:16px;')
  4761. ctrl_preset = vrsetup_dlg_addctrl(dlg, 1.0, function(change)
  4762. {
  4763. var preset_index = -1;
  4764. var i;
  4765. var profile = webvr.mobilevr_profile;
  4766. var presets = krpano.get("mobilevr_presets.headset");
  4767. if (presets)
  4768. {
  4769. presets = presets.getArray();
  4770. for (i=0; i < presets.length; i++)
  4771. {
  4772. if ( profile == presets[i].profile )
  4773. {
  4774. preset_index = i;
  4775. break;
  4776. }
  4777. }
  4778. if (change < 0)
  4779. {
  4780. preset_index--;
  4781. if (preset_index < 0)
  4782. preset_index = presets.length - 1;
  4783. webvr.mobilevr_profile = presets[preset_index].profile;
  4784. }
  4785. else if (change > 0)
  4786. {
  4787. preset_index++;
  4788. if (preset_index >= presets.length)
  4789. preset_index = 0;
  4790. webvr.mobilevr_profile = presets[preset_index].profile;
  4791. }
  4792. if (change != 0)
  4793. {
  4794. ctrl_fov.updateControl();
  4795. ctrl_ild.updateControl();
  4796. ctrl_stl.updateControl();
  4797. if (ctrl_ttl) ctrl_ttl.updateControl();
  4798. ctrl_k1.updateControl();
  4799. ctrl_k2.updateControl();
  4800. }
  4801. }
  4802. if (preset_index >= 0)
  4803. {
  4804. return presets[preset_index].caption;
  4805. }
  4806. return 'Custom';
  4807. });
  4808. vrsetup_dlg_addspace(dlg);
  4809. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_fov"), 'font-size:16px;');
  4810. ctrl_fov = vrsetup_dlg_addctrl(dlg, 0.25, function(change){ var p = webvr.mobilevr_profile.split("|"); if (change < 0) { p[0] = Number(p[0]) - 1.0; webvr.mobilevr_profile = p.join("|"); } else if (change > 0) { p[0] = Number(p[0]) + 1.0; webvr.mobilevr_profile = p.join("|"); } if (change != 0) ctrl_preset.updateControl(); return Number(p[0]).toFixed(0); });
  4811. vrsetup_dlg_addspace(dlg, 8);
  4812. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_interLensDistance"), 'font-size:16px;');
  4813. ctrl_ild = vrsetup_dlg_addctrl(dlg, 0.25, function(change){ var p = webvr.mobilevr_profile.split("|"); if (change < 0) { p[1] = Number(p[1]) - 1.0; webvr.mobilevr_profile = p.join("|"); } else if (change > 0) { p[1] = Number(p[1]) + 1.0; webvr.mobilevr_profile = p.join("|"); } if (change != 0) ctrl_preset.updateControl(); return Number(p[1]).toFixed(0); });
  4814. vrsetup_dlg_addspace(dlg, 8);
  4815. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_screenToLensDistance"), 'font-size:16px;');
  4816. ctrl_stl = vrsetup_dlg_addctrl(dlg, 0.25, function(change){ var p = webvr.mobilevr_profile.split("|"); if (change < 0) { p[2] = Number(p[2]) - 1.0; webvr.mobilevr_profile = p.join("|"); } else if (change > 0) { p[2] = Number(p[2]) + 1.0; webvr.mobilevr_profile = p.join("|"); } if (change != 0) ctrl_preset.updateControl(); return Number(p[2]).toFixed(0); });
  4817. vrsetup_dlg_addspace(dlg, 8);
  4818. if (!webvr.isfake)
  4819. {
  4820. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_trayToLensCenterDistance"), 'font-size:16px;');
  4821. ctrl_ttl = vrsetup_dlg_addctrl(dlg, 0.25, function(change){ var p = webvr.mobilevr_profile.split("|"); if (change < 0) { p[3] = Number(p[3]) - 1.0; webvr.mobilevr_profile = p.join("|"); } else if (change > 0) { p[3] = Number(p[3]) + 1.0; webvr.mobilevr_profile = p.join("|"); } if (change != 0) ctrl_preset.updateControl(); return Number(p[3]).toFixed(0); });
  4822. vrsetup_dlg_addspace(dlg, 8);
  4823. }
  4824. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_lensDistortion"), 'font-size:16px;');
  4825. ctrl_k1 = vrsetup_dlg_addctrl(dlg, 0.1, function(change){ var p = webvr.mobilevr_profile.split("|"); if (change < 0) { p[4] = Number(p[4]) - 0.01; webvr.mobilevr_profile = p.join("|"); } else if (change > 0) { p[4] = Number(p[4]) + 0.01; webvr.mobilevr_profile = p.join("|"); } if (change != 0) ctrl_preset.updateControl(); return Number(p[4]).toFixed(3); });
  4826. ctrl_k2 = vrsetup_dlg_addctrl(dlg, 0.1, function(change){ var p = webvr.mobilevr_profile.split("|"); if (change < 0) { p[5] = Number(p[5]) - 0.01; webvr.mobilevr_profile = p.join("|"); } else if (change > 0) { p[5] = Number(p[5]) + 0.01; webvr.mobilevr_profile = p.join("|"); } if (change != 0) ctrl_preset.updateControl(); return Number(p[5]).toFixed(3); });
  4827. vrsetup_dlg_addspace(dlg);
  4828. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_oversampling"), 'font-size:16px;');
  4829. ctrl_os = vrsetup_dlg_addctrl(dlg, 0.25, function(change){ var p = webvr.oversampling; if (change < 0) { p = Math.max(0.2, Number(p) - 0.1); webvr.oversampling = p; } else if (change > 0) { p = Math.min(4.0, Number(p) + 0.1); webvr.oversampling = p; } return p.toFixed(1); });
  4830. vrsetup_dlg_addspace(dlg);
  4831. vrsetup_dlg_addline(dlg, krpano.get("webvr_text_close"), '', vrsetup_close);
  4832. vrsetup_dlg_finish(dlg);
  4833. return dlg;
  4834. }
  4835. var vrsetup_dialog = null;
  4836. var vrsetup_events = null;
  4837. function vrsetup_close()
  4838. {
  4839. if (vrsetup_dialog)
  4840. {
  4841. webvr.savesettings();
  4842. vrsetup_dlg_remove(vrsetup_dialog);
  4843. vrsetup_dialog = null;
  4844. }
  4845. if (vrsetup_events)
  4846. {
  4847. krpano.events.removeItem(vrsetup_events.name);
  4848. vrsetup_events = null;
  4849. }
  4850. }
  4851. krpano.vrsetup_close = function()
  4852. {
  4853. vrsetup_close();
  4854. }
  4855. krpano.vrsetup_open_js = function()
  4856. {
  4857. if (vrsetup_dialog != null)
  4858. {
  4859. // already open...
  4860. return;
  4861. }
  4862. if (webvr.iswebvr)
  4863. {
  4864. vrsetup_dialog = vrsetup_webvr_dialog();
  4865. }
  4866. else
  4867. {
  4868. vrsetup_dialog = vrsetup_mobilevr_dialog();
  4869. }
  4870. vrsetup_events = krpano.events.createItem("auto");
  4871. vrsetup_events.keep = true;
  4872. vrsetup_events.webvr_onexitvr = function()
  4873. {
  4874. vrsetup_close();
  4875. }
  4876. }
  4877. ]]></action>
  4878. <mobilevr_device_database>
  4879. <device name="iPhone 5/5S/SE" screen="320x568x2" size="4.0" bevel="3"/>
  4880. <device name="iPhone 6/6S/7/8" screen="375x667x2" size="4.7"/>
  4881. <device name="iPhone 6/6S/7/8 Plus" screen="414x736" size="5.5"/>
  4882. <device name="iPhone 6/6S/7/8 Plus (zoomed)" screen="375x667x3" size="5.5"/>
  4883. <device name="iPhone X/XS/11Pro" screen="375x812x3" size="5.85|5.33"/>
  4884. <device name="iPhone XS/11Pro Max" screen="414x896x3" size="6.46|5.95"/>
  4885. <device name="iPhone XR/11" screen="414x896x2" size="6.06|5.58"/>
  4886. <device name="Samsung S6" ua="sm-g930" size="5.1"/>
  4887. <device name="Samsung S6 Edge" ua="sm-g925" size="5.1"/>
  4888. <device name="Samsung S6 Edge Plus" ua="sm-g928" size="5.7"/>
  4889. <device name="Samsung S7" ua="sm-g930" size="5.1"/>
  4890. <device name="Samsung S7 Edge" ua="sm-g935" size="5.5"/>
  4891. <device name="Samsung S8" ua="sm-g950" size="5.8"/>
  4892. <device name="Samsung S8+" ua="sm-g955" size="6.2"/>
  4893. <device name="Samsung S9" ua="sm-g960" size="5.8"/>
  4894. <device name="Samsung S9+" ua="sm-g965" size="6.2"/>
  4895. <device name="Samsung S10e" ua="sm-g970" size="5.8"/>
  4896. <device name="Samsung S10" ua="sm-g973" size="6.1"/>
  4897. <device name="Samsung S10+" ua="sm-g975" size="6.4"/>
  4898. <device name="Samsung S10 5G" ua="sm-g977" size="6.7"/>
  4899. <device name="Samsung Note 7" ua="sm-n930" size="5.7"/>
  4900. <device name="Samsung Note 8" ua="sm-n950" size="6.3"/>
  4901. <device name="Samsung Note 9" ua="sm-n960" size="6.4"/>
  4902. <device name="Samsung Note 10" ua="sm-n970" size="6.3"/>
  4903. <device name="Samsung Note 10 5G" ua="sm-n971" size="6.3"/>
  4904. <device name="Samsung Note 10+" ua="sm-n975" size="6.8"/>
  4905. <device name="Samsung Note 10+ 5G" ua="sm-n976" size="6.8"/>
  4906. <device name="Huawei P10 Lite" ua="HUAWEIWAS-TL10" size="5.2"/>
  4907. <device name="Huawei P20 Lite" ua="HUAWEIANE-LX1" size="5.84"/>
  4908. </mobilevr_device_database>
  4909. <action name="setup_weather">
  4910. if(config.panos.pano[get(scene_name)].sun.id !== null,
  4911. add_sun(get(config.panos.pano[get(scene_name)].sun.ath),get(config.panos.pano[get(scene_name)].sun.atv));
  4912. );
  4913. if(config.panos.pano[get(scene_name)].weather.id !== null AND config.panos.pano[get(scene_name)].weather.id != -1,
  4914. if(config.panos.pano[get(scene_name)].weather.id == 0,
  4915. add_snow(get(config.panos.pano[get(scene_name)].weather.size));
  4916. ,
  4917. if(config.panos.pano[get(scene_name)].weather.id == 1,
  4918. add_rain(get(config.panos.pano[get(scene_name)].weather.size));
  4919. ,
  4920. if(config.panos.pano[get(scene_name)].weather.id == 2,
  4921. add_sun(get(config.panos.pano[get(scene_name)].weather.ath),get(config.panos.pano[get(scene_name)].weather.atv));
  4922. ,
  4923. if(config.panos.pano[get(scene_name)].weather.id == 3,
  4924. if(config.panos.pano[get(scene_name)].weather.type == 1,
  4925. add_image_rain(get(settings.weather_image_1), get(config.panos.pano[get(scene_name)].weather.size));
  4926. ,
  4927. if(config.panos.pano[get(scene_name)].weather.type == 2,
  4928. add_image_rain(get(settings.weather_image_2), get(config.panos.pano[get(scene_name)].weather.size));
  4929. ,
  4930. add_image_rain(get(settings.weather_image_3), get(config.panos.pano[get(scene_name)].weather.size));
  4931. );
  4932. );
  4933. ,
  4934. copy(custom_weather_url,config.panos.pano[get(scene_name)].weather.url);
  4935. txtadd(custom_weather_url,'?imageView2/0/w/512/h/512');
  4936. add_image_rain(get(custom_weather_url), get(config.panos.pano[get(scene_name)].weather.size));
  4937. );
  4938. );
  4939. );
  4940. );
  4941. );
  4942. if(webvr.isenabled AND plugin[snow] !== null,
  4943. set(plugin[snow].visible, false);
  4944. );
  4945. </action>
  4946. <action name="add_sun">
  4947. addlensflare("obj",true);
  4948. set(lensflares[obj].keep,false);
  4949. set(lensflares[obj].visible,true);
  4950. set(lensflares[obj].device,html5);
  4951. set(lensflares[obj].item[flareobj].ath,%1);
  4952. set(lensflares[obj].item[flareobj].atv,%2);
  4953. set(lensflares[obj].item[flareobj].scene,get(xml.scene));
  4954. set(lensflares[obj].item[flareobj].typ,blinkstyle1);
  4955. set(lensflares[obj].item[flareobj].dust_effect,false);
  4956. set(lensflares[obj].item[flareobj].keep,false);
  4957. </action>
  4958. <action name="add_rain">
  4959. if(%1 === null,
  4960. set(rain_size, 2);
  4961. ,
  4962. set(rain_size, %1);
  4963. );
  4964. removeplugin(snow);
  4965. addplugin(snow);
  4966. set(plugin[snow].keep, false);
  4967. set(plugin[snow].onloaded,
  4968. set(plugin[snow].mode, image);
  4969. copy(plugin[snow].imageurl, settings.rain_image);
  4970. set(plugin[snow].blendmode, normal);
  4971. set(plugin[snow].flakes, 1000);
  4972. mul(plugin[snow].flakes, rain_size);
  4973. set(plugin[snow].color, 0xefe3e4);
  4974. set(plugin[snow].speed, 15.5);
  4975. set(plugin[snow].shake, 1.0);
  4976. set(plugin[snow].speedvariance, 1.0);
  4977. set(plugin[snow].spreading, 2.0);
  4978. set(plugin[snow].rainwidth, 0.4);
  4979. mul(plugin[snow].rainwidth, rain_size);
  4980. set(plugin[snow].rainalpha, 0.5);
  4981. set(plugin[snow].wind, 2.0);
  4982. );
  4983. if(device.flash,
  4984. copy(plugin[snow].url, plugin_url.SNOW_SWF);
  4985. ,
  4986. copy(plugin[snow].url, plugin_url.SNOW_JS);
  4987. );
  4988. </action>
  4989. <action name="remove_rain">
  4990. removeplugin(snow);
  4991. </action>
  4992. <action name="add_snow">
  4993. if(%1 === null,
  4994. set(snow_size, 2);
  4995. ,
  4996. set(snow_size, %1);
  4997. );
  4998. removeplugin(snow);
  4999. addplugin(snow);
  5000. set(plugin[snow].keep, false);
  5001. set(plugin[snow].onloaded,
  5002. set(plugin[snow].mode, image);
  5003. copy(plugin[snow].imageurl, settings.snow_image);
  5004. set(plugin[snow].blendmode, normal);
  5005. set(plugin[snow].flakes, 1500);
  5006. mul(plugin[snow].flakes, snow_size);
  5007. set(plugin[snow].color, 0xdfe3e4);
  5008. set(plugin[snow].speed, get(snow_size));
  5009. mul(plugin[snow].speed, snow_size);
  5010. add(plugin[snow].speed, 1);
  5011. set(plugin[snow].shake, 4.0);
  5012. set(plugin[snow].speedvariance, 2.0);
  5013. set(plugin[snow].spreading, 4.0);
  5014. set(plugin[snow].wind, 1.0);
  5015. sub(plugin[snow].wind, snow_size);
  5016. );
  5017. if(device.flash,
  5018. copy(plugin[snow].url, plugin_url.SNOW_SWF);
  5019. ,
  5020. copy(plugin[snow].url, plugin_url.SNOW_JS);
  5021. );
  5022. </action>
  5023. <action name="add_image_rain">
  5024. if(%2 == null ,
  5025. set(snow_size, 2);
  5026. ,
  5027. set(snow_size, %2);
  5028. );
  5029. removeplugin(snow);
  5030. addplugin(snow);
  5031. set(plugin[snow].keep, false);
  5032. set(plugin[snow].onloaded,
  5033. set(plugin[snow].mode, image);
  5034. set(plugin[snow].imageurl, %1);
  5035. set(plugin[snow].imagescale, 0.5);
  5036. set(plugin[snow].blendmode, normal);
  5037. set(plugin[snow].flakes, 150);
  5038. mul(plugin[snow].flakes, snow_size);
  5039. set(plugin[snow].color, 0xdfe3e4);
  5040. add(plugin[snow].speed, 0.5);
  5041. set(plugin[snow].shake, 1.0);
  5042. set(plugin[snow].speedvariance, 2.0);
  5043. set(plugin[snow].spreading, 1.5);
  5044. set(plugin[snow].wind, 0);
  5045. );
  5046. if(device.flash,
  5047. copy(plugin[snow].url, plugin_url.SNOW_SWF);
  5048. ,
  5049. copy(plugin[snow].url, plugin_url.SNOW_JS);
  5050. );
  5051. </action>
  5052. <action name="update_bgcolor">
  5053. set(hotspot[%1].bgcolor, %2);
  5054. </action>
  5055. <action name="update_backgroundalpha">
  5056. set(hotspot[%1].backgroundalpha, %2);
  5057. </action>
  5058. <action name="update_color">
  5059. set(css,get(hotspot[%1].css));
  5060. indexoftxt(startIndex,get(css),'color');
  5061. if(startIndex GE 0,
  5062. indexoftxt(endIndex,get(css),';',get(startIndex));
  5063. add(endIndex,1);
  5064. calc(startSrc,substr(get(css),0,startIndex));
  5065. calc(endSrc,substr(get(css),endIndex));
  5066. set(newcss,get(startSrc));
  5067. txtadd(newcss,get(endSrc));
  5068. ,
  5069. set(newcss,get(css));
  5070. );
  5071. txtadd(newcss, 'color:');
  5072. txtadd(newcss, %2);
  5073. txtadd(newcss, ';');
  5074. set(hotspot[%1].css,get(newcss))
  5075. </action>
  5076. <action name="update_font_size">
  5077. set(css,get(hotspot[%1].css));
  5078. indexoftxt(startIndex,get(css),'font-size');
  5079. if(startIndex GE 0,
  5080. indexoftxt(endIndex,get(css),';',get(startIndex));
  5081. add(endIndex,1);
  5082. calc(startSrc,substr(get(css),0,startIndex));
  5083. calc(endSrc,substr(get(css),endIndex));
  5084. set(newcss,get(startSrc));
  5085. txtadd(newcss,get(endSrc));
  5086. ,
  5087. set(newcss,get(css));
  5088. );
  5089. txtadd(newcss, 'font-size:');
  5090. txtadd(newcss, %2);
  5091. txtadd(newcss, 'px;');
  5092. set(hotspot[%1].css,get(newcss))
  5093. </action>
  5094. <action name="add_embed_txt_default">
  5095. addhotspot(%1);
  5096. set(hotspot[%1].embedTxt,true);
  5097. set(hotspot[%1].ath,%3);
  5098. set(hotspot[%1].atv,%4);
  5099. set(hotspot[%1].scale,1);
  5100. set(hotspot[%1].keep,false);
  5101. set(hotspot[%1].type,text);
  5102. set(hotspot[%1].html,%2);
  5103. txtreplace(hotspot[%1].html,'
  5104. ','[br]');
  5105. set(hotspot[%1].bgcolor,#000000);
  5106. set(hotspot[%1].backgroundalpha,0.5);
  5107. set(hotspot[%1].roundedge,5);
  5108. set(hotspot[%1].padding,10);
  5109. set(hotspot[%1].multiline,true);
  5110. set(hotspot[%1].oy,-9);
  5111. set(hotspot[%1].css,font-family:STXihei; font-size:12px; color:#ffffff;letter-spacing:1px;textAlign:center;line-height: 20px;);
  5112. set(hotspot[%1].edge,bottom);
  5113. set(hotspot[%1].renderer,"css3d");
  5114. set(hotspot[%1].zorder2, 1.0);
  5115. set(hotspot[%1].parent,'embed_container');
  5116. set(embed_txt_bg_name,%1);
  5117. txtadd(embed_txt_bg_name,"_bg");
  5118. addhotspot(get(embed_txt_bg_name));
  5119. copy(hotspot[get(embed_txt_bg_name)].url, settings.embed_txt_image);
  5120. copy(hotspot[get(embed_txt_bg_name)].ath,hotspot[%1].ath);
  5121. copy(hotspot[get(embed_txt_bg_name)].atv,hotspot[%1].atv);
  5122. set(hotspot[get(embed_txt_bg_name)].keep,false);
  5123. set(hotspot[get(embed_txt_bg_name)].scale,0.5);
  5124. set(hotspot[get(embed_txt_bg_name)].edge,top);
  5125. if(device.mobile == true,
  5126. set(hotspot[get(embed_txt_bg_name)].oy,-6);
  5127. ,
  5128. set(hotspot[get(embed_txt_bg_name)].oy,-9);
  5129. );
  5130. set(hotspot[get(embed_txt_bg_name)].handcursor, false);
  5131. set(hotspot[get(embed_txt_bg_name)].enabled, false);
  5132. set(hotspot[get(embed_txt_bg_name)].renderer, 'css3d');
  5133. set(hotspot[get(embed_txt_bg_name)].parent,get(embed_container));
  5134. set(hotspot[%1].onclick,
  5135. jscall(calc('window.onKrpEmbedClick("'+ name + '")'));
  5136. );
  5137. </action>
  5138. <action name="add_embed_txt_line">
  5139. addhotspot(%1);
  5140. if(%3,
  5141. set(hotspot[%1].ath,%3);
  5142. ,
  5143. set(hotspot[%1].ath,get(view.hlookat));
  5144. );
  5145. if(%4,
  5146. set(hotspot[%1].atv,%4);
  5147. ,
  5148. set(hotspot[%1].atv,get(view.vlookat));
  5149. );
  5150. set(hotspot[%1].scale,1);
  5151. set(hotspot[%1].embedTxt,true);
  5152. set(hotspot[%1].type,text);
  5153. set(hotspot[%1].keep,false);
  5154. set(hotspot[%1].html,%2);
  5155. set(hotspot[%1].bgcolor, %5);
  5156. set(hotspot[%1].backgroundalpha,%6);
  5157. set(hotspot_css,'font-family:STXihei; letter-spacing:1px;textAlign:center;line-height: 20px;');
  5158. set(hotspot[%1].oy,-36);
  5159. txtadd(hotspot_css, 'color:');
  5160. txtadd(hotspot_css, %7);
  5161. txtadd(hotspot_css, ';');
  5162. txtadd(hotspot_css, 'font-size:');
  5163. txtadd(hotspot_css, %8);
  5164. txtadd(hotspot_css, 'px;');
  5165. copy(hotspot[%1].css, hotspot_css);
  5166. set(hotspot[%1].borderwidth,1.0);
  5167. set(hotspot[%1].bordercolor,0xfad057);
  5168. set(hotspot[%1].bgroundedge,5);
  5169. set(hotspot[%1].padding,10);
  5170. set(hotspot[%1].renderer,"css3d");
  5171. set(hotspot[%1].edge,bottom);
  5172. set(hotspot[%1].onup,
  5173. jscall(calc('window.onKrpEmbedMoveEnd("'+ name + '",' + ath + ',' + atv + ')'));
  5174. );
  5175. set(hotspot[%1].ondown,drag_enable_embed_txt(););
  5176. set(hotspot[%1].onclick,
  5177. jscall(calc('window.onKrpEmbedClick("'+ name + '")'));
  5178. );
  5179. set(embed_txt_bg_name,%1);
  5180. txtadd(embed_txt_bg_name,"_bg");
  5181. addhotspot(get(embed_txt_bg_name));
  5182. copy(hotspot[get(embed_txt_bg_name)].url, settings.embed_line_image);
  5183. copy(hotspot[get(embed_txt_bg_name)].ath,hotspot[%1].ath);
  5184. copy(hotspot[get(embed_txt_bg_name)].atv,hotspot[%1].atv);
  5185. set(hotspot[get(embed_txt_bg_name)].keep,false);
  5186. set(hotspot[get(embed_txt_bg_name)].scale,0.5);
  5187. set(hotspot[get(embed_txt_bg_name)].edge,top);
  5188. set(hotspot[get(embed_txt_bg_name)].oy,-36);
  5189. </action>
  5190. <action name="remove_all_embed_txt">
  5191. def(arr,array);
  5192. def(arrIndex,number,0);
  5193. trace(arr);
  5194. for(set(i,0),i LT hotspot.count,inc(i),
  5195. if(hotspot[get(i)].embedTxt,
  5196. set(arr[get(arrIndex)],get(hotspot[get(i)].name));
  5197. add(arrIndex,1)
  5198. );
  5199. );
  5200. for(set(i,0),i LT arrIndex,inc(i),
  5201. set(id,get(arr[get(i)]));
  5202. removehotspot(get(id));
  5203. txtadd(id,"_bg");
  5204. removehotspot(get(id));
  5205. );
  5206. </action>
  5207. <action name="addEmbedEnd">
  5208. hide_vr_hotspot();
  5209. </action>
  5210. </krpano>
  5211. <scene name="s_63001578" pano_id="35249793" scene_id="63001578">
  5212. <preview url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/35249793/imgs/preview.jpg"/>
  5213. <image if="true">
  5214. <cube url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/35249793/imgs/mobile_%s.jpg"/>
  5215. </image>
  5216. </scene>
  5217. <scene name="s_63001579" pano_id="35033441" scene_id="63001579">
  5218. <preview url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/35033441/imgs/preview.jpg"/>
  5219. <image if="true">
  5220. <cube url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/35033441/imgs/mobile_%s.jpg"/>
  5221. </image>
  5222. </scene>
  5223. <scene name="s_62962605" pano_id="36030771" scene_id="62962605">
  5224. <preview url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/36030771/imgs/preview.jpg"/>
  5225. <image if="true">
  5226. <cube url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/36030771/imgs/mobile_%s.jpg"/>
  5227. </image>
  5228. </scene>
  5229. <scene name="s_62962604" pano_id="36030772" scene_id="62962604">
  5230. <preview url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/36030772/imgs/preview.jpg"/>
  5231. <image if="true">
  5232. <cube url="%$cdnDomain130%/resource/prod/ba83f1fde1t/85bjkdyfvk1/36030772/imgs/mobile_%s.jpg"/>
  5233. </image>
  5234. </scene>
  5235. <config>
  5236. <autoTours>
  5237. <tour title="一键导览" startImage="%$mediaDomain%/85bjkdyfvk1/2/4d4f065c7e8b99f5026148f17c683454v5.png" stopImage="%$mediaDomain%/85bjkdyfvk1/2/4d4f065c7e8b99f5026148f17c683454v5.png" hideHotspots="false" loop="false" disableMusic="false" subtitlePosition="bottom" subtitleSize="16" subtitleBackground="black" newTitle="导览" endBackToStart="false">
  5238. <point name="piont_0" endatv="-1.3374506172596108" endath="-120.19396266728683" playMode="1" startfov="95" music="%$mediaDomain%/85bjkdyfvk1/1/b2ea955f75d02620a29434a4ce63eb4av5.mp3" musicName="谢海清 - 清平乐(古琴曲).mp3" endfov="95" startatv="0.513610111008311" moveTime="5" startath="43.06368191921319" targetPano="35249793" targetScene="" subtitle="大黄鸭大黄鸭大黄鸭大黄鸭大黄鸭大黄鸭大黄鸭" blendMode="0" volume="1"/>
  5239. <point name="piont_1" endatv="-7.5046347877928845" endath="66.00453849023253" playMode="3" startfov="95" music="" musicName="" endfov="95" startatv="-1.3374506172596108" moveTime="5" startath="-120.19396266728683" targetPano="35249793" targetScene="" subtitle="" blendMode="0" volume="1"/>
  5240. <point name="piont_2" endatv="-4.557" endath="-20.719" playMode="1" startfov="95" music="" musicName="" endfov="95" startatv="-7.5046347877928845" moveTime="5" startath="66.00453849023253" targetPano="36030771" targetScene="" subtitle="" blendMode="0" volume="1"/>
  5241. <point name="piont_3" endatv="13.5571161198236" endath="-228.89689867965873" playMode="3" startfov="95" music="" musicName="" endfov="95" startatv="-4.557" moveTime="5" startath="-20.719" targetPano="36030771" targetScene="" subtitle="" blendMode="0" volume="1"/>
  5242. <point name="piont_4" endatv="10.515114591550208" endath="-0.2950380275813873" playMode="1" startfov="95" music="" musicName="" endfov="95" startatv="13.5571161198236" moveTime="5" startath="-228.89689867965873" targetPano="36030772" targetScene="" subtitle="" blendMode="0" volume="1"/>
  5243. <point name="piont_5" endatv="" endath="" playMode="1" startfov="95" music="" musicName="" endfov="" startatv="10.515114591550208" moveTime="5" startath="-0.2950380275813873" targetPano="36030772" targetScene="" subtitle="" blendMode="0" volume="1"/>
  5244. </tour>
  5245. </autoTours>
  5246. <panos>
  5247. <pano name="s_63001578">
  5248. <info title="水悦喷泉" pano_id="35249793"/>
  5249. <view autorotatekeepview="0" maxpixelzoom="2.0" fovmin="70" loadscenekeepview="0" hlookatmax="180" fov="95" vlookatmax="90" vlookat="-0.19272354352438953" fovmax="120" hlookatmin="-180" vlookatmin="-90" hlookat="203.68762226219638" fovtype="MFOV"/>
  5250. <autoplay duration="30" hiddenscene_noenter="0" keep_originview="1" enabled="1" enter_next="1"/>
  5251. <top_circle scale="0.5" is_float="0" type="2" url="%$mediaDomain%/85bjkdyfvk1/2/4d4f065c7e8b99f5026148f17c683454v5.png"/>
  5252. <bottom_circle scale="1" is_float="0" type="2" url="%$mediaDomain%/85bjkdyfvk1/2/7e09f89bb50fbcd627250dc5fc2b6920v5.png"/>
  5253. <weather size="1" id="0"/>
  5254. </pano>
  5255. <pano name="s_63001579">
  5256. <info title="免税广场喷泉" pano_id="35033441"/>
  5257. <view autorotatekeepview="0" maxpixelzoom="2.0" fovmin="70" loadscenekeepview="0" hlookatmax="180" fov="95" vlookatmax="90" vlookat="4.400086331986964" fovmax="135.2" hlookatmin="-180" vlookatmin="-90" hlookat="69.36782718495546" fovtype="MFOV"/>
  5258. <autoplay duration="30" hiddenscene_noenter="0" keep_originview="false" enabled="1" enter_next="1"/>
  5259. <top_circle scale="1" is_float="0" type="2" url="%$mediaDomain%/85bjkdyfvk1/2/4d4f065c7e8b99f5026148f17c683454v5.png"/>
  5260. <bottom_circle type="1" scale="1" is_float="0"/>
  5261. </pano>
  5262. <pano name="s_62962605">
  5263. <info title="云戒广场" pano_id="36030771"/>
  5264. <view autorotatekeepview="0" maxpixelzoom="2.0" fovmin="70" loadscenekeepview="0" hlookatmax="180" fov="95" vlookatmax="90" vlookat="0" fovmax="120" hlookatmin="-180" vlookatmin="-90" hlookat="0" fovtype="MFOV"/>
  5265. <autoplay duration="30" hiddenscene_noenter="0" keep_originview="0" enabled="1" enter_next="1"/>
  5266. </pano>
  5267. <pano name="s_62962604">
  5268. <info title="云戒桥2" pano_id="36030772"/>
  5269. <view autorotatekeepview="0" maxpixelzoom="2.0" fovmin="70" loadscenekeepview="0" hlookatmax="180" fov="95" vlookatmax="90" vlookat="0" fovmax="120" hlookatmin="-180" vlookatmin="-90" hlookat="0" fovtype="MFOV"/>
  5270. <autoplay duration="30" hiddenscene_noenter="0" keep_originview="0" enabled="1" enter_next="1"/>
  5271. </pano>
  5272. </panos>
  5273. </config>