diff --git a/_server/config.json b/_server/config.json index f22fdf2..a77e904 100644 --- a/_server/config.json +++ b/_server/config.json @@ -1 +1 @@ -{"viewportLoc":[0,0],"editorLastFloorId":"U1"} \ No newline at end of file +{"viewportLoc":[0,0],"editorLastFloorId":"MT9","lastUsed":[{"idnum":554,"id":"N554","images":"npcs","y":42,"recent":1668243635497,"frequent":2},{"idnum":551,"id":"N551","images":"npcs","y":41,"recent":1668243645267,"frequent":2},{"idnum":46,"id":"fly","images":"items","y":12,"recent":1668239925419,"frequent":1},{"idnum":45,"id":"book","images":"items","y":9,"recent":1668238365160,"frequent":1}]} \ No newline at end of file diff --git a/libs/enemys.js b/libs/enemys.js index 122657a..825c3ba 100644 --- a/libs/enemys.js +++ b/libs/enemys.js @@ -197,7 +197,7 @@ enemys.prototype.getDamageString = function (enemy, x, y, floorId) { color = '#FF2222'; } else { - if (damage <= 0) color = '#11FF11'; + if (damage < 0) color = '#11FF11'; else if (damage < core.status.hero.hp / 3) color = '#FFFFFF'; else if (damage < core.status.hero.hp * 2 / 3) color = '#FFFF00'; else if (damage < core.status.hero.hp) color = '#FF9933'; diff --git a/project/data.js b/project/data.js index 15e4cea..6dff00f 100644 --- a/project/data.js +++ b/project/data.js @@ -1524,7 +1524,7 @@ var data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d = "extendToolbar": false, "flyNearStair": true, "flyRecordPosition": false, - "itemFirstText": false, + "itemFirstText": true, "equipboxButton": false, "enableAddPoint": false, "enableNegativeDamage": false, diff --git a/project/floors/MT0.js b/project/floors/MT0.js index bc6bed7..e1c33a4 100644 --- a/project/floors/MT0.js +++ b/project/floors/MT0.js @@ -129,12 +129,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -169,12 +176,19 @@ main.floors.MT0= "value": "flag:juqing+1" }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -212,12 +226,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -246,12 +267,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -280,12 +308,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianziwunai.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -314,12 +349,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianziwunai.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -348,12 +390,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzilianhong.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -382,12 +431,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzilianhong.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -416,12 +472,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -436,12 +499,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzileng.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 0 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 0 @@ -574,12 +644,19 @@ main.floors.MT0= "time": 2000 }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzileng.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 170, - 50 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 500 @@ -640,12 +717,19 @@ main.floors.MT0= "time": 1000 }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 170, - 50 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 500 @@ -666,12 +750,19 @@ main.floors.MT0= "\t[守塔仙子]你.......你是指.........", "\t[邵虎]我想守护的人和教我怎样守护别人的人在里面,我怕他们有危险,所以我必须走这一趟。", { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzileng.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 170, - 50 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 500 @@ -691,12 +782,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianzileng.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 170, - 50 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 500 @@ -704,12 +802,19 @@ main.floors.MT0= "\t[守塔仙子](是为了爱的坚持吗......)", "\t[守塔仙子](我没理由阻拦他呢......)", { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "xianziwunai.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 170, - 50 + 330, + 50, + 320, + 480 ], "opacity": 1, "time": 500 @@ -790,12 +895,19 @@ main.floors.MT0= "condition": "((flag:hard==1 )||(( flag:hard==2 )||( flag:hard==5)))", "true": [ { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "npcnv.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 40 + 330, + 70, + "287.2", + "417.6" ], "opacity": 1, "time": 0 @@ -842,15 +954,20 @@ main.floors.MT0= ], "1,3": [ { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "shaohusikao.png", - "loc": [ + "sloc": [ 0, - 20 + 0, + null + ], + "loc": [ + 80, + 50, + "291.2", + "466.4" ], - "dw": 100, - "dh": 100, "opacity": 1, "time": 0 }, @@ -926,12 +1043,19 @@ main.floors.MT0= "condition": "(flag:344==1)", "true": [ { - "type": "showImage", + "type": "showImage2", "code": 7, "image": "gongzhuzhending.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 40 + 330, + 90, + "319.2", + "389.6" ], "opacity": 1, "time": 0 @@ -951,12 +1075,19 @@ main.floors.MT0= "condition": "(flag:1fgongzhu==1)", "true": [ { - "type": "showImage", + "type": "showImage2", "code": 6, - "image": "gongzhubuzaihu.png", + "image": "gongzhuzaihu.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 40 + 330, + 90, + "319.2", + "389.6" ], "opacity": 1, "time": 0 @@ -978,12 +1109,19 @@ main.floors.MT0= "number": "princess" }, { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "gongzhupinghe.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 40 + 330, + 90, + "319.2", + "389.6" ], "opacity": 1, "time": 0 @@ -991,12 +1129,19 @@ main.floors.MT0= "\t[公主]...............", "\t[公主].......看看塔外面,还真的有点想家。", { - "type": "showImage", + "type": "showImage2", "code": 2, "image": "shaohuzixin.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - -30, - 20 + 80, + 50, + "291.2", + "466.4" ], "opacity": 1, "time": 0 @@ -1008,12 +1153,19 @@ main.floors.MT0= "time": 0 }, { - "type": "showImage", + "type": "showImage2", "code": 3, "image": "gongzhuzhending.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 40 + 330, + 90, + "319.2", + "389.6" ], "opacity": 1, "time": 0 @@ -1025,12 +1177,19 @@ main.floors.MT0= "time": 0 }, { - "type": "showImage", + "type": "showImage2", "code": 4, "image": "shaohusikao.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - -30, - 20 + 80, + 50, + "291.2", + "466.4" ], "opacity": 1, "time": 0 @@ -1057,12 +1216,19 @@ main.floors.MT0= ] }, { - "type": "showImage", + "type": "showImage2", "code": 5, "image": "gongzhulianhong.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 180, - 40 + 330, + 90, + "319.2", + "389.6" ], "opacity": 1, "time": 0 diff --git a/project/floors/MT1.js b/project/floors/MT1.js index bf86dbf..6ad16d9 100644 --- a/project/floors/MT1.js +++ b/project/floors/MT1.js @@ -295,14 +295,14 @@ main.floors.MT1= [ 0,348, 21, 2, 31, 2, 88, 2, 27, 2, 31, 2, 28,352, 0], [ 0,348,205, 81, 0, 0, 0, 2, 21,209, 0,209, 32,352, 0], [ 0,348, 21, 2,201, 2, 2, 2, 2, 2, 81, 2, 2,352, 0], - [ 0,348, 2, 2, 0,121, 2, 0, 22, 2,209, 0, 2,352, 0], + [ 0,348, 2, 2, 0,121, 2, 0, 45, 2,209, 22, 2,352, 0], [ 0,348, 31,202, 0, 0,202, 0, 0, 0, 0, 0, 2,352, 0], [ 0,348, 2, 2,210, 2, 2, 2, 82, 2, 2, 0, 2,352, 0], [ 0,348, 31, 21,209, 0, 21, 0,209, 32, 2, 0, 87,352, 0], [ 0,348, 2, 2, 2, 2,209, 2, 2, 2, 2, 2, 2,352, 0], [ 0,348, 21, 0, 2, 21,205, 2, 0, 28, 2, 0, 27,352, 0], - [ 0,348, 21,205, 81, 0, 0, 81,217, 31, 81,210, 0,352, 0], - [ 0,348, 22, 0, 2, 0, 21, 2, 0, 21, 2, 0, 31,352, 0], + [ 0,348, 21,205, 81, 0, 0, 81,217, 31, 81,210, 31,352, 0], + [ 0,348, 22, 0, 2, 0, 21, 2, 0, 21, 2, 0, 46,352, 0], [ 0,349,346,346,346,346,346,346,346,346,346,346,346,347, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] diff --git a/project/floors/MT10.js b/project/floors/MT10.js index e28a53e..2efa8da 100644 --- a/project/floors/MT10.js +++ b/project/floors/MT10.js @@ -155,7 +155,7 @@ main.floors.MT10= "time": 500 }, "\t[嗜骨]...................如果我说了的话...你可不可以放过我啊........", - "\t[邵虎]当然,看你的态度,可以。", + "\t[邵虎]当然,看你的态度可以。", { "type": "sleep", "time": 1000 diff --git a/project/floors/MT21.js b/project/floors/MT21.js index cc39884..5f89c5f 100644 --- a/project/floors/MT21.js +++ b/project/floors/MT21.js @@ -45,7 +45,7 @@ main.floors.MT21= { "type": "moveHero", "steps": [ - "down" + "down:1" ] }, { @@ -136,24 +136,38 @@ main.floors.MT21= "text": "否", "action": [ { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "shaohuyilv.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - -30, - 20 + 80, + 50, + "291.2", + "466.4" ], "opacity": 1, "time": 0 }, "\t[邵虎]这...这是!?", { - "type": "showImage", + "type": "showImage2", "code": 2, "image": "jiekexiaohei.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 @@ -184,7 +198,7 @@ main.floors.MT21= "time": 500, "keep": true, "steps": [ - "down" + "down:1" ] }, { @@ -208,7 +222,7 @@ main.floors.MT21= "time": 500, "keep": true, "steps": [ - "down" + "down:1" ] }, "\t[蓝衣老者]......可恶的魔物!竟然如此嚣张跋扈!今天我就要以联盟的名义将你们消灭!", @@ -221,7 +235,7 @@ main.floors.MT21= "time": 500, "keep": true, "steps": [ - "up" + "up:1" ] }, "\t[蓝衣老者]游荡于空间之中的雷元素啊!我以双手为引,心灵为介,呼唤你伟大的能量!无上之雷元素聚集-------裁决之雷!", @@ -260,7 +274,7 @@ main.floors.MT21= "time": 500, "keep": true, "steps": [ - "up" + "up:1" ] }, "\t[蓝衣老者]哼......马上就气急败坏了呢。", @@ -301,12 +315,19 @@ main.floors.MT21= }, "\t[蓝衣老者].....你...你是.....!!", { - "type": "showImage", + "type": "showImage2", "code": 3, "image": "jiekedajiao.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 @@ -319,12 +340,19 @@ main.floors.MT21= }, "\t[蓝衣老者].....啊....全身使不出力气.....", { - "type": "showImage", + "type": "showImage2", "code": 4, "image": "fuyi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 220, - 80 + 400, + 100, + 192, + 300 ], "opacity": 1, "time": 0 @@ -341,24 +369,38 @@ main.floors.MT21= "time": 0 }, { - "type": "showImage", + "type": "showImage2", "code": 5, "image": "jiekedajiao2.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 }, "\t[杰克]老大咱们快走!!被抓住就麻烦了!!", { - "type": "showImage", + "type": "showImage2", "code": 6, "image": "shaohuyilv.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - -30, - 20 + 80, + 50, + "291.2", + "466.4" ], "opacity": 1, "time": 0 @@ -377,12 +419,19 @@ main.floors.MT21= "time": 0 }, { - "type": "showImage", + "type": "showImage2", "code": 7, "image": "fuyi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 220, - 80 + 400, + 100, + 192, + 300 ], "opacity": 1, "time": 0 @@ -473,12 +522,19 @@ main.floors.MT21= "time": 300 }, { - "type": "showImage", + "type": "showImage2", "code": 8, "image": "fuyi.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 220, - 80 + 400, + 100, + 192, + 300 ], "opacity": 1, "time": 0 @@ -562,24 +618,38 @@ main.floors.MT21= "time": 300 }, { - "type": "showImage", - "code": 9, + "type": "showImage2", + "code": 6, "image": "shaohusikao.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - -30, - 20 + 80, + 50, + "291.2", + "466.4" ], "opacity": 1, "time": 0 }, "\t[邵虎]........刚才的那个家伙......虽然体型不大,但我能感觉到是个非常难缠的对手.....实力恐怕要比嗜骨和毒尾还高......", { - "type": "showImage", + "type": "showImage2", "code": 10, "image": "jiekezixin.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 @@ -591,12 +661,19 @@ main.floors.MT21= "time": 0 }, { - "type": "showImage", + "type": "showImage2", "code": 11, "image": "shaohuyilv.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - -30, - 20 + 80, + 50, + "291.2", + "466.4" ], "opacity": 1, "time": 0 @@ -629,7 +706,7 @@ main.floors.MT21= "time": 500, "keep": true, "steps": [ - "right" + "right:1" ] }, { @@ -641,12 +718,19 @@ main.floors.MT21= ] }, { - "type": "showImage", + "type": "showImage2", "code": 12, "image": "jiekeyilv.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 @@ -658,12 +742,19 @@ main.floors.MT21= "time": 0 }, { - "type": "showImage", + "type": "showImage2", "code": 13, "image": "jiekezixin.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 @@ -762,12 +853,19 @@ main.floors.MT21= "condition": "(flag:21fnpc==1)", "true": [ { - "type": "showImage", + "type": "showImage2", "code": 4, "image": "jiekedajiao.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 @@ -792,12 +890,19 @@ main.floors.MT21= "text": "否", "action": [ { - "type": "showImage", + "type": "showImage2", "code": 1, "image": "jiekedajiao.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 @@ -809,12 +914,19 @@ main.floors.MT21= "time": 300 }, { - "type": "showImage", + "type": "showImage2", "code": 2, "image": "shaohuzixin.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - -30, - 20 + 80, + 50, + "291.2", + "466.4" ], "opacity": 1, "time": 0 @@ -826,12 +938,19 @@ main.floors.MT21= "time": 0 }, { - "type": "showImage", + "type": "showImage2", "code": 3, "image": "jiekeyilv.png", + "sloc": [ + 0, + 0, + null + ], "loc": [ - 200, - 40 + 330, + 70, + "289.6", + "376.8" ], "opacity": 1, "time": 0 diff --git a/project/floors/MT9.js b/project/floors/MT9.js index b077049..e18195a 100644 --- a/project/floors/MT9.js +++ b/project/floors/MT9.js @@ -139,7 +139,7 @@ main.floors.MT9= }, { "type": "animate", - "name": "han", + "name": "hanyou", "loc": [ 8, 3 @@ -244,7 +244,7 @@ main.floors.MT9= [ 0,345,350,350,350,350,350,350,350,350,350,350,350,351, 0], [ 0,348, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,352, 0], [ 0,348, 4, 4, 4, 2, 2, 2, 2, 2, 2, 2, 2,352, 0], - [ 0,348, 4, 4, 4, 2, 0, 0,211,301, 0, 0, 0,352, 0], + [ 0,348, 4, 4, 4, 2, 0, 0,551,554, 0, 0, 0,352, 0], [ 0,348, 4, 4, 4, 2, 0, 2, 0, 0, 0, 0, 89,352, 0], [ 0,348, 4, 4, 4, 2, 0, 2, 2, 2, 2, 2, 2,352, 0], [ 0,348, 4, 4, 4, 2, 0, 2, 4, 4, 4, 4, 4,352, 0], diff --git a/project/icons.js b/project/icons.js index 16ce662..3d2bba7 100644 --- a/project/icons.js +++ b/project/icons.js @@ -260,7 +260,8 @@ var icons_4665ee12_3a1f_44a4_bea3_0fccba634dc1 = "N519": 38, "N529": 39, "N547": 40, - "N551": 41 + "N551": 41, + "N554": 42 }, "npc48": { "npc0": 0, diff --git a/project/maps.js b/project/maps.js index 2f51f82..3783a81 100644 --- a/project/maps.js +++ b/project/maps.js @@ -438,5 +438,6 @@ var maps_90f36752_8815_4be8_b32b_d7fad1d0542e = "550": {"cls":"terrains","id":"T550","canPass":false}, "551": {"cls":"npcs","id":"N551"}, "552": {"cls":"animates","id":"A552"}, - "553": {"cls":"animates","id":"A553","trigger":"openDoor","doorInfo":{"time":160,"openSound":"045-Push01.mp3","closeSound":"045-Push01.mp3","keys":{}},"animate":1} + "553": {"cls":"animates","id":"A553","trigger":"openDoor","doorInfo":{"time":160,"openSound":"045-Push01.mp3","closeSound":"045-Push01.mp3","keys":{}},"animate":1}, + "554": {"cls":"npcs","id":"N554"} } \ No newline at end of file diff --git a/project/materials/npcs.png b/project/materials/npcs.png index 83b39ee..3b20a50 100644 Binary files a/project/materials/npcs.png and b/project/materials/npcs.png differ diff --git a/project/plugins.js b/project/plugins.js index a23c539..5d45646 100644 --- a/project/plugins.js +++ b/project/plugins.js @@ -2788,5 +2788,116 @@ var plugins_bb40132b_638b_4a9f_b028_d3fe47acc8d1 = } animateHwnd.start(); } +}, + "怪物手册和显伤": function () { + // 在此增加新插件 + ////// 获得所有特殊属性的名称 ///// + enemys.prototype.getSpecialText = function (enemy) { + if (typeof enemy == 'string') enemy = core.material.enemys[enemy]; + if (!enemy) return []; + var special = enemy.special; + var text = []; + + var specials = this.getSpecials(); + if (specials) { + for (var i = 0; i < specials.length; i++) { + if (this.hasSpecial(special, specials[i][0])) + text.push(this._calSpecialContent(enemy, specials[i][1])); + } + } + if (special === 0) { + text.push('普通'); ///////无特殊属性时增加“普通”属性显示 + } + return text; + } + + ////// 获得所有特殊属性的颜色 ////// + enemys.prototype.getSpecialColor = function (enemy) { + if (typeof enemy == 'string') enemy = core.material.enemys[enemy]; + if (!enemy) return []; + var special = enemy.special; + var colors = []; + + var specials = this.getSpecials(); + if (specials) { + for (var i = 0; i < specials.length; i++) { + if (this.hasSpecial(special, specials[i][0])) + colors.push(specials[i][3] || null); + } + } + if (special === 0) { + colors.push("#ffffff"); ////“普通”属性显示为白色 + } + return colors; + + } + ui.prototype._drawBook_drawDamage = function (index, enemy, offset, position) { + core.setTextAlign('ui', 'center'); + var damage = enemy.damage, + color = '#FFFF00'; + if (damage == null) { + damage = '????'; ////////无法战斗怪物手册中改为????显示 + color = '#FF2222'; + } else { + if (damage >= core.status.hero.hp) color = '#FF2222'; + else if (damage >= core.status.hero.hp * 2 / 3) color = '#FF9933'; + else if (damage <= 0) color = '#11FF11'; + damage = core.formatBigNumber(damage); + if (core.enemys.hasSpecial(enemy, 19)) damage += "+"; + if (core.enemys.hasSpecial(enemy, 21)) damage += "-"; + if (core.enemys.hasSpecial(enemy, 11)) damage += "^"; + } + if (enemy.notBomb) damage += "[b]"; + core.fillText('ui', damage, offset, position, color, this._buildFont(13, true)); + } + + + + + + +}, + "楼传界面": function () { + // 在此增加新插件 + ////// 绘制楼层传送器 ////// + ui.prototype.drawFly = function (page) { + core.status.event.data = page; + var floorId = core.floorIds[page]; + var title = core.status.maps[floorId].title; + core.clearMap('ui'); + core.setAlpha('ui', 0.85); + core.fillRect('ui', 0, 0, core._PX_, core._PY_, '#000000'); + core.setAlpha('ui', 1); + core.setTextAlign('ui', 'center'); + core.fillText('ui', '楼层跳跃', core._PX_ / 2, 48, '#FFFFFF', this._buildFont(28, true)); + core.fillText('ui', '返回游戏', core._PX_ / 2, core._PY_ - 13, null, this._buildFont(15, true)) + core.setTextAlign('ui', 'right'); + core.fillText('ui', '浏览地图时也', core._PX_ - 10, core._PY_ - 23, '#aaaaaa', this._buildFont(10, false)); + core.fillText('ui', '可楼层跳跃!', core._PX_ - 10, core._PY_ - 11, null, this._buildFont(10, false)); + core.setTextAlign('ui', 'center'); + + var middle = core._PY_ / 2 + 39; + + // 换行 + var lines = core.splitLines('ui', title, 120, this._buildFont(16, true)); + var start_y = middle - (lines.length - 1) * 11; + for (var i in lines) { + core.fillText('ui', lines[i], core._PX_ - 60, start_y, '#FFFFFF'); + start_y += 22; + } + if (core.actions._getNextFlyFloor(1) != page) { + core.fillText('ui', '▲', core._PX_ - 60, middle - 64, null, this._buildFont(17, false)); + core.fillText('ui', '▲', core._PX_ - 60, middle - 96); + core.fillText('ui', '▲', core._PX_ - 60, middle - 96 - 7); + } + if (core.actions._getNextFlyFloor(-1) != page) { + core.fillText('ui', '▼', core._PX_ - 60, middle + 64, null, this._buildFont(17, false)); + core.fillText('ui', '▼', core._PX_ - 60, middle + 96); + core.fillText('ui', '▼', core._PX_ - 60, middle + 96 + 7); + } + var size = 0.75; + core.strokeRect('ui', 16, 64, size * core._PX_, size * core._PY_, '#FFFFFF', 2); + core.drawThumbnail(floorId, null, { ctx: 'ui', x: 16, y: 64, size: size, damage: true, all: true }); + } } } \ No newline at end of file