Commit Graph

65 Commits

Author SHA1 Message Date
wagic.the.homebrew@gmail.com
cee2da600d Erwan
- fix a bug where the AI would crash when playing cards with cycling or any other "autohand" ability
2010-01-10 09:48:26 +00:00
wagic.the.homebrew@gmail.com
69c5dee979 Erwan
- IMPORTANT: Legendary is not an ability anymore, creating cards with super types should be much more natural. You can now say "type=Snow Land", and stuff like that. No backward compatibility!!!
2010-01-03 03:11:30 +00:00
wagic.the.homebrew@gmail.com
54142cc816 Erwan
- fix a segfault with Shivan Gorge
- Fix a memory leak in the AI
- Commit a test for issue 265
2009-12-22 13:11:08 +00:00
d32.wagic
002851a943 Daddy32: Tasks Mode
Gives the user the opportunity to earn some credits for performing various tasks.

Known bugs removed, tested stability-wise, not so much game-wise.
Lots of to-dos and ideas still remaining, better balance between task difficulty and their rewards needed - please comment.

Usage:
Enter shop, open menu, select 'See available tasks'.
All tasks in the list are active, until they expire ('Days left'; day passes after each duel (won, lost or quited)).
You can finish any of the tasks and get bonus. For particular task, the bonus gets a bit smaller every day (until expiration).
2009-12-13 22:12:14 +00:00
wagic.the.homebrew@gmail.com
512f649147 Erwan
- Adding cycling. Check Akroma's vengeance in ONS for an example. Note that this uses autohand instead of auto, this is important! You can also use autograveyard. 
- All "auto" activated abilities should work with autohand, so this is not only for cycling, but could be used for other abilities as well. For example autohand={3}:cycling can also be written autohand={3}{S}:Draw:1
2009-12-12 11:09:13 +00:00
wagic.the.homebrew@gmail.com
0d2c6cf3e5 Erwan
- Adding external rules mechanism. It is very crude for the moment, but I hope it will grow. Have a look at Rules/mtg.txt for basic usage
2009-12-06 04:47:29 +00:00
wagic.the.homebrew@gmail.com
ea3ed7061f Erwan
- Lords are now taken into account in AI statistics. (To display information, uncomment RENDER_AI_STATS in config.h)
- fixed a potential segfault with NoFizzle
2009-12-03 02:05:03 +00:00
wagic.the.homebrew@gmail.com
f924546dcc Erwan
- Code cleanup
- fix issue 142 . This will lead to other issues for some cards. These issues can be fixed by using targetcontroller/controller...etc
- Added a few cards
2009-11-21 09:40:14 +00:00
wagic.the.homebrew@gmail.com
f6a75a0e43 Erwan
- Fix issue 194
- Attempt at doing basic AI tests
2009-11-15 09:31:33 +00:00
wagic.the.homebrew@gmail.com
e059890446 Erwan
-reduced SFX Quality. This seems to fix the Bug with samples getting silent on the PSP (issue 112), and improves loading times. If you think this is unacceptable, let's discuss it
- AI now should play fetchlands' ability, although still not "efficiently"
- Fix a bug where the game would crash if a card has a valid alias to a hardcoded card that is in no _cards.dat (starwars mod cards aliasing a MTG card)
2009-11-12 11:39:47 +00:00
wagic.the.homebrew@gmail.com
1d20f37ded Erwan
- fix issue 151 (I hope)
- small french translation Update
- Nezumi Cutthroat fix
2009-11-03 03:51:05 +00:00
wagic.the.homebrew@gmail.com
273b0672e4 Erwan
- various optimization fixes
2009-10-19 11:37:47 +00:00
wagic.the.homebrew@gmail.com
6f159fb39c Erwan - cache fixes - Code review highly appreciated, please criticize my code!
- fix issue 65 (quads when no image  load slowly in shop/deck editor)
- Possibly fix issue 92, please let me know if it reproduces
- Fix issue 97 (Deck editor: weird behavior of deck display)
- Fix issue 39 - please verify
- Issue 56 can probably be closed as well
- Fix issue 86
2009-10-13 14:16:30 +00:00
wagic.the.homebrew@gmail.com
b2b88f1f23 Erwan
-fix issue 76. There's a huge performance cost for this fix, I hope it won't show too much in the PSP version.
2009-10-04 10:52:13 +00:00
wagic.the.homebrew@gmail.com
61cb849d33 Erwan
-attempt at issue 81. It will do for now
2009-10-04 08:39:34 +00:00
wagic.the.homebrew@gmail.com
3f2bf948eb Erwan
-fix issue 79 (AI and legendary cards)
2009-09-28 15:18:54 +00:00
wagic.the.homebrew@gmail.com
f7331b7066 Erwan
- Fix one card in ZEN
- Fix AI and counters (issue 75, see tests/manual/torture_ai.txt)
- Fix counters target
2009-09-28 13:34:49 +00:00
wagic.the.homebrew@gmail.com
30ef39d49d Erwan
- "fix" issue 25
- A few AI fixes for Deck 36 (artifact lands deck)
2009-09-27 06:37:24 +00:00
wagic.the.homebrew@gmail.com
71d4818646 Erwan
- Fix issue #16 (testsuite segfaults if file does not exist)
- Fix issue #37 (Normal Combat Damage is not dealt to creatures when the AI attacks)
- TestSuite now has an "AI" mode (see test/manual/p2_attacks.txt)
2009-09-22 06:15:32 +00:00
wagic.jeck
d55fc91112 Jeck - [Requires JGE rebuild] Extensive cache improvements.
* Numerous cache fixes, reduced filesystem access.
 * Cache fails very gracefully. 
 * Cache is now a templated class, with individual caches per data-type.
 * Much easier to extend.
 * Extensively debugged. Try compiling with -DDEBUG_CACHE.
 * Caches limits can be set on a per-item basis.
 * hgeParticleSystemInfo are now cached, mana particles now fall back to defaults.
 * Samples are not cached, but track filesystem misses using the cache backbone. 
 * Avatars are cached. Default baka avatar is now baka.jpg, to prevent collision with player.

