Update ScriptLib.java (#2227)

This commit is contained in:
Nazrin 2023-06-23 21:37:13 -07:00 committed by GitHub
parent 9fd5f7665c
commit 30d093f348
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -823,17 +823,17 @@ public class ScriptLib {
//TODO implement
return 0;
}
public int IsPlayerAllAvatarDie(int sceneUid){
public boolean IsPlayerAllAvatarDie(int sceneUid){
logger.warn("[LUA] Call unimplemented IsPlayerAllAvatarDie {}", sceneUid);
var playerEntities = getSceneScriptManager().getScene().getEntities().values().stream().filter(e -> e.getEntityType() == EntityType.Avatar).toList();
for (GameEntity p : playerEntities){
var player = (EntityAvatar)p;
if(player.isAlive()){
return 0;
return false;
}
}
//TODO check
return 1;
return true;
}
public int sendShowCommonTipsToClient(String title, String content, int closeTime) {
@ -869,6 +869,11 @@ public class ScriptLib {
//TODO implement var6 object has int success, int fail, bool fail_on_wipe
return 0;
}
public int StopChallenge(int var1, int var2){
logger.warn("[LUA] Call unimplemented StopChallenge with {} {}", var1, var2);
//TODO implement
return 0;
}
public int CreateEffigyChallengeMonster(int var1, int[] var2){
logger.warn("[LUA] Call unimplemented CreateEffigyChallengeMonster with {} {}", var1, var2);
//TODO implement