angepasst an player

This commit is contained in:
Ivan
2014-11-26 11:38:25 +01:00
parent b7ec09a2ed
commit b0f96305e5
2 changed files with 5 additions and 6 deletions
@@ -42,7 +42,6 @@ public class ActionControl{
resetActionPanel();
}
public static void setAction(int rd){
System.out.println(" 33 "+Thread.currentThread());
setKeyA();
if(rd==1){
option=1;
@@ -112,7 +111,7 @@ public class ActionControl{
}else{
resetActionPanel();
actionLabel.setText("Manipulation erfolgreich!");
HardewareManipulate.setHardware(MapGrid.getGridCell(Main.player01.getGridLocation().x, Main.player01.getGridLocation().y).getCorrespondingHardwareToTrigger());
HardewareManipulate.setHardware(MapGrid.getGridCell(Main.getPlayer().getGridLocation().x, Main.getPlayer().getGridLocation().y).getCorrespondingHardwareToTrigger());
}
}
private static void setAchiv(){
@@ -19,16 +19,16 @@ public class ActionWatcher{
}
public static void tick(){
//Infotext, wenn man in der nhe von einem Hardwareteil steht
if(MapGrid.getGridCell(Main.player01.getGridLocation().x, Main.player01.getGridLocation().y).isTrigger() && !action && !setAction){
if(MapGrid.getGridCell(Main.getPlayer().getGridLocation().x, Main.getPlayer().getGridLocation().y).isTrigger() && !action && !setAction){
infoText=true;
if(!HardewareManipulate.getHardware(MapGrid.getGridCell(Main.player01.getGridLocation().x, Main.player01.getGridLocation().y).getCorrespondingHardwareToTrigger())){
if(!HardewareManipulate.getHardware(MapGrid.getGridCell(Main.getPlayer().getGridLocation().x, Main.getPlayer().getGridLocation().y).getCorrespondingHardwareToTrigger())){
ActionControl.setTextforA();
}else{
ActionControl.setTextforManipulate();
}
}
//Entfernt InfoText
if(!MapGrid.getGridCell(Main.player01.getGridLocation().x, Main.player01.getGridLocation().y).isTrigger() && infoText){
if(!MapGrid.getGridCell(Main.getPlayer().getGridLocation().x, Main.getPlayer().getGridLocation().y).isTrigger() && infoText){
ActionControl.resetActionPanel();
infoText=false;
}
@@ -39,7 +39,7 @@ public class ActionWatcher{
ActionControl.setAction(new Random().nextInt(2)+1);
}
//Entfernt jeglichen Text wenn man sich von dem Hardwarestck entfernt, nachdem Aktion bereits eingeleitet wurde, und setzt Booleans/Counter wieder auf die Ausgangssituation
if(!MapGrid.getGridCell(Main.player01.getGridLocation().x, Main.player01.getGridLocation().y).isTrigger() && setAction){
if(!MapGrid.getGridCell(Main.getPlayer().getGridLocation().x, Main.getPlayer().getGridLocation().y).isTrigger() && setAction){
ActionControl.resetActionPanel();
ActionControl.resetKeyA();
infoText=false;