Commit Graph

652 Commits

Author SHA1 Message Date
haven1433
2b8c35c1d5 <auto> improvements
if the last thing is a label, make sure to include an end command for it
if the last thing isn't an end command (or goto, etc) make sure to include an end command for it
2023-01-22 21:25:31 -06:00
haven1433
9622784b1c Adding lots of niche tables
Thanks Shiny and Soup :)
2023-01-22 20:21:08 -06:00
haven1433
f74c1abd45 include unused labels at end of script 2023-01-22 20:20:16 -06:00
haven1433
0ae5726551 table update (data.menus.text.pc) 2023-01-21 22:10:50 -06:00
haven1433
7d1e6065d5 ScriptParser updates
* add a basic limiter so that parsing scripts will 'give up' if they get the same 0-arg command 20 times
* fix crash that could happen sometimes when trying to check a pointer for sources during script decoding
* don't try to decode streams as scripts (misuse of the destinations collection)
2023-01-21 21:29:49 -06:00
haven1433
e55ef5c8a3 Include sub-scripts from scripts that were combined with the current script
Since scripts don't always end at an `end` or `goto` anymore (if there's a label from within the script to directly after the script), we need to make sure that these appended scripts still get a chance to add more scripts into the UI.
2023-01-21 20:41:42 -06:00
haven1433
8b3f29cf6d update animation script reference 2023-01-16 22:17:05 -06:00
haven1433
1d4749b41f misc feature updates from pins
* add anchor for misc animations
* flags should be seen as hex in the script editor
* various table updates
* update text in empty block selection case
2023-01-15 23:03:48 -06:00
Smig0l
cc7b67fff2
Create default.bpei0.toml (#104)
* Create default.bpei.toml

Added the toml file with addresses valid for BPEI (Pokemon Emerald Italian Version).
Some are sourced from https://github.com/Gamer2020/PokemonGameEditor/blob/master/roms.ini

* Update default.bpei.toml

added maps addresses

* Update default.bpei.toml

updated and reordered

* Update HardcodeTablesModel.cs

* Rename default.bpei.toml to default.bpei0.toml

* Update default.bpei0.toml

fixed exception error in 0.5.0.2

* Update default.bpei0.toml

deleted commented lines

* Update HexManiac.Core.csproj

* Update HexManiac.Core.csproj

Indented correctly
2023-01-15 12:12:48 -06:00
haven1433
216dece90b scripts.callstd should only have 10 elements in firered 2023-01-12 22:21:01 -06:00
haven1433
bf4e766b6b allow tabs in thumb editor
we need to copy both newlines _and_ tabs for the text editor viewmodel, or the spacing won't line up right between colors
2023-01-06 20:55:18 -06:00
haven1433
47388d5f3e map editor bug fixes
* creating a new map should be considered an autonomous operation for undo purposes
* support connection-objects for FireRed
* crash less when reading invalid map / layout data
* show correct hover square when hovering over neighbor maps with borders
* fix elevation names / map permissions
* don't update tile render info for the block editor if the x/y change is a no-op
*
2023-01-05 22:53:35 -06:00
haven1433
65e534a46d map editor fixes
* say width/height correctly in the tooltips of the map size handles
* less flickering during undo
* include default OW sprite instead of blank (for example, tutorial catch man in viridian city)
* speed up the initial script-check process that looks for default trainer sprites for each OW by not caring about the length of child scripts
* use proper thread locking during block cache invalidation and renewal so that undo doesn't mess up the number of blocks shown in the block panel
2023-01-04 23:06:51 -06:00
haven1433
fe07a3e458 <auto> pointer bugfix 2022-12-22 17:26:56 -06:00
haven1433
c4dba402cb battlescript bugfixes 2022-12-22 17:26:35 -06:00
haven1433
5ab843d3b2 implement game-specific macros 2022-12-21 22:47:41 -06:00
haven1433
2c52358396 Compile / Decompile improvements
* when docompiling, don't include a box that contains a partial script that's already in the main box
* when compiling, require arg counting for getting macro length
2022-12-21 08:33:53 -06:00
haven1433
3e16f8ee20 add stream content recursively for scripts
This should make <auto> able to work even when there are scripts that point to scripts, as the content will appear after the last attached script.
2022-12-20 22:34:26 -06:00
haven1433
3b6a18072f improving auto support
for mart, movement, and if statements
2022-12-20 14:29:20 -06:00
haven1433
5371397475 first part of <auto> support 2022-12-18 10:26:02 -06:00
haven1433
6874768ffc additional macros
support for out-of-order macro commands
also allows for arguments to be applied multiple times
2022-12-15 08:06:26 -06:00
haven1433
8a5e5c793c implement additional UBL features
universal branchlink can now handle selection/cut/paste in cases involving pointers and anchors
2022-12-09 08:40:49 -06:00
haven1433
30026eea8d first pass at universal-branch-link feature
this allows us to select/cut/paste thumb routines safely
2022-12-09 00:09:42 -06:00
haven1433
b53baace97 fix trainer back animation labels 2022-12-08 20:40:27 -06:00
haven1433
66f3bd9006 syntax highlighting for multiline comments 2022-12-06 21:40:45 -06:00
haven1433
0285808eb0 bufferPokemon species should allow pokemon names as input 2022-12-06 21:40:08 -06:00
haven1433
f9848fa85c add callstd routines
They can be expanded to make more 'standard' routines to call in scripts
2022-12-06 21:39:03 -06:00
haven1433
f96a3ada92 thumb macro fixes 2022-12-06 07:08:25 -06:00
haven1433
7d8ae74a00 script bugfixes
add enum types for fanfare / bufferitem
allow script constants to contain underscores
allow autocomplete for constants that are the last argument
allow 'find usages -> scripts' to find usages from macros (and fix crash)
2022-12-04 22:38:04 -06:00
haven1433
4a5f351d6f final fixes for 0.5
givePokemon, use item constants
fix crashes/errors in hover-tip logic for trainerbattle commands
* tested that macros and array args still work right
2022-12-03 22:50:33 -06:00
haven1433
88e90f980c fix completion tips for array-arg and 0-arg commands 2022-12-03 21:24:05 -06:00
haven1433
380738609b draft of auto-complete for script tool 2022-12-03 19:09:31 -06:00
haven1433
bf1d30fe7d more macros
also clear constant cache when refreshing ViewPort
2022-12-02 23:28:56 -06:00
haven1433
d6d6a6c54f initial macro support 2022-12-02 22:41:39 -06:00
haven1433
830740ad34 script editor is now colored 2022-12-02 20:44:59 -06:00
haven1433
4e7148a5f6 thumb editor is now colored 2022-12-02 11:35:24 -06:00
haven1433
c0f3ade883 allow script lines to have multiple stream sections 2022-12-02 10:22:00 -06:00
haven1433
a44841290f first pass at updating script pointer logic
instead of the script line itself knowing that it points to something,
pull it down to the argument level, so that each argument knows
if it points to something.

This will allow a single script line to point to multiple things (like trainers pointing to multiple text or scripts)
2022-12-02 08:38:21 -06:00
TheDiamondMiner
bcea3d6768
Updated TOML based on Shiny's Changes (#102)
* Added shiny's changes.

* Fixed typo
2022-11-29 06:47:14 -06:00
haven1433
c355f07993 fix toml upgrade issue (tuples) 2022-11-28 22:42:21 -06:00
haven1433
acf55f0101 improve animationScriptReference
thanks `AGSMG?`!
2022-11-28 21:07:14 -06:00
haven1433
a7b1734404 add data.items.stats format for item-related script commands 2022-11-28 20:22:55 -06:00
haven1433
8ad4298809 fix number of thumb routines in specials table 2022-11-26 22:50:04 -06:00
haven1433
8f3da7f04e bugfixes 2022-11-25 13:17:21 -06:00
haven1433
4c2089196b usability feedback
label stuff
center new connections
berry shortcuts
fix goto shortcuts
2022-11-24 11:24:56 -06:00
haven1433
d66a02d518 fix trainer backsprite palettes for R/S 2022-11-23 11:04:00 -06:00
haven1433
1728e73143 include field item enums for non-pokeball items 2022-11-23 10:59:14 -06:00
haven1433
e285eaaf7b add 'scripts' option to 'show uses' button
Unlike the other ones, this one doesn't pre-calculate, and may end up being empty when you click on it.
2022-11-23 08:26:46 -06:00
haven1433
2ce867a955 update trainertower format 2022-11-22 15:14:53 -06:00
haven1433
d350c6bfa9 fix ai scripts for emerald 2022-11-22 08:52:52 -06:00