mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 19:28:01 +00:00
Prevent passing game object to client when adding card to field
This commit is contained in:
@@ -6271,7 +6271,6 @@ public class Card extends GameEntity implements Comparable<Card>, IIdentifiable
|
||||
|
||||
public List<SpellAbility> getAllPossibleAbilities(Player player, boolean removeUnplayable) {
|
||||
// this can only be called by the Human
|
||||
|
||||
final List<SpellAbility> abilities = new ArrayList<SpellAbility>();
|
||||
for (SpellAbility sa : getSpellAbilities()) {
|
||||
//add alternative costs as additional spell abilities
|
||||
|
||||
@@ -1744,7 +1744,7 @@ public class PlayerControllerHuman extends PlayerController {
|
||||
}
|
||||
|
||||
public void addCardToBattlefield() {
|
||||
final Player p = SGuiChoose.oneOrNone("Put card in play for which player?", (FCollection<Player>)game.getPlayers());
|
||||
final Player p = Player.get(SGuiChoose.oneOrNone("Put card in play for which player?", PlayerView.getCollection(game.getPlayers())));
|
||||
if (p == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user