A note on the retrieval types: 
  RETRIEVE_MANAGE puts a resource into a seperate, managed resource list.
    Managed resources are guarenteed valid for the lifetime of the program. 
    Retrieving a managed quad promotes the associated texture to managed. Don't do that by mistake.
    Calls to Resources.Refresh() will attempt to reload managed resources in place.

  RETRIVE_LOCK (and by extension, RETRIEVE_VRAM), returns a resource after locking it.
    A resource may have many locks, and remains in cache until they are all released. 
    If the resource is managed, it returns it unmodified.

A note on quads:
Unlike all other RetrieveWhatever() functions, the default behavior for RetrieveQuad is RETRIEVE_LOCK. Worse, Release(JQuad*) is slow, and will /always/ release one lock from the associated texture.   

There's a long and complicated explanation for this, involving support for live relinking of textures to existing quads, but basically what it means is that we only use RetrieveQuad for quads we intend to store and later Release(). If a temporary quad is needed, the preferred method is to use NEW JQuad* and SAFE_DELETE with RetrieveTexture(). RetrieveTempQuad is also provided, but is only guaranteed until the next call to the cache.

Note that RetrieveCard has none of these problems.
2009-09-14 08:28:49 +00:00
wagic.the.homebrew@gmail.com
7ce2c563e1 Erwan
- Fixed empty ActionStack "interrupt" messages
- If no attackers are declared, go straight to Combat end phase
- Once First strike damage is declared, attacking player needs to "actively" request a next phase event to go to the next damage step
- Second Damage step is called "Combat Damage (2)"
- UserRequestNextPhase is to be used knowing that it might not succeed
- Step change for GuiCombat is now computed at GameObserver::nextGamePhase

