Commit Graph

2126 Commits

Author SHA1 Message Date
xawotihs a43854420d Fixed compilation issue on Windows 2013-11-27 20:33:59 +01:00
xawotihs a695323bc7 Merge pull request #564 from ZobyTwo/cleanup_1
Add a few namespaces and fix header guards.
2013-11-25 15:42:18 -08:00
xawotihs fd6bc95539 Merge pull request #562 from citiral/master
Updated deckmenu.cpp to properly render deck description and summary
2013-11-24 10:28:05 -08:00
Tobias Loose 0bb211a581 Remove unused global variables from DeckStats.cpp and add proper...
member variable initialization.
2013-11-24 09:18:34 +01:00
Tobias Loose e0428ac7b0 Avoid more conflicts. We could now do unit builds...
and make the linker put every data element and function into its own section.
On linktime, we can output every discarded section and get a list of dead
code (for that build).
2013-11-23 17:04:24 +01:00
Tobias Loose 9f0b70d1c9 Put constans into extra namespace as kBackToMainMenuID...
collides with itself. GameStateAwards::kBackToMainMenuID and
GameStateOptions::kBackToMainMenuID define those with different
values.
2013-11-23 16:18:45 +01:00
Dmitry Panin 678a4734bb Merge pull request #560 from ZobyTwo/dead_code
Remove some dead code
2013-11-22 00:09:40 -08:00
Dmitry Panin 052e3abdb8 Small fix in match_and ( [-color1; -color2] was handled incorrectly ) 2013-11-22 01:03:07 +04:00
citiral 73c2d17080 Updated deckmenu.cpp to properly render deck description and summary
Deck description and statistics were being drawn as black text, this made it invisible as it was rendered over a black background. I made it change the color to white before drawing, so its shown as its suposed to be.(Did the default text color change?)
2013-11-21 20:38:41 +01:00
Tobias Loose 3cee80e3bc Delete another unused file (GuiMessageBox.cpp) 2013-11-20 14:01:59 +01:00
Tobias Loose 8209716fc9 Remove unused file 2013-11-20 13:53:15 +01:00
Tobias Loose e76c57d747 Fix some valgrind memcheck warnings. However there remains one...
... within the threaded texture cache. Once it is resized, some textures
in GetQuad(...) (WCachedResource.cpp:102/103) have uninitialized widths/heights.
2013-11-20 12:56:33 +01:00
Tobias Loose bbc310dec7 Remove some dead code 2013-11-20 11:43:27 +01:00
Tobias Loose 35697a65b4 Use style guide 2013-11-20 11:13:35 +01:00
Tobias Loose 6bed1666be Merge branch 'master' into defines 2013-11-20 11:06:41 +01:00
Tobias Loose f021866368 Merge remote-tracking branch 'wp/master' 2013-11-20 11:06:28 +01:00
xawotihs d7e527166c Merge branch 'show-output-only-for-failing-tests' 2013-11-19 11:14:41 +01:00
Dmitry Panin 6c41e5c92c Added option (#define CAPTURE_STDERR)
if set then the DebugTrace calls only for failing tests are shown
2013-11-19 02:41:30 +04:00
Tobias Loose 82e3ab3977 Merge branch 'cleanup' into defines
Merge cleanup codings style commit as i accidentally used that branch as
the base.
2013-11-17 21:06:56 +01:00
Tobias Loose f2314ca673 Use proposed coding style 2013-11-17 21:05:07 +01:00
Tobias Loose 94c3ac9ad9 Fix FTBFS 2013-11-17 21:02:08 +01:00
Tobias Loose 5419d87e4e Get rid of two more define groups. 2013-11-17 20:22:03 +01:00
Tobias Loose 446ed20758 Fix typo ActionLayer::receiveEventPlus(...)
This method is rarely used, however it returned 0 after adding stuff.
It now returns the sum.
2013-11-17 19:39:46 +01:00
Tobias Loose 7a48c5e087 Fix some cppcheck warnings (mostly style and postfix vs prefix iteration) 2013-11-17 19:36:24 +01:00
Tobias Loose 3ca2f1c1ed Replace defines in Damage.h with enums. 2013-11-17 17:12:58 +01:00
Tobias Loose 146872797b ActionElement.h: Replace defines, remove superfluous ";"
Defines do not follow scope rules, but enums do. Enum classes
even utilize strong type checking (but i am not sure about compiler
support for c++11 on all target platforms).
2013-11-17 16:08:29 +01:00
Tobias Loose c6dc51c7d3 Simplify Damage::resolve a bit 2013-11-17 15:37:56 +01:00
Dmitry Panin 2835bdf767 Fixed issue with Cranial Plating.
Issue
	attach then equip: plating will give bonus to both creatures
Fix
	Changed "attach" to "retarget target(creature|mybattlefield)"
	as this doesnot admit this bug
	Attach should become deprecated in future
2013-11-17 01:49:51 +04:00
Dmitry Panin afc903e31b Added different names for attach and equip
+ moved implementation of AEquip to .cpp
2013-11-17 00:44:37 +04:00
xawotihs 017f6dd1ed Deactivated part of the traces outputted by the testsuite to make Travis
happy.
2013-10-30 22:58:04 +01:00
xawotihs 784d127a6e I think I got it ... messy / not appearing at the end of folders in the
travis linux where it appears fine on mine :(
2013-10-30 22:28:09 +01:00
xawotihs f6c47b85e3 More debug 2013-10-30 22:02:43 +01:00
xawotihs 74280aef1d Added some traces in the primitives and sets loading. 2013-10-30 20:50:34 +01:00
Dmitry Panin 6bbe290762 Fixed bug with syncopate to consume all the mana available
Now pay[[{x}]] is not supported because of this.
use "pay[[{value:storedx}]]" instead
2013-10-30 12:39:08 +04:00
xawotihs db1c552321 Tries to work around crash of the testsuite in Travis. 2013-10-30 00:20:58 +01:00
xawotihs f08f0ad3b9 Merge branch 'master' of https://github.com/WagicProject/wagic
Conflicts:
	JGE/include/JTypes.h
2013-10-29 23:36:07 +01:00
xawotihs a3a1bc2b79 Created a dedicate console Qt based wagic application and run it in the
travis file.
2013-10-29 22:38:37 +01:00
Michael Nguyen b17d9d3f85 Merge branch 'master' of github.com:WagicProject/wagic 2013-10-28 15:35:45 -07:00
Michael Nguyen 84ca7457b5 updaed for iOS6 2013-10-28 15:20:35 -07:00
Unknown 224c94e890 Included some testsuite into qtmain and updated travis file to try to use it. 2013-10-27 23:06:29 +01:00
Dmitry Panin cf50b7d403 Fizzle unless pay x (thanks to excessum)
- saves source card in storedSourceCard for ATransform
- adds support for WParsedInt in pay as "pay[[{value:WParsedInt}]]":

name=Spell Rupture
target=*|stack
auto=if cantargetcard(*|opponentstack) then transforms((,newability[pay[[{value:power:highest:creature:opponentbattlefield}]] name(pay {value} mana) donothing?fizzle])) forever
text=Counter target spell unless its controller pays {X}, where X is the greatest power among creatures you control.
mana={1}{U}
type=Instant

- adds support for {x} in *some* “pay” abilities (Syncopate):

name=Syncopate
target=*|stack
auto=transforms((,newability[pay[[{x}]] name(pay {value} mana) donothing?fizzleto(exile)])) forever
text=Counter target spell unless its controller pays {X}. If that spell is countered this way, exile it instead of putting it into  its owner's graveyard.
mana={X}{U}
type=Instant

- support of "name(pay {value} mana)" in pay abilities to show actual number to pay (see example above)
2013-10-27 13:47:00 +04:00
Dmitry Panin b8b6153cc5 Reworked AVanishing (fixed bugs + more fair implementation) 2013-10-27 13:42:48 +04:00
Dmitry Panin 461eedd626 Fixed bug with preventing Melira from putting +1/+1 counters on creatures you control 2013-10-27 13:42:48 +04:00
xawotihs 4ac376b5f2 Ignored non-source extensions 2013-10-24 21:53:46 +02:00
Xawotihs@gmail.com 1f0485ff8e Support for running the testsuite in command line programs for continuous integration.
Here is a small example inspired from SDLmain.c:

g_launcher = new JGameLauncher();
InitGame();
MTGCollection()->loadFolder("sets/primitives/");
MTGCollection()->loadFolder("sets/", "_cards.dat");
options.reloadProfile();
TestSuite testSuite("test/_tests.txt");
int result = testSuite.run();
DestroyGame();
delete g_launcher;
return result;
2013-10-23 22:08:30 +00:00
Xawotihs@gmail.com 98861dd916 Fixed memory leaks and refactored a bit the ManaCost class while I was at it. 2013-10-19 14:29:17 +00:00
pankdm b5794ad328 Small fixes (misstype, formatting, target p2) 2013-10-18 06:38:15 +00:00
pankdm 38b4213f9c Refactored formatting for easier reading of the code 2013-10-18 06:38:03 +00:00
pankdm 5c3eb2c405 Changed the owner of ManaCost in LifeorManaCost to itself 2013-10-18 06:37:31 +00:00
pankdm f7eded7417 Devotion mechanics (thanks to excessum for patch)
+ some refactoring:
extrManaCost --> ExtraManaCost
unattachCost --> UnattachCost
2013-10-18 06:37:09 +00:00