MCPcopy Create free account
hub / github.com/Card-Forge/forge / copyLastState

Method copyLastState

forge-game/src/main/java/forge/game/Game.java:218–226  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

216 }
217
218 public void copyLastState() {
219 lastStateBattlefield.clear();
220 lastStateGraveyard.clear();
221 Map<Integer, Card> cachedMap = Maps.newHashMap();
222 for (final Player p : getPlayers()) {
223 lastStateBattlefield.addAll(p.getZone(ZoneType.Battlefield).getLKICopy(cachedMap));
224 lastStateGraveyard.addAll(p.getZone(ZoneType.Graveyard).getLKICopy(cachedMap));
225 }
226 }
227
228 public CardCollectionView copyLastState(ZoneType type) {
229 CardCollection result = new CardCollection();

Callers 8

dealAssignedDamageMethod · 0.95
applyGameOnThreadMethod · 0.80
playLandMethod · 0.80
resolveStackMethod · 0.80
mainLoopStepMethod · 0.80
simulateSpellAbilityMethod · 0.80

Calls 5

getPlayersMethod · 0.95
clearMethod · 0.45
addAllMethod · 0.45
getLKICopyMethod · 0.45
getZoneMethod · 0.45

Tested by

no test coverage detected