Commit Graph

440 Commits

Author SHA1 Message Date
Guangcong Luo
32a16d3879 Add default start messages
Default start messages do two things:

1. Remind us that we don't have a real message coded for an effect.

2. Support showing any kind of start message by default for custom
modded games. (It's of course still an option to pass `[silent]` and
then add a custom message with `|-message|`.)
2018-11-15 18:52:36 -06:00
Guangcong Luo
38a033ac4e Remove weather ability-start messages
These _are_ real messages from Gen 3, but since it's not like we
otherwise accurately simulate Gen 3 messages, it's a bit weird to
keep these around.
2018-11-15 18:52:36 -06:00
Guangcong Luo
fd89a66510 Implement new battle-text-parser
All battle text messages have been moved out of `src/battle.ts` and
into its own file `data/text.js`.

Code for handling this is in the new files `src/battle-log.ts` and
`src/battle-text-parser.ts`.

`data/text.js` is now extremely self-contained, and nearly ready for
translation support!

This is a significant modernization of battle.ts. In addition to moving
messages out:

Functions for getting names (`pokemon.getLowerName()` etc) have been
removed.

`battle.minorQueue` has been removed. Minor lines are now processed
directly on the main queue, with a new `battle.waitForAnimations`
flag to decide whether or not the main queue should wait for animations
to finish before moving on to the next line.

`battle.waitForResult()` and `battle.endPrevAction()` have been
removed. These confusingly-named functions closed the messagebar (and
flush the minor queue). They've been replaced with
`scene.maybeCloseMessagebar()`.

`pokemon.markMove()` and `pokemon.markAbility()` have been renamed
`pokemon.rememberMove()` and `pokemon.rememberAbility()`.
2018-11-15 18:52:36 -06:00
Guangcong Luo
4e7f998afa TypeScript data/graphics.js 2018-05-18 17:10:58 -05:00
Guangcong Luo
d247364027 Migrate js/battle.js to TypeScript
This is only a first step and doesn't pass strictNullChecks.

I'm committing now because skipping straight to refactoring will be
easier than trying to make it pass strictNullChecks as-is.

TypeScript found at least a few bugs here, which is nice.
2018-05-16 19:49:25 -05:00
Ridaz
76618605af Fix build 2018-04-01 09:22:37 +01:00
Ridaz
af903221e7 Update move animations 2018-04-01 09:11:28 +01:00
Ridaz
482249f48a Update move animations
Added a new particle so it can be used by some moves like Haze and Smokescreen
2018-01-27 22:45:18 +00:00
Guangcong Luo
5f33456468 Sync data 2018-01-26 18:15:03 -05:00
Ridaz
91fc604eec Update Teleport animation 2018-01-11 09:02:48 +00:00
Ridaz
013399cbdd Add Let's Snuggle Forever move animation 2018-01-09 20:30:43 +00:00
Ridaz
2bbde1eadf Update Fake Out & Photon Geyser animations 2018-01-06 17:34:54 +00:00
Ridaz
d868019313 Update Spite & Throat Chop animations
Also removed the redundant Brick Break animation
2018-01-04 00:23:31 +00:00
Ridaz
bef58119a4 Update Aura Sphere animation 2018-01-01 15:39:05 +00:00
Ridaz
97c40a4143 Update Extreme Speed & Teleport animations
... And Earthquake. Slightly.
2017-12-11 20:21:15 +00:00
Guangcong Luo
3d977d3026 Fix style error 2017-12-08 11:27:35 -06:00
Ridaz
b82f125a1c Update background shaking animations 2017-12-06 23:46:13 +00:00
Ridaz
b472cf6946 Update Bulldoze and Earth Power animations
Stomping Tantrum uses Bulldoze's animation
2017-12-04 17:55:25 +00:00
Ridaz
400bfa5b59 Update Earthquake move animation
Hopefully this will decrease the motion sickness
2017-12-03 14:42:30 +00:00
Ridaz
1c2089b75e Add confused self hit animation 2017-12-02 06:31:35 +00:00
Ridaz
f444d6b8f4 Properly update Earthquake animation (#1056) 2017-12-01 19:40:58 -06:00
Guangcong Luo
60d707ef6d Revert "Update Earthquake and Confusion animations"
Bugged commit

This reverts commit 3c5498591d.
2017-11-27 11:34:06 -05:00
Ridaz
3c5498591d Update Earthquake and Confusion animations 2017-11-26 12:04:21 +00:00
Guangcong Luo
45264383e8 Fix relative URLs in graphics.js
They were breaking replays.
2017-11-21 20:28:53 -05:00
Ridaz
45fa8cfaf3 Alias USUM move animations
It's temporary
2017-11-17 00:07:22 +00:00
Ridaz
5a632d951d Add USUM animations 2017-11-16 23:26:03 +00:00
urkerab
c14cd19648 Remove unexpected trailing commas (#1044) 2017-11-09 18:29:28 -05:00
Ridaz
c41d2b288c
Remove spook from battles (#1039)
Halloween is over
2017-11-01 22:45:29 +00:00
Ridaz
c6771d71b8 Update Shadow Sneak move animation 2017-10-31 06:20:57 +00:00
Ridaz
41d70b24ff
Add cursed effect animation (#1037)
... And a few extras
2017-10-30 17:28:40 +00:00
Ridaz
9f620edc6b Fix 958022a4e4 2017-10-22 20:10:48 +01:00
Ridaz
958022a4e4 Fix 6270fc5eef 2017-10-22 16:54:01 +01:00
Ridaz
6270fc5eef Add new Z-Move Animations 2017-10-21 21:08:54 +01:00
Guangcong Luo
0b83675340 Sync learnsets 2017-10-21 14:51:40 -04:00
Ridaz
7e6ab9b099 Fix Oceanic Operetta move animation 2017-09-10 09:46:00 +01:00
Ridaz
49a6d8dcef Add Acid Downpour move animation
...And make the code more consistent
2017-09-02 18:44:58 +01:00
Guangcong Luo
051f16287e Sync data 2017-08-24 20:16:25 -04:00
Ridaz
b5f8e261be Add gear based move animations (#983) 2017-08-17 12:51:53 -07:00
Ridaz
60705393cb Add All-Out Pummeling move animation
And update some other moves
2017-08-03 19:11:55 +01:00
Guangcong Luo
9b9497454c Sync learnsets 2017-07-28 23:09:38 -04:00
Guangcong Luo
f94441b8ac Sync learnsets 2017-07-12 04:44:02 -04:00
Ridaz
ddee8a318f Add Soul Stealing 7 Star Strike move animation 2017-07-06 21:16:20 +01:00
Guangcong Luo
a4cc6d1040 Sync data 2017-05-15 05:55:08 -04:00
Ridaz
323195c4b6 Update move animations 2017-05-01 12:20:32 +01:00
Guangcong Luo
1d5943db7f Sync learnsets 2017-03-13 02:29:10 -04:00
Guangcong Luo
a7ae37a9cf Sync learnsets 2017-03-09 13:54:20 -05:00
Ridaz
4d199fee60 Add missing adjacent move animations
And improve some other animations
2017-01-20 11:22:30 +00:00
Ridaz
41d1b34ae4 Update adjacent move animations 2017-01-19 16:25:55 +00:00
Ridaz
b453acb9cb Add Power Gem move animation 2017-01-14 23:44:59 +00:00
Ridaz
7550dce301 Add Shadow Punch move animation
And fix some other animations
2017-01-08 10:51:53 +00:00