question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Devs: battlefield's countAll and other all-methods must be removed from cards

See original GitHub issue

Found big problem for multiplayer games: many popular methods in Battlefield.java don’t use range settings (e.g. it’s will counts/finds too many permanent from non accessible players).

Affected methods (search by field.values()):

  • countAll;
  • contains (2 of 3 implementation);
  • getAllPermanents;
  • getAllPermanentIds;
  • getAllActivePermanents;
  • getPhasedIn – ok, not used in cards;
  • getPhasedOut – ok, not used in cards.

Cards/abilities/effects must use only range related methods like game.getBattlefield().count(), but inner game engine must use full permanents list like game.getBattlefield().countAll().

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
JayDi85commented, Jun 27, 2022

I think it’s was about containsControlled and containsPermanent.

Usage must be researched. containsPermanent as example: it’s used to check a permanent on battlefield (is it actual/removed or not). It’s ok in that use case. But that method can be potentially buggy in searching/filtering code.

shot_220627_211843

0reactions
github-actions[bot]commented, Jun 27, 2022

Steam Vines - (Gatherer) (Scryfall) (EDHREC)

{1}{R}{R} Enchantment — Aura Enchant land When enchanted land becomes tapped, destroy it and Steam Vines deals 1 damage to that land’s controller. That player attaches Steam Vines to a land of their choice.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Defenders of the Realm: Battlefields Review - play board games
The first hit will stun the card and the next will remove it. You must stun all your opponent's cards at a location...
Read more >
Lecture Notes for Machine Learning and Data Science Courses ...
This is a collection of notes made for INFO370, INFO371, IMT573 and IMT574 courses, taught at the Information School, University of Washington.
Read more >
Titanfall beta discussion : r/Games - Reddit
Oh and complete removal of the 'smart pistol' - It's the most ridiculous weapon to even consider having in a multiplayer game. (Not...
Read more >
Army in Europe Regulation 350-1, 16 November 2017
This regulation prescribes training policy for the Army in Europe and must be used with. AR 350-1. Summary of Change. This revision—.
Read more >
Fire Monitoring Handbook - Indian Affairs
dures will enable fire monitors to move to or assist other parks without additional training. The fire monitoring program described in this Fire....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found