Note: Combat damage to creatures is not assigned when AI attacks. As this seems to be a problem with the previous SVN version, I4m still committing this change
2009-09-13 12:42:18 +00:00
wagic.jeck
f220d2e9b9 Jeck - Cache and resource manager merged, streamlined.
This is pretty major, so there'll probably be something wrong with it... even though I did spend a few hours looking.
NOTES:
 * If you've Retrieved it, don't delete it--- Use resources.Release(Whatever). 
    Textures automatically release subordinate quads.
 * Most of the time, use resources.RetrieveQuad to grab a quad. Should handle everything for you.
    RetrieveQuad will load the required texture, if needed.
    Only managed resources have a resource name ("back", "simon", etc). 
    Managed resources can be retrieved with GetTexture/GetQuad/GetWhatever.
    Non managed quads lookup by position/dimensions, defaulting to the whole texture.
 * Use resources.RetrieveTexture only when you need to do something special to it. 
    Calling retrieve texture with RETRIEVE_MANAGE will permanently add a texture to the manager
    RETRIEVE_LOCK and RETRIEVE_VRAM will lock a texture. It will not leave the cache until
    Release(JTexture*) is called, or as a last resort during cache overflow.
 * Try to only store (as a class member) pointers to textures retrieved with RETRIEVE_MANAGE. 
    All others may become invalid, although locked textures do have a high degree of stability. It's
    pretty safe to store a locked texture if you're not going to load much between uses.

There's a lot going on here, so I might have missed something... but it runs through the test suite alright.

TODO: 
 * When called without any arguments, RetrieveQuad sometimes leaves a thin border around the image. 
    This can be bypassed by specifying a quad one or two pixels less than the image size. Why?
 * I've had a crash while runing the Demo mode, something to do with receiveEventMinus? 
    This hasn't exactly reproduced on a clean SVN copy, (being a hang, rather than a crash) so 
    I've probably done something to worsen the problem somehow? I'll look into it tomorrow.
 * Clean up lock/unlock system, memory usage. Streamline interface, consider phasing out calls using GetWhatever() format.
2009-09-03 09:28:16 +00:00
jean.chalard
7214248494 J :
* Some more tweaking for combat.
* This still doesn't work, but it's closer.
2009-09-03 02:16:53 +00:00
wagic.the.homebrew@gmail.com
794eec8bb8 Erwan
-code cleanup
-fix one card in TSP
2009-08-31 10:17:28 +00:00
jean.chalard
6dab048a9e J :
* Interface for damage assignment.
2009-08-31 02:00:33 +00:00
wagic.the.homebrew@gmail.com
890c893c94 Erwan
-a few warning fixes
2009-08-27 13:11:29 +00:00
wagic.jeck
355ee7a271 Jeck - Support for user profiles, preliminary theme support, virtual keypad, options GUI update. Still a bit unorganized, but it works. 2009-08-26 20:13:09 +00:00
wagic.the.homebrew@gmail.com
0dfa3f2e16 Erwan
-fixesRockslide Elemental, Welkin Hawk
-Added messages for Manapool updates
-Cleaned up ManaProducer code
2009-08-26 14:30:24 +00:00
jean.chalard
3349f974f1 J :
* New interface.
* This breaks a lot of things. It is not feature-equivalent. It
  probably doesn't compile under windows and doesn't work on PSP.
