Commit Graph

124 Commits

Author SHA1 Message Date
Guangcong Luo
34b2b937c9 Learnset checker support breeding DW with past gens
The learnset checker now allows DW mons to be bred with a mon of the
same species moved from a past generation.

Specifically, this supports DW Sableye with Sucker Punch and Recover
is now supported.
2013-04-07 14:46:19 -07:00
Marty-D
f016041a73 Give 'moves' with no priority a default of 0. 2013-03-16 23:07:53 -04:00
Guangcong Luo
738804c1f9 Refactor gen 1
This is simple stuff to bring it in line with PS's coding style.

Mod-specific rules are getting moved to mods/gen1/formats.js and
formats are condensed into one Custom Game format.
2013-03-08 08:59:17 -08:00
Joimer
0441a929c8 Allow an Illegal check without abilities.
Add callback for getStat.
2013-03-06 12:53:27 +01:00
Guangcong Luo
3bf7e226d7 Make sure custom games default to level 100
this way, even if it allows higher levels, the default won't be
higher than 100
2013-03-04 18:08:30 -08:00
Cathy J. Fitzpatrick
5bee686bb2 Refactor Battle to use prototypes 2013-02-26 22:49:10 -07:00
Bill Meltsner
dc355cd734 Prevent Smeargle from having Chatter or Struggle in its moveset, as neither can be Sketched. 2013-02-20 22:45:34 -08:00
Guangcong Luo
37b0cc44e3 Fix Tools-modifying Scripts
Specifically, this fixes init scripts as well as command-line random team
generation
2013-02-20 12:54:53 -08:00
Guangcong Luo
d5c8ac1d88 Fix more chainbreeding learnset check bugs
- Level-up moves can always be chainbred
2013-02-19 20:12:29 -08:00
Guangcong Luo
c77afcbe85 Scripts can now override the Battle prototype
(well, pseudo-prototype, I've yet to refactor Battle to actually use
prototypes)
2013-02-18 23:44:39 -08:00
Cathy J. Fitzpatrick
5f78f746c9 Better error messages in tools.js 2013-02-18 17:26:55 -07:00
Guangcong Luo
b39ff77883 Support for config/formats.js 2013-02-18 11:33:05 -08:00
Guangcong Luo
618868b50c Better error messages for the learnset checker 2013-02-17 13:22:32 -08:00
Guangcong Luo
72ffbc0359 Really fix level forcing 2013-02-17 01:08:38 -08:00
Guangcong Luo
abde83ddae Fix validation bug with maxLevel
(affects LC)
2013-02-17 00:15:58 -08:00
Guangcong Luo
2ef0a42b9d Learnset checker is more forgiving for VGC
- if you bring a level 50 pokemon to VGC, it'll be treated as level 100
  for the purposes of checking level-up moves
