mirror of
https://athene2.informatik.unibw-muenchen.de/progproj/gruppen-ht24/Gruppe-02.git
synced 2025-08-03 18:14:18 +02:00
fixed verhandeln
This commit is contained in:
@@ -80,7 +80,7 @@ public class ConfirmTrade extends Dialog {
|
||||
// Ablehnen-Button
|
||||
Button declineButton = confirmTradeContainer.addChild(new Button("Ablehnen", new ElementId("button")));
|
||||
declineButton.setFontSize(32);
|
||||
declineButton.addClickCommands(s -> ifTopDialog(() -> { //TODO Buttonfunktion prüfen
|
||||
declineButton.addClickCommands(s -> ifTopDialog(() -> {
|
||||
app.getGameLogic().playSound(Sound.BUTTON);
|
||||
app.getGameLogic().send(new TradeResponse(false, tradeHandler));
|
||||
close();
|
||||
@@ -91,7 +91,9 @@ public class ConfirmTrade extends Dialog {
|
||||
negotiateButton.addClickCommands(s -> ifTopDialog( () -> {
|
||||
app.getGameLogic().playSound(Sound.BUTTON);
|
||||
close();
|
||||
new TradeMenu(app, new TradeHandler(app.getGameLogic().getPlayerHandler().getPlayerById(app.getId()))).open();
|
||||
TradeHandler t = new TradeHandler(app.getGameLogic().getPlayerHandler().getPlayerById(tradeHandler.getSender().getId()));
|
||||
t.setReceiver(app.getGameLogic().getPlayerHandler().getPlayerById(tradeHandler.getReceiver().getId()));
|
||||
new TradeMenu(app, t).open();
|
||||
}));
|
||||
// Confirm-Button
|
||||
Button confirmButton = confirmTradeContainer.addChild(new Button("Bestätigen", new ElementId("button")));
|
||||
|
Reference in New Issue
Block a user