* Damage is not resolved any more. This will have to be fixed.
* Blockers can't be ordered any more. This will have to be fixed.
* A lot of new art is included.
2009-08-22 05:59:43 +00:00
wagic.the.homebrew@gmail.com
94e199d92a Erwan
- some cleanup (gcc warnings)
2009-07-26 07:27:27 +00:00
wagic.the.homebrew@gmail.com
8cc2fc9d52 Erwan
- The AI can now use May Abilities
2009-07-25 11:43:36 +00:00
wagic.the.homebrew@gmail.com
cca8d0f600 Erwan
-fixed bug with elvish promenade (and various instants/sorceries)
-Fixed bug with some auras that wouldn't go to graveyard in some conditions
2009-07-19 06:42:00 +00:00
wagic.the.homebrew@gmail.com
9b263eaee1 Erwan
- Dragon Whelp bug fix
- Rampage bug fix
- AI can use mana abilities.
2009-07-19 04:19:24 +00:00
wagic.the.homebrew@gmail.com
01c62d04bf Erwan
-removing useless code
-fixed a few cards (incorrect set)
2009-07-18 14:26:58 +00:00
wagic.the.homebrew@gmail.com
c8333e76b1 Erwan
- Updated Parser mechanism. Right now this doesn't change functionalities much, but should be more readable, and make it easier to code some new abilities in the future
- Fixed regenerate, broken with r532
- Death Ward now works
- I think "&&" now works with all abilities, needs to be tested...
2009-07-11 15:59:51 +00:00
wagic.the.homebrew@gmail.com
11af671496 Erwan
- Added "Evil twin" Mode to unlock
2009-07-05 10:08:13 +00:00
wagic.the.homebrew@gmail.com
d52f06d98d Erwan
- Magic 2010 - blockers ordering
- Fixed a memory leak introduced in a previous revision (foreach)
2009-07-04 04:15:05 +00:00
wagic.laurent
dcdd0a18d8 Laurent - Added damage to the foreach parser (finally did it).
I tryed everything for weeks, adding lines of codes with no success...Finally the answer was so simple as 2 lines of code...
Also added/removed from code Spitting earth and corrupt... Need to chase and remove all the lookalike/alias in the rest of the code. And also as usual will require further testing...

Grü.

L.
2009-06-27 09:49:31 +00:00
wagic.the.homebrew@gmail.com
630a239f31 Erwan
- tap/untap of a card now sends an event
2009-06-25 14:23:21 +00:00
wagic.the.homebrew@gmail.com
53b1b5e9ec Erwan
- Magic 2010 - inplay becomes Battlefield. Wagic is still compatible with both, but try to use "battlefield" from now on. For example moveTo(battlefield) instead of moveTo(inPlay)
- Magic 2010 - "Removed from game" becomes "Exile". Wagic is still compatible with both, but try to use "exile" from now on. For example moveTo(exile) instead of moveTo(removedFromGame)
- Magic 2010 - "End of turn" step becomes "end" step. Wagic is still compatible with both, but try to use "end" from now on. for example: "@next end" rather than "@next endofturn" (not sure this is more clear than before, but at least it's consistent with the rules)
2009-06-17 13:11:45 +00:00
wagic.the.homebrew@gmail.com
33e79e234e Erwan
- Cache size is now an option
2009-04-19 06:02:29 +00:00
wagic.the.homebrew@gmail.com
e7678522ee Erwan
- fixed a few memory leaks (but Wagic still crashes on the PSP after a few games :( )
2009-04-12 12:39:44 +00:00
wagic.the.homebrew@gmail.com
fab150414b Erwan
- Added name effect for Momir
- Fixed a couple bugs with "moveTo", see test/Amugaba.txt
2009-04-11 03:59:46 +00:00
wagic.the.homebrew@gmail.com
12bd665409 Erwan
- add Mercadian Masques, Mirrodin, Odyssey -> let's do some cleanup!
- Attempt at solving a bug with AI+psychic venom (manaburn), not tested
- Added Abrasax's monocolor AI decks
- Momir better randomizer
- Removed 64 Abilities limitation, I hope...
2009-04-11 02:02:10 +00:00
wagic.the.homebrew@gmail.com
e46b199a6c Erwan
- small AI improvements for Momir
2009-04-06 13:04:00 +00:00
wagic.the.homebrew@gmail.com
e9190ff19f Erwan
- fix with Momir+ */* creatures
2009-04-06 12:19:18 +00:00
wagic.the.homebrew@gmail.com
6582a1972a Erwan
- Added Momir Basic mode :)
2009-04-04 12:52:36 +00:00
wagic.the.homebrew@gmail.com
5952b382a2 Erwan
-Fixed bug with fountain of youth
-New alternate format for decks
2009-04-02 12:50:18 +00:00
wagic.the.homebrew@gmail.com
3994006d7e Erwan
- fixed a few memory leaks
2009-03-29 10:33:42 +00:00
wagic.the.homebrew
a3c3006043 Erwan
- AI bugfixes (manaburn with ankh of mishra...)
- small tweaks
2009-03-18 11:29:23 +00:00