修复单挑的get.attitude函数不检测from或to是否存在的问题.
This commit is contained in:
parent
c672136bcb
commit
8c84806aff
|
@ -1562,6 +1562,7 @@ game.import("mode", function (lib, game, ui, get, ai, _status) {
|
||||||
},
|
},
|
||||||
get: {
|
get: {
|
||||||
attitude: function (from, to) {
|
attitude: function (from, to) {
|
||||||
|
if (!from || !to) return 0;
|
||||||
if (from.identity == to.identity) return 10;
|
if (from.identity == to.identity) return 10;
|
||||||
return -10;
|
return -10;
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue