Commit Graph

3416 Commits

Author SHA1 Message Date
Guangcong Luo
5abc202006 Don't cache old tournament JS files 2015-07-02 12:47:51 -04:00
Ivo Julca
744a2d80a6 Fix teams not being sent for tournament battles 2015-07-02 07:08:43 -05:00
Guangcong Luo
4aabfaf07f Fix crashes related to empty teams 2015-07-02 04:20:00 -04:00
Guangcong Luo
5a5f8e0c9a Merge branch 'MasterFloat-patch-1' 2015-06-30 15:55:15 -05:00
MasterFloat
1603a1a7a5 Fix popmenu button padding in Mozilla
This adds 1px top and bottom padding to popupmenu's button to match its
hover offset. Necessary because of a bug in Mozilla involving box-sizing
of buttons.
2015-06-30 15:25:42 -05:00
Guangcong Luo
6c15f75c61 Update 'icons' for empty team 2015-06-30 04:18:42 -05:00
Guangcong Luo
35ea08391d An empty string is not a corrupt team 2015-06-30 04:17:26 -05:00
Ivo Julca
464129ce8c Safe return type ([]) for team unpacker functions 2015-06-30 04:05:36 -05:00
Ivo Julca
b3276d0290 Fix Desktop client teambuilder crash
Attempting to go to Team List after deletion of all Pokémon in a team triggered a TypeError
2015-06-30 03:59:26 -05:00
Guangcong Luo
d674dfca8d Support packed teams in desktop client 2015-06-30 03:20:29 -05:00
Ivo Julca
4106dd379d Fix crash in Storage.packTeam for some corrupted teams 2015-06-30 02:45:34 -05:00
Guangcong Luo
86820e79a0 Minor grammatical fix to a comment 2015-06-30 02:25:01 -05:00
Guangcong Luo
84be1cd2f2 Teambuilder: more reliable team saving 2015-06-30 02:24:50 -05:00
Guangcong Luo
37af6ced67 Remove extraneous saveTeams function 2015-06-30 02:24:17 -05:00
Guangcong Luo
bbc2188a40 Refactor teambuilder to use packed teams
This is a major refactor that changes the teambuilder to store
teams in packed format whenever possible, for approximately 50%
less memory usage for team storage.

The only visible change here is that pokemon nicknames have been
replaced with pokemon icons in the teambuilder team list, to
match the team selector in the main menu, which simplifies
extracting information from packed teams.
2015-06-30 02:16:55 -05:00
Guangcong Luo
df1ec9ff3c Make sure popups are on-screen 2015-06-30 02:06:24 -05:00
Guangcong Luo
d41b7329b3 Show popup error for corrupt teams 2015-06-30 02:06:24 -05:00
Guangcong Luo
cc7af41bd5 Refactor Storage not to use _Storage class 2015-06-30 02:06:24 -05:00
Guangcong Luo
2a6a2667a7 Move team import/export functions to storage.js
This refactor moves:

TeambuilderRoom.parseText -> Storage.importTeam
TeambuileerRoom.toText -> Storage.exportTeam
TeambuilderRoom.teamsToText -> Storage.exportAllTeams
2015-06-29 17:17:51 -05:00
Guangcong Luo
4d21b8fc61 Support |popup||html|
This displays a popup containing (sanitized) HTML.
2015-06-29 17:21:32 -04:00
Guangcong Luo
2019b60cf1 Support |c|~|text
This displays "text" as a line in chat that can highlight, but otherwise
looks like a `||text` line.
2015-06-29 17:21:32 -04:00
Guangcong Luo
c1330dc050 Support <<roomid>> links in chat 2015-06-29 17:21:32 -04:00
Guangcong Luo
2723b1df3d Fix testclient.html support
(It was broken by the protocol change)
2015-06-29 02:26:16 -05:00
Guangcong Luo
1eea2b3f45 Prevent 'Find a user' from finding Zarel
It has been deemed to cause too much spam for Zarel :(
2015-06-28 00:50:17 -04:00
Guangcong Luo
434be97f8a Support |popup| options
Specifically, |wide| makes a wide popup, suitable for modlog results.
And |modal| makes a modal popup, currently only used for locks and
bans, to make sure they're not accidentally dismissed.
2015-06-28 00:50:17 -04:00
Guangcong Luo
50c8273d03 Support /error in PMs
It's like /text, except the text is red.
2015-06-28 00:50:17 -04:00
Guangcong Luo
2a6993f31e Forfeit menu also closes window by default
A lot of people think the case of someone wanting to forfeit but
not leave the room is obscure, but for now, I think it's still
worth supporting. It's currently implemented as a checkbox, so
it's pretty unobtrusive.
2015-06-28 00:50:17 -04:00
Guangcong Luo
7c802fc4e0 Rainbow main menu!
In honor of Obergefell v. Hodges
2015-06-28 00:50:17 -04:00
Guangcong Luo
3f8ffa684f Support new challstr protocol
See Zarel/Pokemon-Showdown@d5c622b493

New system is backwards-compatible with old one. This also slightly
refactors some other stuff, for an overall simpler system.
2015-06-28 00:50:17 -04:00
Guangcong Luo
a6e56e969a Update jQuery to 2.1.4 2015-06-28 00:50:16 -04:00
Guangcong Luo
ea348e8a19 Remove outdated -webkit and -moz CSS
linear-gradient has been supported in most major browsers for long
enough that we can drop gradient support for really old browsers.
2015-06-28 00:50:16 -04:00
Ivo Julca
db16dd8abe Use toName to sanitize command targets 2015-06-27 02:40:08 -05:00
Ivo Julca
4a49f37f08 Don't warn on window close at localhost 2015-06-27 02:39:47 -05:00
Guangcong Luo
d2b5a0bad3 Support some CSS in sanitized HTML 2015-06-27 02:46:00 -04:00
Guangcong Luo
0486cc1026 Minor refactor to /user 2015-06-27 02:42:11 -04:00
Guangcong Luo
ec43507738 New 'Find a user' button in Main Menu
Should make it easier for players arranging battles outside of PS
to challenge each other.
2015-06-25 20:14:00 -04:00
Guangcong Luo
da98991b11 Fix crash in Forfeit menu 2015-06-25 20:13:42 -04:00
Guangcong Luo
37ca8f342a /part now gives a warning during active battles 2015-06-25 19:48:16 -04:00
Guangcong Luo
53bd58e18a Add 'Replace player' button in Forfeit menu
This is relevant to unrated battles, where you can swap out players.
2015-06-25 19:46:36 -04:00
Guangcong Luo
b1286fa7d9 Don't close when forfeiting from Close button
The Forfeit button in the menu that appears when you try to Close an
active battle is actually a 'Forfeit and close' button. It's now
just a Forfeit button, in case players want to stay in the room
for whatever reason. Actually leaving the room just involves clicking
the Close button again.
2015-06-25 19:20:51 -04:00
Guangcong Luo
d51f9afdeb Open Forfeit menu next to Close button
We have to pass an event through a few more functions to make the
Forfeit menu work like other semimodals in terms of opening near
the Close button when the Close button opens it.
2015-06-25 19:14:04 -04:00
Guangcong Luo
2ce4754043 Remove Google Analytics ugly URLs
Google Analytics adds weird things to the URL when linking cross-
domain. This removes them after loading for less ugliness.
2015-06-25 19:09:59 -04:00
Guangcong Luo
6fab7de011 Warn before closing window with active battles 2015-06-25 19:08:39 -04:00
Guangcong Luo
fa6f20d352 Watch Battle window: Move Close button to top right 2015-06-25 19:07:46 -04:00
Guangcong Luo
9a9c7010de Open semimodal popups next to opener
Before, only nonmodal popups would appear next to the button that
opens them. Now, semimodal popups do as well. This should make certain
operations faster and more intuitive.

Watch Battle is now modal instead of semimodal, because it doesn't
work well in this kind of presentation.
2015-06-25 19:05:09 -04:00
Guangcong Luo
60957d95c5 Fix bug in leaveBattle
It would show the other side as left, instead of your side.
2015-06-25 18:44:20 -04:00
Guangcong Luo
96dfe64a58 Close button forfeit menu opens for unrated battles too
Previously, the close button forfeit menu only appeared for rated
battles.
2015-06-25 18:43:04 -04:00
Guangcong Luo
d923f047cd Improve spoiler tag support
Putting parentheses like this: (spoiler: test) now allows you to
designate a part of a line to be spoilered, instead of spoilering
everything to end-of-line. Yes, it's also possible to have
multiple spoilers on a line.

As a side effect, this also fixes the issue where spoilers messed
up modlogs by restricting them to one line.
2015-06-25 18:02:45 -04:00
Guangcong Luo
c4129beef0 Merge pull request #406 from ascriptmaster/move-messages
Change -endability message structure
2015-06-25 21:41:38 +00:00
Kevin Lau
97eaa72cbf Change -endability message structure
With Simple Beam and Worry Seed now using -endability as well to reveal
the old ability, it is more appropriate to use a new message. Parentheses
are traditionally used by the client to indicate messages that do not
actually appear as in-game text.
2015-06-25 12:30:02 -07:00