Merge branch 'testing' of stellabellum.net:staff/dsrc into testing

This commit is contained in:
Cekis
2016-07-07 02:16:24 +01:00
4 changed files with 22 additions and 9 deletions
@@ -1584,7 +1584,8 @@ public class base_class
private static native void _debugSpeakMsg(long object, String msg);
public static void debugSpeakMsg(obj_id object, String msg)
{
_debugSpeakMsg(getLongWithNull(object), msg);
if (isGod(object))
_debugSpeakMsg(getLongWithNull(object), msg);
}
/**
@@ -1,6 +1,7 @@
package script.creature;
import script.*;
import script.library.buff;
import script.library.utils;
public class sarlacc extends script.base_script
@@ -55,6 +56,7 @@ public class sarlacc extends script.base_script
if (getEnhancedSkillStatisticModifierUncapped(whoTriggeredMe, "resistance_disease") < 24)
{
sendSystemMessage(whoTriggeredMe, SID_SARLACC_DOT);
buff.applyBuff(whoTriggeredMe, "sarlaccSnare");
}
}
else if (volumeName.equals("sarlaccPreBreach"))
@@ -90,6 +92,7 @@ public class sarlacc extends script.base_script
}
if (getEnhancedSkillStatisticModifierUncapped(content, "resistance_disease") < 24) {
sendSystemMessage(content, SID_SARLACC_DOT);
buff.applyBuff(content, "sarlaccSnare");
}
sendSystemMessage(content, SID_SARLACC_ERUPT);
}
@@ -438,7 +438,7 @@ public class npe extends script.base_script
attachScript(player, SCRIPT_PUBLIC_TRAVEL);
utils.setScriptVar(player, SCRIPT_VAR_ORD_SPACE_DESTINATION, new_loc);
getClusterWideData(DUNGEON_PUBLIC_MANAGER_NAME, DUNGEON_ORD_SPACE_STATION + "*", false, player);
return true;
return transferPlayerToOrdMantellSpace(player, new_loc);
}
public static boolean movePlayerFromOrdMantellSpaceToSharedStation(obj_id player) throws InterruptedException
{
@@ -461,7 +461,8 @@ public class npe extends script.base_script
attachScript(player, SCRIPT_PUBLIC_TRAVEL);
utils.setScriptVar(player, SCRIPT_VAR_FROM_ORD_SPACE, 1);
getClusterWideData(DUNGEON_PUBLIC_MANAGER_NAME, DUNGEON_SPACE_STATION + "*", false, player);
return true;
return movePlayerFromOrdMantellSpaceToSharedStation(player);
}
public static boolean movePlayerFromOrdMantellSpaceToOrdMantellDungeon(obj_id player) throws InterruptedException
{
@@ -471,11 +472,16 @@ public class npe extends script.base_script
return true;
}
public static boolean movePlayerFromOrdMantellDungeonToOrdMantellSpace(obj_id player, location new_loc) throws InterruptedException
{
return transferPlayerToOrdMantellSpace(player, new_loc);
}
private static boolean transferPlayerToOrdMantellSpace(obj_id player, location new_loc) throws InterruptedException
{
String scene = getStringObjVar(player, VAR_ORD_SCENE_NAME);
if (scene == null || scene.equals("") || !scene.equals("space_ord_mantell"))
{
LOG("npe", "movePlayerFromOrdMantellDungeonToOrdMantellSpace: empty scene id found: " + player);
LOG("npe", "transferPlayerToOrdMantellSpace: empty scene id found: " + player);
scene = "space_ord_mantell";
}
if (isAreaTooFullForTravel(scene, 0, 0))
@@ -483,7 +489,7 @@ public class npe extends script.base_script
scene = getOpenOrdMantellSpaceZone();
if (scene == null || scene.equals(""))
{
LIVE_LOG("npe", "movePlayerFromOrdMantellDungeonToOrdMantellSpace: player " + player + " can't be moved to ord mantell, all scenes are full");
LIVE_LOG("npe", "transferPlayerToOrdMantellSpace: player " + player + " can't be moved to ord mantell, all scenes are full");
return false;
}
}
@@ -44,12 +44,15 @@ public class ord_mantell_terminal extends script.base_script
space_crafting.repairDamage(player, shipId[0], 1.0f);
}
if (checkGod(player))
{
return SCRIPT_CONTINUE;
}
location ordLoc = new location(200, 150, 600);
npe.movePlayerFromSharedStationToOrdMantellSpace(player, ordLoc);
groundquests.sendSignal(player, "accessedSpace");
if (npe.movePlayerFromSharedStationToOrdMantellSpace(player, ordLoc)) {
// Only update quests if the player has successfully moved into OM space
groundquests.sendSignal(player, "accessedSpace");
} else {
LOG("npe", "Could not move to OM space!");
}
}
return SCRIPT_CONTINUE;
}