- we introduce a new flag 'maxForcedLevel' for this
2013-02-16 21:34:30 -08:00
Guangcong Luo
2e6926f22f Genderless pokemon can't pass egg moves
(Fix learnset checker suggesting otherwise
2013-02-15 19:31:20 -08:00
Cathy J. Fitzpatrick
2518f779f3 Remove buggy debug string 2013-02-14 23:58:12 -07:00
Cathy J. Fitzpatrick
a51b66b5e7 Fix debug message for overriding Battle properties 2013-02-14 13:34:43 -07:00
Cathy J. Fitzpatrick
0fdb3fdec9 Allow BattleScripts to override properties of Battle
This allows functions defined as properties of `BattleScripts`
(i.e. in scripts.js) to override properties of a `Battle` object.
2013-02-14 13:26:52 -07:00
Cathy J. Fitzpatrick
6506f492f9 Add better error message when mod file fails to load 2013-02-14 12:30:20 -07:00
Guangcong Luo
0dfc2c9b23 More learnset checking for egg moves
- instead of a free pass, level-up moves from a level higher than the
  current level is checked as an egg move
(other ways of learning a level-up move are still available)
2013-02-12 20:30:28 -08:00
Guangcong Luo
08eee348ae Learnset checker: LC fixes
- pokemon can only learn level-up moves before their current level
  if they can breed
- gen 3 pomeg glitch implemented
- gen 3 pomeg glitch (and any other gen 3 trick) disallowed for gen 4
  abilities on pokemon that haven't evolved
2013-02-12 20:16:08 -08:00
Guangcong Luo
b67454743b Hidden Power fix:
- Random battles and automatic detection sets Hidden Power IVs correctly
- Hidden Power now always does damage based on user's IVs
- User's Hidden Power base power is now reported
2013-01-24 15:03:04 -08:00
TheImmortal
f70ce8b12c Fix LC bug with DW moves
- No LC Pokemon can legally use its moves that are exclusively obtained from the Dream World

In other words, the Pokemon has to be above level 10 with it's DW ability + DW exclusive move
2013-01-15 01:51:34 +04:00
TheImmortal
65e0cebf6f Set level before set is validated- maxLevel for LC 2013-01-11 14:03:52 +04:00
Guangcong Luo
39c33e409c Fix the learnset checker to handle chainbreeding better
Specifically, Spikes + Sleep Powder Roserade is no longer legal
Also add more comments to checkLearnset
2013-01-11 01:42:47 -08:00
TheImmortal
3b647dbdfd Update learnset checker 2013-01-10 11:36:00 +04:00
Guangcong Luo
dad08d86a4 Correctly disallow empty movesets 2012-12-16 11:42:56 -08:00
Marty-D
8bf1653969 Implement move aliases. 2012-12-15 18:33:37 -05:00
Guangcong Luo
cae58c2fde More consistent name validation 2012-12-14 18:58:18 -08:00
Guangcong Luo
6f96a06440 Allow underleveled pokemon at level 50 if forced by VGC rules
(also add item clause to VGC)
2012-12-12 15:51:02 -08:00
Guangcong Luo
1e1cd11410 Implement item aliases 2012-12-12 15:49:48 -08:00
小太
b5b2b42ac4 Merge tools.js and chat-commands.js from master. This adds support for evoLevel, modifies checkLearnset() to return the problem and fixes a few things in chat-commands.js 2012-11-30 21:05:56 +11:00
小太
8d2387c3f5 Update pokedex with evoLevel and evoMove; and add camelCase 2012-11-30 21:03:37 +11:00
Guangcong Luo
f45f1c118e Sets without valid pokemon should be rejected
(they were previously converted to Bulbasaur later on, back before PS
had a set validator)
2012-11-15 19:32:35 -08:00
Guangcong Luo
52de2b4d19 Ran a static analyzer, fixed some errors
Specifically, Git Canary: gitconary.com
2012-11-12 15:31:57 -08:00
Guangcong Luo
c15bd05e8d Fix move legality checker bug
Combinations of level-up/tutor/TM moves from before gen-5 now work correctly
2012-10-22 11:30:18 -07:00
Guangcong Luo
28f550b5a4 Fullnames should use actual names where relevant 2012-10-05 01:30:34 -07:00
Guangcong Luo
bf191e778d Correctly disallow | in nicknames 2012-10-04 22:04:26 -07:00
Guangcong Luo
4d1ea5569c Disallow | in pokemon names 2012-10-04 21:25:44 -07:00
Guangcong Luo
c1a63d4f92 Fix learnset checker for baby pokemon 2012-09-17 11:31:03 -07:00
Guangcong Luo
b7ea982716 New system for event abilities
Fixes validation issues on Salamence and Gallade
2012-09-09 00:39:31 -07:00
Guangcong Luo
4c6a85d1d5 Different algorithm for checking event abilities 2012-08-22 19:32:06 -07:00
Guangcong Luo
157c0cbaec Small fix to learnset checker
A forme with a prevo presumably can't switch formes
2012-08-21 23:33:14 -07:00
Guangcong Luo
c41e7813f7 Several improvements to learnset checker 2012-08-21 23:17:50 -07:00
Guangcong Luo
ad72b5e657 Take event data into account by the set validator 2012-08-20 23:26:01 -07:00
Guangcong Luo
b1d448c717 !learnset command, for checking learnsets 2012-08-20 19:56:31 -07:00
Guangcong Luo
c335870340 Make sure formats have their full ruleset 2012-08-01 19:54:23 -07:00
Guangcong Luo
b801be60c0 Normalize set variables 2012-07-28 17:28:42 -07:00