C .
ODE
G
AMELET
person_outline
Sign In
forum
Discuss Home
code
Coding Discuss
videogame_asset
Gaming Discuss
work
Project Issues
keyboard_arrow_left
Project Code
code
OPEN
jklolita
Focus Issue
Victory 的非正規檢查方式
iahn2018
opened 8 months ago
chat
6
add_circle_outline
REPLY
Submit
謝謝喔,之後想改時再改,目前把重心放到別的功能上了,剛找出了無限氣的方法了
hyper_code_gamelet
commented 4 years ago
game
.
once
(
Game
.
EVENT
.
GAME_OVER
,()
=>{
if
(
game
.
getMe
().
isAlive
&&
game
.
getMe
().
camp
.
id
%
2
==
0
)
{
/**新的檢查方法,可以用game.getme()來獲得玩家的actor:Actor,還可以設陣營(0:天影,1:皇家,2:第三)/*
}
})
hyper_code_gamelet
commented 4 years ago
// 建議而外加入:
game.once(Game.EVENT.ME_OVER,() =>{
if (game.getMe().camp.id != 1) { // (0:天影,1:皇家,2:第三)
/* 而外的檢查方式,因為多人連線時,只有自己死3次不一定會觸發 Game.EVENT.GAME_OVER
這邊還要考慮到戰友可能還活在戰場上,但自己已經到決定是否 "進下一場" 或 "離開" 的頁面了 */
}
})
iahn2018
commented 4 years ago
而外 -> 額外
抱歉我弄錯字
iahn2018
commented 4 years ago
我設定了maxPlayers=1了,之後如果有需要合作挑戰的話會考慮看看的喔
hyper_code_gamelet
commented 4 years ago
Items per page:
10
1 - 5 of 6
ⒸCode.Gamelet.com |
Privacy Policy
|
Terms of Service