Commit Graph

12661 Commits

Author SHA1 Message Date
The Immortal
4d6bb64aac Add new RoA Spotlight 2017-03-01 20:39:37 +04:00
Guangcong Luo
60b788cf96 Fix grammar/style
Credit to #3304
2017-03-01 02:41:38 -05:00
Guangcong Luo
156325d44c Fix past-gen event validator
Future-gen events were previously allowed in past gens.
2017-03-01 02:13:08 -05:00
Guangcong Luo
1daa700434 Validator: Validate incomplete teams
In VGC and Battle Spot, the validator wouldn't do any validation at all
if you didn't bring the minimum number of Pokemon. Now, it still gives
other error messages in addition to "You need at least X Pokemon".

This is mostly nice for validating a single Pokemon for VGC etc without
needing to fill the rest of the team with junk.
2017-03-01 02:13:08 -05:00
Guangcong Luo
e8b60c1e90 Fix Gen 1-2 DV/EV/shiny/gender validation
The old code tried to validate by changing incorrect values to correct
values, but had lots of bugs. Even if it didn't have bugs, it would have
various flaws like stats being different from what you would expect from
the teambuilder, so the new code just tells you when your HP DV,
shininess, gender, and Hidden Power type are inconsistent with your
other DVs.

(The one exception is SD Thick Club Marowak, which still automatically
fixes its Atk IV, since we still don't have teambuilder UI for that.)
2017-03-01 02:13:08 -05:00
The Immortal
390fb3419b Remove BH suspect test 2017-02-28 21:48:36 +04:00
Charlie Kobayashi
9dd4236479 Prevent permalocked users from getting unlocked (#3303) 2017-02-28 00:49:54 -04:00
Quinton Lee
01a029172d Tournaments: support rulesets in /tour banlist (#3300)
* Validator: fully support overriding rulesets

* Tournaments: support rulesets in /tour banlist
2017-02-27 02:32:01 -04:00
Guangcong Luo
9031680e5d Battle timer: Only disconnected players should have 60s
Previously, if one player was disconnected when the timer was started,
both players would default to a 60 second limit.
2017-02-27 01:38:37 -04:00
Guangcong Luo
fc16f4fe4f Hacked Z-moves can't be Z-boosted 2017-02-27 01:14:35 -04:00
Guangcong Luo
0bf08c2ad3 Fix calling Z-move names
e.g. Z-Sleep Talk would previously call Z-Taunt, when it should be
calling Taunt.

This was only ever a text error; it never used Z-Taunt's Z-effect.
2017-02-27 01:06:54 -04:00
panpawn
7c4ed6dd46 Scavengers: Fix crashing help command (#3302) 2017-02-26 22:52:45 -05:00
Charlie Kobayashi
e9886a2935 Fix Triple Hit mechanics in Gen 2 (#3299)
- Don't use multi accuracy setting
- Set multihit between 1 and 3 randomly, as it has been mentioned in here https://github.com/Zarel/Pokemon-Showdown/issues/3239#event-977289878 (scripts __should__ automatically do a random distribution if the ratio is not between 2 and 5)
2017-02-26 02:11:44 -05:00
Charlie Kobayashi
a844906098 Fix HTML and date field check in room-events (#3298) 2017-02-25 22:28:19 -05:00
Charlie Kobayashi
9141cb8415 Fix permissions for pminfobox (#3295) 2017-02-25 21:14:00 -05:00
MacChaeger
19b0b48ac0 Random Battle: Improve level balancing (#3293) 2017-02-26 04:37:38 +04:00
Guangcong Luo
224400408a CONTRIBUTING.md: Improve phrasing 2017-02-25 14:48:15 -06:00
The Immortal
6bdcdbfcfa AAA: Ban Innards Out 2017-02-25 19:45:21 +04:00
urkerab
1d4ac35d37 Simplify the way the factory tier is chosen (#3286) 2017-02-25 06:16:55 -06:00
Spandan Punwatkar
9d8fde5436 Update formats.js 2017-02-25 06:21:15 -05:00
Spandan Punwatkar
732d2a7598 Update Inheritance Hack
This is a worse hack, but it will prevent locked users from cheating by getting their nicknames suppressed.
I also wanna know: What would be the problems that this could possibly face? I've tested this and it works fine (But I dont yet know about any problems)
2017-02-25 06:21:15 -05:00
panpawn
03b2c4763d Roomevents: Check description HTML syntax (#3291) 2017-02-25 02:05:14 -06:00
panpawn
8a4566a172 Markshared: Return help command on no target (#3290) 2017-02-25 01:43:44 -06:00
Guangcong Luo
a8393c40ed Support Config.loglevel
Another undocumented config setting; this one lets you specify what
you want to appear in standard out.
2017-02-25 02:48:16 -05:00
Guangcong Luo
c2ae5c5354 Fix validator crashes 2017-02-25 02:36:00 -05:00
Guangcong Luo
9990a25385 Give higher battle limit to shared IPs 2017-02-25 02:35:32 -05:00
panpawn
0bdd3e6c19 Roomevents: Correct typo in errorReply (#3288) 2017-02-24 23:26:29 -06:00
panpawn
5e1cfefe64 Implement room events plugin (#3287)
This adds a room-managed room-specific events plugin that allows rooms to keep track of upcoming room events.

This is multipurpose and could be helpful to multiple rooms; may it be tournaments or upcoming sports games, this would be helpful in many use-case scenarios.
2017-02-24 22:45:07 -06:00
Ivo Julca
55641c2635 Fix regressions in random team generation and improve comments
The regressions affected information handling
- Seeds used for random teams were no longer being logged.
- The seed used for generating p2's team was also used for the battle itself.
2017-02-24 20:18:59 -05:00
HoeenHero
1551ec0e98 Battle Factory: Fix issue with sides having different tiered teams (#3285) 2017-02-24 15:28:43 -06:00
Guangcong Luo
220d9cf7d9 Add more useful errors for Validator#validateSource 2017-02-24 06:55:11 -06:00
Guangcong Luo
6306b5979f Fix infinite looping Dancer 2017-02-24 06:54:13 -06:00
asgdf
04a944010b Fix VGC17 discussion thread link (#3284) 2017-02-24 15:57:07 +04:00
Ben Davies
5031794f97 Sockets: fix unit tests (#3281)
* Sockets: fix Sockets.killWorker not disconnecting connections

* Sockets: fix unit tests

- Fix crash when constructing mock sockets in certain cases
- Properly prevent workers from writing to stdout
- Fix race conditions in workers-related tests that were causing false
  positives

* Tests: mock workers now more closely imitate sockets' workers

This helps catch cases where messages are being sent in the wrong order
to the workers, e.g. messages sent to sockets that no longer exist.
2017-02-24 05:38:37 -06:00
Guangcong Luo
eeea7e3ed0 Fix Hidden Power validation 2017-02-24 05:13:44 -06:00
Guangcong Luo
bb7b168355 Fix crash in PRNG 2017-02-24 05:46:51 -05:00
The Immortal
e34318b518 Standard GBU: Fix undefined Pokemon name 2017-02-24 14:23:58 +04:00
The Immortal
37e383e13b Remove OU suspect test 2017-02-24 13:55:46 +04:00
The Immortal
f70d3cf1cc Standard GBU: Use format name for Soul Dew message 2017-02-24 13:49:28 +04:00
Guangcong Luo
abc2d22e96 Sync datacenters.csv 2017-02-24 04:57:53 -05:00
Guangcong Luo
2bc476d9a2 Fix crash in validator 2017-02-24 04:57:52 -05:00
Guangcong Luo
8ee23475e4 Fix Dancer + Petal Dance
Dancer Petal Dance shouldn't lock. This is a horrible hack but it fixes
the problem. A real fix would involve refactoring basically all locking
moves. Which I guess I should do one day...

Fixes #2974
2017-02-24 03:25:00 -06:00
Guangcong Luo
9200062819 Improve Dancer implementation
This doesn't fix the biggest issue with Dancer (Petal Dance locking),
but it does fix every other Dancer issue, by moving it from useMove
to runMove.

This also adds improved comments on runMove and useMove.
2017-02-24 03:17:37 -06:00
Guangcong Luo
d9b431b7c2 Stop converting set values to names
Because of the way fastUnpackTeam works, it's currently a reasonable
assumption that all the values in a `set` are IDs, and various parts
of the code have started to rely on that assumption.

Removing some old code to try to guarantee that the values in a `set`
are names allow us to work towards a new guarantee that `set` values
are IDs.

Closes #2553
2017-02-24 01:38:45 -06:00
Guangcong Luo
d4a968cab5 Make Copycat fail to copy Baneful Bunker 2017-02-24 00:57:40 -06:00
Guangcong Luo
8b25a865b9 Support /groups room and /groups global
Closes #3086
2017-02-24 00:53:16 -06:00
Guangcong Luo
5a95f6f247 Remove unnecessary code
The Diancie check is now implemented in Diancie's event data.
2017-02-24 00:41:48 -06:00
Guangcong Luo
4052b28cec Refactor event validator
This is a huge refactor that consolidates many different places event,
DW, and VC moves are validated, so that they're now validated in the
single place Validator#validateEvent. DW and VC moves are now treated
as special cases of events.

Validator#checkLearnset now does zero validation of event, DW, and VC
moves; it now simply passes the list of possible sources back to
Validator#validateSet, and it's validateSet's job to determine if the
Pokemon meets the requirements for any of those sources.

(In addition to simplifying checkLearnset, this also means more
useful error messages if you fail to meet the requirements for an
event move or DW move.)

validateSet should also be a decent margin simpler, due to a lot of
its code being folded into validateEvent.
2017-02-24 00:38:47 -06:00
PainterEspeon
59a9d8bd8c Change to /scavengerhelp (#3033)
Changed "/scavenge <em>guess</em>" to "/scavenge _______" in the /scavengerhelp command. Especially considering UGM is beginning effective today-ish, helps make the command more clear to new users and get them acclimatized to the room. There has been recurring issue for a long time of new users believing that they need to type "/scavenge guess [their answer]" instead of "/scavenge [their answer]," the latter of which is correct.
2017-02-24 00:33:19 -06:00
Kris Johnson
621b737ca3 info.js: add Ash-Greninja exception (#3282) 2017-02-23 18:25:58 -06:00