Compare commits

...
Author SHA1 Message Date
apion 7b3fd8206e Got rotations working for locator bound riders (kinda) 2025-02-08 20:15:21 -05:00
apion e211095317 Player model now stays tethered to seat locator when riding 2025-02-07 21:37:33 -05:00
JPAK b9675ef25c Wrap PlayerRenderer properly now. 2025-02-07 20:29:08 -06:00
apion e25802ab74 Changed bird controller so movement is dependent on pitch and roll 2025-02-07 18:46:55 -05:00
Paul fdc9d48bd6 Reworking generic liquid controller 2025-02-03 18:54:33 +10:00
Paul 74dcbc3e17 Added optional player animations to riding (Lapras as example) 2025-02-01 19:09:51 +10:00
Paul 832999850e Wait put that back 2025-02-01 17:35:42 +10:00
Paul 93b0f40c80 Added vehicle land controller (REVAVROOOOM) 2025-02-01 17:35:14 +10:00
Paul d1928f5b43 Added fall_to_flight controller and polished gliding on Gliscor 2025-02-01 10:22:55 +10:00
Paul 5374fe251d Merge branch 'main' into means-of-transportation
# Conflicts:
#	common/src/main/resources/data/cobblemon/species/generation1/aerodactyl.json
#	common/src/main/resources/data/cobblemon/species/generation1/charizard.json
#	common/src/main/resources/data/cobblemon/species/generation1/lapras.json
#	common/src/main/resources/data/cobblemon/species/generation4/bidoof.json
#	common/src/main/resources/data/cobblemon/species/generation4/gliscor.json
2025-01-31 20:55:59 +10:00
Hiroku 36169db388 Merge branch 'feature/save-file-juggling' into 'main'
old and temp files for everyone

See merge request cable-mc/cobblemon!1484
2025-01-31 07:46:10 +00:00
Paul 1900999a74 Changelogging [skip-ci] 2025-01-31 17:41:56 +10:00
Hiroku ab16814cd2 Merge branch 'fix-setpageondefaultdialoguepage' into 'main'
fix: calling setPages() when initializing the dialogue so default pages can have their timeout scheduled

Closes #1406

See merge request cable-mc/cobblemon!1504
2025-01-31 07:41:29 +00:00
Hiroku 9f622fcd74 Merge branch 'pc-box-2-fix' into 'main'
Fix PC opening on Box 2

See merge request cable-mc/cobblemon!1505
2025-01-31 07:40:16 +00:00
Hiroku 956e2c43b8 Merge branch 'feat-winners-and-losers' into 'main'
feat: set winners and losers on PokemonBattle end

See merge request cable-mc/cobblemon!1501
2025-01-31 07:37:14 +00:00
Hiroku 130f87c9f7 Merge branch 'strip-stripped-log' into 'main'
remove apricorn_stripped_log and apricorn_stripped_log_top as never used

See merge request cable-mc/cobblemon!1502
2025-01-31 07:27:54 +00:00
gbassinello 22b4e8c75f chore: changelog lines 2025-01-31 01:44:50 -03:00
gbassinello c19a3ca444 feat: set winners and losers on battle end 2025-01-31 01:44:50 -03:00
Polymetaandgbassinello a006eb5dcc revert previous attempt and fix camera mode
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-31 01:44:50 -03:00
gbassinello ed419e7e53 fix: removing activeDialogues from the DialogueManager map using the correct key (player uuid) 2025-01-31 01:44:50 -03:00
Hiroku bff2387b4d Merge branch 'feature/particle-fixes' into 'main'
revert previous attempt and fix camera mode

See merge request cable-mc/cobblemon!1506
2025-01-31 04:02:00 +00:00
Polymeta 41544efeba revert previous attempt and fix camera mode
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-30 23:15:08 +00:00
Paul e6e6c9f7f6 Merge remote-tracking branch 'origin/main' 2025-01-31 08:31:31 +10:00
Paul 22d8e39db3 back to snapshots 2025-01-31 08:31:17 +10:00
Hiroku bfdf1e9e6c Merge branch 'fix-activedialoguesmapkey' into 'main'
fix: removing activeDialogues from the DialogueManager map using the correct key (player uuid)

Closes #1405

See merge request cable-mc/cobblemon!1503
2025-01-30 22:19:22 +00:00
BuildTools c3fccfde09 Fix PC opening on Box 2 because default value for 'box' in OpenPCPacket was '1' instead of '0' 2025-01-30 21:48:18 +02:00
gbassinello 4bb8d43a6e fix: calling setPages() when initializing the dialogue so default pages can have their timeout scheduled 2025-01-30 13:50:18 -03:00
gbassinello fda4b67776 fix: removing activeDialogues from the DialogueManager map using the correct key (player uuid) 2025-01-30 13:34:52 -03:00
Xander Forrest f1ee9d45de remove apricorn_stripped_log and apricorn_stripped_log_top as never used 2025-01-28 19:39:28 +00:00
Polymeta 01f7d13e3f update tag and preset list [skip-ci]
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-26 21:32:32 +00:00
Paul d85e30f3a6 But what if we didn't break the yarn mapping 2025-01-26 22:15:17 +10:00
Paul e6f147bd94 Changelog [skip-ci] 2025-01-26 09:34:42 +10:00
Paul c66de51e39 Snapnoshot 2025-01-26 08:53:26 +10:00
Hiroku 7d552735f3 Merge branch 'implement_pokemon' into 'main'
Wobbuffix (and charcadet)

See merge request cable-mc/cobblemon!1500
2025-01-25 22:32:19 +00:00
Carmendar 94c42e7e2c Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-25 16:27:21 -06:00
Carmendar ef4690d4fe Wobbuffet -w- 2025-01-25 16:26:48 -06:00
Polymeta 433c0ff345 Merge remote-tracking branch 'refs/remotes/origin/lang-updates' 2025-01-25 21:00:42 +00:00
FrankTheFarmer 59d42fb328 Updated Charcadet's eye height. Git being dumb 2025-01-26 06:19:18 +10:00
Gustavo PuerariandWeblate 17d6837e34 Translated using Weblate (Portuguese (Brazil))
Currently translated at 42.1% (2695 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/pt_BR/
2025-01-25 10:01:29 +00:00
Carmendar 34b4337849 Updated Eiscue Noice lang 2025-01-25 03:14:00 -06:00
Paul 392e8663be Merge remote-tracking branch 'origin/main' 2025-01-25 14:29:28 +10:00
Paul 578ff37705 More tweaks to bucket jumps for luck of the sea enchants 2025-01-25 14:29:18 +10:00
Hiroku 77406f91a3 Merge branch '1.6.1-spawns' into 'main'
Fixes to some spawns and tags.

See merge request cable-mc/cobblemon!1498
2025-01-25 02:08:20 +00:00
Polymeta 9bf526e93e deleted typo'd amoonguss file
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-25 02:00:33 +00:00
Veraxiel 29b763ef19 Updated spawns and tags. 2025-01-24 20:40:50 -05:00
Polymeta 938b7a7a94 flip UVs to make particle sprite point the other direction
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-25 01:38:00 +00:00
Paul f920639e3f Protect luck of the sea adjustments against custom buckets 2025-01-25 11:35:10 +10:00
Paul ea499a935e Updated fishing bucket rates 2025-01-25 11:02:58 +10:00
Hiroku 1dbe5eb944 Merge branch 'npc-hide-nametag' into 'main'
Added hideNameTag field for NPCs

See merge request cable-mc/cobblemon!1488
2025-01-25 00:47:59 +00:00
Paul dba0bae810 Corrected luck of the sea bucket weights and simplified calculation code 2025-01-25 10:37:19 +10:00
Paul 8c04081af5 Fixed uncaught exception from fishing reeling in blocked entity spawns 2025-01-25 10:00:50 +10:00
Hiroku d7de4b2463 Merge branch 'test/fix_targeting_variant' into 'main'
Fix default form in battle targeting

Closes #1376

See merge request cable-mc/cobblemon!1496
2025-01-24 22:58:15 +00:00
aeroeng15andHiroku 61b767158a Fix default form in battle targeting 2025-01-24 22:58:15 +00:00
Hiroku f2f16cdc9e Merge branch 'implement_pokemon' into 'main'
Merge implement into main

See merge request cable-mc/cobblemon!1497
2025-01-24 22:57:45 +00:00
Deltric 2aec4f972f Updated npc name tag hiding to allow individual entity based hiding. 2025-01-24 04:23:02 -06:00
Deltric bc8164cf17 Merge remote-tracking branch 'origin/npc-hide-nametag' into npc-hide-nametag 2025-01-24 04:22:09 -06:00
Deltric a09cf1b93d Updated NPC README.md with hideNameTag field. 2025-01-24 04:11:29 -06:00
Deltric b436c42cb1 Hide name tag field for NPCs 2025-01-24 04:11:29 -06:00
Polymeta 79b83bc8d7 Merge branch 'test/held_item_evos' into 'main'
Fix held items disappearing for evolutions on re-logs

Closes #1378

See merge request cable-mc/cobblemon!1495
2025-01-24 08:22:25 +00:00
aeroeng15andPolymeta a6b5453b34 Fix held items disappearing for evolutions on re-logs 2025-01-24 08:22:25 +00:00
Carmendar 7fcb9e8b4d Riolu can stare into your soul, Charizard now uses all of his quirks, Corphish & Crawdaunt no longer T-pose. 2025-01-24 02:19:37 -06:00
Hiroku f3740abd39 Merge branch 'sound-packet-updates' into 'main'
Updated UnvalidatedPlaySoundS2CPacket to be public instead of internal and made its fields mutable.

See merge request cable-mc/cobblemon!1494
2025-01-24 06:54:55 +00:00
Hiroku e4decf50ea Merge branch 'spawn-packet-updates' into 'main'
Updated spawn packet visibility and mutability for Pokemon & NPCs

See merge request cable-mc/cobblemon!1489
2025-01-24 04:47:30 +00:00
Hiroku 22d33ac5d8 Merge branch '#1377-npc-held-items-bug' into 'main'
[#1377] Fixed held items being stolen from NPCs

Closes #1377

See merge request cable-mc/cobblemon!1490
2025-01-24 04:46:48 +00:00
DeltricandHiroku f2392db3be [#1377] Fixed held items being stolen from NPCs 2025-01-24 04:46:48 +00:00
Hiroku 9fed44328f Merge branch '#1374-fix-evolution-mid-battle' into 'main'
[#1374] Fixed Pokémon being able to evolve mid-battle

Closes #1374

See merge request cable-mc/cobblemon!1491
2025-01-24 04:46:36 +00:00
Hiroku 26d0340fb5 Merge branch 'sterr/sounds' into 'main'
Sound fixes

See merge request cable-mc/cobblemon!1493
2025-01-24 04:45:06 +00:00
Gustavo PuerariandWeblate 21f2945dc4 Translated using Weblate (Portuguese (Brazil))
Currently translated at 41.4% (2648 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/pt_BR/
2025-01-24 04:01:50 +00:00
Deltric 16a5316a69 Updated UnvalidatedPlaySoundS2CPacket to be public instead of internal and made its fields mutable. 2025-01-23 19:02:14 -06:00
Deltric 378a5ca401 Update evolution handler to disallow evolving while player is in battle. 2025-01-23 17:01:21 -06:00
Konoha d956ca2c3c Re-prep Inkay Easter Egg Evos :) 2025-01-23 17:25:35 -05:00
Deltric 14a079fae1 Updated NPC README.md with hideNameTag field. 2025-01-23 15:44:47 -06:00
Sterrezo 3e9331ec64 Updated the evolution sound to match the particle effect timing better 2025-01-23 22:34:19 +01:00
Sterrezo a7c43701c0 Wild shiny sounds now respect the shinyNoticeParticlesDistance config setting 2025-01-23 22:12:13 +01:00
Kenji_64 34aef306c1 Fixed shiny Flygon's goggles texture 2025-01-23 20:07:47 +01:00
Deltric b4e99204c8 Fixed Pokémon being able to evolve mid-battle 2025-01-23 03:21:04 -06:00
Deltric 8c09cebc59 Updated spawn packet visibility and mutability for Pokemon & NPCs 2025-01-23 01:54:48 -06:00
Deltric b5bfe44196 Hide name tag field for NPCs 2025-01-23 01:45:58 -06:00
Carmendar 38c5fcc23f Applied gravity to Arctozolt profile 2025-01-22 21:51:15 -06:00
Carmendar 9edfa279be Lucario can finally look at your aura. (can turn head) 2025-01-22 21:18:24 -06:00
Carmendar 2769d5560d Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-22 21:02:43 -06:00
Carmendar ed7d2d5d2a Hitbox fixes for Eiscue and Golem. 2025-01-22 21:02:09 -06:00
Test d839a13b7e Merge branch 'feature/my-fren' into 'main'
fix trading crashes

Closes #1336

See merge request cable-mc/cobblemon!1487
2025-01-23 00:56:36 +00:00
Test a23cd170b2 Merge branch 'test/split_pokedex_types' into 'main'
Split type strings in Pokedex view

Closes #1372

See merge request cable-mc/cobblemon!1485
2025-01-23 00:32:27 +00:00
aeroeng15andTest 3dec294728 Split type strings in Pokedex view 2025-01-23 00:32:26 +00:00
Polymeta c67cf2e05d validate event output from FRIENDSHIP_UPDATED event and also fix logic in internal handlers for friendship boosters
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-23 00:16:54 +00:00
Kenji_64 3b96beef36 Adjustments for Krokorok's/Krookodile's sand walk speed 2025-01-23 00:03:27 +01:00
Kenji_64 dcbac52fd7 Some Seaking animation and walk speed edits 2025-01-22 23:52:30 +01:00
Kenji_64 64dd8336c6 Made Krookodile's/Krokorok's look quirk rarer 2025-01-22 23:52:08 +01:00
Polymeta 2681cdc5ba Merge branch '1.6.1-spawns' into 'main'
Updated spawn files. Added Aether compat. Fixed errors with some conditions. Updated tags.

See merge request cable-mc/cobblemon!1486
2025-01-22 09:25:08 +00:00
Hiroku 8d265bd820 Merge branch 'features/help-is-on-the-way' into 'main'
more fixes

Closes #1365 and #1355

See merge request cable-mc/cobblemon!1482
2025-01-22 08:27:24 +00:00
PolymetaandHiroku 6b43e5d99d more fixes 2025-01-22 08:27:24 +00:00
washashu0905andWeblate b430b8a1b4 Translated using Weblate (Chinese (Traditional Han script))
Currently translated at 79.6% (5091 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/zh_Hant/
2025-01-22 01:05:35 +00:00
TeggyandWeblate 329810407a Translated using Weblate (Spanish)
Currently translated at 100.0% (6391 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/es/
2025-01-22 01:05:33 +00:00
Polymeta 6ca04bb064 Update 2 files
- /common/src/main/resources/data/cobblemon/spawn_pool_world/0591_amoongus.json
- /common/src/main/resources/data/cobblemon/spawn_pool_world/0591_amoonguss.json
2025-01-22 00:24:16 +00:00
Veraxiel ebf0144222 Removed space spawns for now. 2025-01-21 18:50:54 -05:00
Konoha a71cfaadc8 Toggleable Mooshtank var. in dex
Also stubs unimplemented branch regional evolutions (Avalugg/Weezing/Mr. Mime) + biome fix to fix chat spam in nether during night.
2025-01-21 11:17:02 -05:00
Konoha 31195dacdb Resolve invalid Molang expression for Golem sleep anim 2025-01-21 09:57:35 -05:00
Polymeta 4074aa50ce refactor storage layer and introduce .old filetype as a stopgap for file corruption during crashes
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-21 02:14:35 +00:00
Konoha 107ec7634d Temp-Swap Unsupported Evo Item References & Sidemod Tutor Support
Temporarily exchanges items that aren't in Cobblemon referenced on some species with items that are, avoiding the crash that would occur when Bisharp's evolution was parsed.
Adds a new utility script to mass-manage TM/Tutor moves from the movepool.
Reintroduces the "tutor" subset of TMs for addons that utilize the source already.
More aggressive culling on unplanned base-mod TM moves from level/egg pools, this prevents breakage with addons using the "lazy" way of only pulling the source in species data. Doing this will eventually break custom TMs in the TMM, so it is recommended that addons/plugins migrate to global lists of TMs for interfacing moves instead of just pulling "tm:" for each species.
Also re-preps the aspect format for Keldeo's species feature to match others.
2025-01-20 16:16:28 -05:00
Hiroku ed85de34b3 Merge branch 'feature/small-fixes-berrylicious' into 'main'
small fixes

Closes #1343

See merge request cable-mc/cobblemon!1480
2025-01-20 12:15:42 +00:00
Polymeta 6dbf1288a0 fix berry bonus yield and sodium dynamic lights compatibility (also small version bumps)
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2025-01-20 11:38:01 +00:00
Hiroku aee915dc91 Merge branch 'fix-evolution-dropping-held-item' into 'main'
Fix evolution dropping held item

Closes #1361

See merge request cable-mc/cobblemon!1481
2025-01-20 07:26:53 +00:00
Luan Nadaletti a1974fbe74 add held item autocomplete 2025-01-20 02:28:36 -03:00
Luan Nadaletti 145481530d fix evolution dropping held item 2025-01-20 02:27:56 -03:00
GenotypeXD-Dev b5694b4e13 Palm tree texture fix 2025-01-19 16:18:56 -07:00
GenotypeXD-Dev 9df4669865 Oops animations and model didnt push 2025-01-19 16:14:16 -07:00
GenotypeXD-Dev 92543f9aed Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-19 16:13:17 -07:00
GenotypeXD-Dev 5d5cb3a240 Implement Alolan Exeggutor Remodel 2025-01-19 16:13:07 -07:00
Hiroku 452117c781 Edit CHANGELOG.md 2025-01-19 22:11:37 +00:00
Konoha bc267ec72b Correct "Undiscovered" form oversight with data tag culling
This only affects the 3 forms who are in the undiscovered group and had accidentally inherited the base form's egg groups during the culling script's comparison, and did not have handling for their "legacy" movesets not totally covered by newer games.
2025-01-19 17:09:33 -05:00
Hiroku 33a2a0a8e0 Edit CHANGELOG.md 2025-01-19 20:29:34 +00:00
Hiroku dac1b3cbf0 Merge branch 'pc-command-box-arg' into 'main'
Added box number argument to PC command.

See merge request cable-mc/cobblemon!1477
2025-01-19 20:25:07 +00:00
Kenji_64 6d89b737a7 Added flame animations to Charcadet 2025-01-19 21:02:53 +01:00
Kenji_64 53e540472a Fixed Eiscue's scale (1 -> 0.85) 2025-01-19 21:02:33 +01:00
Konoha e2804dc83f Reimplement non-Torterra wood choices to Cobblemon Tree feature. 2025-01-19 09:53:16 -05:00
TeggyandWeblate 82e82cb28e Translated using Weblate (Spanish)
Currently translated at 99.3% (6350 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/es/
2025-01-19 05:07:47 +00:00
Hiroku 052fee56a1 Merge branch 'drop-fixes' into 'main'
Drop fixes

See merge request cable-mc/cobblemon!1479
2025-01-19 05:00:08 +00:00
Hiroku 15970f2ab0 Merge branch 'open-player-instanced-data-store' into 'main'
Mark PlayerInstancedDataStoreManager as open alongside methods.

See merge request cable-mc/cobblemon!1478
2025-01-19 03:18:11 +00:00
Paul 3874867b74 Changelog 2025-01-19 13:15:57 +10:00
Paul ed6485f1d3 Merge remote-tracking branch 'origin/lang-updates' 2025-01-19 13:12:26 +10:00
Deltric c7b1036bdf Wrong index for openOnBox default. 2025-01-18 21:06:45 -06:00
Deltric 8730ff3a3e Mark PlayerInstancedDataStoreManager as open alongside methods. 2025-01-18 21:05:42 -06:00
Deltric c8bd7c8604 Added box number argument to PC command. 2025-01-18 20:59:50 -06:00
Hiroku b049a39680 Merge branch 'fix-stat-evolution-requirement-crash' into 'main'
Fix 'defence' stat evolution requirement crashing the game

See merge request cable-mc/cobblemon!1476
2025-01-19 02:57:21 +00:00
Paul 6503b0806a Ran drops script again 2025-01-19 12:48:16 +10:00
Hiroku ef0e785855 Merge branch 'fishing_templates-begone!' into 'main'
Make it so only 1 fishing template fished up at a time (not 3+)

See merge request cable-mc/cobblemon!1474
2025-01-19 02:46:34 +00:00
Hiroku cccd30a284 Merge branch 'more-useful-pokedex-event' into 'main'
Rework pokedex events to actually be useful (always have a Pokemon instance)

See merge request cable-mc/cobblemon!1473
2025-01-19 02:45:21 +00:00
Paul be35e937d9 Merge remote-tracking branch 'origin/main' into drop-fixes
# Conflicts:
#	common/src/main/resources/data/cobblemon/species/generation3/deoxys.json
#	common/src/main/resources/data/cobblemon/species/generation5/samurott.json
#	common/src/main/resources/data/cobblemon/species/generation5/zorua.json
#	common/src/main/resources/data/cobblemon/species/generation8/zacian.json
#	common/src/main/resources/data/cobblemon/species/generation8/zamazenta.json
2025-01-19 12:38:07 +10:00
Hiroku 5a73456202 Merge branch 'implement_pokemon' into 'main'
An implementation merge request, your majesty

See merge request cable-mc/cobblemon!1475
2025-01-19 02:32:13 +00:00
Guilherme Pereira 089e6c15da fix 'defence' stat evolution requirement crashing the game 2025-01-18 23:15:14 -03:00
Hiroku 4f63c40096 Merge branch 'main' into 'implement_pokemon'
# Conflicts:
#   common/src/main/resources/data/cobblemon/species/generation1/grimer.json
#   common/src/main/resources/data/cobblemon/species/generation1/muk.json
2025-01-19 01:54:09 +00:00
Paul 218d33d78d Corrected None-form defect in drops 2025-01-19 11:25:01 +10:00
Sterrezo dae5445c3a Added cries for Nidorans and Pinsir. Fixed Mudkip line and Hitmontop cries that got lost in implementation 2025-01-19 00:55:20 +01:00
Konoha 57f9d5b6dc Reimplement Assignments to Cobblemon Tree feature. 2025-01-18 18:15:33 -05:00
Konoha fdfa10f5fe Reimplement Cobblemon Vivillon patterns to feature choice! 2025-01-18 18:14:30 -05:00
Plastered_Crab e12a1df252 Get those heaps of fishing templates out of my water! 2025-01-18 14:31:41 -08:00
Konoha 69e74be5e5 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-18 17:26:03 -05:00
Konoha 8c9ee22547 We don't like special characters.
But we should probably retain them for compat anyways.
2025-01-18 17:25:49 -05:00
Kenji_64 c8074dd825 Fixed Tauros Blaze and Aqua Breeds using the wrong poser 2025-01-18 23:25:14 +01:00
Kenji_64 bda5e2ade2 Fixed Pinsir's scale + walk speed 2025-01-18 23:24:49 +01:00
Kenji_64 0c5118b840 Added Galarian Slowking's animations 2025-01-18 23:23:42 +01:00
Kenji_64 0d0eaf2465 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-18 23:21:44 +01:00
Kenji_64 4eb90400aa Fixed Galarian Slowpoke's walk speed 2025-01-18 23:21:12 +01:00
Kenji_64 7387612f0e Fixed Munchlax and Snorlax insomnia (sweet dreams) 2025-01-18 23:17:38 +01:00
Kenji_64 5188318f20 Added Eiscue's new animations + fixed it walk speed 2025-01-18 23:17:06 +01:00
GenotypeXD-Dev 627ee5e9b2 Add Implemented tag to foongus and Ducklett line 2025-01-18 15:13:46 -07:00
Kenji_64 7f3bd8bec2 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-18 23:01:39 +01:00
Konoha db70a0f816 Duplicate Key Culling & Inheritance
Cuts down on file size by culling duplicate species data keys. Inherits the necessary implementation keys if only a selection of differences are present.
Removes empty behaviour keys.
2025-01-18 16:21:21 -05:00
Kenji_64 ab9a66c556 Fixed female Seaking's model 2025-01-18 22:19:09 +01:00
Konoha f5e1dfe080 Toxel Pre-Implementation Evo
Corrects the feature requirement on the newly generated Toxel evolution.
2025-01-18 15:01:39 -05:00
Konoha 175aa93284 Last of implemented form corrections.
Resolves the base form of Shellos and Gastrodon to "West Sea," solving an issue where the dex would default to "East Sea" when the entry was given via command, locking the player out of viewing the West Sea.
Fixes an oversight where "Season" was parsed as "Sea" on Deerling and Sawsbuck's form aspects.
2025-01-18 11:32:55 -05:00
Konoha b7926a70ab "Permanent" evo tag implementation. It was new, sorry!
Incorporates the "permanent" evo tag onto scraper gen, resolving an issue with the 3 species that required it aside from Milcery and fixing an oversight where Milcery's evos would be cut off.
Alcremie evolutions now work "as intended" and no longer require 1 sweet per cream, but rather 1 sweet being consumed for the "under 5 seconds" spin and an additional sweet consumed for the "over 5 seconds" spin. Any more than two sweets was excessive.
2025-01-18 10:17:22 -05:00
Konoha 28f2caff58 "Permanent" evo tag implementation. It was new, sorry!
Incorporates the "permanent" evo tag onto scraper gen, resolving an issue with the 3 species that required it aside from Milcery and fixing an oversight where Milcery's evos would be cut off.
Alcremie evolutions now work "as intended" and no longer require 1 sweet per cream, but rather 1 sweet being consumed for the "under 5 seconds" spin and an additional sweet consumed for the "over 5 seconds" spin. Any more than two sweets was excessive.
2025-01-18 10:15:25 -05:00
Konoha 128451785f Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-18 08:36:17 -05:00
Wi2tert 0171ed9747 add "implemented": true 2025-01-18 21:30:59 +08:00
Paul 1fb09e27fc Rework pokedex events to actually be useful (always have a Pokemon instance) 2025-01-18 21:04:06 +10:00
Paul 30a3d6ed83 Updated drops, fixed drops script 2025-01-18 20:02:04 +10:00
Veraxiel 4aa4c229fa Updated spawn files. Added Aether and space mod compat. Fixed errors with some conditions. Updated tags. 2025-01-18 03:32:57 -05:00
Wi2tert 18cecc68dd Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-18 16:09:15 +08:00
Wi2tert 5036ed0db1 fixes Karrablast shelmet Line Missing texture 2025-01-18 16:08:58 +08:00
Konoha 3b3150fc72 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-17 23:44:33 -05:00
Sterrezo b9fb970ec4 Added trailer cries, updated Sceptile's cry 2025-01-18 05:43:52 +01:00
Hiroku 761b306590 Merge branch 'implement_pokemon' into 'main'
Pokemon Implementation

Closes #1230 and #1137

See merge request cable-mc/cobblemon!1472
2025-01-18 04:22:13 +00:00
Konoha 1e7dfce918 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon
# Conflicts:
#	common/src/main/resources/data/cobblemon/species/generation5/shelmet.json
2025-01-17 23:04:06 -05:00
Konoha a453199eae It was new, sorry!
Reimplements the new Shelmet/Karrablast evo method.
2025-01-17 23:00:52 -05:00
GenotypeXD-Dev f5267c832f Add implemented tag to rufflet/Dewpider lines 2025-01-17 20:44:23 -07:00
GenotypeXD-Dev 7f6e0c0377 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon
# Conflicts:
#	common/src/main/resources/data/cobblemon/species/generation5/braviary.json
#	common/src/main/resources/data/cobblemon/species/generation5/rufflet.json
#	common/src/main/resources/data/cobblemon/species/generation7/araquanid.json
#	common/src/main/resources/data/cobblemon/species/generation7/dewpider.json
2025-01-17 20:41:58 -07:00
GenotypeXD-Dev 420d42b36d Added implemented tag to rufflet/Dewpider lines 2025-01-17 20:39:02 -07:00
Tyzillion a45028d83b Palean Tauros < Paldean Tauros 2025-01-17 22:23:42 -05:00
Tyzillion 76ab7e998b Removed duplicate category on changelog. 2025-01-17 22:20:35 -05:00
Tyzillion cbbfa974aa Updated Changelog and merged main to branch. 2025-01-17 22:16:08 -05:00
Tyzillion 9dc6649eb7 Merge branch 'main' of https://gitlab.com/cable-mc/cobblemon into implement_pokemon
# Conflicts:
#	common/src/main/resources/data/cobblemon/dex_entries/pokemon/galar/dubwool.json
#	common/src/main/resources/data/cobblemon/species/generation5/petilil.json
#	common/src/main/resources/data/cobblemon/species/generation9/dudunsparce.json
#	common/src/main/resources/data/cobblemon/species/generation9/palafin.json
2025-01-17 22:13:08 -05:00
Tyzillion 97ef0dda0a Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-17 21:53:23 -05:00
Hiroku 71334dc889 Merge branch 'lion-eats-bugs' into 'main'
Small fixes

Closes #1198

See merge request cable-mc/cobblemon!1471
2025-01-17 23:49:58 +00:00
lionandHiroku 4d8c4b1d7b Small fixes 2025-01-17 23:49:58 +00:00
Hiroku 0701380a36 Merge branch 'the_great_scraper_migration' into 'implement_pokemon'
Migrate species data to accurate sourcing (and fixes)

See merge request cable-mc/cobblemon!1452
2025-01-17 23:47:25 +00:00
Konoha 2b03e5660e Nicely asking the giant centipede not to crush me in my sleep. 2025-01-17 18:08:11 -05:00
Konoha b44a53efce Merge branch 'implement_pokemon' into the_great_scraper_migration
# Conflicts:
#	common/src/main/resources/data/cobblemon/species/generation1/golem.json
#	common/src/main/resources/data/cobblemon/species/generation1/graveler.json
#	common/src/main/resources/data/cobblemon/species/generation5/braviary.json
#	common/src/main/resources/data/cobblemon/species/generation5/rufflet.json
#	common/src/main/resources/data/cobblemon/species/generation5/sandile.json
#	common/src/main/resources/data/cobblemon/species/generation7/araquanid.json
#	common/src/main/resources/data/cobblemon/species/generation7/dewpider.json
2025-01-17 17:58:55 -05:00
Konoha 5678776938 Restricted label for competitive rules. 2025-01-17 16:49:42 -05:00
Konoha f3985d8250 Refactors form moves back to form_change.
Adds the Pink Flower as a dex variation.
Re-adds alternate "striped" key for "fish_stripes"
Corrects scraper generated sweet_decoration back to just decoration
2025-01-17 16:30:16 -05:00
Konoha b497c603ca Re-runs the scrape against latest implementation.
Implements Delibird and dex variation for Mooshtank.
2025-01-17 15:23:58 -05:00
Konoha b9807773ee Merge branch 'refs/heads/implement_pokemon' into the_great_scraper_migration
# Conflicts:
#	common/src/main/resources/data/cobblemon/species/generation1/snorlax.json
#	common/src/main/resources/data/cobblemon/species/generation1/tauros.json
#	common/src/main/resources/data/cobblemon/species/generation2/wobbuffet.json
#	common/src/main/resources/data/cobblemon/species/generation4/munchlax.json
#	common/src/main/resources/data/cobblemon/species/generation4/piplup.json
#	common/src/main/resources/data/cobblemon/species/generation5/accelgor.json
#	common/src/main/resources/data/cobblemon/species/generation5/amoonguss.json
#	common/src/main/resources/data/cobblemon/species/generation5/ducklett.json
#	common/src/main/resources/data/cobblemon/species/generation5/escavalier.json
#	common/src/main/resources/data/cobblemon/species/generation5/karrablast.json
#	common/src/main/resources/data/cobblemon/species/generation5/shelmet.json
#	common/src/main/resources/data/cobblemon/species/generation5/swanna.json
#	common/src/main/resources/data/cobblemon/species/generation6/barbaracle.json
#	common/src/main/resources/data/cobblemon/species/generation6/binacle.json
#	common/src/main/resources/data/cobblemon/species/generation8/kubfu.json
#	common/src/main/resources/data/cobblemon/species/generation8a/basculegion.json
#	common/src/main/resources/data/cobblemon/species/generation9/armarouge.json
#	common/src/main/resources/data/cobblemon/species/generation9/ceruledge.json
#	common/src/main/resources/data/cobblemon/species/generation9/gimmighoul.json
#	common/src/main/resources/data/cobblemon/species_feature_assignments/tauros_bull_breed.json
#	common/src/main/resources/data/cobblemon/species_features/bull_breed.json
2025-01-17 13:20:34 -05:00
Hiroku aba02d7b53 Merge branch 'youre-telling-me-theres-a-second-loader-worth-of-tags' into 'main'
Tag Changes (Everything)

Closes #1350

See merge request cable-mc/cobblemon!1464
2025-01-17 09:19:42 +00:00
Hiroku 0eef30af4a Merge branch 'fix-pasture-overlap-when-draggin-pokemon' into 'main'
Fix pasture overlap when dragging Pokémon on PC

See merge request cable-mc/cobblemon!1469
2025-01-17 06:44:53 +00:00
pv 3a064c7269 Merge branch cobblemon:main into fix-pasture-overlap-when-draggin-pokemon 2025-01-17 05:58:14 +00:00
Luan Nadaletti 1cece70687 fix Pasture overlap being overlapped from selected Pokemon 2025-01-17 02:56:24 -03:00
dhi_holo c2d85df3e0 Merge branch 'main' into youre-telling-me-theres-a-second-loader-worth-of-tags 2025-01-17 11:04:36 +10:00
dhi_holo a7c0242575 Update CobblemonItemTags.kt
I don't get how that got there, legitimately. Only idea I have is when I auto-pilot typed in createTag (which is what the block file uses) while doing the items, it auto-imported it.
2025-01-17 11:04:29 +10:00
Hiroku 97a7554e79 Merge branch 'hanging-in-there' into 'main'
Close Combat Crossover Collab... Paintings

Closes #853

See merge request cable-mc/cobblemon!1466
2025-01-16 22:52:06 +00:00
Hiroku 77108ae687 Merge branch 'fix-karrablast-trade-evolution' into 'main'
Fix Karrablast trade evolution

See merge request cable-mc/cobblemon!1465
2025-01-16 22:30:34 +00:00
lionandHiroku 413271546f Fix Karrablast trade evolution 2025-01-16 22:30:34 +00:00
Hiroku 75e3c4be7a Merge branch 'fortunate-tweaking' into 'main'
Breaking Crop Improvements

See merge request cable-mc/cobblemon!1467
2025-01-16 22:26:04 +00:00
Hiroku 7891347d90 Merge branch 'fix-fast-ball-capture-rate' into 'main'
Fix Fast Ball capture rate ignoring Pokémon stat

Closes #1352

See merge request cable-mc/cobblemon!1468
2025-01-16 21:37:51 +00:00
Luan Nadaletti 0a9b1c5c97 fix fast ball capture rate 2025-01-16 17:39:46 -03:00
dhi_holo 89d86aa6e3 Probably Pointless
Updated the block and item tag kt files to be up to date with all current tags, not touching biome stuff because I don't want to process that, I don't *think* there's a reason for me to make sure it's all referenced, but I was thinking it over, and it's better safe than having addon mod devs shouting at me in 7 months when the list is twice as long or something. Probably.
2025-01-16 21:47:41 +10:00
dhi_holo fd45dacad2 Update CHANGELOG.md
no other crops needed tweaking after investigation, so reworded and finalized
2025-01-16 21:01:47 +10:00
dhi_holo a336f0968a Fortunate Mints
Mint seeds can drop a couple more with fortune, cleaned up the loot tables a touch
2025-01-16 20:21:41 +10:00
Gustavo PuerariandWeblate df852ace9b Translated using Weblate (Portuguese (Brazil))
Currently translated at 41.2% (2634 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/pt_BR/
2025-01-16 06:28:25 +00:00
dhi_holo 9d6ae6952c Pick Up Your Berries!
Breaking any age 0 berries will drop their item again
2025-01-16 08:53:24 +10:00
dhi_holo 19c6f98ea4 Phase 1: Proof of Concept
Oran Berries now drop themselves when broken at growth age 0
Tomorrow, the other 68 berries.
2025-01-15 23:28:49 +10:00
Carmendar dbc1674416 Added new anims for the Sandile line (Extra sandy!), and fixed Slaking's portrait. 2025-01-15 00:56:14 -06:00
dhi_holo 3e8c0ed14e Finally, we have them all
Closes #853 after 7 months of having it on my to-do list. Happy Crossovers!
2025-01-15 16:35:21 +10:00
GenotypeXD-Dev 5f8ee45f1e Added Flight/Swim behavior to Rufflet/Dewpider lines 2025-01-14 22:34:42 -07:00
GenotypeXD-Dev 5f3e1fb395 Implement Rufflet and Braviary 2025-01-14 20:29:55 -07:00
GenotypeXD-Dev 4befb0a16a Implement Dewpider and Araquanid 2025-01-14 20:18:11 -07:00
RedGenesectNinja aab55966a8 Fixed Foongus and Amoonguss not using shiny textures when shiny 2025-01-14 20:03:35 -06:00
Kenji_64 746c29c6f6 Added tap_quirk anim to Armarouge 2025-01-14 17:18:47 +01:00
Kenji_64 0c31f14b15 Implemented Geodude line remodel + added Alolan variant. Translated their posers to json (wild_sleep not working yet) 2025-01-14 17:18:10 +01:00
Tyzillion e565426291 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-13 21:13:24 -05:00
Kenji_64 6f115e44e3 Deleted old posers for Armarouge and Ceruledge 2025-01-13 20:43:59 +01:00
Kenji_64 dd161c2d53 Fixed minor errors in Ceruledge's GEO, fixed the blink animation and interpolation of battle_intro in the poser 2025-01-13 20:43:31 +01:00
Konoha 50500ab204 Minor Asset Corrections and Refactor
Corrects the "klwaf" typo to "klawf".
Reverts "rhyperior_brown" back to "rhyperior" as it was pre-1.6.
Bulbasaur and Ivysaur's new gender differences refactored to follow the format every other gender difference does.
Refactors the Bagon line's resolver folders to have the padded dex number every other line has.
2025-01-13 13:26:40 -05:00
Kenji_64 169c406f03 Adjusted the interpolation of Armarouge's special attack (thank you Hobo) 2025-01-13 18:56:44 +01:00
dhi_holo 985691958f Hopefully Final Cleanup
Doing final tests before submitting a merge request.
2025-01-13 22:03:51 +10:00
Kenji_64 d972b2f998 Added new GEO for Goldeen and implemented animations. Fixed a naming error in Seaking's poser as well 2025-01-13 12:36:18 +01:00
Kenji_64 5dc03a71f6 Fixed Armarouge's battle cry not playing and added a missing texture (oopsie) 2025-01-13 12:04:28 +01:00
dhi_holo 6535dd950a Tweaks
As Shelmet-Karrablast is being implemented, altered the advancement to use the new item, added the item to the item tag, and also some more block tag improvements as I work on those more
2025-01-13 19:47:52 +10:00
dhi_holo 840d7f50ee Error Fixing 2025-01-13 18:21:01 +10:00
dhi_holo 1d7da21e69 Big Upgrades
Lot of recipes updated to use the Convention tags. For most people, this literally changes nothing, for like 3 people maybe this is huge, but hey, compat that takes no effort xD
2025-01-13 17:35:10 +10:00
Wi2tert c33adf3a8b Remodels Pinsir 2025-01-13 14:57:28 +08:00
Wi2tert c39eeb69f4 change 2025-01-13 14:54:01 +08:00
Wi2tert 32d6811884 implementation Shelmet Line 2025-01-13 14:53:25 +08:00
Wi2tert fa7eb0d98c implementation karrblast Line 2025-01-13 14:50:36 +08:00
dhi_holo 242fa3fed8 Tags in Recipes
Since NeoForge and Fabric use the same convention tags, we can make stuff a bit more compatible. This is a first push for that.
2025-01-13 16:26:15 +10:00
RedGenesectNinja 9364992979 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-12 23:12:20 -06:00
dhi_holo 488f9b995a Miracle Seed Compat Fix (plus more progress) 2025-01-13 14:51:01 +10:00
dhi_holo 05f58f86c2 More Work
Collection of current work so it's preserved
2025-01-13 14:39:17 +10:00
RedGenesectNinja 3fa3f06a02 Implemented Ducklett and Swanna 2025-01-12 22:01:47 -06:00
dhi_holo 0a80269670 Fabric
Added to all relevant tags I could find on https://github.com/FabricMC/fabric/tree/769ff5bcf9b2ec8ef5a6f5367cfebac35c27006c/fabric-convention-tags-v2/src/generated/resources/data/c/tags
2025-01-13 13:39:38 +10:00
dhi_holo 5e2373c656 Issue #1350
Resolves #1350
2025-01-13 13:21:56 +10:00
Kenji_64 60b95b6fa5 Charcadet line remodels + new animations added!! Oh boy here we go: Added animated textures, made new posers in json, adjusted all of their portraits, added battle_cry for Armarouge and adjusted their scale and hitbox 2025-01-13 02:04:07 +01:00
Hiroku 77d7bb0fe4 Merge branch 'karrablast-singleplayer-evolution-method' into 'main'
Add Karrablast single-player evolution method

Closes #821

See merge request cable-mc/cobblemon!1463
2025-01-12 23:40:34 +00:00
lionandHiroku bf78e68831 Add Karrablast single-player evolution method 2025-01-12 23:40:34 +00:00
Kenji_64 49a6dd826a Added Wobbuffet animations + walk speed 2025-01-12 15:48:30 +01:00
Kenji_64 b0d80d6c96 Added Dondozo animations + walk speed 2025-01-12 15:48:18 +01:00
Kenji_64 ca1f008319 Updated Seaking models and added animations + walk speed 2025-01-12 15:47:55 +01:00
Kenji_64 d22d7cc5b4 Fixed Magikarp playing the wrong faint on water surface 2025-01-12 15:47:16 +01:00
Kenji_64 1ceba8973f Fixed Swampert line's permanent blink 2025-01-12 15:07:57 +01:00
Kenji_64 558daea446 Adjusted Snorlax line walk speed 2025-01-12 15:07:22 +01:00
Nico MerenqandWeblate 6f5a298a5c Translated using Weblate (Russian)
Currently translated at 83.4% (5332 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/ru/
2025-01-11 22:55:39 +00:00
Konoha e016d48584 Misc. scraper fixes
Addresses a tiny bit of the most noticeable issues leftover from old scraper.
Gimmighoul-Roaming has been granted an actual moveset
Lilligant-Hisui given its appropriate EV Yield
Basculegion-M given its proper gender ratio to not potentially confuse the Pokedex
Piplup given its correct Hidden Ability (which is now accessible via fishing!)
(Unimplemented) Kubfu's stubbed HA updated.
(Unimplemented) Capsakid's base stats corrected.
2025-01-11 14:08:11 -05:00
Konoha 9540a4b3eb Timburr Feature Corrections
Implements "base" Timburr which was previously occupied by the oak variant.
Designates "oak" layer for the resolver to point to when the variant is used.
Adds "cherry" Timburr, which was previously referenced by the resolver but had no texture.
All wood types are now iterable variants in the Pokedex.
2025-01-11 13:51:31 -05:00
Konoha e7234daff6 Animation for Family of Three Maushold
Implements the idle animation for Maushold's base form.
Corrects placement of single child.
Brings the form up to snuff with Family of Four.
2025-01-11 12:43:21 -05:00
Konoha 7fbc2b5143 Form corrections for Paldean Tauros
Creates iterable dex entry so the forms can be accessed in-game via dex.
Reimplements as a Paldean form for feature parity with other regionals.
Refactors species feature to more concisely handle the separation of breed and regional.
Tweaks resolver to point to the right combination of aspects, fallback to Combat breed as "base" Paldean.
2025-01-11 12:12:25 -05:00
washashu0905andWeblate 9d50dae3d1 Translated using Weblate (Chinese (Traditional Han script))
Currently translated at 71.8% (4591 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/zh_Hant/
2025-01-11 16:35:51 +00:00
Gustavo PuerariandWeblate 655a467193 Translated using Weblate (Portuguese (Brazil))
Currently translated at 41.0% (2623 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/pt_BR/
2025-01-11 16:35:50 +00:00
Kenji_64 cbc6c56c9e Implemented Tauros remodel + Paldean variants. Translated their posers to json and made new ones for the variants. Also added paldean_breed species feature assignment for Tauros 2025-01-11 17:03:01 +01:00
Kenji_64 360de79482 Translated Poliwrath's poser to .json 2025-01-11 16:33:20 +01:00
Kenji_64 8e7ceae7e1 Added new Poliwrath animations for ground_idle, ground_walk, physical and quirk 2025-01-11 16:32:03 +01:00
Kenji_64 92221e0e98 Fixed Lurantis' antenna problem 2025-01-11 16:31:27 +01:00
Kenji_64 27285e3e7f Implemented new Snorlax and Munchlax animations, added walk speed, sleep and got rid of unnecessary files 2025-01-11 16:31:01 +01:00
Kenji_64 04612d58f3 Fixed Shiny Dracovish's fins being textured wrongly 2025-01-09 21:27:59 +01:00
Wi2tert ffd5dbb717 Updata Primeape Animations 2025-01-10 00:02:56 +08:00
washashu0905andWeblate d7242d2895 Translated using Weblate (Chinese (Traditional Han script))
Currently translated at 70.2% (4491 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/zh_Hant/
2025-01-08 21:23:54 +00:00
washashu0905andWeblate 51c2a418ce Translated using Weblate (Chinese (Traditional Han script))
Currently translated at 69.0% (4415 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/zh_Hant/
2025-01-08 20:26:38 +00:00
Gustavo PuerariandWeblate 882a5921e8 Translated using Weblate (Portuguese (Brazil))
Currently translated at 40.4% (2587 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/pt_BR/
2025-01-08 20:26:36 +00:00
Wi2tert 9b58e229d6 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-07 19:14:57 +08:00
Wi2tert d357c2cbcb Add Binacle Barbaracle 2025-01-07 19:13:47 +08:00
washashu0905andWeblate 5621326c43 Translated using Weblate (Chinese (Traditional Han script))
Currently translated at 65.8% (4208 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/zh_Hant/
2025-01-06 21:05:37 +00:00
Gustavo PuerariandWeblate 9fd2b3f1d6 Translated using Weblate (Portuguese (Brazil))
Currently translated at 40.2% (2575 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/pt_BR/
2025-01-06 21:05:36 +00:00
Nico MerenqandWeblate a89d428699 Translated using Weblate (Russian)
Currently translated at 83.4% (5333 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/ru/
2025-01-05 07:30:58 +00:00
RedGenesectNinja 91eda647fa Added Amoonguss 2025-01-04 17:49:14 -06:00
Konoha c0da612281 Re-implement color and metal variance features for pokedex 2025-01-04 15:17:22 -05:00
Nico MerenqandWeblate 7dc76fdeb3 Translated using Weblate (Russian)
Currently translated at 83.5% (5342 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/ru/
2025-01-04 18:41:55 +00:00
TeggyandWeblate 7e11497c64 Translated using Weblate (Spanish)
Currently translated at 99.1% (6339 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/es/
2025-01-03 21:17:19 +00:00
Konoha 81978f025b Revert zen and noice aspects to partial flag 2025-01-03 16:08:54 -05:00
TeggyandWeblate 8dc3eaafc7 Translated using Weblate (Spanish)
Currently translated at 98.8% (6317 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/es/
2025-01-03 19:20:31 +00:00
Konoha c0af1abf9f Tree-Feature Dex Fix 2025-01-03 13:16:19 -05:00
Nico MerenqandWeblate b2d56c339c Translated using Weblate (Russian)
Currently translated at 82.5% (5273 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/ru/
2025-01-03 16:50:37 +00:00
TeggyandWeblate bc49537e16 Translated using Weblate (Spanish)
Currently translated at 98.7% (6309 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/es/
2025-01-03 16:50:36 +00:00
Konoha c4c59e6aa5 Corrections and future species feature prep 2025-01-03 10:54:36 -05:00
Konoha de3cac46fb Stub references to scraper-generated species features 2025-01-03 09:53:32 -05:00
Nico MerenqandWeblate 995ad49336 Translated using Weblate (Russian)
Currently translated at 82.3% (5262 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/ru/
2025-01-03 11:44:00 +00:00
Konoha 1abe38f97b Migrate to accurate species data 2025-01-03 01:51:44 -05:00
Konoha ff7fa49baa Migrate to accurate species data 2025-01-03 01:49:36 -05:00
Konoha 92b2612350 Merge branch 'main' into the_great_scraper_migration 2025-01-03 01:08:11 -05:00
Nico MerenqandWeblate ba17f0d35f Translated using Weblate (Russian)
Currently translated at 82.3% (5262 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/ru/
2025-01-03 03:55:29 +00:00
Kenji_64 5a628b4c39 Fixed Raboot's quirk playing during the battle idle 2025-01-03 03:35:51 +01:00
Kenji_64 0b46516ed1 Fixed Feraligatr's head tilt 2025-01-03 03:35:29 +01:00
RedGenesectNinja 715b5d1a08 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-01 23:12:38 -06:00
FrankTheFarmer 44ca37207f Updated Changelog with some placeholders for incoming implementation 2025-01-02 12:24:43 +10:00
RedGenesectNinja cd363e4ef7 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2025-01-01 20:22:54 -06:00
RedGenesectNinja 9d234fa556 Added Foongus 2025-01-01 20:21:03 -06:00
Nico MerenqandWeblate 47e49993ad Translated using Weblate (Russian)
Currently translated at 82.3% (5262 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/ru/
2025-01-02 01:37:26 +00:00
FrankTheFarmer 7afdbd2d4b Merge branch 'main' into implement_pokemon 2025-01-02 10:04:01 +10:00
Ezequiel Neri FerreiraandWeblate 38e699aa44 Translated using Weblate (Portuguese (Brazil))
Currently translated at 35.0% (2241 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/pt_BR/
2024-12-31 23:22:39 +00:00
PolymetaandWeblate 2b26e47876 Translated using Weblate (German)
Currently translated at 98.7% (6313 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/de/
2024-12-31 03:20:55 +00:00
Konoha D 2f07f33a71 Scale A-Exeggutor more accurately based on K-Exeggutor. 2024-12-30 14:09:25 +00:00
PolymetaandWeblate eaec3612aa Translated using Weblate (German)
Currently translated at 98.6% (6306 of 6391 strings)

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/de/
2024-12-30 05:39:46 +00:00
Kenji_64 db0c2a0cc2 Added shiny Slowpoke's new texture 2024-12-30 03:47:55 +01:00
Kenji_64 c431cf7b1e Fixed Serperior's poser playing the ground_walk in battle and the dex 2024-12-30 03:47:31 +01:00
Kenji_64 a5dd0eb924 Scaled up Slowpoke (0.75 > 1) and fixed Slowpoke line posers not having water animations 2024-12-30 03:06:32 +01:00
Kenji_64 466d91fcbf Implemented Smeargle model tweaks 2024-12-30 01:53:54 +01:00
Kenji_64 e1a3077780 Fixed Incineroar's fuzzy fur tail clipping into the tip 2024-12-30 01:53:13 +01:00
Kenji_64 5936ced1d7 Added Eiscue + No Ice Form remodel and adjusted the portrait 2024-12-30 01:52:43 +01:00
Kenji_64 3d6967d3c7 Implemented Slowking Remodel + added Galarian regional. Translated poser to json 2024-12-30 01:15:43 +01:00
Kenji_64 449a8cdb53 Implemented Slowbro Remodel + added Galarian regional. Translated poser to json and added quirk animations 2024-12-30 01:15:11 +01:00
Kenji_64 c91d4a9515 Implemented Slowpoke Remodel + added Galarian regional. Translated poser to json 2024-12-30 01:14:05 +01:00
Patch Notes GuyandWeblate 793f059f3c Deleted translation using Weblate (Vietnamese) 2024-12-27 22:42:29 +00:00
Weblate 7200e87886 Update translation files
Updated by "Remove blank strings" add-on in Weblate.

Translation: Cobblemon/Mod
Translate-URL: http://lang.cobblemon.com/projects/cobblemon/mod/
2024-12-27 22:40:07 +00:00
Patch Notes GuyandWeblate a1dc5c8340 Added translation using Weblate (Vietnamese) 2024-12-27 22:40:05 +00:00
FrankTheFarmer 2345e7efcc Merge branch 'main' into implement_pokemon 2024-12-23 16:01:53 +10:00
Sterrezo d32ed6309c Fixed Horsea and Seadra missing cries 2024-12-22 23:47:40 +01:00
Polymeta 72e9481946 fix cry checker script looking at wrong columns
Signed-off-by: Polymeta <40173118+Polymeta@users.noreply.github.com>
2024-12-21 23:51:53 +00:00
Sterrezo f3ba7ef121 Un-sabotaged a json, no one saw that 2024-12-21 23:44:34 +01:00
Sterrezo e9aca93f70 Fixed Mareanie and Toxapex missing cries 2024-12-21 14:38:44 +01:00
FrankTheFarmer 6f8e3bca29 Added missing implementations to changelog before merge requesting 2024-12-20 22:40:27 +10:00
FrankTheFarmer 49349848b8 Santa is canon in pokemon 🎅🐧📫 2024-12-20 22:31:33 +10:00
FrankTheFarmer bfe1afda4b Merge branch 'main' into implement_pokemon 2024-12-20 21:12:17 +10:00
FrankTheFarmer bd54020c9c Merge branch 'main' into implement_pokemon 2024-12-20 07:20:57 +10:00
Kenji_64 605d44f2c2 Caterpie remodel! 2024-12-19 12:43:21 +01:00
FrankTheFarmer 5c42b441fd Fixed Lotad using Charmander's blink animation for over a year now 2024-12-19 08:50:11 +10:00
Kenji_64 2211232652 Updated Goldeen's regular + shiny texture 2024-12-18 15:49:09 +01:00
Kenji_64 4ef8c40a83 Updated Skeledirge's shiny texture 2024-12-18 15:48:51 +01:00
Kenji_64 99ca941c73 Updated Mudbray's texture 2024-12-18 15:48:36 +01:00
Kenji_64 e5b977ff1a Updated Caterpie's model + textures 2024-12-18 15:48:08 +01:00
Kenji_64 0e381ac098 Fixed the bracket in Whiscash's data 2024-12-18 14:28:30 +01:00
FrankTheFarmer ace08a5673 Fixed Noctowl not having a proper placeholder fly animation 2024-12-18 21:59:00 +10:00
FrankTheFarmer de00622235 Merge branch 'main' into implement_pokemon 2024-12-18 21:23:54 +10:00
Kenji_64 e652b5773d Bigger Big Whiscash! (scale is 1.2 now) 2024-12-18 00:46:46 +01:00
Kenji_64 ae1f6393b7 Fixed big shiny Whiscash using the wrong texture 2024-12-17 15:04:51 +01:00
Kenji_64 ddb0ad4dda More texture fixes on the Charmander line 2024-12-17 12:53:31 +01:00
Kenji_64 83bc1292ea Charmeleon's tail fire is animated now too! 2024-12-17 11:15:55 +01:00
Kenji_64 39075b843e Charmander's tail fire is animated now! 2024-12-17 11:15:22 +01:00
Kenji_64 7db59cc3bd Fixed Alolan Raichu's insomnia. Sleep well! 2024-12-16 15:25:05 +01:00
FrankTheFarmer 5e5f35b306 Corrected rotations in Snivy's head bone set 2024-12-16 10:14:29 +10:00
FrankTheFarmer 65ef2076eb Updated Snivy poser to use head_ai bone instead 2024-12-16 10:09:55 +10:00
FrankTheFarmer e8f6bbd742 Updated Servine poser to use head_ai bone instead 2024-12-16 10:09:40 +10:00
FrankTheFarmer 5256bf1267 Updated placeholder animations for Braixen and Delphox 2024-12-16 08:54:54 +10:00
FrankTheFarmer d2a5dfcdc0 Updated Serperior's placeholders and added a water surface pose because serpent 2024-12-16 08:23:49 +10:00
FrankTheFarmer 124eb876de Merge branch 'main' into implement_pokemon 2024-12-16 08:21:46 +10:00
Kenji_64 7b1f50b183 Transferred Sobble line's posers to json, gave them a sleep placeholder so it no longer t-poses and did minor fixes to their animations 2024-12-13 00:12:51 +01:00
FrankTheFarmer 2c9705e230 Added missing changelog for poser conditions 😠 2024-12-12 16:54:22 +10:00
FrankTheFarmer b78d05611d Added missing minYaw configuration for q.look() function in JSON posers. oopsies 2024-12-12 15:53:21 +10:00
FrankTheFarmer 4574e9ae65 Merge branch 'main' into implement_pokemon 2024-12-12 15:49:08 +10:00
Kenji_64 4508f47c93 Made Venusaur's leaves not clip into its knees anymore. These leaves are tricky 2024-12-11 14:09:21 +01:00
FrankTheFarmer 683d62f9e0 Fixed Bewear T posing 0.25 seconds if fainting out of battle. fixes #1230 2024-12-11 14:27:24 +10:00
FrankTheFarmer 217b1cc561 Wailord is now 25% bigger 2024-12-11 13:18:09 +10:00
Kenji_64 b72f90551e Made Venusaur's leaves not clip into its back anymore 2024-12-11 02:41:58 +01:00
Kenji_64 30b146a59d Added walking speeds to the Kanto starters 2024-12-11 02:17:16 +01:00
Kenji_64 1e4afe36be Fixed Ivysaur's head clipping into its leaf 2024-12-10 22:34:30 +01:00
FrankTheFarmer a76ec37e63 Removed unused future drop data from Ho-oh's drops 2024-12-10 17:02:18 +10:00
FrankTheFarmer c3f397b508 Gave Corsola a placeholder ground walk 2024-12-10 16:56:54 +10:00
FrankTheFarmer d4f5b1c0ca Gave Corsola the look animation 2024-12-10 16:47:52 +10:00
FrankTheFarmer ae4680f546 Updated chewtle and drednaw drops to use new turtle scute id 2024-12-10 16:28:25 +10:00
FrankTheFarmer b0c14c686c Moved Trevenant to a JSON poser and also fixed its T pose sleep 2024-12-10 15:34:25 +10:00
FrankTheFarmer 4a59c02340 Set Seaking's ground idle to loop to prevent error message 2024-12-10 14:50:28 +10:00
FrankTheFarmer 9754515ec6 Re committed the Raichu thingy without the build folder path thingy 2024-12-10 14:04:43 +10:00
FrankTheFarmer f810cdb090 Revert "Replaced Alolan Raichu's kotline poser with a .json one and made it being able to surf on water now"
This reverts commit 2e39aa7f7f.
2024-12-10 14:03:19 +10:00
FrankTheFarmer af8cfa8b3d Corrected Alolan Raichu's poser conditions 2024-12-10 14:02:56 +10:00
FrankTheFarmer c9de2b2bf1 Moved Alolan Raichu poser to the right place 2024-12-10 06:04:18 +10:00
FrankTheFarmer f3bd112f3e Tweaked sight cone for Pignite 2024-12-10 05:04:17 +10:00
FrankTheFarmer 2d3bd8c2af Tweaked eye height, and sight cone for Incineroar 2024-12-10 05:03:54 +10:00
FrankTheFarmer 8a9a59fd3c Tweaked hitbox, eye height, and sight cone for Emboar 2024-12-10 05:03:22 +10:00
FrankTheFarmer c738f55078 Merge branch 'main' into implement_pokemon 2024-12-10 02:30:30 +10:00
Kenji_64 2e39aa7f7f Replaced Alolan Raichu's kotline poser with a .json one and made it being able to surf on water now 2024-12-08 18:37:32 +01:00
Kenji_64 c65aaf03eb Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-12-08 16:20:50 +01:00
Sterrezo d3e18cb8c0 Fixed Garchomp missing it's cry 2024-12-08 14:38:48 +01:00
Sterrezo 8de519ad3f Fixed timing on Gabite's cry 2024-12-08 14:31:39 +01:00
Kenji_64 d06c735585 Made Farigiraf bigger and better (changed the scale from 0.95 to 1.5) 2024-12-08 13:11:53 +01:00
Kenji_64 c820a01db0 -fixed Horsea's and Seadra's posers using the wrong animation
-added ground_walk to Horsea
-added walk speeds to Horsea and Seadra
-fixed Seadra's left fin animation
2024-12-07 21:41:25 +01:00
Sterrezo 0d6f6221cb Tweaked Elekid's cry sound keyframe timing 2024-12-05 09:48:06 +01:00
FrankTheFarmer 77e6070e78 Several adjustment's to Venusaur to allow the leaf to move with the head 2024-12-05 15:52:18 +10:00
FrankTheFarmer 46c5849842 Fixed Charizard tilting its head while looking 2024-12-05 11:07:25 +10:00
FrankTheFarmer 72bca5b6fc Stopped Kingdra from T posing underwater 2024-12-05 10:25:19 +10:00
FrankTheFarmer 94d12f69fe Fixed Hippowdon falling asleep every time it battled 2024-12-05 10:02:25 +10:00
FrankTheFarmer 1f68bab455 Feebas hitbox updated 2024-12-04 16:42:55 +10:00
FrankTheFarmer 390d214976 Magikarp rescaled to 1 2024-12-04 16:36:38 +10:00
FrankTheFarmer 5b40c8bab2 Removed Feebas' ability to walk on water 2024-12-04 15:22:27 +10:00
FrankTheFarmer 7eee9117c0 Feebas and Milotic portrait fixes 2024-12-04 15:22:13 +10:00
FrankTheFarmer 49e1b6ac00 Merge branch 'main' into implement_pokemon 2024-12-04 15:22:08 +10:00
Tyzillion d356ad3a3d Merge branch 'main' of https://gitlab.com/cable-mc/cobblemon into implement_pokemon 2024-12-03 22:55:11 -05:00
FrankTheFarmer 0f38eb5bca Corrected Charizard poser to use head_ai bone instead. 2024-12-02 23:14:30 +10:00
FrankTheFarmer 1d3e54a54a Kecleon can now sleep and also updated its idle to prevent clipping 2024-12-02 21:12:16 +10:00
FrankTheFarmer 4792b14051 Buneary animation update to fix walk and fluff 2024-12-02 21:11:38 +10:00
FrankTheFarmer 66d87d68de Gyarados portrait readjustment 2024-12-02 20:30:16 +10:00
FrankTheFarmer 5d60825c7d Fixed Charizard sometimes using ground idle over water. 2024-12-02 20:10:47 +10:00
FrankTheFarmer 4ca40b59d9 Charizard animation update with poser tweaks to battle and sleeping poses 2024-12-02 18:53:53 +10:00
FrankTheFarmer a9b6e02a71 Fixed Magikarp using ground idle on water surface 🐟🤛🤛🤛👨‍🌾 2024-12-02 16:49:37 +10:00
FrankTheFarmer 055eaab819 Merge branch 'main' into implement_pokemon 2024-12-02 11:11:41 +10:00
FrankTheFarmer 1f467a72a6 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-12-02 11:11:38 +10:00
FrankTheFarmer 14ee434e13 Fixed Flying charizards in battle using their ground battle animations. These are the first air battle anims i think 2024-12-02 11:11:14 +10:00
Sterrezo d317a4488e Update skarmory_cry.ogg 2024-12-01 16:23:08 +01:00
FrankTheFarmer 3b78d68ed0 Fixed Hisuian Sneasel using Johtonian Sneasel's cry 2024-12-01 09:39:46 +10:00
FrankTheFarmer 2d234931d7 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-12-01 09:12:02 +10:00
FrankTheFarmer ff01cc1551 AAAAAAAAAAAAAHHHHHHHHHHHHHHH 2024-12-01 09:11:45 +10:00
FrankTheFarmer 4ae49291ad Merge branch 'main' into implement_pokemon 2024-12-01 09:09:44 +10:00
FrankTheFarmer 268f219754 Renamed and Reorganizes the magikarp jump stuff again lmao. This time, it's for real. 2024-11-30 15:52:32 +10:00
FrankTheFarmer 6d819a0507 Restored Popplio's shoulder animation and removed an unintentional recoil animation 2024-11-26 20:30:11 +10:00
FrankTheFarmer 41e0c1bf2d Fixed Liepard using Purrloin's cry 2024-11-26 19:56:12 +10:00
FrankTheFarmer db8b5ab631 Porygon 2 poser adjustments due to seperate portrait animation. 2024-11-26 19:38:40 +10:00
FrankTheFarmer d7c531d51f Merge branch 'main' into implement_pokemon 2024-11-26 19:29:54 +10:00
FrankTheFarmer 03f690e450 Porygon 2 animation fixes. Holy flip this was a pain lol. 2024-11-26 19:29:47 +10:00
FrankTheFarmer 6ffc6b98e5 Stopped popplio from using battle idle when shoulder mounted. still need to look for shoulder animation tho 2024-11-23 21:16:36 +10:00
FrankTheFarmer a99865e0c6 Porygonz quirk interpolation fix 2024-11-23 21:15:48 +10:00
FrankTheFarmer 2c7d5a937f Merge branch 'main' into implement_pokemon 2024-11-23 20:30:18 +10:00
FrankTheFarmer 37c9c7970a Emergency placeholder spheal rolling animation after community outrage 2024-11-22 19:39:12 +10:00
FrankTheFarmer a9c1c318dc Set default to none for magikarp jump patterns. 2024-11-21 16:22:57 +10:00
FrankTheFarmer 4e74e85976 Oops. Got the order number wrong. 😨 2024-11-21 15:00:29 +10:00
FrankTheFarmer 30f9e506b2 Reorganized the entirety of Magikarp jump patterns to standards and added purple eyed gyarados. theres so many damn gyarados combos dude 2024-11-21 14:50:07 +10:00
FrankTheFarmer 72b17e3c04 Merge branch 'main' into implement_pokemon 2024-11-21 09:02:12 +10:00
FrankTheFarmer ca00521ba8 Merge branch 'main' into implement_pokemon 2024-11-20 14:30:40 +10:00
FrankTheFarmer 3f289b1deb Merge branch 'main' into implement_pokemon 2024-11-19 20:52:17 +10:00
FrankTheFarmer cbd86be78c Fixed hitbox sizes for Grotle and Torterra being set to default values 2024-11-19 14:11:19 +10:00
FrankTheFarmer c62e1bcc28 Merge branch 'main' into implement_pokemon 2024-11-19 13:28:35 +10:00
FrankTheFarmer 6c91bc273e removed female specifications in Seaking's animations causing a crash 2024-11-19 13:17:15 +10:00
FrankTheFarmer 76d9fae579 Removed single quote that broke flamigo profile and portrait 2024-11-19 10:34:50 +10:00
FrankTheFarmer 76de1f6076 Let paldean wooper temporarily use johtonian cry 2024-11-19 10:10:47 +10:00
FrankTheFarmer b1971f90be Quagsire will now inherit the wooper heart aspect from wooper but there are no assets 2024-11-19 10:02:01 +10:00
FrankTheFarmer e702d0088d Krookodile animation update with corrected quirk sound event 2024-11-18 20:43:52 +10:00
FrankTheFarmer 332a0a6e1b Merge branch 'main' into implement_pokemon 2024-11-17 20:36:03 +10:00
FrankTheFarmer 58bf92eeab Merge branch 'main' into implement_pokemon
# Conflicts:
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/animations/0350_milotic/milotic.animation.json
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0350_milotic/milotic.json
2024-11-17 20:34:44 +10:00
FrankTheFarmer 7787d749c9 Magikarp faint fix 2024-11-17 20:32:51 +10:00
FrankTheFarmer b075145090 Hydreigon will now look at you properly. With one of its heads anyways 2024-11-17 15:41:21 +10:00
FrankTheFarmer afe7fff061 Changed Alomomola's pose in the portrait. No more sad fish out of water 2024-11-17 15:14:27 +10:00
FrankTheFarmer 6f3abd0986 Wiglett and Wugtrio will no longer float to the surface and can breathe underwater 2024-11-17 11:14:01 +10:00
FrankTheFarmer 2da2c41011 fixed looping absol blink 2024-11-17 10:53:59 +10:00
FrankTheFarmer 252a223e89 tweaked milotic movement speeds to match the values from the bbmodel 2024-11-15 15:34:25 +10:00
FrankTheFarmer dcf8b22592 fixed Charizard jaw z fighting 2024-11-15 15:34:10 +10:00
FrankTheFarmer 5c1dbfff7b fixed alomomola crashing the game when it tried to sleep quirk (it never had one) 2024-11-15 15:33:51 +10:00
FrankTheFarmer e8c9ae1a64 Fixed mamoswine and piloswine shiny textures 2024-11-15 15:33:18 +10:00
FrankTheFarmer b1f9796e21 Emergency feebas line animations 2024-11-15 14:36:32 +10:00
Carmendar 02847c428d Fixed some invisible mons. 2024-11-12 19:49:19 -06:00
Carmendar 7552038d48 Removed duplicate aspects for Alcremie & Vivillon. Scaled down Kakuna. 2024-11-12 18:03:48 -06:00
Carmendar 84d6a8b110 Merge branch 'main' into implement_pokemon
# Conflicts:
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0973_flamigo/flamigo.json
2024-11-10 03:55:05 -06:00
Carmendar e9be40848a Merge remote-tracking branch 'origin/main' 2024-11-10 03:17:24 -06:00
Carmendar d8dd485d3f Milotic placeholder anims. 2024-11-10 03:12:38 -06:00
Carmendar b27924bd4a converted happiny to poser, and updated garchomp anim. 2024-11-09 17:11:43 -06:00
Carmendar be61d2d2ad Locator update for Charizard, Pivot fix for Aggron, Model fixes for Onix & Gible, Fixed Abra & Flamigo portrait, Height fix for Lapras surfacewater anims. 2024-11-09 00:08:03 -06:00
Carmendar 647989944e Fixed changelog! 2024-11-07 17:30:56 -06:00
Carmendar e80facfd3b Merge branch 'main' into implement_pokemon 2024-11-07 17:27:38 -06:00
Carmendar 43dbc87a1e Merge remote-tracking branch 'origin/main' 2024-11-07 17:23:40 -06:00
Carmendar 4b4ef77d4e Merge remote-tracking branch 'origin/main' 2024-11-07 00:36:25 -06:00
Sterrezo cb431c0b5f Added a placeholder cry animation to Hydreigon 2024-11-07 01:45:35 +01:00
Sterrezo f56960d15b Update gyarados.animation.json 2024-11-07 01:33:30 +01:00
Carmendar 41017342c9 Added temp surface water idle & swim for Flamigo. Updated scale for Electabuzz, Magmar and Rhyperior. Fixed Galvantula blinking breaking game. Added sleep behavior for Spinda. Made Litten line use correct naming scheme for walk behavior. Removed empty line on Tepig species file. Added missing L to "weepinbel" in changelog. 2024-11-06 01:57:15 -06:00
Carmendar 9b218bb4f7 Merge remote-tracking branch 'origin/main' 2024-11-05 17:13:29 -06:00
Carmendar fbe37cf81a Merge branch 'main' into implement_pokemon 2024-11-05 01:53:46 -06:00
Carmendar 6ec091dfa5 Gave Zarude temp walk anims, and added implemented line to Kecleon. little changelog addition. 2024-11-05 01:45:49 -06:00
Carmendar e6a9c8e32e Added implemented line to Finizen & Palafin. 2024-11-05 00:48:27 -06:00
Carmendar ba034be048 Added implemented line to Mantine & Mantyke.
Removed implemented line from Kecleon, Finizen & Palafin.
2024-11-05 00:01:15 -06:00
Carmendar 157fe0435b Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-11-04 22:56:25 -06:00
Carmendar 1123d10b05 implemented shellos & gastrodon west-sea forms as well as clauncher & clawitzer right-claw forms. Gave octillery the ability to swim, and added placeholder walking anims for shellos & gastrodon. 2024-11-04 22:55:59 -06:00
Hiroku 8f7fa9a324 Merge branch 'main' into 'implement_pokemon'
# Conflicts:
#   common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0365_walrein/walrein.json
#   common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0999_gimmighoul/gimmighoulroaming.json
2024-11-05 02:45:30 +00:00
Carmendar 7cf60159c4 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon
# Conflicts:
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0365_walrein/walrein.json
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0999_gimmighoul/gimmighoulroaming.json
2024-11-04 17:40:07 -06:00
Carmendar c5add81e90 Fixed Roaming Gimmighoul's recoil anim, updated textures for Salamence, and updated model & gave temp idle as well as a cry anim for Walrein. 2024-11-04 17:36:14 -06:00
Carmendar 5a6ada47b9 Merge remote-tracking branch 'origin/main' 2024-11-04 17:24:17 -06:00
Polymeta f4336c9227 Merge branch 'refs/heads/main' into implement_pokemon
# Conflicts:
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0091_cloyster/cloyster.json
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0129_magikarp/magikarp.json
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0130_gyarados/gyarados.json
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0131_lapras/lapras.json
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0594_alomomola/alomomola.json
2024-11-03 13:32:29 +00:00
Carmendar 123562c672 Merge remote-tracking branch 'origin/main' 2024-11-03 00:47:41 -05:00
tmetcalfe89 493101850e fornatted posers/resolvers 2024-11-02 18:45:22 -07:00
Carmendar 6bba26a848 Gyarados no longer pretends to be a diglett. 2024-11-02 19:23:32 -05:00
Carmendar 46474f67b8 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-11-02 18:35:14 -05:00
Carmendar 14f0a4643c Removed erroneous anims. 2024-11-02 18:34:37 -05:00
Carmendar 037e667411 Merge branch 'main' into 'implement_pokemon'
# Conflicts:
#   common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0091_cloyster/cloyster.json
#   common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0131_lapras/lapras.json
#   common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0594_alomomola/alomomola.json
2024-11-02 23:07:35 +00:00
Carmendar 0a25c286cd Fixed underwater anim conditions. 2024-11-02 18:01:55 -05:00
Carmendar 5561270a60 Merge branch 'main' into implement_pokemon 2024-11-02 15:27:26 -05:00
Carmendar 1d499bbce8 Gave Hydreigon placeholder anims. 2024-11-02 14:56:37 -05:00
Carmendar 6e8bf6999c updated Model & animations for Tepig line, tweaked Absol model & textures, fixed shoulder mount placements, added some walkSpeeds for some pokemon. Updated changelog. 2024-11-02 02:45:37 -05:00
Carmendar 5da8977ec0 fixed Serperior portrait 2024-11-01 22:40:31 -05:00
Carmendar fcb32062d3 Merge remote-tracking branch 'origin/main' 2024-11-01 22:30:53 -05:00
Carmendar 9e74c7fd18 Added some placeholder anims for serperior, liepard, mareanie, toxapex, sandygast, palossand, regieleki, regidrago. Anim fixes for scorbunny, roaming gimmighoul. Added anims for Fomantis, Lurantis, Smeargle, Tyrogue. Tweak to porygon-z anims. 2024-11-01 22:20:23 -05:00
Carmendar d3d73cc30d Merge branch 'refs/heads/main' into implement_pokemon 2024-11-01 22:10:26 -05:00
Sterrezo d9f76677c0 Fixed a missing cry animation for Trapinch
Closes https://gitlab.com/cable-mc/cobblemon/-/issues/1137
2024-11-02 00:39:23 +01:00
Sterrezo 151999c2cd Fixed cries for Gyarados and Munchlax, updated Magikarp's and Gyarados' cries 2024-11-01 23:58:10 +01:00
Carmendar 0460f17c1f Merge remote-tracking branch 'origin/main' 2024-11-01 00:47:17 -05:00
Carmendar 2c69513d2b Updated PokemonModelRepository.kt 2024-11-01 00:18:35 -05:00
Carmendar 617efe6a58 Remodeled Popplio line, tweaks for Garchomp, Mareanie line, Porygon, added anims for Flabebe line, Litten line, Finneon line, Bagon line, Flamigo, Lapras, Magnezone, Sprigatito. Updated Changelog.
- Removed Herobrine.
2024-11-01 00:05:52 -05:00
Wi2tert 2734f1d00c Update Bulbasaur Ivysaur Venusaur Animation 2024-10-31 12:20:53 +08:00
tmetcalfe89 e66069b270 swapped smeargle colors right way around 2024-10-30 01:49:28 -07:00
tmetcalfe89 a661575451 de-dyed smeargle 2024-10-29 23:16:22 -07:00
Carmendar a23017cd1f Updated scaling of a handful of pokemon, gave pory line dummy sleep cries, fixed mantine antennae, and onix has math.mod now.
- Removed Herobrine.
2024-10-29 22:13:20 -05:00
tmetcalfe89 0df19ce18a integrated retro's changes
Fixed Bellsprout's GEO ("arns" to "arms", "foor" to "foot", etcetera).
Altered Weepinbell's Scale and Hitbox
Altered Victreebel's Walk Speed and Hitbox.
2024-10-29 15:22:53 -07:00
Wi2ter 5a751546ec Update Changelog 2024-10-29 18:38:25 +08:00
Carmendar ee9e1cabc1 remodeled Poliwhirl, Poliwrath, Riolu & Lucario. Added animations for Bagon line, Shellder line, Kecleon, Furret & Spinda. Updated changelog.
- Removed Herobrine.
2024-10-29 01:44:02 -05:00
Wi2ter d78b46155f Update Klink Line animation 2024-10-28 17:26:14 +08:00
Wi2ter 1afd61d517 Update Dreepy Drakloak Animation 2024-10-28 16:27:57 +08:00
Carmendar 97a5083ff5 Updated swim speeds for some water mons & merged main into implement. 2024-10-27 19:43:51 -05:00
Carmendar 0d31e74790 Merge branch 'main' into implement_pokemon 2024-10-27 17:42:35 -05:00
Carmendar 02214196f4 Merge remote-tracking branch 'origin/main' 2024-10-27 17:40:11 -05:00
Carmendar aae268cfc5 New water pokemon can actually water now. 2024-10-27 17:05:46 -05:00
Carmendar 20f37d8799 Third coming of Klawf. (fixed the cry for real this time. 2024-10-27 15:52:46 -05:00
Carmendar 0b825bcda3 The second coming of Klawf (its cry), animation updates for a handful of mons, Portrait/Picture & scale fixes for a handful of mons, added species feature for three-segment dudunsparce, added dummy animation file for sleep cries, and added cries for Magikarp & Gyarados.
- Removed Herobrine.
2024-10-27 15:48:29 -05:00
GenotypeXD-Dev aba3bd22c7 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-26 22:02:04 -06:00
GenotypeXD-Dev b1fc33f5a1 Added Klawf 2024-10-26 22:01:39 -06:00
tmetcalfe89 f2033f5e33 fix alakazam json poser 2024-10-25 12:51:57 -07:00
tmetcalfe89 6c600b7bdb alakazam - kt->json 2024-10-25 12:27:33 -07:00
Wi2ter e93bfb7f0f Update Kleavor Animation 2024-10-25 18:25:09 +08:00
Wi2ter 8976909742 Update Alomomola Animation 2024-10-25 18:23:06 +08:00
Wi2ter 30a9c2f53e Update Mantyke Mantine Animation 2024-10-25 18:18:58 +08:00
Wi2ter ea60790865 I forgot to change the poser! 😭 2024-10-25 11:36:38 +08:00
Wi2ter f906fac8f3 Update Buneary and Lopunny animation 2024-10-25 11:28:57 +08:00
Wi2ter 05b324a3cb Remodel Swinub Piloswine Mamoswine [big guy] 2024-10-25 09:40:37 +08:00
Carmendar 8ce1c7ccf5 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-24 19:06:09 -05:00
Carmendar a37f93241f Slowed Numel, and fixed shiny Staryu emissive texture. 2024-10-24 19:05:14 -05:00
Wi2ter 6689663ca9 remodel Snivy Servin Serperior 🌿 🐍 2024-10-24 19:10:37 +08:00
Carmendar 959b81a58f flashy new models for ✨ Dwebble & Crustle ✨ 2024-10-24 01:27:11 -05:00
Carmendar 62e607b44e Forgot to remove magby line & onix from the kotlin model repository. 2024-10-23 23:22:19 -05:00
Carmendar 407bb6b977 Merge remote-tracking branch 'origin/main' 2024-10-23 20:07:59 -05:00
Carmendar a9efd327b8 Magby line & Onix are now beautiful. 2024-10-23 19:58:34 -05:00
Carmendar 64cb4d2ff8 Removed Herobrine 2024-10-23 00:36:52 -05:00
FrankTheFarmer 54786fa82e I forgot the changelog again 😔 2024-10-23 15:06:56 +10:00
FrankTheFarmer ecab1b7825 Porygon line poser fixes 🖥🦆 2024-10-23 14:57:22 +10:00
FrankTheFarmer 75d7106f46 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-23 14:37:28 +10:00
Carmendar 6f82c09afa angry crying 😠😢 2024-10-22 23:21:40 -05:00
Carmendar 778e5e219c Everyone is crying 😢 so sad. 2024-10-22 22:05:42 -05:00
FrankTheFarmer f4682e0bd2 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-23 11:07:21 +10:00
Tyzillion 906d487ffc Added rootBone to all existing json posers. 2024-10-22 08:08:31 -04:00
Tyzillion 817b801bf7 Merge branch 'main' of https://gitlab.com/cable-mc/cobblemon into implement_pokemon
# Conflicts:
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/animations/0006_charizard/charizard.animation.json
#	common/src/main/resources/assets/cobblemon/bedrock/pokemon/posers/0595_joltik/joltik.json
2024-10-22 07:44:07 -04:00
Sterrezo e401b11ab9 Added a sound keyframe to absol.animation.json 2024-10-22 10:21:08 +02:00
Carmendar 165f70e01d Updated changelog 2024-10-22 02:05:50 -05:00
GenotypeXD-Dev fddfbfb4ed Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-21 20:03:46 -06:00
GenotypeXD-Dev 03e229c511 Implemented Absol and Veluza. Fixed Charizard sleep crash 2024-10-21 20:02:26 -06:00
Sterrezo 0b08372407 Pushed an updated cry checker script. Corrected cries for Smearlge, Ledyba, Ledian, Sunkern, Sunflora, Smeargle.
Thanks to Polymeta for saving the script
2024-10-21 00:43:33 +02:00
Carmendar 6d26b5de20 Joltik can now blink while walking without blowing up your game. 2024-10-20 02:16:00 -05:00
Carmendar ef179410f9 Joltik can now blink while walking without blowing up your game. 2024-10-20 02:08:30 -05:00
FrankTheFarmer 194f6e019a Bellsprout line remodeled and animated 2024-10-18 16:29:15 +10:00
FrankTheFarmer 1f933827b9 Merge branch 'main' into implement_pokemon 2024-10-18 16:08:20 +10:00
FrankTheFarmer 28765bb2ce Merge branch 'main' into implement_pokemon 2024-10-18 13:29:35 +10:00
FrankTheFarmer 136391db04 👨‍🌾🔫🐲 2024-10-18 13:27:26 +10:00
Wi2ter 0cc39e71fc revamp Klink Klang and Klingklang 2024-10-18 10:11:53 +08:00
FrankTheFarmer d65cc08793 Several data fixes for posers and hitboxes 2024-10-17 23:11:43 +10:00
GenotypeXD-Dev a1729a0266 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-17 01:43:17 -06:00
GenotypeXD-Dev 8505634df3 Implement Charmander, Charmeleon, And Charizard Remodels + Gyarados Poser Fixes 2024-10-17 01:42:40 -06:00
FrankTheFarmer 02047c1ec0 Like a bajillion data fixes for posers and hitboxes 2024-10-17 17:24:39 +10:00
FrankTheFarmer 068fa4b2ef Updated Firefox. Make sure to update yours too! 2024-10-17 09:48:45 +10:00
Carmendar bfd266a40e Updated Toxapex, revamped Porygon line, remodeled Gastly and Haunter, updated portraits & pictures for many pokemon. 2024-10-15 23:54:34 -05:00
FrankTheFarmer 6367d4e2aa Tweaked Regional Pokédex orders to allow for proper ordering of the National Pokédex. 2024-10-16 12:59:16 +10:00
FrankTheFarmer f8a680f381 :*: **:** *:*:* :: :***: :;: 2024-10-15 22:32:01 +10:00
GenotypeXD-Dev 81750e6eb9 Added Implemented tag to Finizen and Palafin 2024-10-14 02:17:18 -06:00
GenotypeXD-Dev 818cf682bf Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-14 02:15:11 -06:00
GenotypeXD-Dev 3112a0650f Implemented Finizen and Palafin (+Hero form) 2024-10-14 02:14:51 -06:00
FrankTheFarmer 747ef94f04 Fixed baltoy and claydol exploding the game when scanned. 2024-10-14 15:56:38 +10:00
FrankTheFarmer dbacada48c Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-14 15:16:12 +10:00
FrankTheFarmer 26db8a40cc Un deleted female oinkolognes. This will affect the oinkologne population. 2024-10-14 15:15:30 +10:00
GenotypeXD-Dev 6e5feda00e Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-13 23:12:07 -06:00
GenotypeXD-Dev f04330074b Added implemented tag to all currently implemented 1.6 pokemon 2024-10-13 23:11:46 -06:00
FrankTheFarmer 80d733d329 Merge branch 'main' into implement_pokemon 2024-10-14 14:18:08 +10:00
FrankTheFarmer 0099dcf5c5 Alolan Exeggutor will now appear in front of all pokemon in the dex no matter what lol 2024-10-14 14:16:42 +10:00
GenotypeXD-Dev 0a30551b7d Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-13 19:23:49 -06:00
GenotypeXD-Dev e4ee0227fd Reapply "Implement Magikarp and Gyarados Remodels + Jump Variants"
This reverts commit 4ec7168499.
2024-10-13 19:22:35 -06:00
GenotypeXD-Dev 4ec7168499 Revert "Implement Magikarp and Gyarados Remodels + Jump Variants"
This reverts commit 650647e94b.
2024-10-13 19:20:46 -06:00
GenotypeXD-Dev 650647e94b Implement Magikarp and Gyarados Remodels + Jump Variants 2024-10-13 19:19:46 -06:00
Carmendar a5371f4b5d Updated Tepig line & Baltoy line. 2024-10-13 16:03:10 -05:00
Wi2ter d47e7fb3c4 Implemented Corphish Crawdaunt 2024-10-13 12:32:27 +08:00
Carmendar ef983e17fe Implemented Palossand, updated Bulbasaur texture, Ivysaur model & texture, Mudkip model & texture. Fixed portraits, pictures & scales for many Pokemon. 2024-10-12 22:42:41 -05:00
GenotypeXD-Dev d78975be6e Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-12 01:15:01 -06:00
GenotypeXD-Dev 19a264870c Implemented Scraggy, Scrafty, Hatenna, Hattrem, Hatterene, Wattrel, Kilowattrel, Alola_bias cubone. Fixed Resolver typo from last Push 2024-10-12 01:14:11 -06:00
Carmendar ee1753de67 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-10-11 01:28:24 -05:00
Carmendar 742354b2cb Implemented Slakoth, Vigoroth, Slaking. Adjusted Larvitar scale. 2024-10-11 01:24:30 -05:00
GenotypeXD-Dev e2f6aaa4de Shelgon Basescale adjustment 2024-10-10 18:53:12 -06:00
GenotypeXD-Dev abc2911059 Implemented Bagon, Shelgon, Salamence, Pikipek, Trumbeak, Toucannon, Dondozo, Alolan Marowak 2024-10-10 17:46:09 -06:00
FrankTheFarmer d76caf7093 i forgot to write implemented 😩 2024-10-10 10:37:38 +10:00
FrankTheFarmer bf859f8435 Sand castle :) 2024-10-10 10:06:19 +10:00
FrankTheFarmer b31c10cc52 Took Venusaurs foot off the pedal (bone name changes) 2024-10-04 09:30:45 +10:00
FrankTheFarmer 89e3c7d8b0 Sealeo zfight fix 2024-10-04 08:52:20 +10:00
FrankTheFarmer 167b09f24f Fixed Diggersby using its walk animation in its battle portrait 2024-10-01 21:18:09 +10:00
FrankTheFarmer 39165266d5 🎬🔴👗 👠 2024-10-01 20:35:01 +10:00
FrankTheFarmer 7405f2de75 💍⚡🕶️⚡🧋 2024-10-01 20:34:20 +10:00
FrankTheFarmer 762fe87454 ✨🎡🧣 2024-10-01 20:33:41 +10:00
FrankTheFarmer ebbc81b605 💋🎙️🇫🇷 🎩 2024-10-01 20:33:01 +10:00
FrankTheFarmer 12d41aada1 👁️🍧👁️ 2024-10-01 20:32:20 +10:00
FrankTheFarmer 61fe9c23ce 💅 🪨 👜 🐩 2024-10-01 20:31:20 +10:00
FrankTheFarmer 945c9c60a9 Mmm monkey 2024-10-01 20:30:10 +10:00
FrankTheFarmer 8413b0392e Venusaur scaling stuff for Jazz 😈 2024-10-01 16:26:55 +10:00
FrankTheFarmer 868edcd392 Looped Walreins temp idle animation 2024-10-01 16:21:43 +10:00
FrankTheFarmer a3b2f9b6fc Rotom assets for future implementation 2024-10-01 16:07:26 +10:00
FrankTheFarmer 12b444bb41 Kecleon Assets for future implementation 2024-10-01 16:06:57 +10:00
FrankTheFarmer 0e814fd567 Added Flamigo 🔫🦩 2024-10-01 16:05:42 +10:00
FrankTheFarmer 7b083aa038 Added Walrein 🗡️ 🦭 2024-10-01 15:56:16 +10:00
FrankTheFarmer 4e0a4c84b5 Added Sealeo 🦭 2024-10-01 15:54:30 +10:00
FrankTheFarmer 2d9b47e645 Added Spheal 🪩 2024-10-01 15:53:38 +10:00
FrankTheFarmer 39a2182736 Added Toxapex ☂️ 2024-10-01 15:51:23 +10:00
FrankTheFarmer 5a996abbf3 Added Mareanie ☂️ 2024-10-01 15:50:31 +10:00
FrankTheFarmer a20def5161 Snail textures woops 2024-10-01 15:09:31 +10:00
FrankTheFarmer 030f370290 Added Gastrodon 🐌 2024-10-01 11:15:43 +10:00
FrankTheFarmer f3ade3cb82 Added Shellos 🐌 2024-10-01 11:14:14 +10:00
FrankTheFarmer 315cb6a1ac Added Lumineon 🐠 2024-10-01 10:48:35 +10:00
FrankTheFarmer 60615d32f5 Added Finneon 🐟 2024-10-01 10:48:18 +10:00
FrankTheFarmer 1d27d9cf5b Added Clawitzer 🔫🦞 2024-10-01 10:40:21 +10:00
FrankTheFarmer 2ba760d0f9 Added Clauncher 🦞 2024-10-01 10:38:35 +10:00
FrankTheFarmer c31ec3b418 Added Bruxish 🪥🐟🌈 2024-10-01 10:30:52 +10:00
FrankTheFarmer d0afab9604 Added Wugtrio 🪱🪱🪱 2024-10-01 10:16:39 +10:00
FrankTheFarmer 4e9f8fe1c0 Added Wiglett 🪱 2024-10-01 10:16:18 +10:00
FrankTheFarmer 803f93aa73 Added Corsola 🪸 2024-09-30 17:21:31 +10:00
FrankTheFarmer 853940d009 Added Pincurchin 🦔 2024-09-30 17:16:38 +10:00
FrankTheFarmer 6ddb746d49 Fired for not using indents of 2 again 2024-09-30 17:05:47 +10:00
FrankTheFarmer 2b86b15132 Added Liepard 🐆 2024-09-30 17:05:34 +10:00
FrankTheFarmer 5f0f5d0aa5 Added Purrloin 🐈 2024-09-30 17:02:17 +10:00
FrankTheFarmer 136aab872a Added Mantine 🌊🥞 2024-09-30 17:00:04 +10:00
FrankTheFarmer a1d4702af0 Added Mantyke 🥞 2024-09-30 16:59:33 +10:00
FrankTheFarmer b2777c13b8 Added Milotic 🐍 2024-09-30 16:55:33 +10:00
FrankTheFarmer 26cb473b9d Added Feebas 🎣 2024-09-30 16:55:09 +10:00
FrankTheFarmer 907c639e28 Added Octillery 🐙 2024-09-30 16:52:21 +10:00
FrankTheFarmer 80d2eafed7 Added Remoraid 🐟 2024-09-30 16:51:40 +10:00
FrankTheFarmer 519122e5be Little bit of Rhyhorn line resizing 2024-09-29 22:45:59 +10:00
FrankTheFarmer c211768d5c Forgor to remove Rhyhorn line kotlin posers 2024-09-29 22:45:35 +10:00
FrankTheFarmer 908f318eeb Carvanha remodel 2024-09-29 22:40:27 +10:00
FrankTheFarmer 0143f93577 Rhyperior remodel 🌤🦏 2024-09-29 22:31:46 +10:00
FrankTheFarmer f8615aeb82 Rhyhorn remodel 🦏 2024-09-29 22:26:06 +10:00
FrankTheFarmer b113448a9c Rhydon remodel 🦏 2024-09-29 22:23:56 +10:00
FrankTheFarmer 2930a11c75 Garchomp remodel ✈ 2024-09-29 22:13:00 +10:00
FrankTheFarmer 982de7f5c7 Gabite remodel 🦈 2024-09-29 22:12:08 +10:00
FrankTheFarmer bfdb5e9787 Gible remodel 🐟 2024-09-29 22:11:27 +10:00
FrankTheFarmer d5ea945c6b Krookodile remodel 2024-09-29 22:00:52 +10:00
FrankTheFarmer 5a18d038a2 Wigglytuff remodel 🍎 2024-09-29 21:51:56 +10:00
FrankTheFarmer d0389d6c9c Jigglypuff remodel 🎤 2024-09-29 21:51:32 +10:00
FrankTheFarmer c9bc6e24fe Igglybuff remodel 2024-09-29 21:50:39 +10:00
FrankTheFarmer 8b4a8e9534 oop. Tatsugiri resolver fix 2024-09-29 21:46:25 +10:00
FrankTheFarmer 5adfd00509 Tatsugiri model update 🍙🐟 2024-09-29 21:26:31 +10:00
FrankTheFarmer 4090e038ae Cloyster model update 2024-09-29 21:25:33 +10:00
FrankTheFarmer f3ab282fd1 Shellder model update 2024-09-29 21:25:16 +10:00
FrankTheFarmer 40b97d3c1e Merge branch 'main' into implement_pokemon 2024-09-29 21:17:27 +10:00
FrankTheFarmer 829b97270d Seaking model update 2024-09-29 21:16:49 +10:00
FrankTheFarmer 61111c8038 Goldeen model update 2024-09-29 21:16:34 +10:00
FrankTheFarmer 1f4fbaa177 oop. relicanth resolver update 2024-09-29 21:16:16 +10:00
FrankTheFarmer 9e8ef7e875 Relicanth remodel 2024-09-29 21:15:35 +10:00
FrankTheFarmer 190d90a966 Empoleon remodel 2024-09-29 20:56:38 +10:00
FrankTheFarmer 5a07c82a5d Prinplup remodel 2024-09-29 20:55:57 +10:00
FrankTheFarmer 9c2e56ee8b Cinderace remodel 2024-09-29 20:52:27 +10:00
FrankTheFarmer c83f194dc9 Scorbunny remodel 2024-09-29 20:52:06 +10:00
FrankTheFarmer b9bcb66d2a Swampert remodel 2024-09-29 20:47:43 +10:00
FrankTheFarmer b72050da1d Marshtomp remodel 2024-09-29 20:46:36 +10:00
FrankTheFarmer 82522ad6ab Mudkip remodel 💙 2024-09-29 20:46:02 +10:00
FrankTheFarmer d40e2e6103 Changelog for incoming implementation 2024-09-29 11:41:52 +10:00
FrankTheFarmer 96715770a7 Incineroar Remodel 🔥🧍‍♂️ 2024-09-29 11:41:09 +10:00
FrankTheFarmer 48fa67c2e4 Torracat Remodel 🔥🐆 2024-09-29 11:40:31 +10:00
FrankTheFarmer 9a6217f755 Litten Remodel 🔥🐈 2024-09-29 11:39:38 +10:00
FrankTheFarmer f1f035b5f9 Fired for not using double spaced (2)JSON indents 2024-09-29 11:31:44 +10:00
FrankTheFarmer 19aa53effc Horsea Remodel 2024-09-29 11:24:46 +10:00
FrankTheFarmer be7cb4583c Seadra Remodel 2024-09-29 11:24:36 +10:00
FrankTheFarmer 887891f74d Kingdra Remodel 2024-09-29 11:24:19 +10:00
FrankTheFarmer d83cd34bf4 Removed several pokemon from PokemonModelRepository as they have JSON posers now! 2024-09-28 20:08:54 +10:00
FrankTheFarmer bee41a90f9 Venusaur remodel 2024-09-28 19:59:28 +10:00
FrankTheFarmer 79afe9d812 Ivysaur remodel 2024-09-28 19:59:07 +10:00
FrankTheFarmer 9fe55c5692 Bulbasaur remodel 2024-09-28 19:58:44 +10:00
FrankTheFarmer feddce2575 Merge branch 'main' into implement_pokemon 2024-09-28 19:39:36 +10:00
FrankTheFarmer 4ddc5e3a93 Cetitan can now cry and walk/sleep at the same time! Unfortunately relatable! 2024-09-28 06:43:47 +10:00
FrankTheFarmer f63f1764ab Merge branch 'main' into implement_pokemon 2024-09-28 06:35:49 +10:00
FrankTheFarmer 7c694e9733 Corrected Dachsbun's resolver name. Was using Fidough 2024-09-25 21:19:58 +10:00
FrankTheFarmer 21b6977387 Merge branch 'main' into implement_pokemon 2024-09-25 21:09:08 +10:00
FrankTheFarmer 408735399c Merge branch 'main' into implement_pokemon 2024-09-24 21:13:15 +10:00
FrankTheFarmer f6c856d161 Merge branch 'main' into implement_pokemon 2024-09-24 08:23:07 +10:00
FrankTheFarmer 8173cf13a8 data updates for walking wake and iron leaves 2024-09-17 22:28:39 +10:00
FrankTheFarmer 7d0becf1bd Fixed that one elekid thing that was breaking the thingy™ 2024-09-17 09:45:15 +10:00
FrankTheFarmer 9b4a87ce68 Merge branch 'main' into implement_pokemon 2024-09-16 14:51:53 +10:00
Hiroku 464c4d349d Update CHANGELOG.md 2024-09-15 09:31:47 +00:00
Hiroku a35d3131f8 Update CHANGELOG.md 2024-09-15 09:30:28 +00:00
FrankTheFarmer 9d99d3c331 Merge branch 'main' into implement_pokemon 2024-09-14 19:49:29 +10:00
Paul b100516b24 Fixed JSON posed mons having _issues_ when evolved 2024-09-14 12:31:40 +10:00
FrankTheFarmer 8da5396443 Merge branch 'main' into implement_pokemon 2024-09-13 20:58:59 +10:00
FrankTheFarmer 5d2a727311 Chest Gimmighoul quirk fixes 2024-09-13 20:01:19 +10:00
FrankTheFarmer d7f03215e2 Merge branch 'main' into implement_pokemon 2024-09-13 15:18:46 +10:00
FrankTheFarmer d366471e71 Merge branch 'main' into implement_pokemon 2024-09-12 20:17:22 +10:00
FrankTheFarmer e5163f154a The "true".asExpressionLike fix for the bird wing visibility 2024-09-12 20:16:20 +10:00
FrankTheFarmer cfc497d8ed Consistency update for the first few json posers 2024-09-11 18:39:58 +10:00
FrankTheFarmer 35f8ab0257 Removed life ending comma 2024-09-11 17:35:25 +10:00
FrankTheFarmer e890743c86 Merge branch 'main' into implement_pokemon 2024-09-11 17:34:19 +10:00
FrankTheFarmer ffec6e307d Move over poser! 2024-09-11 16:16:01 +10:00
FrankTheFarmer 7c35db7eaa Temp horse data 2024-09-11 16:15:38 +10:00
FrankTheFarmer 9f0c2296bc Fixed the wing flap placeholder animation 2024-09-09 10:32:27 +10:00
FrankTheFarmer 6b0a06c64d I have restored the named animations. i think they got lost. 2024-09-08 15:18:12 +10:00
FrankTheFarmer 160186931f Merge branch 'main' into implement_pokemon 2024-09-08 14:23:54 +10:00
FrankTheFarmer 22c4a14fbe Changelog and maybe added fortnite 2024-09-08 14:22:14 +10:00
FrankTheFarmer 241a82764b Removal of Kingler kotlin poser. im too lazy to do krabby rn lol 2024-09-08 14:18:58 +10:00
FrankTheFarmer 6e4d48bb07 Cramorant remodel 🐟 2024-09-08 14:16:55 +10:00
FrankTheFarmer 7a383f419a 🦀🦀 Krabby & Kingler updates 🦀🦀 2024-09-08 13:30:16 +10:00
FrankTheFarmer 933b99d349 Wobbuffet! 💁‍♀️ 2024-09-08 11:03:30 +10:00
FrankTheFarmer 72d78084f6 Merge branch 'main' into implement_pokemon 2024-09-08 10:21:30 +10:00
FrankTheFarmer fcee4d2774 Merge branch 'main' into implement_pokemon 2024-09-08 07:47:04 +10:00
FrankTheFarmer 61c7f3bc13 sunkern line look animation fixes 2024-09-08 07:45:15 +10:00
FrankTheFarmer 3830637f3c Stupid ass dinosaur crying in his sleep 2024-09-08 07:45:14 +10:00
FrankTheFarmer 45f8049521 💖🌱Sunkern & Sunflora🌻✨ given Retro's placeholder assets and data 2024-09-06 16:47:43 +10:00
FrankTheFarmer 823774bcfe Merge branch 'main' into implement_pokemon 2024-09-06 10:48:03 +10:00
FrankTheFarmer 920e5211c0 Somebody forgot the changelog again 2024-09-06 10:47:02 +10:00
FrankTheFarmer 7da61e3d8d Fixed the look animations for the ledyba line 2024-09-06 10:41:34 +10:00
FrankTheFarmer 754b60b15c fixed Maushold faints not playing 2024-09-03 21:29:09 +10:00
FrankTheFarmer 839454bfd6 Fixed Slowking battle idle not playing properly 2024-09-03 20:31:41 +10:00
FrankTheFarmer 3b6a0667d6 Adjusted Grafaiai walk speed to reduce feet sliding 2024-09-03 20:05:56 +10:00
FrankTheFarmer f298adaea8 Vivillon will stop being naked when removing Vivillon addons 2024-09-03 09:36:53 +10:00
FrankTheFarmer 641206b811 Merge branch 'main' into implement_pokemon 2024-09-02 14:52:59 +10:00
Tyzillion 93a94b4900 Updated model for Beedrill and Kingler.
Implement Cramorant.
2024-08-05 17:43:24 -04:00
Tyzillion 40363c2ea1 Merge remote-tracking branch 'origin/implement_pokemon' into implement_pokemon 2024-08-04 14:09:00 -04:00
FrankTheFarmer 6f15d65d90 Unbiases your hisuian starter evolution methods 2024-07-15 16:37:53 +10:00
FrankTheFarmer 02f9b21cff Small changelog tweak. I didn't forget i promise. 2024-07-15 12:56:41 +10:00
FrankTheFarmer 79cf154304 What if we take bikini bottom and push it somewhere else?! 2024-07-15 12:19:29 +10:00
FrankTheFarmer a650683d45 Merge remote-tracking branch 'origin/main' into implement_pokemon 2024-07-15 10:54:23 +10:00
Apion 311dc3dc9c Merge branch 'json-poser-conversion' into 'implement_pokemon'
Json poser conversion

See merge request cable-mc/cobblemon!1081
2024-06-27 23:50:31 +00:00
FrankTheFarmer bda1f80ecc Corrected Zangoose's egg moves being in its leveled move list. 2024-06-26 14:28:03 +10:00
FrankTheFarmer 817796bf40 Corrected Klevin's stats to match current databases post S/V patch 2024-06-26 10:22:02 +10:00
FrankTheFarmer 8a48eeab8b Merge branch 'main' into implement_pokemon 2024-06-23 20:48:59 +10:00
FrankTheFarmer 0061104c0d I did not forget the changelog this time 2024-06-23 20:47:37 +10:00
FrankTheFarmer 5110a1be17 Removed Chikorita's ability to look due to some awkward pivots and head structure 2024-06-23 20:28:37 +10:00
FrankTheFarmer 4cbb998106 Adjusted Shroomish's Yaw range for looks. Yeehaw 2024-06-23 20:24:20 +10:00
FrankTheFarmer 17de3f496c Adjusted Bellossom shoulder pose to clip a lot less than before. 2024-06-23 20:08:22 +10:00
FrankTheFarmer b54181e93a Glimmet and Tatsugiri are now shoulder mountable 2024-06-23 20:05:21 +10:00
FrankTheFarmer eaf7edcd94 Fletchling, Skrelp, Klefki, Fomantis, Morelull and Shroodle are now shoulder mountable 2024-06-23 19:46:16 +10:00
FrankTheFarmer cdf1631e2b ZORUA 2 STOP FLOATING 2024-06-23 18:51:40 +10:00
FrankTheFarmer 841f49553e Pidove, Petilil, Hisui Bias Petilil, Zorua, Zorua 2 and Elgyem are now shoulder mountable 2024-06-23 18:51:22 +10:00
FrankTheFarmer 57d7d5a1b9 Minun, Beldum, Starly, Buneary, Combee and Pachirisu are now shoulder mountable 2024-06-23 17:46:41 +10:00
FrankTheFarmer b1f2ab2ed7 Merge branch 'main' into implement_pokemon 2024-06-23 17:26:01 +10:00
FrankTheFarmer f629d95844 Spearow, Murkrow, Mew, Larvitar, Taillow and Plusleare now shoulder mountable 2024-06-23 16:58:37 +10:00
FrankTheFarmer 30904fbdda Caterpie, Weedle, and Smoochum are now shoulder mountable 2024-06-23 16:00:14 +10:00
FrankTheFarmer 9a3be6a85a Roaming Gimmighoul is now shoulder mountable 2024-06-23 15:01:17 +10:00
FrankTheFarmer 88c91d9bdd Reverted Hisuian Zoroark stats to be different from base Zoroark 2024-06-23 09:50:05 +10:00
FrankTheFarmer 5d2efe3e6b Merge branch 'main' into implement_pokemon 2024-06-23 09:41:59 +10:00
FrankTheFarmer d6354d3d94 Fixed Duskull and Dusclops spawn data 2024-06-14 11:51:33 +10:00
FrankTheFarmer 4ddfdd828c Merge branch 'main' into implement_pokemon 2024-06-14 11:30:43 +10:00
FrankTheFarmer 06b70c6204 After nearly 2 years, the Magby line received their placeholder walks 2024-06-12 14:05:54 +10:00
FrankTheFarmer 2dc9d11f79 Merge branch 'main' into implement_pokemon 2024-06-12 14:00:10 +10:00
FrankTheFarmer fbb161c511 I FORGOT THE CHANGELOG 2024-06-04 14:36:35 +10:00
FrankTheFarmer f84bc62d61 Dreepy can now float on your shoulders 2024-06-04 14:17:39 +10:00
FrankTheFarmer 2e20554d1e Fixed Chimchar and Monferno sleeping T pose 2024-06-04 13:55:16 +10:00
apion bb9fcc64ed Started working on Aerodactyl JSON poser 2024-05-24 21:52:16 -04:00
apion 2d908468ea Fixed issue where singular conditions not met, abra is now completely working with a JSON poser 2024-05-24 11:21:01 -04:00
apion c9ae148d86 Moved Abra to JSON poser, pose conditions not properly working 2024-05-24 10:24:50 -04:00
2641 changed files with 223109 additions and 123310 deletions
+184 -41
View File
@@ -1,52 +1,163 @@
# Changelog
## [1.6.1 (Release TBD)](#1-6-1)
## [1.7.0 (Month xth, 2025)](#1-7-0)
### Fixes
- Fixed Particles sometimes facing the wrong direction (looking at you, Swords Dance)
- Fixed PCs always opening at box 2 instead of box 1.
### Developer
- A finished battle now has winners and losers set inside of `PokemonBattle` instead of them always being empty.
- Dialogues are correctly removed from memory when they are stopped.
- Dialogues with variably-set initial pages now properly start timeout tracking.
## [1.6.1 (January 26th, 2025)](#1-6-1)
### Additions
- Added crossover paintings from Close Combat: Premonition, Altar, Slumber, and Nomad.
- Added Galarica Nuts, used for crafting Galarica Cuffs and Wreaths. Dropped from certain Pokémon. Take a wild guess which.
- Added compatibility with Repurposed Structures. (Thank you, TelepathicGrunt!)
- Added an evolution method for Karrablast to evolve into Escavalier in singleplayer.
- Pokédexes can now be placed in Chiseled Bookshelves.
- Added optional box argument to the /pc command.
- Pokédex and Dialogue screens now close when the inventory keybind is pressed.
- Added config setting `maxPokedexScanningDetectionRange` to control from what distance the player can scan Pokémon using the Pokédex.
- Added the `is_standing_on_blocks(depth, blocks...)` MoLang function, which returns whether the specified entity is standing on a specific block or set of blocks. Example usage: `q.is_standing_on_blocks(2, minecraft:sand)`
- Added config setting `hideUnimplementedPokemonInThePokedex` which hides unimplemented Pokémon from the Pokédex when set to true.
- Added molang particle queries for getting distance to targeted entities.
- Added debug renderer for poseable entity locators.
- Added `baseScale` property to NPCs.
- Added the player to `PokerodReelEvent`.
- Pokédex and Dialogue API screens now close when the inventory keybind is pressed.
- Added Galarica Nuts, used for crafting Galarica Cuffs and Wreaths. Dropped from certain Pokémon.
- Added specific compatibility with Repurposed Structures. (Thank you, TelepathicGrunt!)
- Added debug renderer for posable entity locators.
- Added crossover paintings from Close Combat, Premonition, Altar, Slumber, and Nomad.
- Added optional box argument to the /pc command
### Changes
- Pokémon will now be dynamically revealed to the Pokédex as they're seen instead of revealing entire parties at the end of battle regardless.
- Unseen wild Pokémon will update their name from '???' to their real name as soon as a battle starts to reflect the battle UI showing the actual species name.
- Pokémon under the illusion effect will reveal their disguise to the Pokédex first and then the base Pokémon once the disguise is broken.
- Added more support for a variety of Fabric/NeoForge Convention tags.
- Reformatted some tags to be more consistent.
- Edited some recipes to utilize tags instead of direct item ids, for greater mod compatibility.
- Berries will drop if broken at age 0
- Improved Fortune drops on Mint Seeds
- New Slowpoke shiny texture.
- Updated drops for many Pokémon.
- Completely resynced Pokémon move and stat data based on later games. Learnsets have changed considerably to maximise available moves.
- Cobblemon save data now saves .old files where applicable as a means to recover from file corruption due to crashes or similar abrupt stops
### Pokémon Added
#### Gen 5
- Ducklett
- Swanna
- Shelmet
- Accelgor
- Karrablast
- Escavalier
- Rufflet
- Braviary
- Foongus
- Amoonguss
#### Gen 6
- Binacle
- Barbaracle
#### Gen 7
- Dewpider
- Araquanid
- Alolan Geodude
- Alolan Graveler
- Alolan Golem
#### Gen 8
- Galarian Slowpoke
- Galarian Slowbro
- Galarian Slowking
#### Gen 9
- Paldean Tauros
### Added cries to the following Pokémon
- All Nidorans
- Shellder, Cloyster
- Pinsir
- Tyrogue, Hitmontop
- Spinda
### Animation updates for the following Pokémon
- Primeape
- Munchlax
- Snorlax
- Poliwrath
- Goldeen
- Seaking
- Dondozo
- Wobbuffet
- Charcadet
- Armarouge
- Ceruledge
- Geodude
- Graveler
- Golem
- Sandile
- Krokorok
- Krookodile
### Model updates for the following Pokémon
- Slowpoke
- Slowbro
- Slowking
- Eiscue
- Tauros
- Goldeen
- Seaking
- Charcadet
- Armarouge
- Ceruledge
- Pinsir
- Geodude
- Graveler
- Golem
### Cry updates for the following Pokémon
- Sceptile
### Changes
- Completely re-synced Pokémon move and stat data based on later games. Learnsets have changed considerably to maximise available moves.
- Pokémon will now be dynamically revealed to the Pokédex as they're seen in battle instead of revealing entire parties at the end of battle.
- Unseen wild Pokémon will update their name from '???' to their real name as soon as a battle starts to match how the battle UI shows the actual species name.
- Pokémon under the illusion effect will reveal their disguise to the Pokédex first and then the base Pokémon once the disguise is broken.
- Berries will now drop from berry trees if broken at age 0 so you aren't punished for mistaken planting.
- Increased Fortune drops on Mint Seeds.
- Updated Slowpoke's shiny texture.
- Updated drops for many Pokémon.
- Adjusted the evolution sound to match the timing of the particle effect.
- Made berry trees shear-able by dispenser blocks. I'm sure nobody will make unholy contraptions with this.
- Edited some recipes to utilize tags instead of direct item IDs, for better mod compatibility.
- Added more support for a variety of Fabric/NeoForge conventional tags.
- Reformatted some tags to be more consistent.
### Fixes
- Fixed Pokédex sometimes crashing when switching forms.
- Fixed Pokédex interface not transitioning out when closed.
- Fixed texture dimensions for the interact interface.
- Fixed crash related to Tom's Simple Storage mod and Fossil Machine.
- Fixed texture dimensions for the player and Pokémon interact interface.
- Fixed crash related to Tom's Simple Storage mod and the Fossil Machine.
- Fixed not being able to retrieve a fossil from the Fossil Machine with an empty hand.
- Fixed Pokémon being collidable while being captured by a Poké Ball.
- Fixed Pokémon being collidable (collidible? collissionable? kaleidoscopable?) while being captured by a Poké Ball.
- Fixed `full_party`, `own_zangoose_seviper`, `use_revive` and `use_candy` Advancement triggers.
- Fixed `healing_machine` Advancement by using the correct 1.21 trigger.
- Fix Display Cases not dropping items if destroyed through explosions.
- Fixed an issue where the first Pokémon in the pastured Pokémon list clipped into the interface.
- Fixed all Pokémon facing South on spawn.
- Parametric particle motion now works.
- Event spawned particles now work.
- Particles can now have independent coordinate spaces.
- Fixed bait being consumed when not reeling in any Pokémon.
- Fixed bait being consumed even when not reeling in any Pokémon.
- Fixed Miltank milk magically disappearing out of your bucket.
- Fixed Pokémon nicknames migrating from 1.5.2 not being displayed properly.
- Fixed capitalization in one of our config fields, but allowing typo'd version to still be valid.
- Fixed Poké Rods not working if lure or luck of the sea enchantments get removed by other mods.
- Fixed crashes related to Pokémon when they are ready to evolve while holding an enchanted item.
- Fixed crashes that sometimes occur when evolving Nincada.
- Fixed plants not being compostible on NeoForge.
- Fixed capitalization in one of our config options. It was a very important fix. Very important. Old configs are fine.
- Fixed Poké Rods not working if Lure or Luck of the Sea enchantments get removed by other mods.
- Fixed crashes related to Pokémon when they are ready to evolve while holding an enchanted item. Very specific.
- Fixed a crash that sometimes occurred when evolving Nincada.
- Fixed Cobblemon plants not being compostable on NeoForge.
- Fixed hide UI (F1 key) not hiding the party overlay.
- Fixed NPC MoLang command `player_lose_command` not working.
- Corrected misaligned tooltips with editboxes in the NPC editor screen.
- Fixed misaligned tooltips with edit boxes in the NPC editor screen.
- Fixed Pokémon riding two boats when attempting to deploy a platform on water.
- Made berry trees be shearable by dispenser blocks.
- Fixed the summary screen showing there's experience to reach the next level when at level cap.
- Fixed the summary screen showing there's experience to reach the next level when they are at the level cap.
- Fixed Pokémon forgetting moves when evolving on specific cases.
- Fixed Adorn compatibility, including improvements when using JEI/REI (Apricorn items now show up under the collapsed entries rather than standalone).
- Fixed error message appearing on battle log when using Solar Beam with Sunny Day.
@@ -54,35 +165,68 @@
- Fixed `/pokedex grant all` command not giving male/female/shininess completion for some Pokémon.
- Fixed `/pokedex grant only` and `/pokedex remove only` not respecting the form parameter passed.
- Fixed variant forms appearing incorrectly in the Pokédex when the normal form had not been unlocked.
- Fixed Pokémon occasionally being shot into the sky during battle.
- Fixed Pokémon occasionally being shot into the sky during battle. No Pokémon were harmed by this bug, probably.
- Fixed NPC editing GUI not updating aspects until a game restart.
- Fix some users being unable to open their PC if a Pokémon in said PC had a lot of pp raises beyond normal bounds
- Fix some color variants (dubwool, conkeldurr and undyed wooloo) missing in the Pokédex
- Fix invalid species or held_items causing Players to not be able to load into their world anymore (commonly happening after removing addons/mods)
- Fixed some users being unable to open their PC if a Pokémon in it had a lot of PP raises beyond normal bounds. How did you get those, anyway? Tell me or the Bellossom gets it.
- Fixed some color variants (Dubwool, Conkeldurr and Undyed wooloo) being missing in the Pokédex.
- Fixed invalid species or held items causing Players to not be able to load into their world anymore (commonly happening after removing addons/mods).
- Fixed Wooloo variants not being automatically registered in the owner's Pokédex when dyed.
- Fixed Vivichoke Dip and Leek and Potato Stew not returning a bowl upon consumption.
- Fixed Fossil Restoration Machine not accepting Hay Bales.
- Fixed Potion items so that they no longer apply over double their intended healing value.
- Fixed Vivichoke Dip and Leek & Potato Stew not returning a bowl upon consumption.
- Fixed Fossil Restoration Tank not accepting Hay Bales as organic material.
- Fixed Potion items applying double their intended healing value.
- Fixed Fast Ball capture bonuses applying to all Pokémon, making it the Best Ball instead of the Mediocre Edge-Case Ball.
- Fixed "learned new move" messages appearing for already-known moves on Pokémon evolutions.
- Fixed Pokémon Item Models breaking shadows nearby when being placed in Display Cases or Item Frames.
- Fixed berries not giving bonus yields when planted in their preferred biomes. I'm sure we've fixed that 5 times now.
- Fixed the NeoForge version not supporting "SodiumDynamicLights".
- Fixed players disconnecting from servers if they made changes to certain config options.
- Fixed players with shouldered Pokémon not being able to rejoin their 1.5.2 worlds using 1.6.
- Fixed `PokemonProperties` utilizing `ability=<some ability>` being treated as a forced ability even when it is a legal ability for the Pokémon.
- Fixed type formatting in Pokédex scanner mode when dual types require two lines.
- Fixed trading sometimes crashing the game or server.
- Fixed Wild shiny sounds not respecting the `shinyNoticeParticlesDistance` config setting.
- Fixed Pokémon being able to evolve mid-battle.
- Fixed NPC held items being able to be stolen by players. Don't be a thief!
- Fixed evolutions that require a held item consuming it as soon as meeting requirements when it should only be consumed upon evolution.
- Fixed Pokémon showing only the default form when selecting them as a target in battle.
- Fixed a possible error coming out of reeling fishing rods in specific situations.
- Fixed incorrect weights being used when Poké Fishing with Luck of the Sea.
- Parametric particle motion now works.
- Event-spawned particles now work.
- Particles can now have independent coordinate spaces.
### Molang & Datapacks
### Developer
- Updated the Pokédex data updated events to always include a `Pokemon` instance, and optionally a `DisguiseData` instance.
- Updated fields in `SpawnNPCPacket` and `SpawnPokemonPacket` to be visible and mutable.
- Updated `UnvalidatedPlaySoundS2CPacket` to be public instead of internal and made its fields mutable.
- Added `hideNameTag` field and `HideNPCNameTag` nbt tag to `NPCEntity` to allow hiding the name tag of the NPC.
- Added the player to `PokerodReelEvent` so you know who is doing the reeling.
### MoLang & Datapacks
- Added flows for:
- `forme_change`: Triggered when a Pokémon changes form in battle.
- `mega_evolution`: Triggered when a Pokémon mega evolves in battle. (Note: Third party mods are required for this feature currently)
- `zpower_used`: Triggered when a Pokémon uses a Z-Power move in battle. (Note: Third party mods are required for this feature currently)
- `terastallization`: Triggered when a Pokémon terastallizes in battle. (Note: Third party mods are required for this feature currently)
- `mega_evolution`: Triggered when a Pokémon mega evolves in battle. (Note: Third-party mods are required for this feature currently)
- `zpower_used`: Triggered when a Pokémon uses a Z-Power move in battle. (Note: Third-party mods are required for this feature currently)
- `terastallization`: Triggered when a Pokémon terastallizes in battle. (Note: Third-party mods are required for this feature currently)
- `battle_fainted`: Triggered when a Pokémon faints in battle.
- `battle_fled`: Triggered when a Player flees from battle.
- `battle_fled`: Triggered when a player flees from battle.
- `battle_started_pre`: Triggered when a battle starts. Cancelable!
- `battle_started_post`: Triggered when a battle starts.
- `apricorn_harvested`: Triggered when an apricorn is harvested.
- `apricorn_harvested`: Triggered when an Apricorn is harvested.
- `thrown_pokeball_hit`: Triggered when a thrown Pokéball hits a Pokémon.
- `level_up`: Triggered when a Pokémon levels up.
- `pokemon_fainted`: Triggered when a Pokémon faints.
- `pokemon_gained`: Triggered when a Player gains a Pokémon.
- Added molang functions:
- `pokemon_gained`: Triggered when a player gains a Pokémon.
- Added MoLang functions:
- For Pokémon:
- `pokemon.apply(PokemonProperties)`: Applies the given properties to the Pokémon.
- `pokemon.owner`: Returns the owner of the Pokémon or 0.0 if there is no owner or they are not online.
- For all entities:
- `entity.is_standing_on_blocks(depth, blocks...)`: Returns whether the specified entity is standing on a specific block or set of blocks. Example usage: `q.is_standing_on_blocks(2, minecraft:sand)`
- Added NPC field:
- `hideNameTag`: Hides the name tag of the NPC.
- Added `baseScale` property to NPCs.
- Added MoLang particle queries for getting distance to targeted entities.
## [1.6.0 - The Record Catch Update (December 25th, 2024)](#1-6-0)
#### "Now that there's a fishing mechanic, the mod is actually good!"
@@ -1985,5 +2129,4 @@ Thank you so much to all of our community translators that bring the mod to the
- Added species, ability, and move translations for `ko_ko`, `jp_jp`, `fr_fr`, `es_es`, `it_it`, and `zh_cn`.
## [1.0.0 (November 12th, 2022)](#1-0-0)
- Initial release.
- Initial release.
@@ -15,7 +15,11 @@ import org.joml.Vector3f;
import java.util.function.Function;
public interface Rollable {
//The directions specified by all of the vectors in this class are from the perspective
//of an observer looking at the front of the player model
//These vectors aren't actually accurate, since "forward" can be any of +x -x +z -z depending on the rotation about
//the world-Y axis of the player
Vector3f FORWARDS = new Vector3f(0, 0, 1);
Vector3f LEFT = new Vector3f(1, 0, 0);
Vector3f UP = new Vector3f(0, 1, 0);
@@ -0,0 +1,66 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.mixin;
import com.cobblemon.mod.common.client.render.player.MountedPlayerRenderer;
import com.cobblemon.mod.common.entity.pokemon.PokemonEntity;
import net.minecraft.client.model.HumanoidModel;
import net.minecraft.client.model.geom.ModelPart;
import net.minecraft.client.player.AbstractClientPlayer;
import net.minecraft.world.entity.Entity;
import net.minecraft.world.entity.LivingEntity;
import org.spongepowered.asm.mixin.Final;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Shadow;
import org.spongepowered.asm.mixin.Unique;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
import java.util.HashMap;
@Mixin(HumanoidModel.class)
public class HumanoidModelMixin {
@Unique HashMap<String, ModelPart> relevantPartsByName = new HashMap<>();
@Shadow @Final
public ModelPart head;
@Shadow @Final
public ModelPart rightArm;
@Shadow @Final
public ModelPart leftArm;
@Shadow @Final
public ModelPart rightLeg;
@Shadow @Final
public ModelPart leftLeg;
@Inject(method = "setupAnim*", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/model/geom/ModelPart;copyFrom(Lnet/minecraft/client/model/geom/ModelPart;)V", shift = At.Shift.BEFORE))
public void cobblemon$animateRiders(
LivingEntity entity,
float limbSwing,
float limbSwingAmount,
float ageInTicks,
float netHeadYaw,
float headPitch,
CallbackInfo ci
) {
if (relevantPartsByName.isEmpty()) {
relevantPartsByName.put("arm_left", leftArm);
relevantPartsByName.put("arm_right", rightArm);
relevantPartsByName.put("leg_left", leftLeg);
relevantPartsByName.put("leg_right", rightLeg);
relevantPartsByName.put("head", head);
}
Entity vehicle = entity.getVehicle();
if (vehicle instanceof PokemonEntity && entity instanceof AbstractClientPlayer) {
MountedPlayerRenderer.INSTANCE.animate((PokemonEntity) vehicle, (AbstractClientPlayer) entity, relevantPartsByName, netHeadYaw, headPitch, ageInTicks, limbSwing, limbSwingAmount);
}
}
}
@@ -16,6 +16,7 @@ import com.cobblemon.mod.common.api.events.item.LeftoversCreatedEvent;
import com.cobblemon.mod.common.api.pokemon.PokemonSpecies;
import com.cobblemon.mod.common.api.riding.Rideable;
import com.cobblemon.mod.common.api.storage.party.PartyStore;
import com.cobblemon.mod.common.api.storage.party.PlayerPartyStore;
import com.cobblemon.mod.common.api.tags.CobblemonItemTags;
import com.cobblemon.mod.common.entity.pokemon.PokemonEntity;
import com.cobblemon.mod.common.pokedex.scanner.PokedexEntityData;
@@ -189,10 +190,10 @@ public abstract class PlayerMixin extends LivingEntity implements Rollable, Scan
@Override @Nullable
public PokedexEntityData resolvePokemonScan() {
if(CompoundTagUtilities.isShoulderPokemon(this.getShoulderEntityRight())){
if (CompoundTagUtilities.isShoulderPokemon(this.getShoulderEntityRight())){
return getDataFromShoulderPokemon(this.getShoulderEntityRight());
}
if(CompoundTagUtilities.isShoulderPokemon(this.getShoulderEntityLeft())){
if (CompoundTagUtilities.isShoulderPokemon(this.getShoulderEntityLeft())){
return getDataFromShoulderPokemon(this.getShoulderEntityLeft());
}
return null;
@@ -201,30 +202,34 @@ public abstract class PlayerMixin extends LivingEntity implements Rollable, Scan
@Nullable @Unique
private PokedexEntityData getDataFromShoulderPokemon(CompoundTag shoulderTag) {
CompoundTag pokemonTag = shoulderTag.getCompound(DataKeys.POKEMON);
if(pokemonTag.isEmpty()) return null;
if (pokemonTag.isEmpty()) return null;
Species species = PokemonSpecies.INSTANCE.getByIdentifier(ResourceLocation.parse(pokemonTag.getString(DataKeys.POKEMON_SPECIES_IDENTIFIER)));
if(species == null) return null;
if (species == null) return null;
String formId = pokemonTag.getString(DataKeys.POKEMON_FORM_ID);
FormData form = species.getStandardForm();
List<FormData> formList = species.getForms().stream().filter(it -> it.formOnlyShowdownId().equals(formId)).toList();
if(!formList.isEmpty()) form = formList.getFirst();
if(form == null) return null;
if (!formList.isEmpty()) form = formList.getFirst();
if (form == null) return null;
String genderString = pokemonTag.getString(DataKeys.POKEMON_GENDER);
if(genderString.isEmpty()) return null;
if (genderString.isEmpty()) return null;
Gender gender = Gender.valueOf(genderString);
boolean shiny = pokemonTag.getBoolean(DataKeys.POKEMON_SHINY);
int level = pokemonTag.getInt(DataKeys.POKEMON_LEVEL);
Set<String> aspects = shoulderTag.getList(DataKeys.SHOULDER_ASPECTS, Tag.TAG_STRING).stream().map(Tag::getAsString).collect(Collectors.toSet());
return new PokedexEntityData(
species,
form,
gender,
aspects,
shiny,
level,
this.getUUID()
);
Pokemon pokemon = new Pokemon();
if (level().isClientSide) {
pokemon.setSpecies(species);
pokemon.setForm(form);
pokemon.setGender(gender);
pokemon.setShiny(shiny);
pokemon.setLevel(level);
pokemon.setForcedAspects(aspects);
} else {
PlayerPartyStore party = Cobblemon.INSTANCE.getStorage().getParty(this.getUUID(), this.registryAccess());
pokemon = party.get(shoulderTag.getUUID(DataKeys.SHOULDER_UUID));
}
return new PokedexEntityData(pokemon, null);
}
@Override
@@ -9,12 +9,27 @@
package com.cobblemon.mod.common.mixin;
import com.cobblemon.mod.common.Rollable;
import com.cobblemon.mod.common.api.riding.Rideable;
import com.cobblemon.mod.common.api.riding.Seat;
import com.cobblemon.mod.common.client.entity.PokemonClientDelegate;
import com.cobblemon.mod.common.client.render.ClientPlayerIcon;
import com.cobblemon.mod.common.client.render.player.PlayerRendererHook;
import com.llamalad7.mixinextras.injector.wrapmethod.WrapMethod;
import com.llamalad7.mixinextras.injector.wrapoperation.Operation;
import com.cobblemon.mod.common.client.render.MatrixWrapper;
import com.cobblemon.mod.common.entity.pokemon.PokemonEntity;
import com.mojang.authlib.minecraft.client.MinecraftClient;
import com.mojang.blaze3d.vertex.PoseStack;
import net.fabricmc.loader.impl.lib.sat4j.core.Vec;
import net.minecraft.client.Minecraft;
import net.minecraft.client.player.AbstractClientPlayer;
import net.minecraft.client.renderer.GameRenderer;
import net.minecraft.client.renderer.MultiBufferSource;
import net.minecraft.client.renderer.entity.player.PlayerRenderer;
import net.minecraft.util.Mth;
import net.minecraft.world.phys.Vec3;
import org.joml.Matrix4f;
import org.joml.Vector3d;
import org.joml.Vector3f;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
@@ -25,31 +40,12 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
public class PlayerRendererMixin {
private static boolean disableRollableRenderDebug = false;
@Inject(method = "render", at = @At(value = "HEAD"))
public void renderPlayer$head(AbstractClientPlayer player, float f, float g, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, CallbackInfo ci) {
if(player instanceof Rollable && !disableRollableRenderDebug) {
Rollable rollable = (Rollable) player;
if(rollable.shouldRoll()){
poseStack.pushPose();
Matrix4f transformationMatrix = new Matrix4f();
Vector3f center = new Vector3f(0, player.getBbHeight()/2, 0);
transformationMatrix.translate(center);
@WrapMethod(method = "render")
public void applyRotation(AbstractClientPlayer player, float entityYaw, float partialTicks, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, Operation<Integer> original) {
PlayerRendererHook.INSTANCE.before(player, entityYaw, partialTicks, poseStack, multiBufferSource, i);
//transformationMatrix.rotate(180f.toRadians() - (rollable.getYaw()).toRadians(), rollable.getUpVector(), transformationMatrix);
transformationMatrix.rotate((float) Math.toRadians(-rollable.getPitch()), rollable.getLeftVector(), transformationMatrix);
transformationMatrix.rotate((float) Math.toRadians(-rollable.getRoll()), rollable.getForwardVector(), transformationMatrix);
original.call(player, entityYaw, partialTicks, poseStack, multiBufferSource, i);
transformationMatrix.translate(center.negate(new Vector3f()));
poseStack.mulPose(transformationMatrix);
}
}
}
@Inject(method = "render", at = @At(value = "TAIL"))
public void renderPlayer$tail(AbstractClientPlayer player, float f, float g, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, CallbackInfo ci) {
ClientPlayerIcon.Companion.onRenderPlayer(player);
if(player instanceof Rollable && !disableRollableRenderDebug && ((Rollable) player).shouldRoll()){
poseStack.popPose();
}
}
}
@@ -14,6 +14,7 @@ import com.cobblemon.mod.common.api.SeasonResolver
import com.cobblemon.mod.common.api.data.DataProvider
import com.cobblemon.mod.common.api.drop.CommandDropEntry
import com.cobblemon.mod.common.api.drop.DropEntry
import com.cobblemon.mod.common.api.drop.EvolutionItemDropEntry
import com.cobblemon.mod.common.api.drop.ItemDropEntry
import com.cobblemon.mod.common.api.events.CobblemonEvents
import com.cobblemon.mod.common.api.events.CobblemonEvents.DATA_SYNCHRONIZED
@@ -200,6 +201,7 @@ object Cobblemon {
DropEntry.register("command", CommandDropEntry::class.java)
DropEntry.register("item", ItemDropEntry::class.java, isDefault = true)
DropEntry.register("evolution", EvolutionItemDropEntry::class.java)
ExperienceGroups.registerDefaults()
CaptureCalculators.registerDefaults()
@@ -218,7 +220,7 @@ object Cobblemon {
storage.onPlayerDataSync(it)
playerDataManager.syncAllToPlayer(it)
starterHandler.handleJoin(it)
ServerSettingsPacket(this.config.preventCompletePartyDeposit, this.config.displayEntityLevelLabel, this.config.displayEntityNameLabel, this.config.maxPokemonLevel).sendToPlayer(it)
ServerSettingsPacket(this.config.preventCompletePartyDeposit, this.config.displayEntityLevelLabel, this.config.displayEntityNameLabel, this.config.maxPokemonLevel, this.config.maxPokemonFriendship, this.config.maxDynamaxLevel).sendToPlayer(it)
}
PlatformEvents.SERVER_PLAYER_LOGOUT.subscribe {
PCLinkManager.removeLink(it.player.uuid)
@@ -256,6 +258,8 @@ object Cobblemon {
// Lowest priority because this applies after luxury ball bonus as of gen 4
CobblemonEvents.FRIENDSHIP_UPDATED.subscribe(Priority.LOWEST) { event ->
var increment = (event.newFriendship - event.pokemon.friendship).toFloat()
if (increment <= 0) //these affects are only meant to affect positive gains
return@subscribe
// Our Luxury ball spec is diff from official, but we will still assume these stack
if (event.pokemon.heldItemNoCopy().`is`(CobblemonItemTags.IS_FRIENDSHIP_BOOSTER)) {
increment += increment * 0.5F
@@ -317,6 +317,7 @@ object CobblemonItems : PlatformRegistry<Registry<Item>, ResourceKey<Registry<It
@JvmField val RAZOR_FANG = noSettingsItem("razor_fang")
@JvmField val AUSPICIOUS_ARMOR = heldItem("auspicious_armor")
@JvmField val MALICIOUS_ARMOR = heldItem("malicious_armor")
@JvmField val SHELL_HELMET = heldItem("shell_helmet")
private val berries = mutableMapOf<ResourceLocation, BerryItem>()
// Plants
@@ -55,6 +55,7 @@ class ActiveDialogue(var playerEntity: ServerPlayer, var dialogueReference: Dial
)
dialogueReference.initializationAction.invoke(this)
setPage(currentPage)
if (!completion.isDone) {
val packet = DialogueOpenedPacket(this, true)
@@ -52,6 +52,6 @@ object DialogueManager {
fun stopDialogue(playerEntity: ServerPlayer) {
val activeDialogue = playerEntity.activeDialogue ?: return
DialogueClosedPacket(activeDialogue.dialogueId).sendToPlayer(playerEntity)
activeDialogues.remove(activeDialogue.dialogueId)
activeDialogues.remove(playerEntity.uuid)
}
}
@@ -8,6 +8,7 @@
package com.cobblemon.mod.common.api.drop
import com.cobblemon.mod.common.pokemon.Pokemon
import net.minecraft.server.level.ServerLevel
import net.minecraft.server.level.ServerPlayer
import net.minecraft.world.entity.LivingEntity
@@ -40,17 +41,23 @@ interface DropEntry {
* to be dropped.
*/
val percentage: Float
/**
* The drop's quantity when doing selection from the [DropTable]. See the drop table documentation for more on how
* this works.
*/
val quantity: Int
/**
* The maximum number of times the item can be selected drop the [DropTable]. In most cases this will just be 1,
* meaning that the item, once picked, cannot be picked again. A larger value will allow the same [DropEntry] from
* appearing multiple times in a drop action.
*/
val maxSelectableTimes: Int
/** Whether this is considered a possible drop at the moment or not */
fun canDrop(pokemon: Pokemon?): Boolean = true
/** The logic to use to actually drop the thing. */
fun drop(entity: LivingEntity?, world: ServerLevel, pos: Vec3, player: ServerPlayer?)
}
@@ -11,11 +11,13 @@ package com.cobblemon.mod.common.api.drop
import com.cobblemon.mod.common.api.events.CobblemonEvents.LOOT_DROPPED
import com.cobblemon.mod.common.api.events.drops.LootDroppedEvent
import com.cobblemon.mod.common.entity.pokemon.PokemonEntity
import com.cobblemon.mod.common.pokemon.Pokemon
import kotlin.random.Random
import net.minecraft.network.RegistryFriendlyByteBuf
import net.minecraft.server.level.ServerLevel
import net.minecraft.server.level.ServerPlayer
import net.minecraft.world.entity.LivingEntity
import net.minecraft.world.item.ItemStack
import net.minecraft.world.phys.Vec3
/**
@@ -45,9 +47,11 @@ class DropTable {
* Gets a drop list from this table as a list of [DropEntry]. You can specify the range of drop quantity totals
* that will be possible, or if you leave it blank it will use [DropTable.amount].
*/
fun getDrops(amount: IntRange = this.amount): List<DropEntry> {
fun getDrops(amount: IntRange = this.amount, pokemon: Pokemon? = null): List<DropEntry> {
val chosenAmount = amount.random()
val possibleDrops = entries.filter { it.quantity <= chosenAmount }.toMutableList()
val possibleDrops = entries.filter {
it.quantity <= chosenAmount && it.canDrop(pokemon)
}.toMutableList()
if (possibleDrops.isEmpty()) {
return emptyList()
@@ -87,11 +91,10 @@ class DropTable {
world: ServerLevel,
pos: Vec3,
player: ServerPlayer?,
amount: IntRange = this.amount
amount: IntRange = this.amount,
pokemon: Pokemon? = null,
) {
val drops = getDrops(amount).toMutableList()
val heldItem = (entity as PokemonEntity).pokemon.heldItemNoCopy()
if (!heldItem.isEmpty) entity.spawnAtLocation(heldItem.item)
val drops = getDrops(amount, pokemon).toMutableList()
LOOT_DROPPED.postThen(
event = LootDroppedEvent(this, player, entity, drops),
ifSucceeded = { it.drops.forEach { it.drop(entity, world, pos, player) } }
@@ -0,0 +1,18 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.api.drop
import com.cobblemon.mod.common.api.pokemon.evolution.requirement.EvolutionRequirement
import com.cobblemon.mod.common.pokemon.Pokemon
class EvolutionItemDropEntry : ItemDropEntry() {
val requirements: MutableSet<EvolutionRequirement> = mutableSetOf()
override fun canDrop(pokemon: Pokemon?): Boolean = pokemon != null && requirements.all { it.check(pokemon) }
}
@@ -18,19 +18,17 @@ import net.minecraft.server.level.ServerPlayer
import net.minecraft.world.entity.LivingEntity
data class PokemonScannedEvent(val player: ServerPlayer, val scannedPokemonEntityData: PokedexEntityData, val scannedEntity: ScannableEntity) {
val pokedexEntityData: PokedexEntityData
get() = scannedPokemonEntityData
val isOwned: Boolean
get() = scannedPokemonEntityData.ownerUUID == player.uuid
get() = scannedPokemonEntityData.pokemon.getOwnerUUID() == player.uuid
val context = mutableMapOf(
"player" to player.asMoLangValue(),
"pokemon" to scannedPokemonEntityData.struct,
"pokemon" to scannedPokemonEntityData.pokemon.struct,
"disguise" to (scannedPokemonEntityData.disguise?.struct ?: DoubleValue.ZERO),
"entity" to {
when (scannedEntity) {
is LivingEntity -> scannedEntity.asMostSpecificMoLangValue()
else -> DoubleValue(0.0)
else -> DoubleValue.ZERO
}
},
)
@@ -8,6 +8,7 @@
package com.cobblemon.mod.common.api.events.pokemon
import com.cobblemon.mod.common.Cobblemon
import com.cobblemon.mod.common.pokemon.Pokemon
/**
@@ -18,5 +19,11 @@ import com.cobblemon.mod.common.pokemon.Pokemon
*/
data class FriendshipUpdatedEvent(
val pokemon: Pokemon,
var newFriendship: Int
)
val newFriendshipInitial: Int
)
{
var newFriendship: Int = newFriendshipInitial
set(value) {
field = value.coerceIn(0, Cobblemon.config.maxPokemonFriendship)
}
}
@@ -17,16 +17,14 @@ import com.cobblemon.mod.common.api.pokedex.AbstractPokedexManager
import com.cobblemon.mod.common.api.pokedex.FormDexRecord
import com.cobblemon.mod.common.api.pokedex.PokedexEntryProgress
import com.cobblemon.mod.common.pokedex.scanner.PokedexEntityData
import com.cobblemon.mod.common.pokemon.Pokemon
import com.cobblemon.mod.common.util.getPlayer
import com.mojang.datafixers.util.Either
import java.util.UUID
/**
* Event that fires when a Pokémon's information is gained or updated in the Pokédex.
*/
sealed interface PokedexDataChangedEvent {
val dataSource: Either<PokedexEntityData, Pokemon>
val dataSource: PokedexEntityData
val knowledge: PokedexEntryProgress
val playerUUID: UUID
val record: FormDexRecord
@@ -37,22 +35,22 @@ sealed interface PokedexDataChangedEvent {
fun getContext(): MutableMap<String, MoValue> {
return mutableMapOf(
"player" to (playerUUID.getPlayer()?.asMoLangValue() ?: DoubleValue.ZERO),
"pokemon" to dataSource.map({ DoubleValue.ZERO }, { it.struct }),
"data" to dataSource.map({ it.struct }, { DoubleValue.ZERO }),
"pokemon" to dataSource.pokemon.struct,
"disguise" to (dataSource.disguise?.struct ?: DoubleValue.ZERO),
"knowledge" to StringValue(knowledge.name.lowercase()),
"pokedex" to pokedexManager.struct
)
}
class Pre(
override val dataSource: Either<PokedexEntityData, Pokemon>,
override val dataSource: PokedexEntityData,
override val knowledge: PokedexEntryProgress,
override val playerUUID: UUID,
override val record: FormDexRecord
) : PokedexDataChangedEvent, Cancelable()
class Post(
override val dataSource: Either<PokedexEntityData, Pokemon>,
override val dataSource: PokedexEntityData,
override val knowledge: PokedexEntryProgress,
override val playerUUID: UUID,
override val record: FormDexRecord
@@ -54,7 +54,15 @@ class BenchedMoves : Iterable<BenchedMove> {
}
}
fun add(benchedMove: BenchedMove) = doThenEmit { benchedMoves.add(benchedMove) }
fun add(benchedMove: BenchedMove): Boolean {
if (any { it.moveTemplate == benchedMove.moveTemplate }) {
return false
}
doThenEmit { benchedMoves.add(benchedMove) }
return true
}
fun addAll(benchedMoves: Iterable<BenchedMove>) = doThenEmit { this.benchedMoves.addAll(benchedMoves) }
fun clear() = doThenEmit { benchedMoves.clear() }
fun remove(benchedMove: BenchedMove) = doThenEmit { benchedMoves.remove(benchedMove) }
@@ -134,18 +134,21 @@ class MoveSet : Iterable<Move> {
return json
}
fun add(move: Move) {
fun add(move: Move): Boolean {
if (any { it.template == move.template }) {
return
return false
}
for (i in 0 until MOVE_COUNT) {
if (moves[i] == null) {
moves[i] = move
move.observable.subscribe { this.update() }
update()
return
return true
}
}
return false
}
fun update() {
@@ -57,6 +57,7 @@ class NPCClass {
var isInvulnerable = false
var isLeashable = true
var allowProjectileHits = true
var hideNameTag = false
// If you're adding stuff here, add it to NPCPreset and NPCClassAdapter too
@@ -97,6 +98,7 @@ class NPCClass {
buffer.writeBoolean(isInvulnerable)
buffer.writeBoolean(isLeashable)
buffer.writeBoolean(allowProjectileHits)
buffer.writeBoolean(hideNameTag)
}
fun decode(buffer: RegistryFriendlyByteBuf) {
@@ -148,5 +150,6 @@ class NPCClass {
isInvulnerable = buffer.readBoolean()
isLeashable = buffer.readBoolean()
allowProjectileHits = buffer.readBoolean()
hideNameTag = buffer.readBoolean()
}
}
@@ -37,6 +37,7 @@ class NPCPreset {
var isInvulnerable: Boolean? = null
var isLeashable: Boolean? = null
var allowProjectileHits: Boolean? = null
var hideNameTag: Boolean? = null
fun applyTo(npcClass: NPCClass) {
resourceIdentifier?.let { npcClass.resourceIdentifier = it }
@@ -63,5 +64,6 @@ class NPCPreset {
isInvulnerable?.let { npcClass.isInvulnerable = it }
isLeashable?.let { npcClass.isLeashable = it }
allowProjectileHits?.let { npcClass.allowProjectileHits = it }
hideNameTag?.let { npcClass.hideNameTag = it }
}
}
@@ -78,6 +78,7 @@ any number of presets and the properties of those presets will be merged into th
"skill": 5,
"autoHealParty": true,
"randomizePartyOrder": true,
"hideNameTag": false,
"party": {
"type": "simple",
"pokemon": [
@@ -411,4 +412,7 @@ Pokémon in the party.
### ai
The AI property is an array of brain configurations. This is used to configure the behaviours of the NPC. See
the documentation for brain configurations at [AI Configuration](../ai/config/README.md).
the documentation for brain configurations at [AI Configuration](../ai/config/README.md).
### hideNameTag
Whether the NPC's nametag should be hidden or not. Defaults to false.
@@ -202,6 +202,8 @@ object PokeBalls : JsonDataRegistry<PokeBall> {
// Luxury ball effect, low priority as it must be triggered before soothe bell as of gen 4
CobblemonEvents.FRIENDSHIP_UPDATED.subscribe(priority = Priority.LOW) { event ->
var increment = (event.newFriendship - event.pokemon.friendship).toFloat()
if (increment <= 0) //these affects are only meant to affect positive gains
return@subscribe
if (increment <= 1F) {
event.pokemon.caughtBall.effects.filterIsInstance<FriendshipEarningBoostEffect>()
.forEach { increment *= it.multiplier }
@@ -42,7 +42,10 @@ class BaseStatModifier(
override fun behavior(thrower: LivingEntity, pokemon: Pokemon): CatchRateModifier.Behavior = CatchRateModifier.Behavior.MULTIPLY
override fun isValid(thrower: LivingEntity, pokemon: Pokemon): Boolean = pokemon.form.baseStats[this.stat] != null
override fun isValid(thrower: LivingEntity, pokemon: Pokemon): Boolean {
val valStat = pokemon.form.baseStats[this.stat] ?: return false
return comparator(valStat)
}
override fun modifyCatchRate(currentCatchRate: Float, thrower: LivingEntity, pokemon: Pokemon): Float = this.behavior(thrower, pokemon).mutator(currentCatchRate, this.value(thrower, pokemon))
@@ -96,15 +96,21 @@ abstract class AbstractPokedexManager {
}
fun getNewInformation(pokedexEntityData: PokedexEntityData): PokedexLearnedInformation {
val speciesRecord = getSpeciesRecord(pokedexEntityData.species.resourceIdentifier)
val speciesRecord = getSpeciesRecord(pokedexEntityData.getApparentSpecies().resourceIdentifier)
if (speciesRecord == null || speciesRecord.getKnowledge() == PokedexEntryProgress.NONE) {
return PokedexLearnedInformation.SPECIES
}
val formRecord = speciesRecord.getFormRecord(pokedexEntityData.form.name)
val formRecord = speciesRecord.getFormRecord(pokedexEntityData.getApparentForm().name)
if (formRecord == null || formRecord.knowledge == PokedexEntryProgress.NONE) {
return PokedexLearnedInformation.FORM
}
if (pokedexEntityData.aspects.any{ !speciesRecord.hasAspect(it) } || pokedexEntityData.gender !in formRecord.getGenders() || !formRecord.hasSeenShinyState(pokedexEntityData.shiny)) {
// Can't update aspects on a disguise
if (pokedexEntityData.disguise != null) {
return PokedexLearnedInformation.NONE
}
if (pokedexEntityData.pokemon.aspects.any { !speciesRecord.hasAspect(it) } || pokedexEntityData.pokemon.gender !in formRecord.getGenders() || !formRecord.hasSeenShinyState(pokedexEntityData.pokemon.shiny)) {
return PokedexLearnedInformation.VARIATION
}
return PokedexLearnedInformation.NONE
@@ -89,21 +89,15 @@ class FormDexRecord {
it.knowledge = knowledge
}
fun encountered(pokemon: Pokemon) {
if (wouldBeDifferent(pokemon, PokedexEntryProgress.ENCOUNTERED)) {
addInformation(pokemon, PokedexEntryProgress.ENCOUNTERED)
}
}
fun encountered(pokedexEntityData: PokedexEntityData) {
if (wouldBeDifferent(pokedexEntityData, PokedexEntryProgress.ENCOUNTERED)) {
addInformation(pokedexEntityData, PokedexEntryProgress.ENCOUNTERED)
}
}
fun caught(pokemon: Pokemon) {
if (wouldBeDifferent(pokemon, PokedexEntryProgress.CAUGHT)) {
addInformation(pokemon, PokedexEntryProgress.CAUGHT)
fun caught(pokedexEntityData: PokedexEntityData) {
if (wouldBeDifferent(pokedexEntityData, PokedexEntryProgress.CAUGHT)) {
addInformation(pokedexEntityData, PokedexEntryProgress.CAUGHT)
}
}
@@ -125,47 +119,18 @@ class FormDexRecord {
speciesDexRecord.onFormRecordUpdated(this)
}
private fun addInformation(pokemon: Pokemon, knowledge: PokedexEntryProgress) {
(speciesDexRecord.pokedexManager as? PokedexManager)?.let { pokedexManager ->
CobblemonEvents.POKEDEX_DATA_CHANGED_PRE.postThen(
PokedexDataChangedEvent.Pre(
Either.right(pokemon),
knowledge,
pokedexManager.uuid,
this
),
ifSucceeded = {
genders.add(pokemon.gender)
seenShinyStates.add(if (pokemon.shiny) "shiny" else "normal")
if (knowledge.ordinal > this.knowledge.ordinal) {
this.knowledge = knowledge
}
speciesDexRecord.addInformation(pokemon, knowledge)
speciesDexRecord.onFormRecordUpdated(this)
CobblemonEvents.POKEDEX_DATA_CHANGED_POST.post(
PokedexDataChangedEvent.Post(
Either.right(pokemon),
knowledge,
pokedexManager.uuid,
this
)
)
})
}
}
private fun addInformation(pokedexEntityData: PokedexEntityData, knowledge: PokedexEntryProgress) {
(speciesDexRecord.pokedexManager as? PokedexManager)?.let { pokedexManager ->
CobblemonEvents.POKEDEX_DATA_CHANGED_PRE.postThen(
PokedexDataChangedEvent.Pre(
Either.left(pokedexEntityData),
knowledge,
pokedexManager.uuid,
this
pokedexEntityData,
knowledge,
pokedexManager.uuid,
this
),
ifSucceeded = {
genders.add(pokedexEntityData.gender)
seenShinyStates.add(if (pokedexEntityData.shiny) "shiny" else "normal")
genders.add(pokedexEntityData.pokemon.gender)
seenShinyStates.add(if (pokedexEntityData.pokemon.shiny) "shiny" else "normal")
if (knowledge.ordinal > this.knowledge.ordinal) {
this.knowledge = knowledge
}
@@ -173,10 +138,10 @@ class FormDexRecord {
speciesDexRecord.onFormRecordUpdated(this)
CobblemonEvents.POKEDEX_DATA_CHANGED_POST.post(
PokedexDataChangedEvent.Post(
Either.left(pokedexEntityData),
knowledge,
pokedexManager.uuid,
this
pokedexEntityData,
knowledge,
pokedexManager.uuid,
this
)
)
}
@@ -184,19 +149,10 @@ class FormDexRecord {
}
}
/** Returns whether the given [Pokemon] and [knowledge] would add new information to the Pokédex.*/
fun wouldBeDifferent(pokemon: Pokemon, knowledge: PokedexEntryProgress): Boolean {
return pokemon.gender !in genders
|| (pokemon.shiny && "shiny" !in seenShinyStates)
|| (!pokemon.shiny && "normal" !in seenShinyStates)
|| knowledge.ordinal > this.knowledge.ordinal
|| speciesDexRecord.wouldBeDifferent(pokemon)
}
fun wouldBeDifferent(pokedexEntityData: PokedexEntityData, knowledge: PokedexEntryProgress): Boolean {
return pokedexEntityData.gender !in genders
|| (pokedexEntityData.shiny && "shiny" !in seenShinyStates)
|| (!pokedexEntityData.shiny && "normal" !in seenShinyStates)
return pokedexEntityData.pokemon.gender !in genders
|| (pokedexEntityData.pokemon.shiny && "shiny" !in seenShinyStates)
|| (!pokedexEntityData.pokemon.shiny && "normal" !in seenShinyStates)
|| knowledge.ordinal > this.knowledge.ordinal
|| speciesDexRecord.wouldBeDifferent(pokedexEntityData)
}
@@ -30,19 +30,19 @@ class PokedexManager(
fun encounter(pokemon: Pokemon) {
val speciesId = pokemon.species.resourceIdentifier
val formName = pokemon.form.name
getOrCreateSpeciesRecord(speciesId).getOrCreateFormRecord(formName).encountered(pokemon)
getOrCreateSpeciesRecord(speciesId).getOrCreateFormRecord(formName).encountered(PokedexEntityData(pokemon = pokemon, disguise = null))
}
fun encounter(pokedexEntityData: PokedexEntityData) {
val speciesId = pokedexEntityData.species.resourceIdentifier
val formName = pokedexEntityData.form.name
val speciesId = pokedexEntityData.getApparentSpecies().resourceIdentifier
val formName = pokedexEntityData.getApparentForm().name
getOrCreateSpeciesRecord(speciesId).getOrCreateFormRecord(formName).encountered(pokedexEntityData)
}
fun catch(pokemon: Pokemon) {
val speciesId = pokemon.species.resourceIdentifier
val formName = pokemon.form.name
getOrCreateSpeciesRecord(speciesId).getOrCreateFormRecord(formName).caught(pokemon)
getOrCreateSpeciesRecord(speciesId).getOrCreateFormRecord(formName).caught(PokedexEntityData(pokemon = pokemon, disguise = null))
}
override fun markDirty() {
@@ -97,7 +97,7 @@ class SpeciesDexRecord {
}
fun addInformation(pokedexEntityData: PokedexEntityData, knowledge: PokedexEntryProgress) {
aspects.addAll(pokedexEntityData.aspects)
aspects.addAll(pokedexEntityData.pokemon.aspects)
}
fun addAspects(addedAspects: Set<String>) {
@@ -107,7 +107,7 @@ class SpeciesDexRecord {
/** Returns true if the given Pokémon contains new information. Internal because it's only to be called from [FormDexRecord.wouldBeDifferent]. */
internal fun wouldBeDifferent(pokemon: Pokemon) = pokemon.aspects.any { it !in aspects }
internal fun wouldBeDifferent(pokedexEntityData: PokedexEntityData) = pokedexEntityData.aspects.any { it !in aspects }
internal fun wouldBeDifferent(pokedexEntityData: PokedexEntityData) = pokedexEntityData.pokemon.aspects.any { it !in aspects }
fun getOrCreateFormRecord(formName: String): FormDexRecord {
return formRecords.getOrPut(formName.lowercase()) {
@@ -468,6 +468,10 @@ open class PokemonProperties {
return this.commonMatches(pokemonEntity.pokemon) && this.customProperties.none { !it.matches(pokemonEntity) }
}
fun matches(properties: PokemonProperties): Boolean {
return properties.asString() == this.asString()
}
private fun commonMatches(pokemon: Pokemon): Boolean {
level?.takeIf { it != pokemon.level }?.let { return false }
shiny?.takeIf { it != pokemon.shiny }?.let { return false }
@@ -805,7 +809,7 @@ open class PokemonProperties {
private fun createAbility(id: String, form: FormData): Ability? {
val ability = Abilities.get(id) ?: return null
val potentialAbility = form.abilities.firstOrNull { potential -> potential.template == ability } ?: return ability.create(true)
return potentialAbility.template.create(false)
return potentialAbility.template.create(false, potentialAbility.priority)
}
}
@@ -13,6 +13,7 @@ import com.cobblemon.mod.common.CobblemonItems
import com.cobblemon.mod.common.CobblemonSounds
import com.cobblemon.mod.common.advancement.CobblemonCriteria
import com.cobblemon.mod.common.advancement.criterion.EvolvePokemonContext
import com.cobblemon.mod.common.api.drop.DropTable
import com.cobblemon.mod.common.api.events.CobblemonEvents
import com.cobblemon.mod.common.api.events.pokemon.PokemonGainedEvent
import com.cobblemon.mod.common.api.events.pokemon.evolution.EvolutionCompleteEvent
@@ -32,9 +33,8 @@ import com.cobblemon.mod.common.pokemon.evolution.variants.LevelUpEvolution
import com.cobblemon.mod.common.pokemon.evolution.variants.TradeEvolution
import com.cobblemon.mod.common.util.lang
import com.cobblemon.mod.common.util.party
import net.minecraft.client.Minecraft
import net.minecraft.core.registries.BuiltInRegistries
import net.minecraft.network.protocol.game.ClientboundSoundPacket
import com.cobblemon.mod.common.world.gamerules.CobblemonGameRules
import net.minecraft.server.level.ServerLevel
import net.minecraft.sounds.SoundSource
import net.minecraft.world.entity.Entity
import net.minecraft.world.item.ItemStack
@@ -80,6 +80,11 @@ interface Evolution : EvolutionLike {
*/
val learnableMoves: MutableSet<MoveTemplate>
/**
* The items that will drop once the evolution finishes.
*/
val drops: DropTable
/**
* Checks if the given [Pokemon] passes all the conditions and is ready to evolve.
*
@@ -100,9 +105,6 @@ interface Evolution : EvolutionLike {
* @param pokemon The [Pokemon] being evolved.
*/
fun evolve(pokemon: Pokemon): Boolean {
if (this.consumeHeldItem) {
pokemon.swapHeldItem(ItemStack.EMPTY)
}
if (this.optional) {
// All the networking is handled under the hood, see EvolutionController.
return pokemon.evolutionProxy.server().add(this)
@@ -198,19 +200,41 @@ interface Evolution : EvolutionLike {
val movesToLearn = previousSpeciesLearnableMoves + this.learnableMoves
movesToLearn.forEach { move ->
if (pokemon.moveSet.hasSpace()) {
pokemon.moveSet.add(move.create())
} else {
pokemon.benchedMoves.add(BenchedMove(move, 0))
}
val couldAddMove =
if (pokemon.moveSet.hasSpace()) {
pokemon.moveSet.add(move.create())
} else {
pokemon.benchedMoves.add(BenchedMove(move, 0))
}
pokemon.getOwnerPlayer()?.sendSystemMessage(lang("experience.learned_move", pokemon.getDisplayName(), move.displayName))
val previousSpeciesKnewMove = previousSpeciesLearnableMoves.any { move.name == it.name }
if (couldAddMove && !previousSpeciesKnewMove) {
pokemon.getOwnerPlayer()?.sendSystemMessage(lang("experience.learned_move", pokemon.getDisplayName(), move.displayName))
}
}
// we want to instantly tick for example you might only evolve your Bulbasaur at level 34 so Venusaur should be immediately available
pokemon.evolutions.filterIsInstance<PassiveEvolution>().forEach { evolution -> evolution.attemptEvolution(pokemon) }
pokemon.lockedEvolutions.filterIsInstance<PassiveEvolution>().forEach { evolution -> evolution.attemptEvolution(pokemon) }
this.shed(pokemon)
if (this.consumeHeldItem) {
pokemon.swapHeldItem(ItemStack.EMPTY)
}
val ownerPlayer = pokemon.getOwnerPlayer()
if (ownerPlayer != null && ownerPlayer.level().gameRules.getBoolean(CobblemonGameRules.DO_POKEMON_LOOT)) {
drops.drop(
pokemon.entity,
ownerPlayer.level() as ServerLevel,
pokemon.entity?.position() ?: ownerPlayer.position(),
ownerPlayer,
pokemon = pokemon
)
}
CobblemonEvents.EVOLUTION_COMPLETE.post(EvolutionCompleteEvent(pokemon, this))
CobblemonEvents.POKEMON_GAINED.post(PokemonGainedEvent(pokemon.getOwnerUUID()!!, pokemon))
}
@@ -218,4 +242,4 @@ interface Evolution : EvolutionLike {
fun applyTo(pokemon: Pokemon) {
result.apply(pokemon)
}
}
}
@@ -21,6 +21,12 @@ object CobblemonPokemonLabels {
*/
const val LEGENDARY = "legendary"
/**
* Represents a Pokémon who is typically banned or has restricted usage in competitive sanctions.
* For example usage see this [VGC](https://www.pokemon.com/us/pokemon-news/trainers-can-once-again-use-a-restricted-pokemon-in-ranked-battles-series-10-starting-august-1-2021) page.
*/
const val RESTRICTED = "restricted"
/**
* Represents a mythical Pokémon.
* In Cobblemon terms they do not exist since we do not share the concept of timed event only Pokémon but the official ones are still tagged.
@@ -28,14 +34,21 @@ object CobblemonPokemonLabels {
const val MYTHICAL = "mythical"
/**
* Represents Pokémon that originate from Ultra Space.
* Represents Pokémon that receive a boosted catch rate from the Beast Ball. (Due to Beast Boost)
* Does not include [thematically related](https://bulbapedia.bulbagarden.net/wiki/Ultra_Beast#Related_Pok%C3%A9mon) beasts.
*/
const val ULTRA_BEAST = "ultra_beast"
/**
* Represents the pseudo legendary Pokémon.
* Represents a Pokémon whose family could be derived from resurrecting a fossil.
*/
const val PSEUDO_LEGENDARY = "pseudo_legendary"
const val FOSSIL = "fossil"
/**
* Represents the "pseudo-legendary" Pokémon. (Slow-rate three-stage lines with a base stat total of 600)
* Term reference on this [Pokémon Center](https://www.pokemoncenter.com/search/powerhouse) page.
*/
const val POWERHOUSE = "powerhouse"
/**
* Represents a baby Pokémon, this is not just a first stage Pokémon species, it is also unable to breed.
@@ -52,52 +65,55 @@ object CobblemonPokemonLabels {
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
*/
const val REGIONAL_OF_KANTO = "kanto_regional"
const val KANTONIAN_FORM = "kantonian_form"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
* Source for adjectival form: [Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Johto#Trivia)
*/
const val JOHTONIAN_FORM = "johtonian_form"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
* Source for adjectival form:[Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Hoenn#Trivia)
*/
const val HOENNIAN_FORM = "hoennian_form"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
* Source for adjectival form:[Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Sinnoh#Trivia)
*/
const val SINNOHAN_FORM = "sinnohan_form"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
*/
const val REGIONAL_OF_JOHTO = "johto_regional"
const val UNOVAN_FORM = "unovan_form"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
*/
const val REGIONAL_OF_HOENN = "hoenn_regional"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
*/
const val REGIONAL_OF_SINNOH = "sinnoh_regional"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
*/
const val REGIONAL_OF_UNOVA = "unova_regional"
/**
* See [REGIONAL], this has no official regionals but it consists of the "base" form that comes from the region.
*/
const val REGIONAL_OF_KALOS = "kalos_regional"
const val KALOSIAN_FORM = "kalosian_form"
/**
* See [REGIONAL] and this [Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Regional_form#Alolan_Form) page.
*/
const val REGIONAL_OF_ALOLA = "alola_regional"
const val ALOLAN_FORM = "alolan_form"
/**
* See [REGIONAL] and this [Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Regional_form#Galarian_Form) page.
*/
const val REGIONAL_OF_GALAR = "galar_regional"
const val GALARIAN_FORM = "galarian_form"
/**
* See [REGIONAL] and this [Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Regional_form#Hisuian_Form) page.
*/
const val REGIONAL_OF_HISUI = "hisui_regional"
const val HISUIAN_FORM = "hisuian_form"
/**
* See [REGIONAL] and this [Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Regional_form#Paldean_Form) page.
*/
const val REGIONAL_OF_PALDEA = "paldea_regional"
const val PALDEAN_FORM = "paldean_form"
/**
* Represents a mega evolution.
@@ -124,7 +140,7 @@ object CobblemonPokemonLabels {
const val TOTEM = "totem"
/**
* Represents a Paradox species.
* Represents Pokémon that trigger the Booster Energy item (due to Protosynthesis/Quark Drive)
* For more information see the [Bulbapedia](https://bulbapedia.bulbagarden.net/wiki/Paradox_Pok%C3%A9mon) page.
*/
const val PARADOX = "paradox"
@@ -171,12 +187,24 @@ object CobblemonPokemonLabels {
*/
const val GENERATION_7 = "gen7"
/**
* The "official" designation for Pokémon from Gen 7 (Unknown) and not the Alola region
* This may also include forms of Pokémon that had been previously introduced
*/
const val GENERATION_7B = "gen7b"
/**
* Pokémon from the national Pokédex of 810 to 905
* This may also include forms of Pokémon that had been previously introduced
*/
const val GENERATION_8 = "gen8"
/**
* The "official" designation for Pokémon from Gen 8 (Hisui) and not the Galar region
* This may also include forms of Pokémon that had been previously introduced
*/
const val GENERATION_8A = "gen8a"
/**
* Pokémon from the national Pokédex from 906 to 1008
* This may also include forms of Pokémon that had been previously introduced
@@ -53,7 +53,7 @@ enum class Stats(override val identifier: ResourceLocation, override val display
fun getStat(statKey: String) = when(statKey.lowercase()) {
"hp" -> HP
"atk", "attack" -> ATTACK // Hyper Cutter states the full stat name "Attack"
"def", "defense" -> DEFENCE // Big Pecks states the full stat name "Defense"
"def", "defense", "defence" -> DEFENCE // Big Pecks states the full stat name "Defense"
"spa" -> SPECIAL_ATTACK
"spd" -> SPECIAL_DEFENCE
"spe", "speed" -> SPEED
@@ -14,9 +14,8 @@ import com.cobblemon.mod.common.api.molang.MoLangFunctions.setup
import com.cobblemon.mod.common.api.riding.controller.RideController
import com.cobblemon.mod.common.entity.pokemon.PokemonEntity
import com.cobblemon.mod.common.util.withQueryValue
import net.minecraft.ChatFormatting
import net.minecraft.network.chat.Component
import net.minecraft.resources.ResourceLocation
import net.minecraft.world.entity.LivingEntity
import net.minecraft.world.entity.player.Player
import net.minecraft.world.phys.Vec2
import net.minecraft.world.phys.Vec3
@@ -24,6 +23,7 @@ import net.minecraft.world.phys.Vec3
data class RidingManager(val entity: PokemonEntity) {
var lastSpeed = 0F
var states: MutableMap<ResourceLocation, RidingState> = mutableMapOf()
var deltaRotation = Vec2.ZERO
val runtime: MoLangRuntime by lazy {
MoLangRuntime()
@@ -59,7 +59,7 @@ data class RidingManager(val entity: PokemonEntity) {
val pose = controller.pose(entity)
entity.entityData.set(PokemonEntity.POSE_TYPE, pose)
driver.displayClientMessage(Component.literal("Speed: ").withStyle { it.withColor(ChatFormatting.GREEN) }.append(Component.literal("$lastSpeed b/t")), true)
// driver.displayClientMessage(Component.literal("Speed: ").withStyle { it.withColor(ChatFormatting.GREEN) }.append(Component.literal("$lastSpeed b/t")), true)
}
fun speed(entity: PokemonEntity, driver: Player): Float {
@@ -69,8 +69,21 @@ data class RidingManager(val entity: PokemonEntity) {
}
fun controlledRotation(entity: PokemonEntity, driver: Player): Vec2 {
val controller = getController(entity) ?: return Vec2.ZERO
return controller.rotation(entity, driver)
val controller = getController(entity) ?: return entity.rotationVector
val previousRotation = entity.rotationVector
val rotation = controller.rotation(entity, driver)
this.deltaRotation = Vec2(rotation.x - previousRotation.x, rotation.y - previousRotation.y)
return rotation
}
fun clampPassengerRotation(entity: PokemonEntity, driver: LivingEntity) {
val controller = getController(entity) ?: return
return controller.clampPassengerRotation(entity, driver)
}
fun updatePassengerRotation(entity: PokemonEntity, driver: LivingEntity) {
val controller = getController(entity) ?: return
return controller.updatePassengerRotation(entity, driver)
}
fun velocity(entity: PokemonEntity, driver: Player, input: Vec3): Vec3 {
@@ -9,6 +9,7 @@
package com.cobblemon.mod.common.api.riding
import com.cobblemon.mod.common.api.net.Encodable
import com.cobblemon.mod.common.api.riding.controller.RidingAnimation
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.util.readString
import com.cobblemon.mod.common.util.writeString
@@ -19,9 +20,10 @@ import net.minecraft.world.phys.Vec3
* Seat Properties are responsible for the base information that would then be used to construct a Seat on an entity.
*/
data class Seat(
val locator: String = "seat1",
val locator: String = "seat_1",
val offset: Vec3 = Vec3.ZERO,
val poseOffsets: MutableList<SeatPoseOffset> = mutableListOf()
val poseOffsets: MutableList<SeatPoseOffset> = mutableListOf(),
val poseAnimations: MutableList<SeatPoseAnimations> = mutableListOf()
) : Encodable {
fun getOffset(poseType: PoseType) : Vec3 {
return poseOffsets.firstOrNull { poseType in it.poseTypes }?.offset ?: offset
@@ -33,6 +35,7 @@ data class Seat(
buffer.writeDouble(offset.y)
buffer.writeDouble(offset.z)
buffer.writeCollection(poseOffsets) { _, offset -> offset.encode(buffer) }
buffer.writeCollection(poseAnimations) { _, animations -> animations.encode(buffer) }
}
companion object {
@@ -40,7 +43,8 @@ data class Seat(
return Seat(
buffer.readString(),
Vec3(buffer.readDouble(), buffer.readDouble(), buffer.readDouble()),
buffer.readList { SeatPoseOffset.decode(buffer) }
buffer.readList { SeatPoseOffset.decode(buffer) },
buffer.readList { SeatPoseAnimations.decode(buffer) }
)
}
}
@@ -66,3 +70,22 @@ class SeatPoseOffset {
}
}
}
class SeatPoseAnimations {
val poseTypes = mutableSetOf<PoseType>()
var animations = mutableListOf<RidingAnimation>()
fun encode(buffer: RegistryFriendlyByteBuf) {
buffer.writeCollection(poseTypes) { _, poseType -> buffer.writeString(poseType.name) }
buffer.writeCollection(animations) { _, animation -> animation.encode(buffer) }
}
companion object {
fun decode(buffer: RegistryFriendlyByteBuf) : SeatPoseAnimations {
val animations = SeatPoseAnimations()
animations.poseTypes.addAll(buffer.readList { buffer.readString().let { PoseType.valueOf(it) } })
animations.animations = buffer.readList { RidingAnimation.decode(buffer) }
return animations
}
}
}
@@ -71,6 +71,12 @@ interface RideController : Encodable, Decodable {
*/
fun rotation(entity: PokemonEntity, driver: LivingEntity) : Vec2
fun clampPassengerRotation(entity: PokemonEntity, driver: LivingEntity) {}
fun updatePassengerRotation(entity: PokemonEntity, driver: LivingEntity) {
driver.yRot = entity.yRot
}
/**
* Manipulates the movement input as necessary by the controller. This is primarily used to apply limits
* to the types of movements. For instance, we can apply limits to any sort of sideways movement input, so that
@@ -0,0 +1,32 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.api.riding.controller
import com.cobblemon.mod.common.util.readString
import com.cobblemon.mod.common.util.writeString
import net.minecraft.network.RegistryFriendlyByteBuf
class RidingAnimation(
val fileName: String,
val animationName: String
) {
fun encode(buffer: RegistryFriendlyByteBuf) {
buffer.writeString(fileName)
buffer.writeString(animationName)
}
companion object {
fun decode(buffer: RegistryFriendlyByteBuf) : RidingAnimation {
return RidingAnimation(
buffer.readString(),
buffer.readString()
)
}
}
}
@@ -498,7 +498,7 @@ class LookAtDirection : ParticleCameraMode {
rotation.hamiltonProduct(Axis.ZP.rotationDegrees(particleAngle))
// Minecraft in 1.21 or 1.20.4 or something fucked with vertex draw order, and it flipped everything.
rotation.hamiltonProduct(Axis.YP.rotationDegrees(180F))
rotation.hamiltonProduct(Axis.XP.rotationDegrees(180F))
return rotation
}
@@ -10,15 +10,12 @@ package com.cobblemon.mod.common.api.spawning.fishing
import com.cobblemon.mod.common.Cobblemon
import com.cobblemon.mod.common.Cobblemon.LOGGER
import com.cobblemon.mod.common.api.Priority
import com.cobblemon.mod.common.api.abilities.Abilities
import com.cobblemon.mod.common.api.events.CobblemonEvents
import com.cobblemon.mod.common.api.events.fishing.BobberSpawnPokemonEvent
import com.cobblemon.mod.common.api.fishing.FishingBait
import com.cobblemon.mod.common.api.pokemon.Natures
import com.cobblemon.mod.common.api.pokemon.PokemonSpecies
import com.cobblemon.mod.common.api.pokemon.egg.EggGroup
import com.cobblemon.mod.common.api.pokemon.stats.Stat
import com.cobblemon.mod.common.api.pokemon.stats.Stats
import com.cobblemon.mod.common.api.spawning.SpawnBucket
import com.cobblemon.mod.common.api.spawning.SpawnCause
@@ -27,7 +24,6 @@ import com.cobblemon.mod.common.api.spawning.detail.PokemonSpawnDetail
import com.cobblemon.mod.common.api.spawning.detail.SpawnDetail
import com.cobblemon.mod.common.api.spawning.spawner.Spawner
import com.cobblemon.mod.common.api.types.ElementalTypes
import com.cobblemon.mod.common.api.types.tera.TeraTypes
import com.cobblemon.mod.common.entity.pokemon.PokemonEntity
import com.cobblemon.mod.common.item.interactive.PokerodItem
import com.cobblemon.mod.common.pokemon.Gender
@@ -129,8 +125,8 @@ class FishingSpawnCause(
}
fun alterFriendshipAttempt(pokemonEntity: PokemonEntity, effect: FishingBait.Effect) {
if (pokemonEntity.pokemon.friendship + effect.value > 255)
pokemonEntity.pokemon.setFriendship(255)
if (pokemonEntity.pokemon.friendship + effect.value > Cobblemon.config.maxPokemonFriendship)
pokemonEntity.pokemon.setFriendship(Cobblemon.config.maxPokemonFriendship)
else
pokemonEntity.pokemon.setFriendship(pokemonEntity.pokemon.friendship + effect.value.toInt())
}
@@ -46,16 +46,16 @@ open class JSONStoreAdapter(
override fun <E, T : PokemonStore<E>> load(file: File, storeClass: Class<out T>, uuid: UUID, registryAccess: RegistryAccess): T? {
return try {
val br = BufferedReader(FileReader(file))
val json = gson.fromJson<JsonObject>(br)
br.close()
val store = try {
storeClass.getConstructor(UUID::class.java, UUID::class.java).newInstance(uuid, uuid)
} catch (exception: NoSuchMethodException) {
storeClass.getConstructor(UUID::class.java).newInstance(uuid)
file.reader().use {
val json = gson.fromJson<JsonObject>(it)
val store = try {
storeClass.getConstructor(UUID::class.java, UUID::class.java).newInstance(uuid, uuid)
} catch (exception: NoSuchMethodException) {
storeClass.getConstructor(UUID::class.java).newInstance(uuid)
}
store.loadFromJSON(json, registryAccess)
store
}
store.loadFromJSON(json, registryAccess)
store
} catch (e: Exception) {
null
}
@@ -42,6 +42,7 @@ abstract class OneToOneFileStoreAdapter<S>(
) : FileStoreAdapter<S>, CobblemonAdapterParent<S>() {
abstract fun save(file: File, serialized: S)
abstract fun <E, T : PokemonStore<E>> load(file: File, storeClass: Class<out T>, uuid: UUID, registryAccess: RegistryAccess): T?
fun getFile(storeClass: Class<out PokemonStore<*>>, uuid: UUID): File {
val className = storeClass.simpleName.lowercase()
val subfolder1 = if (folderPerClass) "$className/" else ""
@@ -56,34 +57,54 @@ abstract class OneToOneFileStoreAdapter<S>(
override fun save(storeClass: Class<out PokemonStore<*>>, uuid: UUID, serialized: S) {
val file = getFile(storeClass, uuid)
val tempFile = File(file.absolutePath + ".temp")
val oldFile = File(file.absolutePath + ".old")
tempFile.createNewFile()
save(tempFile, serialized)
if (file.exists()) {
file.copyTo(oldFile, overwrite = true)
}
tempFile.copyTo(file, overwrite = true)
tempFile.delete()
}
override fun <E : StorePosition, T : PokemonStore<E>> provide(storeClass: Class<T>, uuid: UUID, registryAccess: RegistryAccess): T? {
val file = getFile(storeClass, uuid)
val tempFile = File(file.absolutePath + ".temp")
if (tempFile.exists()) {
try {
val tempLoaded = load(tempFile, storeClass, uuid, registryAccess)
if (tempLoaded != null) {
save(file, serialize(tempLoaded, registryAccess))
return tempLoaded
}
} finally {
tempFile.delete()
}
}
val oldFile = File(file.absolutePath + ".old")
return if (file.exists()) {
return if (file.exists() && file.length() > 0L) {
load(file, storeClass, uuid, registryAccess)
?: let {
LOGGER.error("Pokémon save file for ${storeClass.simpleName} ($uuid) was corrupted. A fresh file will be created.")
storeClass.getConstructor(UUID::class.java).newInstance(uuid)
file.delete()
if (oldFile.exists() && oldFile.length() > 0L) {
var result = load(oldFile, storeClass, uuid, registryAccess) ?: let {
LOGGER.error("Pokémon save file for ${storeClass.simpleName} ($uuid) was corrupted. A fresh file will be created.")
var result = storeClass.getConstructor(UUID::class.java).newInstance(uuid)
save(storeClass, uuid, serialize(result, registryAccess))
oldFile.delete()
return result
}
LOGGER.warn("Loading old Pokémon save file for ${storeClass.simpleName} ($uuid) due to corruption of current file.")
oldFile.copyTo(file, overwrite = true)
result
}
else {
storeClass.getConstructor(UUID::class.java).newInstance(uuid)
var result = storeClass.getConstructor(UUID::class.java).newInstance(uuid)
save(storeClass, uuid, serialize(result, registryAccess))
oldFile.delete()
result
}
}
} else {
file.delete()
if (oldFile.exists() && oldFile.length() > 0L) {
var result = load(oldFile, storeClass, uuid, registryAccess) ?: let {
oldFile.delete()
return null
}
oldFile.copyTo(file, overwrite = true)
result
}
null
}
}
@@ -27,15 +27,15 @@ import net.minecraft.world.entity.player.Player
* @since February 21, 2024
*/
class PlayerInstancedDataStoreManager {
open class PlayerInstancedDataStoreManager {
val factories = mutableMapOf<PlayerInstancedDataStoreType, PlayerInstancedDataFactory<*>>()
val saveTasks = mutableMapOf<PlayerInstancedDataStoreType, ScheduledTask>()
fun setFactory(factory: PlayerInstancedDataFactory<*>, dataType: PlayerInstancedDataStoreType) {
open fun setFactory(factory: PlayerInstancedDataFactory<*>, dataType: PlayerInstancedDataStoreType) {
factories[dataType] = factory
}
fun setup(server: MinecraftServer) {
open fun setup(server: MinecraftServer) {
factories.values.forEach {
it.setup(server)
}
@@ -57,62 +57,62 @@ class PlayerInstancedDataStoreManager {
.build()
}
fun get(playerId: UUID, dataType: PlayerInstancedDataStoreType): InstancedPlayerData {
open fun get(playerId: UUID, dataType: PlayerInstancedDataStoreType): InstancedPlayerData {
if (!factories.contains(dataType)) {
throw UnsupportedOperationException("No factory registered for $dataType")
}
return factories[dataType]!!.getForPlayer(playerId)
}
fun get(player: Player, dataType: PlayerInstancedDataStoreType): InstancedPlayerData {
open fun get(player: Player, dataType: PlayerInstancedDataStoreType): InstancedPlayerData {
return get(player.uuid, dataType)
}
fun saveAllOfOneType(dataType: PlayerInstancedDataStoreType) {
open fun saveAllOfOneType(dataType: PlayerInstancedDataStoreType) {
if (!factories.contains(dataType)) {
throw UnsupportedOperationException("No factory registered for $dataType")
}
return factories[dataType]!!.saveAll()
}
fun saveSingle(playerData: InstancedPlayerData, dataType: PlayerInstancedDataStoreType) {
open fun saveSingle(playerData: InstancedPlayerData, dataType: PlayerInstancedDataStoreType) {
if (!factories.contains(dataType)) {
throw UnsupportedOperationException("No factory registered for $dataType")
}
return factories[dataType]!!.saveSingle(playerData.uuid)
}
fun onPlayerDisconnect(player: ServerPlayer) {
open fun onPlayerDisconnect(player: ServerPlayer) {
factories.values.forEach {
it.onPlayerDisconnect(player)
}
}
fun syncAllToPlayer(player: ServerPlayer) {
open fun syncAllToPlayer(player: ServerPlayer) {
factories.values.forEach {
it.sendToPlayer(player)
}
}
fun saveAllStores() {
open fun saveAllStores() {
factories.values.forEach {
it.saveAll()
}
}
fun getGenericData(player: ServerPlayer): GeneralPlayerData {
open fun getGenericData(player: ServerPlayer): GeneralPlayerData {
return getGenericData(player.uuid)
}
fun getGenericData(playerId: UUID): GeneralPlayerData {
open fun getGenericData(playerId: UUID): GeneralPlayerData {
return get(playerId, PlayerInstancedDataStoreTypes.GENERAL) as GeneralPlayerData
}
fun getPokedexData(player: ServerPlayer): PokedexManager {
open fun getPokedexData(player: ServerPlayer): PokedexManager {
return getPokedexData(player.uuid)
}
fun getPokedexData(playerId: UUID): PokedexManager {
open fun getPokedexData(playerId: UUID): PokedexManager {
return get(playerId, PlayerInstancedDataStoreTypes.POKEDEX) as PokedexManager
}
}
@@ -8,10 +8,12 @@
package com.cobblemon.mod.common.api.storage.player.adapter
import com.cobblemon.mod.common.Cobblemon
import com.cobblemon.mod.common.api.storage.player.InstancedPlayerData
import com.cobblemon.mod.common.api.storage.player.PlayerInstancedDataStoreType
import net.minecraft.server.MinecraftServer
import net.minecraft.world.level.storage.LevelResource
import java.io.File
import java.nio.file.Path
import java.util.UUID
@@ -35,15 +37,70 @@ abstract class FileBasedPlayerDataStoreBackend<T : InstancedPlayerData>(
savePath = server.getWorldPath(LevelResource.PLAYER_DATA_DIR).parent
}
//TODO: Set file extension to be a field
fun getSubFile(uuid: UUID): String {
return if (useNestedStructure) {
"${uuid.toString().substring(0, 2)}/$uuid.$fileExt"
protected fun postSaveFileMoving(playerData: T) {
val tempFile = filePath(playerData.uuid, TEMPORARY_FILE_EXTENSION)
val oldFile = filePath(playerData.uuid, OLD_FILE_EXTENSION)
val file = filePath(playerData.uuid)
if (file.exists()) {
file.copyTo(oldFile, overwrite = true)
}
tempFile.copyTo(file, overwrite = true)
tempFile.delete()
}
protected fun loadWithFallback(uuid: UUID, loadFunction: (File) -> T): T {
val playerFile = filePath(uuid)
val playerFileOld = filePath(uuid, OLD_FILE_EXTENSION)
playerFile.parentFile.mkdirs()
val loadFallback: () -> T = {
playerFile.delete()
if (playerFileOld.exists() && playerFileOld.length() > 0L) {
try {
var result = loadFunction(playerFileOld)
playerFileOld.copyTo(playerFile)
Cobblemon.LOGGER.debug("Loaded .old {} for {}", subfolder, uuid)
result
} catch (e: Exception) {
Cobblemon.LOGGER.error("Failed to load .old $subfolder for $uuid due to ${e.message}. Data is lost")
Cobblemon.LOGGER.error(e)
playerFileOld.delete()
defaultData.invoke(uuid).also(::save)
}
}
else {
Cobblemon.LOGGER.error(".old File $subfolder for $uuid is corrupt or missing. Data is lost")
playerFileOld.delete()
defaultData.invoke(uuid).also(::save)
}
}
return if (playerFile.exists() && playerFile.length() > 0L) {
try {
loadFunction(playerFile)
}
catch (e: Exception) {
Cobblemon.LOGGER.warn("Failed to load $subfolder for $uuid due to ${e.message}")
Cobblemon.LOGGER.warn(e)
loadFallback()
}
} else {
"$uuid.$fileExt"
loadFallback()
}.also { it.initialize() }
}
@JvmOverloads
fun getSubFile(uuid: UUID, extension: String? = null): String {
return if (useNestedStructure) {
"${uuid.toString().substring(0, 2)}/$uuid.$fileExt${if (extension != null) ".$extension" else ""}"
} else {
"$uuid.$fileExt.${if (extension != null) ".$extension" else ""}"
}
}
fun filePath(uuid: UUID) = savePath.resolve("$subfolder/${getSubFile(uuid)}").toFile()
@JvmOverloads
fun filePath(uuid: UUID, extension: String? = null): File = savePath.resolve("$subfolder/${getSubFile(uuid, extension)}").toFile()
companion object {
const val OLD_FILE_EXTENSION = "old"
const val TEMPORARY_FILE_EXTENSION = "tmp"
}
}
@@ -28,29 +28,26 @@ abstract class JsonBackedPlayerDataStoreBackend<T : InstancedPlayerData>(
abstract val classToken: TypeToken<T>
override fun save(playerData: T) {
val file = filePath(playerData.uuid)
file.parentFile.mkdirs()
val pw = PrintWriter(filePath(playerData.uuid))
pw.write(gson.toJson(playerData))
pw.flush()
pw.close()
val fileTmp = filePath(playerData.uuid, TEMPORARY_FILE_EXTENSION)
fileTmp.parentFile.mkdirs()
fileTmp.printWriter().use { pw ->
pw.write(gson.toJson(playerData))
}
postSaveFileMoving(playerData)
}
override fun load(uuid: UUID): T {
val playerFile = filePath(uuid)
playerFile.parentFile.mkdirs()
return if (playerFile.exists() && playerFile.length() > 0L) {
gson.fromJson(BufferedReader(FileReader(playerFile)), classToken).also {
// Resolves old data that's missing new properties
val newProps = it::class.memberProperties.filterIsInstance<KMutableProperty<*>>().filter { member -> member.getter.call(it) == null }
if (newProps.isNotEmpty()) {
val defaultData = defaultData(uuid)
newProps.forEach { member -> member.setter.call(it, member.getter.call(defaultData)) }
return loadWithFallback(uuid) {
it.reader().use { reader ->
gson.fromJson(reader, classToken).also {
// Resolves old data that's missing new properties
val newProps = it::class.memberProperties.filterIsInstance<KMutableProperty<*>>().filter { member -> member.getter.call(it) == null }
if (newProps.isNotEmpty()) {
val defaultData = defaultData(uuid)
newProps.forEach { member -> member.setter.call(it, member.getter.call(defaultData)) }
}
}
}
} else {
defaultData.invoke(uuid).also(::save)
}.also { it.initialize() }
}
}
}
@@ -24,29 +24,24 @@ abstract class NbtBackedPlayerData<T : InstancedPlayerData>(
type: PlayerInstancedDataStoreType
) : FileBasedPlayerDataStoreBackend<T>(subfolder, type, "nbt") {
abstract val codec: Codec<T>
override fun save(playerData: T) {
val file = filePath(playerData.uuid)
file.parentFile.mkdirs()
val os = DataOutputStream(FileOutputStream(filePath(playerData.uuid)))
val encodeResult = NbtOps.INSTANCE.withEncoder(codec).apply(playerData)
NbtIo.write(encodeResult.result().get() as CompoundTag, os)
os.flush()
os.close()
val fileTmp = filePath(playerData.uuid, TEMPORARY_FILE_EXTENSION)
fileTmp.parentFile.mkdirs()
val encodeResult = codec.encodeStart(NbtOps.INSTANCE, playerData)
NbtIo.write(encodeResult.result().get() as CompoundTag, fileTmp.toPath())
postSaveFileMoving(playerData)
}
override fun load(uuid: UUID): T {
val playerFile = filePath(uuid)
playerFile.parentFile.mkdirs()
return if (playerFile.exists() && playerFile.length() > 0L) {
val input = NbtIo.read(playerFile.toPath())
val decodeResult = NbtOps.INSTANCE.withDecoder(codec).apply(input)
decodeResult.getPartialOrThrow {
return loadWithFallback(uuid) {
val input = NbtIo.read(it.toPath())
val decodeResult = codec.decode(NbtOps.INSTANCE, input)
decodeResult.getOrThrow {
Cobblemon.LOGGER.error("Error decoding $subfolder for player uuid $uuid")
Cobblemon.LOGGER.error(it)
throw UnsupportedOperationException()
}.first
} else {
defaultData.invoke(uuid).also(::save)
}.also { it.initialize() }
}
}
}
@@ -23,30 +23,72 @@ object CobblemonBlockTags {
@JvmField val ALL_HANGING_SIGNS = createTag("all_hanging_signs")
@JvmField val ALL_SIGNS = createTag("all_signs")
@JvmField val ANCIENT_CITY_BLOCKS = createTag("ancient_city_blocks")
@JvmField val APRICORN_LEAVES = createTag("apricorn_leaves")
@JvmField val APRICORN_LOGS = createTag("apricorn_logs")
@JvmField val APRICORN_SAPLINGS = createTag("apricorn_saplings")
@JvmField val APRICORNS = createTag("apricorns")
@JvmField val BERRY_WILD_SOIL = createTag("berry_wild_soil")
@JvmField val BERRY_SOIL = createTag("berry_soil")
@JvmField val BERRIES = createTag("berries")
@JvmField val BERRY_REPLACEABLE = createTag("berry_replaceable")
@JvmField val BERRY_SOIL = createTag("berry_soil")
@JvmField val BERRY_WILD_SOIL = createTag("berry_wild_soil")
@JvmField val BLACK_TUMBLESTONE_BRICKS = createTag("black_tumblestone_bricks")
@JvmField val BLACK_TUMBLESTONES = createTag("black_tumblestones")
@JvmField val BLUE_FLOWERS = createTag("blue_flowers")
@JvmField val CEILING_HANGING_SIGNS = createTag("ceiling_hanging_signs")
@JvmField val CROPS = createTag("crops")
@JvmField val DAWN_STONE_ORES = createTag("dawn_stone_ores")
@JvmField val DESERT_PYRAMID_BLOCKS = createTag("desert_pyramid_blocks")
@JvmField val DRIPSTONE_GROWABLE = createTag("dripstone_growable")
@JvmField val DRIPSTONE_REPLACEABLES = createTag("dripstone_replaceables")
@JvmField val DUSK_STONE_ORES = createTag("dusk_stone_ores")
@JvmField val END_CITY_BLOCKS = createTag("end_city_blocks")
@JvmField val EVOLUTION_STONE_BLOCKS = createTag("evolution_stone_blocks")
@JvmField val FIRE_STONE_ORES = createTag("fire_stone_ores")
@JvmField val FLOWERS = createTag("flowers")
@JvmField val FOSSIL_MACHINE_PARTS = createTag("fossil_machine_parts")
@JvmField val GEMSTONES = createTag("gemstones")
@JvmField val GILDED_CHESTS = createTag("gilded_chests")
@JvmField val GLAZED_TERRACOTTA_BLOCKS = createTag("glazed_terracotta_blocks")
@JvmField val ICE_STONE_ORES = createTag("ice_stone_ores")
@JvmField val JUNGLE_PYRAMID_BLOCKS = createTag("jungle_pyramid_blocks")
@JvmField val LEAF_STONE_ORES = createTag("leaf_stone_ores")
@JvmField val MACHINES = createTag("machines")
@JvmField val MANSION_BLOCKS = createTag("mansion_blocks")
@JvmField val MEDICINAL_LEEK_PLANTABLE = createTag("medicinal_leek_plantable")
@JvmField val MINTS = createTag("mints")
@JvmField val ROOTS_SPREADABLE = createTag("roots_spreadable")
@JvmField val SIGNS = createTag("signs")
@JvmField val SMALL_FLOWERS = createTag("small_flowers")
@JvmField val SEES_SKY = createTag("sees_sky")
@JvmField val SNOW_BLOCK = createTag("snow_block")
@JvmField val MOON_STONE_ORES = createTag("moon_stone_ores")
@JvmField val NATURAL = createTag("natural")
@JvmField val NETHER_STRUCTURE_BLOCKS = createTag("nether_structure_blocks")
@JvmField val PINK_FLOWERS = createTag("pink_flowers")
@JvmField val RED_FLOWERS = createTag("red_flowers")
@JvmField val RED_TUMBLESTONE_BRICKS = createTag("red_tumblestone_bricks")
@JvmField val RED_TUMBLESTONES = createTag("red_tumblestones")
@JvmField val REDSTONE_BLOCKS = createTag("redstone_blocks")
@JvmField val ROOTS = createTag("roots")
@JvmField val ROOTS_SPREADABLE = createTag("roots_spreadable")
@JvmField val RUINED_PORTAL_BLOCKS = createTag("ruined_portal_blocks")
@JvmField val SEES_SKY = createTag("sees_sky")
@JvmField val SHINY_STONE_ORES = createTag("shiny_stone_ores")
@JvmField val SIGNS = createTag("signs")
@JvmField val SKY_TUMBLESTONE_BRICKS = createTag("sky_tumblestone_bricks")
@JvmField val SKY_TUMBLESTONES = createTag("sky_tumblestones")
@JvmField val SMALL_FLOWERS = createTag("small_flowers")
@JvmField val SNOW_BLOCK = createTag("snow_block")
@JvmField val STANDING_SIGNS = createTag("standing_signs")
@JvmField val SUN_STONE_ORES = createTag("sun_stone_ores")
@JvmField val THUNDER_STONE_ORES = createTag("thunder_stone_ores")
@JvmField val TRAIL_RUINS_BLOCKS = createTag("trail_ruins_blocks")
@JvmField val TRASH = createTag("trash")
@JvmField val TREES = createTag("trees")
@JvmField val TUMBLESTONE_BRICKS = createTag("tumblestone_bricks")
@JvmField val TUMBLESTONES = createTag("tumblestones")
@JvmField val TUMBLESTONE_HEAT_SOURCE = createTag("tumblestone_heat_source")
@JvmField val WALL_HANGING_SIGNS = createTag("wall_hanging_signs")
@JvmField val WALL_SIGNS = createTag("wall_signs")
@JvmField val WATER_STONE_ORES = createTag("water_stone_ores")
@JvmField val WHITE_FLOWERS = createTag("white_flowers")
@JvmField val YELLOW_FLOWERS = createTag("yellow_flowers")
private fun createTag(name: String) = TagKey.create(Registries.BLOCK, cobblemonResource(name))
@@ -21,137 +21,108 @@ import net.minecraft.tags.TagKey
*/
@Suppress("unused", "HasPlatformType")
object CobblemonItemTags {
@JvmField
val ANCIENT_POKE_BALLS = create("ancient_poke_balls")
@JvmField
val APRICORN_LOGS = create("apricorn_logs")
@JvmField
val APRICORN_SPROUTS = create("apricorn_sprouts")
@JvmField
val APRICORNS = create("apricorns")
@JvmField
val POKEDEX = create("pokedex")
/**
* This tag is only used for a Torterra aspect based easter egg evolution at the moment.
* It simply includes the 'minecraft:azalea' and 'minecraft:flowering_azalea' items by default.
*/
@JvmField
val AZALEA_TREE = create("azalea_tree")
@JvmField
val BERRIES = create("berries")
@JvmField
val BOATS = create("boats")
@JvmField
val COBBLEMON_SEEDS = create("cobblemon_seeds")
/**
* This tag is used for Fossil Machine natural materials
*/
@JvmField
val COOKED_MEAT = create("cooked_meat")
@JvmField
val DAWN_STONE_ORES = create("dawn_stone_ores")
@JvmField
val DUSK_STONE_ORES = create("dusk_stone_ores")
@JvmField
val EVOLUTION_ITEMS = create("evolution_items")
@JvmField
val EVOLUTION_STONES = create("evolution_stones")
@JvmField
val EXPERIENCE_CANDIES = create("experience_candies")
@JvmField
val FIRE_STONE_ORES = create("fire_stone_ores")
@JvmField
val FOSSILS = create("fossils")
@JvmField
val HANGING_SIGNS = create("hanging_signs")
@JvmField
val HERBS = create("herbs")
@JvmField
val ICE_STONE_ORES = create("ice_stone_ores")
@JvmField
val LEAF_STONE_ORES = create("leaf_stone_ores")
@JvmField
val MINT_LEAF = create("mint_leaf")
@JvmField
val MINT_SEEDS = create("mint_seeds")
@JvmField
val MINTS = create("mints")
@JvmField
val MOON_STONE_ORES = create("moon_stone_ores")
@JvmField
val MUTATED_BERRIES = create("mutated_berries")
@JvmField
val PLANTS = create("plants")
@JvmField
val POKE_BALLS = create("poke_balls")
@JvmField
val PROTEIN_INGREDIENTS = create("protein_ingredients")
@JvmField val ABILITY_CHANGERS = create("ability_changers")
@JvmField val ANCIENT_POKE_BALLS = create("ancient_poke_balls")
@JvmField val APPLES = create("apples")
@JvmField val APRICORN_LOGS = create("apricorn_logs")
@JvmField val APRICORN_POKE_BALLS = create("apricorn_poke_balls")
@JvmField val APRICORN_SPROUTS = create("apricorn_sprouts")
@JvmField val APRICORNS = create("apricorns")
/** This tag is only used for a Torterra aspect based easter egg evolution at the moment.
* It simply includes the 'minecraft:azalea' and 'minecraft:flowering_azalea' items by default. */
@JvmField val AZALEA_TREE = create("azalea_tree")
@JvmField val BATTLE_ITEMS = create("battle_items")
@JvmField val BERRIES = create("berries")
@JvmField val BLACK_TUMBLESTONE_BRICKS = create("black_tumblestone_bricks")
@JvmField val BLACK_TUMBLESTONES = create("black_tumblestones")
@JvmField val BOATS = create("boats")
/** This tag is used for Fossil Machine natural materials */
@JvmField val COOKED_MEAT = create("cooked_meat")
@JvmField val DAWN_STONE_ORES = create("dawn_stone_ores")
@JvmField val POTTERY_SHERDS = create("decorated_pot_sherds")
@JvmField val DEEP_SEAS = create("deep_seas")
@JvmField val DUSK_STONE_ORES = create("dusk_stone_ores")
@JvmField val ETHERS = create("ethers")
@JvmField val EVOLUTION_ITEMS = create("evolution_items")
@JvmField val EVOLUTION_STONE_BLOCKS = create("evolution_stone_blocks")
@JvmField val EVOLUTION_STONES = create("evolution_stones")
@JvmField val EXPERIENCE_CANDIES = create("experience_candies")
@JvmField val FEATHERS = create("feathers")
@JvmField val FIRE_STONE_ORES = create("fire_stone_ores")
@JvmField val FOSSIL_MACHINE_PARTS = create("fossil_machine_parts")
@JvmField val FOSSILS = create("fossils")
@JvmField val GILDED_CHESTS = create("gilded_chests")
@JvmField val HANGING_SIGNS = create("hanging_signs")
@JvmField val HERBS = create("herbs")
@JvmField val ICE_STONE_ORES = create("ice_stone_ores")
@JvmField val LEAF_STONE_ORES = create("leaf_stone_ores")
@JvmField val MACHINES = create("machines")
@JvmField val MINT_LEAF = create("mint_leaf")
@JvmField val MINT_SEEDS = create("mint_seeds")
@JvmField val MINTS = create("mints")
@JvmField val MOON_STONE_ORES = create("moon_stone_ores")
@JvmField val MUTATED_BERRIES = create("mutated_berries")
@JvmField val PLANTS = create("plants")
@JvmField val POKE_BALLS = create("poke_balls")
@JvmField val POKE_RODS = create("poke_rods")
@JvmField val POKEDEX = create("pokedex")
@JvmField val POKEDEX_SCREEN = create("pokedex_screen")
@JvmField val POTIONS = create("potions")
@JvmField val PROTEIN_INGREDIENTS = create("protein_ingredients")
/** See [COOKED_MEAT] */
@JvmField
val RAW_MEAT = create("raw_meat")
@JvmField
val SEEDS = create("seeds")
@JvmField
val SHINY_STONE_ORES = create("shiny_stone_ores")
@JvmField
val SIGNS = create("signs")
@JvmField
val SUN_STONE_ORES = create("sun_stone_ores")
@JvmField
val THUNDER_STONE_ORES = create("thunder_stone_ores")
@JvmField
val TUMBLESTONES = create("tumblestones")
@JvmField
val WATER_STONE_ORES = create("water_stone_ores")
@JvmField
val ZINC_INGREDIENTS = create("zinc_ingredients")
@JvmField val RAW_MEAT = create("raw_meat")
@JvmField val RED_TUMBLESTONE_BRICKS = create("red_tumblestone_bricks")
@JvmField val RED_TUMBLESTONES = create("red_tumblestones")
@JvmField val REMEDIES = create("remedies")
@JvmField val RESTORES = create("restores")
@JvmField val REVIVES = create("revives")
@JvmField val SEEDS = create("seeds")
@JvmField val SHINY_STONE_ORES = create("shiny_stone_ores")
@JvmField val SIGNS = create("signs")
@JvmField val SKY_TUMBLESTONE_BRICKS = create("sky_tumblestone_bricks")
@JvmField val SKY_TUMBLESTONES = create("sky_tumblestones")
@JvmField val SUN_STONE_ORES = create("sun_stone_ores")
@JvmField val SWEETS = create("sweets")
@JvmField val TEACUPS = create("teacups")
@JvmField val TEAPOTS = create("teapots")
@JvmField val THUNDER_STONE_ORES = create("thunder_stone_ores")
@JvmField val TIER_1_POKE_BALL_MATERIALS = create("tier_1_poke_ball_materials")
@JvmField val TIER_1_POKE_BALLS = create("tier_1_poke_balls")
@JvmField val TIER_2_POKE_BALL_MATERIALS = create("tier_2_poke_ball_materials")
@JvmField val TIER_2_POKE_BALLS = create("tier_2_poke_balls")
@JvmField val TIER_3_POKE_BALL_MATERIALS = create("tier_3_poke_ball_materials")
@JvmField val TIER_3_POKE_BALLS = create("tier_3_poke_balls")
@JvmField val TIER_4_POKE_BALL_MATERIALS = create("tier_4_poke_ball_materials")
@JvmField val TIER_4_POKE_BALLS = create("tier_4_poke_balls")
@JvmField val TIER_5_POKE_BALLS = create("tier_5_poke_balls")
@JvmField val TUMBLESTONE_BRICKS = create("tumblestone_bricks")
@JvmField val TUMBLESTONES = create("tumblestones")
@JvmField val TYPE_GEMS = create("type_gems")
@JvmField val VITAMINS = create("vitamins")
@JvmField val WATER_STONE_ORES = create("water_stone_ores")
@JvmField val ZINC_INGREDIENTS = create("zinc_ingredients")
// Held Item Tags
@JvmField
val ANY_HELD_ITEM = create("held/is_held_item")
@JvmField
val EXPERIENCE_SHARE = create("held/experience_share")
@JvmField
val LUCKY_EGG = create("held/lucky_egg")
@JvmField
val DESTINY_KNOT = create("held/destiny_knot")
@JvmField
val EVERSTONE = create("held/everstone")
@JvmField
val POWER_ANKLET = create("held/power_anklet")
@JvmField
val POWER_BAND = create("held/power_band")
@JvmField
val POWER_BELT = create("held/power_belt")
@JvmField
val POWER_BRACER = create("held/power_bracer")
@JvmField
val POWER_LENS = create("held/power_lens")
@JvmField
val POWER_WEIGHT = create("held/power_weight")
@JvmField
val CONSUMED_IN_NPC_BATTLE = create("held/consumed_in_npc_battle")
@JvmField
val CONSUMED_IN_PVP_BATTLE = create("held/consumed_in_pvp_battle")
@JvmField
val CONSUMED_IN_WILD_BATTLE = create("held/consumed_in_wild_battle")
@JvmField
val TERRAIN_SEEDS = create("held/terrain_seeds")
@JvmField val CONSUMED_IN_NPC_BATTLE = create("held/consumed_in_npc_battle")
@JvmField val CONSUMED_IN_PVP_BATTLE = create("held/consumed_in_pvp_battle")
@JvmField val CONSUMED_IN_WILD_BATTLE = create("held/consumed_in_wild_battle")
@JvmField val DESTINY_KNOT = create("held/destiny_knot")
@JvmField val EVERSTONE = create("held/everstone")
@JvmField val EXPERIENCE_SHARE = create("held/experience_share")
@JvmField val IS_FRIENDSHIP_BOOSTER = create("is_friendship_booster")
@JvmField val ANY_HELD_ITEM = create("held/is_held_item")
/** Tag that flags items as being able to "create" [CobblemonItems.LEFTOVERS]. */
@JvmField val LEAVES_LEFTOVERS = create("held/leaves_leftovers")
@JvmField val LUCKY_EGG = create("held/lucky_egg")
@JvmField val POWER_ANKLET = create("held/power_anklet")
@JvmField val POWER_BAND = create("held/power_band")
@JvmField val POWER_BELT = create("held/power_belt")
@JvmField val POWER_BRACER = create("held/power_bracer")
@JvmField val POWER_LENS = create("held/power_lens")
@JvmField val POWER_WEIGHT = create("held/power_weight")
@JvmField val TERRAIN_SEEDS = create("held/terrain_seeds")
/**
* Tag that flags items as being able to "create" [CobblemonItems.LEFTOVERS].
*/
@JvmField
val LEAVES_LEFTOVERS = create("held/leaves_leftovers")
@JvmField
val POTTERY_SHERDS = create("decorated_pot_sherds")
@JvmField
val ABILITY_CHANGERS = create("ability_changers")
@JvmField
val IS_FRIENDSHIP_BOOSTER = create("is_friendship_booster")
private fun create(path: String) = TagKey.create(Registries.ITEM, cobblemonResource(path))
@@ -68,6 +68,8 @@ class WinInstruction(val message: BattleMessage): InterpreterInstruction {
}
}
battle.dispatchGo {
battle.winners = winners
battle.losers = losers
battle.end()
CobblemonEvents.BATTLE_VICTORY.post(BattleVictoryEvent(battle, winners, losers, wasCaught))
ShowdownInterpreter.lastCauser.remove(battle.battleId)
@@ -372,24 +372,24 @@ class PokemonClientDelegate : PosableState(), PokemonSideDelegate {
override fun tick(entity: PokemonEntity) {
incrementAge(entity)
if(currentEntity.ownerUUID == null && currentEntity.pokemon.shiny && secondsSinceLastShinyParticle > SHINY_PARTICLE_COOLDOWN && !currentEntity.isBattling) {
//wild shiny not looked at
playShinyEffect("cobblemon:shiny_sparkle_ambient_wild")
lastShinyParticle = System.currentTimeMillis()
}
getClientShinyPokemon()
playWildShinySounds()
}
fun getClientShinyPokemon() {
fun playWildShinySounds() {
val player = Minecraft.getInstance().player ?: return
val isWithinRange = player.position().distanceTo(currentEntity.position()) <= Cobblemon.config.shinyNoticeParticlesDistance
if (currentEntity.pokemon.shiny && currentEntity.ownerUUID == null && !player.isSpectator ) {
if (isWithinRange && !shined) {
playShinyEffect("cobblemon:wild_shiny_ring")
shined = true
lastShinyParticle = System.currentTimeMillis()
} else if (!isWithinRange) {
if (currentEntity.pokemon.shiny && currentEntity.ownerUUID == null) {
if (isWithinRange) {
if (secondsSinceLastShinyParticle > SHINY_PARTICLE_COOLDOWN && !currentEntity.isBattling) {
playShinyEffect("cobblemon:shiny_sparkle_ambient_wild")
lastShinyParticle = System.currentTimeMillis()
}
if (!shined && !player.isSpectator) {
playShinyEffect("cobblemon:wild_shiny_ring")
shined = true
}
} else {
shined = false
}
}
@@ -191,6 +191,8 @@ class BattleTargetSelection(
matrices.pushPose()
matrices.translate(x + TARGET_WIDTH - (25 / 2.0) - 2, y + 5.0, 0.0)
matrices.scale(2.5F, 2.5F, 1F)
// Grab aspects for right variant
state.currentAspects = battlePokemon.state.currentAspects
drawProfilePokemon(
species = battlePokemon.species.resourceIdentifier,
matrixStack = matrices,
@@ -17,6 +17,10 @@ class GrabbedStorageSlot(
private val pokemon: Pokemon
) : StorageSlot(x, y, parent, {}) {
init {
isSlotSelected = true
}
override fun renderWidget(context: GuiGraphics, mouseX: Int, mouseY: Int, delta: Float) {
renderSlot(context = context, posX = mouseX - (width / 2), posY = mouseY - (height / 2), partialTicks = delta)
}
@@ -40,7 +40,8 @@ import net.minecraft.sounds.SoundEvent
class PCGUI(
val pc: ClientPC,
val party: ClientParty,
val configuration: PCGUIConfiguration
val configuration: PCGUIConfiguration,
val openOnBox: Int = 0
) : Screen(Component.translatable("cobblemon.ui.pc.title")), CobblemonRenderable {
companion object {
@@ -110,6 +111,7 @@ class PCGUI(
pc = pc,
party = party
)
this.storageWidget.box = openOnBox
this.setPreviewPokemon(null)
this.addRenderableWidget(storageWidget)
@@ -46,6 +46,8 @@ open class StorageSlot(
private val slotOverlayMoveIconResource = cobblemonResource("textures/gui/pasture/pc_slot_icon_move.png")
}
protected var isSlotSelected = false;
override fun playDownSound(soundManager: SoundManager) {
}
@@ -82,50 +84,52 @@ open class StorageSlot(
context.disableScissor()
// Ensure elements are not hidden behind Pokémon render
matrices.pushPose()
matrices.translate(0.0, 0.0, 100.0)
// Level
drawScaledText(
context = context,
text = lang("ui.lv.number", pokemon.level),
x = posX + 1,
y = posY + 1,
shadow = true,
scale = PCGUI.SCALE
)
if (pokemon.gender != Gender.GENDERLESS) {
blitk(
matrixStack = matrices,
texture = if (pokemon.gender == Gender.MALE) genderIconMale else genderIconFemale,
x = (posX + 21) / PCGUI.SCALE,
y = (posY + 1) / PCGUI.SCALE,
width = 6,
height = 8,
if (!isSlotSelected) {
// Ensure elements are not hidden behind Pokémon render
matrices.pushPose()
matrices.translate(0.0, 0.0, 100.0)
// Level
drawScaledText(
context = context,
text = lang("ui.lv.number", pokemon.level),
x = posX + 1,
y = posY + 1,
shadow = true,
scale = PCGUI.SCALE
)
}
// Held Item
val heldItem = pokemon.heldItemNoCopy()
if (!heldItem.isEmpty) {
renderScaledGuiItemIcon(
itemStack = heldItem,
x = posX + 16.0,
y = posY + 16.0,
scale = 0.5,
matrixStack = matrices
)
if (pokemon.gender != Gender.GENDERLESS) {
blitk(
matrixStack = matrices,
texture = if (pokemon.gender == Gender.MALE) genderIconMale else genderIconFemale,
x = (posX + 21) / PCGUI.SCALE,
y = (posY + 1) / PCGUI.SCALE,
width = 6,
height = 8,
scale = PCGUI.SCALE
)
}
// Held Item
val heldItem = pokemon.heldItemNoCopy()
if (!heldItem.isEmpty) {
renderScaledGuiItemIcon(
itemStack = heldItem,
x = posX + 16.0,
y = posY + 16.0,
scale = 0.5,
matrixStack = matrices
)
}
matrices.popPose()
}
matrices.popPose()
// Ensure overlay elements are on top
matrices.pushPose()
matrices.translate(0.0, 0.0, 500.0)
val config = parent.pcGui.configuration
if (pokemon.tetheringId != null) {
if (pokemon.tetheringId != null && !isSlotSelected) {
if (isStationary()) {
blitk(
matrixStack = matrices,
@@ -286,7 +286,10 @@ class StorageWidget(
}
pastureWidget?.render(context, mouseX, mouseY, delta)
matrices.pushPose()
matrices.translate(0.0, 0.0, 1000.0)
grabbedSlot?.render(context, mouseX, mouseY, delta)
matrices.popPose()
}
override fun mouseClicked(pMouseX: Double, pMouseY: Double, pButton: Int): Boolean {
@@ -163,8 +163,8 @@ class Summary private constructor(party: Collection<Pokemon?>, private val edita
},
text = lang("ui.evolve"),
resource = evolveButtonResource,
renderRequirement = { selectedPokemon.evolutionProxy.client().isNotEmpty() },
clickRequirement = { selectedPokemon.evolutionProxy.client().isNotEmpty() }
renderRequirement = { selectedPokemon.evolutionProxy.client().isNotEmpty() && CobblemonClient.battle == null },
clickRequirement = { selectedPokemon.evolutionProxy.client().isNotEmpty() && CobblemonClient.battle == null }
)
)
@@ -19,6 +19,8 @@ object ServerSettingsPacketHandler : ClientNetworkPacketHandler<ServerSettingsPa
ServerSettings.displayEntityLevelLabel = packet.displayEntityLevelLabel
ServerSettings.displayEntityNameLabel = packet.displayEntityNameLabel
ServerSettings.maxPokemonLevel = packet.maxPokemonLevel
ServerSettings.maxPokemonFriendship = packet.maxPokemonFriendship
ServerSettings.maxDynamaxLevel = packet.maxDynamaxLevel
}
}
@@ -18,6 +18,6 @@ import net.minecraft.client.Minecraft
object OpenPCHandler : ClientNetworkPacketHandler<OpenPCPacket> {
override fun handle(packet: OpenPCPacket, client: Minecraft) {
val pc = CobblemonClient.storage.pcStores[packet.storeID] ?: return
Minecraft.getInstance().setScreen(PCGUI(pc, CobblemonClient.storage.myParty, PCGUIConfiguration()))
Minecraft.getInstance().setScreen(PCGUI(pc, CobblemonClient.storage.myParty, PCGUIConfiguration(), packet.box))
}
}
@@ -116,7 +116,7 @@ class PokedexScannerRenderer {
drawScaledText(
context = graphics,
font = CobblemonResources.DEFAULT_LARGE,
text = lang("ui.lv.number", pokedexEntityData.level).bold(),
text = lang("ui.lv.number", pokedexEntityData.pokemon.level).bold(),
x = centerX + xOffset + xOffsetText,
y = centerY + yOffset + yOffsetText,
shadow = true,
@@ -126,7 +126,7 @@ class PokedexScannerRenderer {
if (infoDisplayedCounter == 2) {
val hasTrainer = (usageContext.scannableEntityInFocus?.resolveEntityScan() as? PokemonEntity)?.ownerUUID !== null
val speciesName = pokedexEntityData.species.translatedName.bold()
val speciesName = pokedexEntityData.getApparentSpecies().translatedName.bold()
var yOffsetName = if (hasTrainer) 2 else 0
if (hasTrainer) {
drawScaledText(
@@ -149,7 +149,7 @@ class PokedexScannerRenderer {
centered = true
)
val gender = pokedexEntityData.gender
val gender = pokedexEntityData.pokemon.gender
val speciesNameWidth = Minecraft.getInstance().font.width(speciesName.font(CobblemonResources.DEFAULT_LARGE))
if (gender != Gender.GENDERLESS) {
val isMale = gender == Gender.MALE
@@ -179,14 +179,15 @@ class PokedexScannerRenderer {
}
if (infoDisplayedCounter == 3) {
val typeText = lang("type.suffix", pokedexEntityData.form.types.map { it.displayName.copy() }.reduce { acc, next -> acc.plus("/").plus(next) }).bold()
val typeText = lang("type.suffix", pokedexEntityData.getApparentForm().types.map { it.displayName.copy() }.reduce { acc, next -> acc.plus("/").plus(next) }).bold()
val typeWidth = Minecraft.getInstance().font.width(typeText.font(CobblemonResources.DEFAULT_LARGE))
// Split into 2 lines if text width is too long
if (typeWidth > (OUTER_INFO_FRAME_WIDTH - 8) && pokedexEntityData.form.secondaryType !== null) {
if (typeWidth > (OUTER_INFO_FRAME_WIDTH - 8) && pokedexEntityData.getApparentForm().secondaryType !== null) {
val splitLines = typeText.string.split("/")
drawScaledText(
context = graphics,
font = CobblemonResources.DEFAULT_LARGE,
text = lang("type.suffix", pokedexEntityData.form.primaryType.displayName).bold(),
text = text(splitLines[0], "/").bold(),
x = centerX + xOffset + xOffsetText,
y = centerY + yOffset + yOffsetText - 4,
shadow = true,
@@ -196,7 +197,7 @@ class PokedexScannerRenderer {
drawScaledText(
context = graphics,
font = CobblemonResources.DEFAULT_LARGE,
text = lang("type.suffix", pokedexEntityData.form.secondaryType!!.displayName).bold(),
text = text(splitLines[1]).bold(),
x = centerX + xOffset + xOffsetText,
y = centerY + yOffset + yOffsetText + 3,
shadow = true,
@@ -15,12 +15,12 @@ import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.item.PokemonItem
import com.cobblemon.mod.common.util.math.fromEulerXYZDegrees
import com.mojang.blaze3d.platform.Lighting
import net.minecraft.client.renderer.texture.OverlayTexture
import net.minecraft.client.renderer.RenderType
import com.mojang.blaze3d.vertex.VertexConsumer
import net.minecraft.client.renderer.MultiBufferSource
import com.mojang.blaze3d.vertex.PoseStack
import com.mojang.blaze3d.vertex.VertexConsumer
import net.minecraft.client.renderer.LightTexture
import net.minecraft.client.renderer.MultiBufferSource
import net.minecraft.client.renderer.RenderType
import net.minecraft.client.renderer.texture.OverlayTexture
import net.minecraft.world.item.ItemDisplayContext
import net.minecraft.world.item.ItemStack
import org.joml.Quaternionf
@@ -50,7 +50,10 @@ class PokemonItemRenderer : CobblemonBuiltinItemRenderer {
val transformations = positions[mode]!!
Lighting.setupForFlatItems()
if (mode == ItemDisplayContext.GUI) {
Lighting.setupForFlatItems()
}
matrices.scale(transformations.scale.x, transformations.scale.y, transformations.scale.z)
matrices.translate(transformations.translation.x, transformations.translation.y, transformations.translation.z)
state.setPoseToFirstSuitable(PoseType.PORTRAIT)
@@ -84,7 +87,10 @@ class PokemonItemRenderer : CobblemonBuiltinItemRenderer {
model.setDefault()
matrices.popPose()
matrices.popPose()
Lighting.setupFor3DItems()
if (mode == ItemDisplayContext.GUI) {
Lighting.setupFor3DItems()
}
}
companion object {
@@ -51,7 +51,7 @@ open class BedrockActiveAnimation(
headPitch: Float,
intensity: Float
): Boolean {
return animation.run(context, model, state, state.animationSeconds - startedSeconds, limbSwing, limbSwingAmount, ageInTicks, intensity).also {
return animation.run(model, state, state.animationSeconds - startedSeconds, limbSwing, limbSwingAmount, ageInTicks, intensity).also {
if (!it) {
afterAction(context, state)
}
@@ -14,15 +14,17 @@ import com.bedrockk.molang.runtime.value.DoubleValue
import com.cobblemon.mod.common.api.molang.ExpressionLike
import com.cobblemon.mod.common.api.snowstorm.BedrockParticleOptions
import com.cobblemon.mod.common.client.particle.ParticleStorm
import com.cobblemon.mod.common.client.render.MatrixWrapper
import com.cobblemon.mod.common.client.render.models.blockbench.PosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Bone
import com.cobblemon.mod.common.client.render.models.blockbench.repository.RenderContext
import com.cobblemon.mod.common.util.effectiveName
import com.cobblemon.mod.common.util.genericRuntime
import com.cobblemon.mod.common.util.getString
import com.cobblemon.mod.common.util.math.geometry.toRadians
import com.cobblemon.mod.common.util.resolveDouble
import java.util.SortedMap
import java.util.TreeMap
import net.minecraft.CrashReport
import net.minecraft.ReportedException
import net.minecraft.client.Minecraft
@@ -33,8 +35,6 @@ import net.minecraft.resources.ResourceLocation
import net.minecraft.sounds.SoundEvent
import net.minecraft.world.entity.Entity
import net.minecraft.world.phys.Vec3
import org.joml.Matrix4f
import java.util.*
data class BedrockAnimationGroup(
val formatVersion: String,
@@ -149,7 +149,40 @@ data class BedrockAnimation(
/** Useful to have, gets set after loading the animation. */
var name: String = ""
fun run(context: RenderContext, model: PosableModel, state: PosableState, animationSeconds: Float, limbSwing: Float, limbSwingAmount: Float, ageInTicks: Float, intensity: Float): Boolean {
fun run(
model: PosableModel,
state: PosableState,
animationSeconds: Float,
limbSwing: Float,
limbSwingAmount: Float,
ageInTicks: Float,
intensity: Float
): Boolean {
return run(
model.context,
model.relevantPartsByName,
model.rootPart,
state,
animationSeconds,
limbSwing,
limbSwingAmount,
ageInTicks,
intensity
)
}
fun run(
context: RenderContext?,
relevantPartsByName: Map<String, ModelPart>,
rootPart: Bone?,
state: PosableState,
animationSeconds: Float,
limbSwing: Float,
limbSwingAmount: Float,
ageInTicks: Float,
intensity: Float
): Boolean {
var animationSeconds = animationSeconds
if (shouldLoop) {
animationSeconds %= animationLength.toFloat()
@@ -164,7 +197,7 @@ data class BedrockAnimation(
runtime.environment.setSimpleVariable("age_in_ticks", DoubleValue(ageInTicks.toDouble()))
boneTimelines.forEach { (boneName, timeline) ->
val part = model.relevantPartsByName[boneName] ?: if (boneName == "root_part") (model.rootPart as ModelPart) else null
val part = relevantPartsByName[boneName] ?: if (boneName == "root_part") (rootPart as? ModelPart) else null
if (part !== null) {
if (!timeline.position.isEmpty()) {
val position = timeline.position.resolve(animationSeconds.toDouble(), runtime).scale(intensity.toDouble())
@@ -184,7 +217,7 @@ data class BedrockAnimation(
zRot += rotation.z.toFloat().toRadians()
}
} catch (e: Exception) {
val exception = IllegalStateException("Bad animation for entity: ${(model.context.request(RenderContext.ENTITY))!!.effectiveName().string}", e)
val exception = IllegalStateException("Bad animation for entity: ${(context?.request(RenderContext.ENTITY))?.effectiveName()?.string ?: "unknown entity (riding animation?)"}", e)
val crash = CrashReport("Cobblemon encountered an unexpected crash", exception)
val section = crash.addCategory("Animation Details")
section.setDetail("Pose", state.currentPose!!)
@@ -34,7 +34,7 @@ class BedrockPoseAnimation(val animation: BedrockAnimation) : PoseAnimation() {
}
override fun setupAnim(context: RenderContext, model: PosableModel, state: PosableState, limbSwing: Float, limbSwingAmount: Float, ageInTicks: Float, headYaw: Float, headPitch: Float, intensity: Float) {
animation.run(context, model, state, state.animationSeconds, limbSwing, limbSwingAmount, ageInTicks, intensity)
animation.run(model, state, state.animationSeconds, limbSwing, limbSwingAmount, ageInTicks, intensity)
}
override fun applyEffects(entity: Entity?, state: PosableState, previousSeconds: Float, newSeconds: Float) {
@@ -1,106 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.animation.SingleBoneLookAnimation
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BipedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.STATIONARY_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import com.cobblemon.mod.common.util.isBattling
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class ExeggutorAlolanModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, BipedFrame {
override val rootPart = root.registerChildWithAllChildren("exeggutor")
override val head = getPart("head")
override val leftLeg = getPart("leg_left")
override val rightLeg = getPart("leg_right")
val head2 = object : HeadedFrame {
override val rootPart = this@ExeggutorAlolanModel.rootPart
override val head: ModelPart = getPart("head2")
}
val head3 = object : HeadedFrame {
override val rootPart = this@ExeggutorAlolanModel.rootPart
override val head: ModelPart = getPart("head3")
}
override var portraitScale = 1.0F
override var portraitTranslation = Vec3(-1.4, 16.55, 0.0)
override var profileScale = 0.45F
override var profileTranslation = Vec3(0.0, 1.0, -30.0)
lateinit var standing: Pose
lateinit var walk: Pose
lateinit var sleep: Pose
lateinit var battleidle: Pose
override fun registerPoses() {
val blink1 = quirk { bedrockStateful("exeggutor_alolan", "blink") }
val blink2 = quirk { bedrockStateful("exeggutor_alolan", "blink2") }
val blink3 = quirk { bedrockStateful("exeggutor_alolan", "blink3") }
val blink4 = quirk { bedrockStateful("exeggutor_alolan", "blink4") }
sleep = registerPose(
poseType = PoseType.SLEEP,
animations = arrayOf(bedrock("exeggutor_alolan", "sleep"))
)
standing = registerPose(
poseName = "standing",
poseTypes = STATIONARY_POSES + UI_POSES,
quirks = arrayOf(blink1, blink2, blink3, blink4),
condition = { !it.isBattling },
animations = arrayOf(
singleBoneLook(),
SingleBoneLookAnimation(head2, false, false, disableX = false, disableY = false),
SingleBoneLookAnimation(head3, false, false, disableX = false, disableY = false),
bedrock("exeggutor_alolan", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseTypes = MOVING_POSES,
quirks = arrayOf(blink1, blink2, blink3, blink4),
animations = arrayOf(
singleBoneLook(),
SingleBoneLookAnimation(head2, false, false, disableX = false, disableY = false),
SingleBoneLookAnimation(head3, false, false, disableX = false, disableY = false),
bedrock("exeggutor_alolan", "ground_walk")
)
)
battleidle = registerPose(
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
transformTicks = 10,
quirks = arrayOf(blink1, blink2, blink3, blink4),
condition = { it.isBattling },
animations = arrayOf(
singleBoneLook(),
SingleBoneLookAnimation(head2, false, false, disableX = false, disableY = false),
SingleBoneLookAnimation(head3, false, false, disableX = false, disableY = false),
bedrock("exeggutor_alolan", "battle_idle")
)
)
}
// override fun getFaintAnimation(
// pokemonEntity: PokemonEntity,
// state: PosableState<PokemonEntity>
// ) = if (state.isPosedIn(standing, walk)) bedrockStateful("exeggutor_alolan", "faint") else null
}
@@ -13,6 +13,7 @@ import com.cobblemon.mod.common.client.render.models.blockbench.animation.BipedW
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BimanualFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BipedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
@@ -40,6 +41,8 @@ class NidokingModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, B
lateinit var standing: Pose
lateinit var walk: Pose
override val cryAnimation = CryProvider { bedrockStateful("nidoking", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("nidoking", "blink")}
standing = registerPose(
@@ -14,6 +14,7 @@ import com.cobblemon.mod.common.client.render.models.blockbench.animation.BipedW
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BimanualFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BipedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
@@ -40,6 +41,8 @@ class NidoqueenModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame,
lateinit var standing: Pose
lateinit var walk: Pose
override val cryAnimation = CryProvider { bedrockStateful("nidoqueen", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("nidoqueen", "blink")}
val spg = quirk(secondsBetweenOccurrences = 600F to 900F) { bedrockStateful("nidoqueen", "spgs_happy_place") }
@@ -11,6 +11,7 @@ package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.animation.QuadrupedWalkAnimation
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.QuadrupedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.CobblemonPose
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
@@ -37,6 +38,8 @@ class NidoranfModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, Q
lateinit var standing: CobblemonPose
lateinit var walk: CobblemonPose
override val cryAnimation = CryProvider { bedrockStateful("nidoranf", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("nidoranf", "blink") }
standing = registerPose(
@@ -11,6 +11,7 @@ package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.animation.QuadrupedWalkAnimation
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.QuadrupedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
@@ -37,6 +38,8 @@ class NidoranmModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, Q
lateinit var standing: Pose
lateinit var walk: Pose
override val cryAnimation = CryProvider { bedrockStateful("nidoranm", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("nidoranm", "blink") }
standing = registerPose(
@@ -11,6 +11,7 @@ package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.animation.QuadrupedWalkAnimation
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.QuadrupedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
@@ -40,6 +41,8 @@ class NidorinaModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, Q
lateinit var walk: Pose
lateinit var battleidle: Pose
override val cryAnimation = CryProvider { bedrockStateful("nidorina", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("nidorina", "blink")}
standing = registerPose(
@@ -12,6 +12,7 @@ import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonP
import com.cobblemon.mod.common.client.render.models.blockbench.animation.QuadrupedWalkAnimation
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.QuadrupedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.STATIONARY_POSES
@@ -36,6 +37,8 @@ class NidorinoModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, Q
lateinit var standing: Pose
lateinit var walk: Pose
override val cryAnimation = CryProvider { bedrockStateful("nidorino", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("nidorino", "blink")}
standing = registerPose(
@@ -8,6 +8,7 @@
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.CobblemonPose
import com.cobblemon.mod.common.entity.PoseType
@@ -32,6 +33,8 @@ class PinsirModel(root: ModelPart) : PokemonPosableModel(root) {
lateinit var battleidle: CobblemonPose
lateinit var sleep: CobblemonPose
override val cryAnimation = CryProvider { bedrockStateful("pinsir", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("pinsir", "blink")}
sleep = registerPose(
@@ -1,100 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import com.cobblemon.mod.common.util.isBattling
import com.cobblemon.mod.common.util.isUnderWater
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class SlowbroModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame {
override val rootPart = root.registerChildWithAllChildren("slowbro")
override val head = getPart("head")
override var portraitScale = 2.0F
override var portraitTranslation = Vec3(-0.23, -0.1, 0.0)
override var profileScale = 0.95F
override var profileTranslation = Vec3(0.0, 0.3, 0.0)
lateinit var standing: Pose
lateinit var walk: Pose
lateinit var float: Pose
lateinit var swim: Pose
lateinit var battleidle: Pose
override fun registerPoses() {
val blink = quirk { bedrockStateful("slowbro", "blink1") }
val blink2 = quirk { bedrockStateful("slowbro", "blink2") }
val bite = quirk(secondsBetweenOccurrences = 60F to 120F) { bedrockStateful("slowbro", "bite_quirk") }
standing = registerPose(
poseName = "standing",
poseTypes = UI_POSES + PoseType.STAND,
quirks = arrayOf(blink, blink2, bite),
condition = { !it.isBattling },
animations = arrayOf(
singleBoneLook(),
bedrock("slowbro", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseType = PoseType.WALK,
quirks = arrayOf(blink, blink2, bite),
animations = arrayOf(
singleBoneLook(),
bedrock("slowbro", "ground_walk")
)
)
float = registerPose(
poseName = "float",
poseType = PoseType.FLOAT,
quirks = arrayOf(blink, blink2, bite),
animations = arrayOf(
singleBoneLook(),
bedrock("slowbro", "water_idle")
)
)
swim = registerPose(
poseName = "swim",
poseType = PoseType.SWIM,
quirks = arrayOf(blink, blink2, bite),
animations = arrayOf(
singleBoneLook(),
bedrock("slowbro", "water_swim")
)
)
battleidle = registerPose(
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
transformTicks = 10,
quirks = arrayOf(blink, blink2, bite),
condition = { it.isBattling && !it.isUnderWater },
animations = arrayOf(
singleBoneLook(),
bedrock("slowbro", "battle_idle")
)
)
}
// override fun getFaintAnimation(
// pokemonEntity: PokemonEntity,
// state: PosableState<PokemonEntity>
// ) = if (state.isPosedIn(standing, walk)) bedrockStateful("slowbro", "faint") else null
}
@@ -1,96 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.animation.QuadrupedWalkAnimation
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.QuadrupedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class SlowpokeModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, QuadrupedFrame {
override val rootPart = root.registerChildWithAllChildren("slowpoke")
override val head = getPart("head")
override val foreLeftLeg= getPart("leftfrontleg")
override val foreRightLeg = getPart("rightfrontleg")
override val hindLeftLeg = getPart("leftbackleg")
override val hindRightLeg = getPart("rightbackleg")
override var portraitScale = 2.2F
override var portraitTranslation = Vec3(-0.6, -1.6, 0.0)
override var profileScale = 0.8F
override var profileTranslation = Vec3(0.0, 0.52, 0.0)
lateinit var standing: Pose
lateinit var walk: Pose
lateinit var float: Pose
lateinit var swim: Pose
lateinit var sleep: Pose
override fun registerPoses() {
val blink = quirk { bedrockStateful("slowpoke", "blink") }
sleep = registerPose(
poseType = PoseType.SLEEP,
animations = arrayOf(bedrock("slowpoke", "sleep"))
)
standing = registerPose(
poseName = "standing",
poseTypes = UI_POSES + PoseType.STAND,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("slowpoke", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseType = PoseType.WALK,
quirks = arrayOf(blink),
animations = arrayOf(
QuadrupedWalkAnimation(this, periodMultiplier = 3.6F, amplitudeMultiplier = 2.2F),
singleBoneLook(),
bedrock("slowpoke", "ground_walk")
)
)
float = registerPose(
poseName = "float",
poseType = PoseType.FLOAT,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("slowpoke", "water_idle")
)
)
swim = registerPose(
poseName = "swim",
poseType = PoseType.SWIM,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("slowpoke", "water_swim")
)
)
}
// override fun getFaintAnimation(
// pokemonEntity: PokemonEntity,
// state: PosableState<PokemonEntity>
// ) = if (state.isPosedIn(standing, walk)) bedrockStateful("slowpoke", "faint") else null
}
@@ -1,60 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.CobblemonPose
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.STATIONARY_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class SnorlaxModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame {
override val rootPart = root.registerChildWithAllChildren("snorlax")
override val head = getPart("head")
override var portraitScale = 2.3F
override var portraitTranslation = Vec3(-0.45, 0.75, 0.0)
override var profileScale = 0.75F
override var profileTranslation = Vec3(0.0, 0.55, 0.0)
lateinit var standing: CobblemonPose
lateinit var walk: CobblemonPose
override val cryAnimation = CryProvider { bedrockStateful("snorlax", "cry") }
override fun registerPoses() {
standing = registerPose(
poseName = "standing",
poseTypes = STATIONARY_POSES + UI_POSES,
animations = arrayOf(
singleBoneLook(),
bedrock("snorlax", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseTypes = MOVING_POSES,
animations = arrayOf(
singleBoneLook(),
bedrock("snorlax", "ground_walk")
)
)
}
// override fun getFaintAnimation(
// pokemonEntity: PokemonEntity,
// state: PosableState<PokemonEntity>
// ) = if (state.isPosedIn(standing, walk)) bedrockStateful("snorlax", "faint") else null
}
@@ -1,65 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen1
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.STATIONARY_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class TaurosModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame {
override val rootPart = root.registerChildWithAllChildren("tauros")
override val head = getPart("head")
override var portraitScale = 1.9F
override var portraitTranslation = Vec3(-0.7, -0.25, 0.0)
override var profileScale = 0.75F
override var profileTranslation = Vec3(0.0, 0.6, 0.0)
lateinit var standing: Pose
lateinit var walk: Pose
override val cryAnimation = CryProvider { bedrockStateful("tauros", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("tauros", "blink")}
standing = registerPose(
poseName = "standing",
poseTypes = STATIONARY_POSES + UI_POSES,
transformTicks = 10,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("tauros", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseTypes = MOVING_POSES,
transformTicks = 10,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("tauros", "ground_walk")
)
)
}
// override fun getFaintAnimation(
// pokemonEntity: PokemonEntity,
// state: PosableState<PokemonEntity>
// ) = if (state.isPosedIn(standing, walk)) bedrockStateful("tauros", "faint") else null
}
@@ -25,7 +25,7 @@ import net.minecraft.world.phys.Vec3
class FeraligatrModel (root: ModelPart) : PokemonPosableModel(root), HeadedFrame, BipedFrame {
override val rootPart = root.registerChildWithAllChildren("feraligatr")
override val head = getPart("head")
override val head = getPart("head_ai")
override val leftLeg = getPart("leg_left")
override val rightLeg = getPart("leg_right")
@@ -9,6 +9,7 @@
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen2
import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
@@ -32,7 +33,7 @@ class HitmontopModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame {
lateinit var walk: Pose
lateinit var battleidle: Pose
// override val cryAnimation = CryProvider { bedrockStateful("hitmontop", "cry") }
override val cryAnimation = CryProvider { bedrockStateful("hitmontop", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("hitmontop", "blink") }
@@ -1,99 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen2
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import com.cobblemon.mod.common.util.isBattling
import com.cobblemon.mod.common.util.isInWater
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class SlowkingModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame {
override val rootPart = root.registerChildWithAllChildren("slowking")
override val head = getPart("head")
override var portraitScale = 2.0F
override var portraitTranslation = Vec3(-0.1, 0.1, 0.0)
override var profileScale = 0.8F
override var profileTranslation = Vec3(0.0, 0.55, 0.0)
lateinit var standing: Pose
lateinit var walk: Pose
lateinit var float: Pose
lateinit var swim: Pose
lateinit var battleidle: Pose
override fun registerPoses() {
val blink = quirk { bedrockStateful("slowking", "blink") }
val blink2 = quirk { bedrockStateful("slowking", "blink2") }
standing = registerPose(
poseName = "standing",
poseTypes = UI_POSES + PoseType.STAND,
quirks = arrayOf(blink, blink2),
condition = { !it.isBattling },
animations = arrayOf(
singleBoneLook(),
bedrock("slowking", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseType = PoseType.WALK,
quirks = arrayOf(blink, blink2),
animations = arrayOf(
singleBoneLook(),
bedrock("slowking", "ground_walk")
)
)
float = registerPose(
poseName = "float",
poseType = PoseType.FLOAT,
quirks = arrayOf(blink, blink2),
animations = arrayOf(
singleBoneLook(),
bedrock("slowking", "water_idle")
)
)
swim = registerPose(
poseName = "swim",
poseType = PoseType.SWIM,
quirks = arrayOf(blink, blink2),
animations = arrayOf(
singleBoneLook(),
bedrock("slowking", "water_swim")
)
)
battleidle = registerPose(
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
transformTicks = 10,
quirks = arrayOf(blink, blink2),
condition = { it.isBattling },
animations = arrayOf(
singleBoneLook(),
bedrock("slowking", "battle_idle")
)
)
}
// override fun getFaintAnimation(
// pokemonEntity: PokemonEntity,
// state: PosableState<PokemonEntity>
// ) = if (state.isPosedIn(standing, walk)) bedrockStateful("slowking", "faint") else null
}
@@ -1,83 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen5
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.CobblemonPose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.util.asExpressionLike
import com.cobblemon.mod.common.util.isBattling
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class KrokorokModel (root: ModelPart) : PokemonPosableModel(root) {
override val rootPart = root.registerChildWithAllChildren("krokorok")
override var portraitScale = 1.86F
override var portraitTranslation = Vec3(-0.43, 0.98, 0.0)
override var profileScale = 0.55F
override var profileTranslation = Vec3(0.05, 0.93, 0.0)
lateinit var sleep: CobblemonPose
lateinit var standing: CobblemonPose
lateinit var walk: CobblemonPose
lateinit var battleidle: CobblemonPose
override fun registerPoses() {
// animations["physical"] = "q.bedrock_primary('krokorok', 'physical', 'look', q.curve('symmetrical_wide'))".asExpressionLike()
// animations["special"] = "q.bedrock_primary('krokorok', 'special', 'look', q.curve('symmetrical_wide'))".asExpressionLike()
// animations["status"] = "q.bedrock_primary('krokorok', 'status', q.curve('symmetrical_wide'))".asExpressionLike()
// animations["recoil"] = "q.bedrock_stateful('krokorok', 'recoil')".asExpressionLike()
animations["cry"] = "q.bedrock_stateful('krokorok', 'cry')".asExpressionLike()
val faint = "q.bedrock_primary('krokorok', 'faint', q.curve('one'))".asExpressionLike()
val blink = quirk { bedrockStateful("krokorok", "blink") }
val look = quirk { bedrockStateful("krokorok", "look_quirk") }
sleep = registerPose(
poseType = PoseType.SLEEP,
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(bedrock("krokorok", "sleep"))
)
standing = registerPose(
poseName = "standing",
poseTypes = PoseType.STATIONARY_POSES + PoseType.UI_POSES,
quirks = arrayOf(blink, look),
condition = { !it.isBattling },
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(
bedrock("krokorok", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseTypes = PoseType.MOVING_POSES,
quirks = arrayOf(blink),
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(
bedrock("krokorok", "ground_walk")
)
)
battleidle = registerPose(
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
quirks = arrayOf(blink, look),
condition = { it.isBattling },
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(
bedrock("krokorok", "battle_idle")
)
)
}
}
@@ -1,84 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen5
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.CobblemonPose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.util.asExpressionLike
import com.cobblemon.mod.common.util.isBattling
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class SandileModel (root: ModelPart) : PokemonPosableModel(root) {
override val rootPart = root.registerChildWithAllChildren("sandile")
override var portraitScale = 2.54F
override var portraitTranslation = Vec3(-0.5, -1.9, 0.0)
override var profileScale = 0.84F
override var profileTranslation = Vec3(0.05, 0.48, 0.0)
lateinit var sleep: CobblemonPose
lateinit var standing: CobblemonPose
lateinit var walk: CobblemonPose
lateinit var battle_idle: CobblemonPose
override fun registerPoses() {
// animations["physical"] = "q.bedrock_primary('sandile', 'physical', 'look', q.curve('symmetrical_wide'))".asExpressionLike()
// animations["special"] = "q.bedrock_primary('sandile', 'special', 'look', q.curve('symmetrical_wide'))".asExpressionLike()
// animations["status"] = "q.bedrock_primary('sandile', 'status', q.curve('symmetrical_wide'))".asExpressionLike()
// animations["recoil"] = "q.bedrock_stateful('sandile', 'recoil')".asExpressionLike()
animations["cry"] = "q.bedrock_stateful('sandile', 'cry')".asExpressionLike()
val faint = "q.bedrock_primary('sandile', 'faint', q.curve('one'))".asExpressionLike()
val blink = quirk { bedrockStateful("sandile", "blink") }
val bite = quirk { bedrockStateful("sandile", "bite_quirk") }
sleep = registerPose(
poseType = PoseType.SLEEP,
quirks = arrayOf(bite),
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(bedrock("sandile", "sleep"))
)
standing = registerPose(
poseName = "standing",
poseTypes = PoseType.STATIONARY_POSES + PoseType.UI_POSES,
quirks = arrayOf(blink, bite),
condition = { !it.isBattling },
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(
bedrock("sandile", "ground_idle")
)
)
walk = registerPose(
poseName = "walk",
poseTypes = PoseType.MOVING_POSES,
quirks = arrayOf(blink),
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(
bedrock("sandile", "ground_walk")
)
)
battle_idle = registerPose(
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
quirks = arrayOf(blink, bite),
condition = { it.isBattling },
namedAnimations = mutableMapOf("faint" to faint),
animations = arrayOf(
bedrock("sandile", "battle_idle")
)
)
}
}
@@ -28,7 +28,7 @@ class ArctozoltModel (root: ModelPart) : PokemonPosableModel(root), HeadedFrame
override var portraitTranslation = Vec3(-0.45, 2.15, 0.0)
override var portraitScale = 0.85F
override var profileTranslation = Vec3(0.02, 0.95, 0.0)
override var profileTranslation = Vec3(0.02, 1.14, 0.0)
override var profileScale = 0.33F
lateinit var sleep: CobblemonPose
@@ -8,6 +8,7 @@
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen8
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
@@ -21,15 +22,17 @@ class EiscueModel (root: ModelPart) : PokemonPosableModel(root), HeadedFrame {
override val head = getPart("head")
override var portraitScale = 2.0F
override var portraitTranslation = Vec3(-0.1, -0.2, 0.0)
override var portraitTranslation = Vec3(-0.1, 0.31, 0.0)
override var profileScale = 1.0F
override var profileTranslation = Vec3(0.0, 0.3, 0.0)
override var profileScale = 0.8F
override var profileTranslation = Vec3(0.0, 0.55, 0.0)
lateinit var standing: Pose
lateinit var walk: Pose
lateinit var sleep: Pose
override val cryAnimation = CryProvider { bedrockStateful("eiscue_ice", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("eiscue_ice", "blink")}
sleep = registerPose(
@@ -71,7 +71,7 @@ class RabootModel (root: ModelPart) : PokemonPosableModel(root), HeadedFrame {
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
condition = { it.isBattling },
quirks = arrayOf(blink, hipQuirk),
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("raboot", "battle_idle")
@@ -1,91 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen9
// import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BimanualFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BipedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.STATIONARY_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import com.cobblemon.mod.common.util.isBattling
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class ArmarougeModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, BipedFrame, BimanualFrame {
override val rootPart = root.registerChildWithAllChildren("armarouge")
override val head = getPart("head")
override val rightArm = getPart("arm_right")
override val leftArm = getPart("arm_left")
override val rightLeg = getPart("leg_right")
override val leftLeg = getPart("leg_left")
override var portraitScale = 1.8F
override var portraitTranslation = Vec3(-0.2, 1.8, 0.0)
override var profileScale = 0.5F
override var profileTranslation = Vec3(0.0, 1.0, 0.0)
lateinit var standing: Pose
lateinit var walking: Pose
lateinit var sleep: Pose
lateinit var battleidle: Pose
override val cryAnimation = CryProvider { bedrockStateful("armarouge", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("armarouge", "blink") }
sleep = registerPose(
poseType = PoseType.SLEEP,
animations = arrayOf(bedrock("armarouge", "sleep"))
)
standing = registerPose(
poseName = "standing",
poseTypes = STATIONARY_POSES + UI_POSES,
transformTicks = 10,
condition = { !it.isBattling },
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("armarouge", "ground_idle")
)
)
walking = registerPose(
poseName = "walking",
poseTypes = MOVING_POSES,
transformTicks = 10,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("armarouge", "ground_walk")
)
)
battleidle = registerPose(
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
transformTicks = 10,
quirks = arrayOf(blink),
condition = { it.isBattling },
animations = arrayOf(
singleBoneLook(),
bedrock("armarouge", "battle_idle")
)
)
}
override fun getFaintAnimation(state: PosableState) = if (state.isPosedIn(standing, walking, battleidle, sleep)) bedrockStateful("armarouge", "faint") else null
}
@@ -1,120 +0,0 @@
/*
* Copyright (C) 2023 Cobblemon Contributors
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package com.cobblemon.mod.common.client.render.models.blockbench.pokemon.gen9
// import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.client.render.models.blockbench.createTransformation
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BimanualFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.BipedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.frame.HeadedFrame
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.CryProvider
import com.cobblemon.mod.common.client.render.models.blockbench.pokemon.PokemonPosableModel
import com.cobblemon.mod.common.client.render.models.blockbench.pose.Pose
import com.cobblemon.mod.common.entity.PoseType
import com.cobblemon.mod.common.entity.PoseType.Companion.MOVING_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.STATIONARY_POSES
import com.cobblemon.mod.common.entity.PoseType.Companion.UI_POSES
import com.cobblemon.mod.common.util.isBattling
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.world.phys.Vec3
class CeruledgeModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame, BipedFrame, BimanualFrame {
override val rootPart = root.registerChildWithAllChildren("ceruledge")
override val head = getPart("head")
override val rightArm = getPart("arm_right")
override val leftArm = getPart("arm_left")
override val rightLeg = getPart("leg_right")
override val leftLeg = getPart("leg_left")
val bladeright = getPart("blade_right")
val bladeleft = getPart("blade_left")
val passivebladeright = getPart("passive_blade_right")
val passivebladeleft = getPart("passive_blade_left")
override var portraitScale = 1.8F
override var portraitTranslation = Vec3(-0.2, 1.9, 0.0)
override var profileScale = 0.5F
override var profileTranslation = Vec3(0.0, 1.0, 0.0)
lateinit var standing: Pose
lateinit var walking: Pose
lateinit var sleep: Pose
lateinit var battleidle: Pose
override val cryAnimation = CryProvider { bedrockStateful("ceruledge", "cry") }
override fun registerPoses() {
val blink = quirk { bedrockStateful("ceruledge", "blink") }
sleep = registerPose(
poseType = PoseType.SLEEP,
transformedParts = arrayOf(
bladeright.createTransformation().withVisibility(visibility = false),
bladeleft.createTransformation().withVisibility(visibility = false),
passivebladeright.createTransformation().withVisibility(visibility = true),
passivebladeleft.createTransformation().withVisibility(visibility = true)
),
animations = arrayOf(bedrock("ceruledge", "sleep"))
)
standing = registerPose(
poseName = "standing",
poseTypes = STATIONARY_POSES + UI_POSES,
transformTicks = 10,
quirks = arrayOf(blink),
condition = { !it.isBattling },
transformedParts = arrayOf(
bladeright.createTransformation().withVisibility(visibility = false),
bladeleft.createTransformation().withVisibility(visibility = false),
passivebladeright.createTransformation().withVisibility(visibility = true),
passivebladeleft.createTransformation().withVisibility(visibility = true)
),
animations = arrayOf(
singleBoneLook(),
bedrock("ceruledge", "ground_idle")
)
)
walking = registerPose(
poseName = "walking",
poseTypes = MOVING_POSES,
transformTicks = 10,
quirks = arrayOf(blink),
transformedParts = arrayOf(
bladeright.createTransformation().withVisibility(visibility = false),
bladeleft.createTransformation().withVisibility(visibility = false),
passivebladeright.createTransformation().withVisibility(visibility = true),
passivebladeleft.createTransformation().withVisibility(visibility = true)
),
animations = arrayOf(
singleBoneLook(),
bedrock("ceruledge", "ground_walk")
)
)
battleidle = registerPose(
poseName = "battle_idle",
poseTypes = PoseType.STATIONARY_POSES,
transformTicks = 10,
quirks = arrayOf(blink),
condition = { it.isBattling },
transformedParts = arrayOf(
bladeright.createTransformation().withVisibility(visibility = true),
bladeleft.createTransformation().withVisibility(visibility = true),
passivebladeright.createTransformation().withVisibility(visibility = false),
passivebladeleft.createTransformation().withVisibility(visibility = false)
),
animations = arrayOf(
singleBoneLook(),
bedrock("ceruledge", "battle_idle")
)
)
}
override fun getFaintAnimation(state: PosableState) = if (state.isPosedIn(standing, walking, battleidle, sleep)) bedrockStateful("ceruledge", "faint2") else null
}
@@ -33,8 +33,8 @@ class CharcadetModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame,
override val rightLeg = getPart("leg_right")
override val leftLeg = getPart("leg_left")
override var portraitScale = 2.5F
override var portraitTranslation = Vec3(-0.15, -0.45, 0.0)
override var portraitScale = 1.7F
override var portraitTranslation = Vec3(-0.15, 0.08, 0.0)
override var profileScale = 0.8F
override var profileTranslation = Vec3(0.0, 0.6, 0.0)
@@ -51,7 +51,9 @@ class CharcadetModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame,
val blink = quirk { bedrockStateful("charcadet", "blink") }
sleep = registerPose(
poseType = PoseType.SLEEP,
animations = arrayOf(bedrock("charcadet", "sleep"))
animations = arrayOf(bedrock("charcadet", "sleep"),
bedrock("charcadet", "eye_flame_overlay"),
bedrock("charcadet", "head_flame_overlay"))
)
standing = registerPose(
@@ -61,7 +63,9 @@ class CharcadetModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("charcadet", "ground_idle")
bedrock("charcadet", "ground_idle"),
bedrock("charcadet", "eye_flame_overlay"),
bedrock("charcadet", "head_flame_overlay")
)
)
@@ -72,7 +76,9 @@ class CharcadetModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("charcadet", "ground_walk")
bedrock("charcadet", "ground_walk"),
bedrock("charcadet", "eye_flame_overlay"),
bedrock("charcadet", "head_flame_overlay")
)
)
@@ -81,7 +87,9 @@ class CharcadetModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("charcadet", "shoulder_left")
bedrock("charcadet", "shoulder_left"),
bedrock("charcadet", "eye_flame_overlay"),
bedrock("charcadet", "head_flame_overlay")
),
transformedParts = arrayOf(
rootPart.createTransformation().addPosition(ModelPartTransformation.Y_AXIS, -0.1),
@@ -94,7 +102,9 @@ class CharcadetModel(root: ModelPart) : PokemonPosableModel(root), HeadedFrame,
quirks = arrayOf(blink),
animations = arrayOf(
singleBoneLook(),
bedrock("charcadet", "shoulder_right")
bedrock("charcadet", "shoulder_right"),
bedrock("charcadet", "eye_flame_overlay"),
bedrock("charcadet", "head_flame_overlay")
),
transformedParts = arrayOf(
rootPart.createTransformation().addPosition(ModelPartTransformation.Y_AXIS, -0.1),
@@ -90,17 +90,13 @@ object PokemonModelRepository : VaryingModelRepository<PokemonPosableModel>() {
inbuilt("electabuzz", ::ElectabuzzModel)
inbuilt("exeggcute", ::ExeggcuteModel)
inbuilt("exeggutor", ::ExeggutorModel)
inbuilt("exeggutor_alolan", ::ExeggutorAlolanModel)
inbuilt("farfetchd", ::FarfetchdModel)
inbuilt("farfetchd_galarian", ::FarfetchdGalarianModel)
inbuilt("fearow", ::FearowModel)
inbuilt("flareon", ::FlareonModel)
inbuilt("gengar", ::GengarModel)
inbuilt("geodude", ::GeodudeModel)
inbuilt("golbat", ::GolbatModel)
inbuilt("golduck", ::GolduckModel)
inbuilt("golem", ::GolemModel)
inbuilt("graveler", ::GravelerModel)
inbuilt("grimer", ::GrimerModel)
inbuilt("growlithe", ::GrowlitheModel)
inbuilt("hitmonchan", ::HitmonchanModel)
@@ -146,14 +142,11 @@ object PokemonModelRepository : VaryingModelRepository<PokemonPosableModel>() {
inbuilt("sandslash", ::SandslashModel)
inbuilt("scyther", ::ScytherModel)
inbuilt("seel", ::SeelModel)
inbuilt("slowbro", ::SlowbroModel)
inbuilt("slowpoke", ::SlowpokeModel)
inbuilt("spearow", ::SpearowModel)
inbuilt("starmie", ::StarmieModel)
inbuilt("staryu", ::StaryuModel)
inbuilt("steelix", ::SteelixModel)
inbuilt("tangela", ::TangelaModel)
inbuilt("tauros", ::TaurosModel)
inbuilt("tentacool", ::TentacoolModel)
inbuilt("tentacruel", ::TentacruelModel)
inbuilt("vaporeon", ::VaporeonModel)
@@ -179,7 +172,6 @@ object PokemonModelRepository : VaryingModelRepository<PokemonPosableModel>() {
inbuilt("blissey", ::BlisseyModel)
inbuilt("piloswine", ::PiloswineModel)
inbuilt("quagsire", ::QuagsireModel)
inbuilt("slowking", ::SlowkingModel)
inbuilt("swinub", ::SwinubModel)
inbuilt("wooper", ::WooperModel)
inbuilt("wooper_paldean", ::WooperPaldeanModel)
@@ -343,8 +335,6 @@ object PokemonModelRepository : VaryingModelRepository<PokemonPosableModel>() {
inbuilt("shroomish", ::ShroomishModel)
inbuilt("breloom", ::BreloomModel)
inbuilt("charcadet", ::CharcadetModel)
inbuilt("armarouge", ::ArmarougeModel)
inbuilt("ceruledge", ::CeruledgeModel)
inbuilt("flittle", ::FlittleModel)
inbuilt("espathra", ::EspathraModel)
inbuilt("surskit", ::SurskitModel)
@@ -559,8 +549,6 @@ object PokemonModelRepository : VaryingModelRepository<PokemonPosableModel>() {
inbuilt("roserade", ::RoseradeModel)
inbuilt("woobat", ::WoobatModel)
inbuilt("swoobat", ::SwoobatModel)
inbuilt("sandile", ::SandileModel)
inbuilt("krokorok", ::KrokorokModel)
inbuilt("frillish", ::FrillishModel)
inbuilt("jellicent", ::JellicentModel)
inbuilt("cubchoo", ::CubchooModel)
@@ -60,4 +60,11 @@ class NPCRenderer(context: Context) : LivingEntityRenderer<NPCEntity, PosableEnt
// this.renderLabelIfPresent(entity, entity.displayName, poseMatrix, buffer, packedLight)
// }
}
override fun shouldShowName(entity: NPCEntity): Boolean {
if (entity.hideNameTag) {
return false
}
return super.shouldShowName(entity)
}
}
@@ -8,11 +8,15 @@
package com.cobblemon.mod.common.client.render.player
import com.bedrockk.molang.runtime.value.DoubleValue
import com.cobblemon.mod.common.client.entity.PokemonClientDelegate
import com.cobblemon.mod.common.client.render.models.blockbench.bedrock.animation.BedrockAnimationRepository
import com.cobblemon.mod.common.entity.pokemon.PokemonEntity
import com.cobblemon.mod.common.util.math.geometry.toRadians
import com.cobblemon.mod.common.util.withPlayerValue
import com.mojang.blaze3d.vertex.PoseStack
import net.minecraft.client.Minecraft
import net.minecraft.client.model.geom.ModelPart
import net.minecraft.client.player.AbstractClientPlayer
import net.minecraft.world.phys.Vec3
import org.joml.Matrix4f
@@ -57,4 +61,48 @@ object MountedPlayerRenderer {
offsetMatrix.translate(offsetOrigin.toVector3f())
return offsetMatrix.getTranslation(Vector3f())
}
fun animate(
pokemonEntity: PokemonEntity,
player: AbstractClientPlayer,
relevantPartsByName: Map<String, ModelPart>,
headYaw: Float,
headPitch: Float,
ageInTicks: Float,
limbSwing: Float,
limbSwingAmount: Float
) {
val seatIndex = pokemonEntity.passengers.indexOf(player).takeIf { it != -1 && it < pokemonEntity.seats.size } ?: return
val seat = pokemonEntity.seats[seatIndex]
val animations = seat.poseAnimations.firstOrNull { it.poseTypes.isEmpty() || it.poseTypes.contains(pokemonEntity.getCurrentPoseType()) }?.animations
?: return
val state = pokemonEntity.delegate as PokemonClientDelegate
relevantPartsByName.values.forEach {
it.xRot = 0F
it.yRot = 0F
it.zRot = 0F
}
state.runtime.environment.setSimpleVariable("age_in_ticks", DoubleValue(ageInTicks.toDouble()))
state.runtime.environment.setSimpleVariable("limb_swing", DoubleValue(limbSwing.toDouble()))
state.runtime.environment.setSimpleVariable("limb_swing_amount", DoubleValue(limbSwingAmount.toDouble()))
// TODO add the q.player reference, requires a cached thing or something on the client idk
for (animation in animations) {
val bedrockAnimation = BedrockAnimationRepository.getAnimationOrNull(animation.fileName, animation.animationName) ?: continue
bedrockAnimation.run(
context = null,
relevantPartsByName = relevantPartsByName,
rootPart = null,
state = state,
animationSeconds = state.animationSeconds,
limbSwing = limbSwing,
limbSwingAmount = limbSwingAmount,
ageInTicks = ageInTicks,
intensity = 1F
)
}
}
}
@@ -0,0 +1,117 @@
package com.cobblemon.mod.common.client.render.player
import com.cobblemon.mod.common.Rollable
import com.cobblemon.mod.common.api.riding.Rideable
import com.cobblemon.mod.common.client.entity.PokemonClientDelegate
import com.cobblemon.mod.common.client.render.ClientPlayerIcon.Companion.onRenderPlayer
import com.cobblemon.mod.common.client.render.models.blockbench.PosableState
import com.cobblemon.mod.common.entity.PosableEntity
import com.cobblemon.mod.common.mixin.PlayerRendererMixin
import com.cobblemon.mod.common.util.math.geometry.toRadians
import com.cobblemon.mod.common.util.math.geometry.transformPosition
import com.cobblemon.mod.common.util.toVec3d
import com.llamalad7.mixinextras.injector.wrapoperation.Operation
import com.mojang.blaze3d.vertex.PoseStack
import net.minecraft.client.Minecraft
import net.minecraft.client.player.AbstractClientPlayer
import net.minecraft.client.renderer.LevelRenderer
import net.minecraft.client.renderer.MultiBufferSource
import net.minecraft.client.renderer.RenderType
import net.minecraft.util.Mth
import net.minecraft.world.phys.Vec3
import org.joml.AxisAngle4f
import org.joml.Matrix3f
import org.joml.Matrix4f
import org.joml.Quaternionf
import org.joml.Vector3d
import org.joml.Vector3f
import org.joml.Vector4f
object PlayerRendererHook {
var maxPartialTicks = 0F
const val disableRollableRenderDebug: Boolean = false
fun before(
player: AbstractClientPlayer,
entityYaw: Float,
partialTicks: Float,
poseStack: PoseStack,
multiBufferSource: MultiBufferSource,
i: Int
) {
val shouldRoll = player is Rollable && player.shouldRoll()
if (player.vehicle is Rideable) {
//We want to ignore where vanilla is placing the player, so get rid of any transformations that have occured so far
poseStack.setIdentity()
//The actual rendering of the player model expects to be able to use coordinates relative to the camera's position
//So all of our coordinates need to be offset by the camera position
val cameraPos = Minecraft.getInstance().gameRenderer.mainCamera.position
val vehicle = player.vehicle as Rideable
val entity = player.vehicle!!
//Get the seat
val seatIndex = vehicle.riding.entity.passengers.indexOf(player)
val seat = vehicle.riding.entity.seats[seatIndex]
var playerPosition = seat.offset
//If we are riding a posable entity, use the locator position over the seat offset
if (entity is PosableEntity) {
val posableState = entity.delegate as PosableState
val locator = posableState.locatorStates[seat.locator]!!
val locatorOffset = locator.getOrigin().subtract(entity.position())
val oldLocatorPos = locatorOffset.add(Vec3(entity.xOld, entity.yOld, entity.zOld))
val curLocatorPos = oldLocatorPos.lerp(locator.getOrigin(), partialTicks.toDouble()).subtract(cameraPos)
playerPosition = curLocatorPos
}
if (shouldRoll) {
//Here, basically what we are doing is figuring out the coords of the rotated locator.
//We have to do the same rotations that are done in the pokemon renderer
val rollable = player as Rollable
val pokemonCenter = Vec3(entity.xOld, entity.yOld, entity.zOld).lerp(entity.position(), partialTicks.toDouble()).add(0.0, entity.bbHeight / 2.0, 0.0).subtract(cameraPos)
val transformationMatrix = Matrix4f()
transformationMatrix.translate(pokemonCenter.toVector3f())
transformationMatrix.rotate(180f.toRadians() - (rollable.yaw).toRadians(), rollable.upVector, transformationMatrix)
transformationMatrix.rotate((-rollable.pitch).toRadians(), rollable.leftVector, transformationMatrix)
transformationMatrix.rotate((-rollable.roll).toRadians(), rollable.forwardVector, transformationMatrix)
transformationMatrix.translate(pokemonCenter.toVector3f().negate())
playerPosition = transformationMatrix.transformPosition(playerPosition)
//We need to move "down" half a block to account for the player crouching pose.
playerPosition = playerPosition.subtract(Vector3f(rollable.upVector).mul(0.5F).toVec3d())
}
else {
playerPosition = playerPosition.subtract(0.0, 0.5, 0.0)
}
poseStack.translate(playerPosition.x, playerPosition.y, playerPosition.z)
if (shouldRoll) {
val orientation = Matrix4f((player as Rollable).orientation ?: Matrix3f())
val rotation = orientation.getRotation(AxisAngle4f())
poseStack.mulPose(Quaternionf(rotation))
}
}
}
fun renderAxisLines(
player: AbstractClientPlayer,
entityYaw: Float,
partialTicks: Float,
poseStack: PoseStack,
multiBufferSource: MultiBufferSource,
i: Int
) {
if (player is Rollable) {
val pose = poseStack.last().pose()
val buffer = multiBufferSource.getBuffer(RenderType.lines())
//"Forward" is red
val forwardVector = player.forwardVector.mul(2F)
buffer.addVertex(pose, 0F, 0F, 0F).setColor(1F, 0F, 0F, 1F).setNormal(1F, 1F, 1F)
buffer.addVertex(pose, forwardVector.x, forwardVector.y, forwardVector.z).setColor(1F, 0F, 0F, 1F).setNormal(1F, 1F, 1F)
//"Left" is blue
val leftVector = player.leftVector.mul(2F)
buffer.addVertex(pose, 0F, 0F, 0F).setColor(0F, 0F, 1F, 1F).setNormal(1F, 1F, 1F)
buffer.addVertex(pose, leftVector.x, leftVector.y, leftVector.z).setColor(0F, 0F, 1F, 1F).setNormal(1F, 1F, 1F)
//"Up" is green
val upVector = player.upVector.mul(2F)
buffer.addVertex(pose, 0F, 0F, 0F).setColor(0F, 1F, 0F, 1F).setNormal(1F, 1F, 1F)
buffer.addVertex(pose, upVector.x, upVector.y, upVector.z).setColor(0F, 1F, 0F, 1F).setNormal(1F, 1F, 1F)
}
}
}
@@ -167,14 +167,6 @@ class PokemonRenderer(
val driver = entity.firstPassenger ?: return
val rollable = driver as? Rollable ?: return
//val camera = Minecraft.getInstance().gameRenderer.mainCamera
//val isThirdPerson = camera.isDetached
//val vehicleOrigin = entity.position()
//val driverOrigin = if (isThirdPerson) driver.position() else driver.eyePosition
//val offset = driverOrigin.subtract(vehicleOrigin)
poseMatrix.pushPose()
if(!DISABLE_ROLLING_DEBUG && rollable.shouldRoll()){
@@ -25,5 +25,7 @@ object ServerSettings {
var displayEntityLevelLabel = Cobblemon.config.displayEntityLevelLabel
var displayEntityNameLabel = Cobblemon.config.displayEntityNameLabel
var maxPokemonLevel = Cobblemon.config.maxPokemonLevel
var maxPokemonFriendship = Cobblemon.config.maxPokemonFriendship
var maxDynamaxLevel = Cobblemon.config.maxDynamaxLevel
}
@@ -17,10 +17,12 @@ import com.cobblemon.mod.common.net.messages.client.storage.pc.OpenPCPacket
import com.cobblemon.mod.common.util.*
import com.mojang.brigadier.Command
import com.mojang.brigadier.CommandDispatcher
import com.mojang.brigadier.arguments.IntegerArgumentType
import com.mojang.brigadier.context.CommandContext
import com.mojang.brigadier.exceptions.SimpleCommandExceptionType
import net.minecraft.commands.CommandSourceStack
import net.minecraft.commands.Commands.literal
import net.minecraft.commands.Commands.argument
object PcCommand {
@@ -30,25 +32,36 @@ object PcCommand {
fun register(dispatcher : CommandDispatcher<CommandSourceStack>) {
dispatcher.register(literal(NAME)
.permission(CobblemonPermissions.PC)
.then(argument("box", IntegerArgumentType.integer(1))
.executes(this::execute)
)
.executes(this::execute)
)
}
private fun execute(context: CommandContext<CommandSourceStack>): Int {
val player = context.source.playerOrException
val box = try {
IntegerArgumentType.getInteger(context, "box")
} catch (e: IllegalArgumentException) {
1
}
val pc = player.pc()
if (player.isInBattle()) {
throw IN_BATTLE_EXCEPTION.create()
}
if (pc.boxes.size < box) {
throw SimpleCommandExceptionType(lang("command.pc.invalid-box", box, pc.boxes.size).red()).create()
}
PCLinkManager.addLink(PermissiblePcLink(pc, player, CobblemonPermissions.PC))
OpenPCPacket(pc.uuid).sendToPlayer(player)
OpenPCPacket(pc.uuid, box - 1).sendToPlayer(player)
context.source.level.playSoundServer(
position = context.source.player!!.position(),
sound = CobblemonSounds.PC_ON,
volume = 0.5F,
pitch = 1F
position = context.source.player!!.position(),
sound = CobblemonSounds.PC_ON,
volume = 0.5F,
pitch = 1F
)
return Command.SINGLE_SUCCESS
}
}
}
@@ -29,14 +29,14 @@ class FeatureFix(output: Schema) : PokemonFix(output) {
if (features.result().isPresent) {
return dynamic //already has Features nbt format... no work needed
}
var featureTag = emptyList<CompoundTag>()
var featureTag = mutableListOf<CompoundTag>()
if (dynamic.value is CompoundTag) {
var rootTag = dynamic.value as CompoundTag
var species = PokemonSpecies.getByIdentifier(rootTag.getString(DataKeys.POKEMON_SPECIES_IDENTIFIER).asResource())
if (species == null) {
return dynamic
}
SpeciesFeatures.getFeaturesFor(species!!).forEach {
SpeciesFeatures.getFeaturesFor(species).forEach {
val feature = it(rootTag) ?: return@forEach
var tag = CompoundTag()
tag.putString(FEATURE_ID, feature.name)
@@ -51,7 +51,10 @@ class FeatureFix(output: Schema) : PokemonFix(output) {
} else if (dynamic.value is JsonElement) {
var rootTag = (dynamic.value as JsonElement).asJsonObject
var species = PokemonSpecies.getByIdentifier(rootTag.get(DataKeys.POKEMON_SPECIES_IDENTIFIER).asString.asResource())
SpeciesFeatures.getFeaturesFor(species!!).forEach {
if (species == null) {
return dynamic
}
SpeciesFeatures.getFeaturesFor(species).forEach {
val feature = it(rootTag) ?: return@forEach
var tag = CompoundTag()
tag.putString(FEATURE_ID, feature.name)
@@ -8,18 +8,20 @@
package com.cobblemon.mod.common.datafixer.fix
import com.cobblemon.mod.common.util.DataKeys
import com.mojang.datafixers.schemas.Schema
import com.mojang.serialization.Dynamic
class ShoulderStateJsonFix(output: Schema) : PokemonFix(output) {
override fun fixPokemonData(dynamic: Dynamic<*>): Dynamic<*> {
val moveSetJson = dynamic.get("State").result()
val stateJson = dynamic.get("State").result()
//State not here
if (moveSetJson.isEmpty) {
if (stateJson.isEmpty) {
return dynamic
}
if (moveSetJson.get().mapValues.getOrThrow().size == 0) {
if (stateJson.get().mapValues.getOrThrow().isEmpty() ||
!stateJson.get().mapValues.getOrThrow().containsKey(dynamic.createString(DataKeys.POKEMON_STATE_TYPE))) {
return dynamic.remove("State")
}
@@ -35,6 +35,7 @@ import com.cobblemon.mod.common.util.asIdentifierDefaultingNamespace
import com.cobblemon.mod.common.util.cobblemonResource
import com.cobblemon.mod.common.util.lang
import com.cobblemon.mod.common.util.toBlockPos
import com.cobblemon.mod.common.util.weightedSelection
import net.minecraft.advancements.CriteriaTriggers
import net.minecraft.client.resources.sounds.EntityBoundSoundInstance
import net.minecraft.core.BlockPos
@@ -183,33 +184,19 @@ class PokeRodFishingBobberEntity(type: EntityType<out PokeRodFishingBobberEntity
}
fun chooseAdjustedSpawnBucket(buckets: List<SpawnBucket>, luckOfTheSeaLevel: Int): SpawnBucket {
val baseIncreases = listOf(2.5F, 0.5F, 0.2F) // Base increases for the first three buckets beyond the first
val baseValues = listOf(94.3F, 5.0F, 0.5F, 0.2F)
val adjustments = listOf(-4.1F, 2.5F, 1.0F, 0.6F)
val adjustedWeights = buckets.mapIndexed { index, bucket ->
if (index == 0) {
// Placeholder, will be recalculated
0.0F
} else {
val increase = if (index < baseIncreases.size) baseIncreases[index] else baseIncreases.last() + (index - baseIncreases.size + 1) * 0.15F
bucket.weight + increase * luckOfTheSeaLevel
if (index >= baseValues.size) {
return@mapIndexed bucket to bucket.weight
}
}.toMutableList()
val base = baseValues[index]
val adjustment = adjustments[index]
bucket to (base + adjustment * luckOfTheSeaLevel)
}.toMap()
// Recalculate the first bucket's weight to ensure the total is 100%
val totalAdjustedWeight = adjustedWeights.sum() - adjustedWeights[0] // Corrected to ensure the list contains Floats
adjustedWeights[0] = 100.0F - totalAdjustedWeight + buckets[0].weight
// Random selection based on adjusted weights
val weightSum = adjustedWeights.sum()
val chosenSum = kotlin.random.Random.nextDouble(weightSum.toDouble()).toFloat() // Ensure usage of Random from kotlin.random package
var sum = 0.0F
adjustedWeights.forEachIndexed { index, weight ->
sum += weight
if (sum >= chosenSum) {
return buckets[index]
}
}
return buckets.first() // Fallback
return buckets.weightedSelection { adjustedWeights[it]!! }!!
}
fun isOpenOrWaterAround(pos: BlockPos): Boolean {
@@ -335,7 +322,7 @@ class PokeRodFishingBobberEntity(type: EntityType<out PokeRodFishingBobberEntity
val buckets = Cobblemon.bestSpawner.config.buckets
// choose a spawn bucket according to weights no matter how many there are
// choose a spawn bucket according to weights and luck of the sea
chosenBucket = chooseAdjustedSpawnBucket(buckets, luckOfTheSeaLevel)
CobblemonEvents.BOBBER_BUCKET_CHOSEN.post(BobberBucketChosenEvent(chosenBucket, buckets, luckOfTheSeaLevel)) { event ->
chosenBucket = event.chosenBucket
@@ -698,10 +685,9 @@ class PokeRodFishingBobberEntity(type: EntityType<out PokeRodFishingBobberEntity
)
// This has a chance to fail, if the position has no suitability for a fishing context
// it could also just be a miss which
// means two attempts to spawn in the same location can have differing results (which is expected for
// randomness).
if (result == null) {
// it could also just be a miss which means two attempts to spawn in the same location
// can have differing results (which is expected for randomness).
if (result == null || result.isCompletedExceptionally) {
player.sendSystemMessage(lang("fishing.no_bite").red())
return false
}
@@ -109,6 +109,12 @@ class NPCEntity(world: Level) : AgeableMob(CobblemonEntities.NPC, world), Npc, P
val level: Int
get() = entityData.get(LEVEL)
var hideNameTag: Boolean
get() = entityData.get(HIDE_NAME_TAG)
set(value) {
entityData.set(HIDE_NAME_TAG, value)
}
var skill: Int? = null // range from 0 - 5
var baseScale: Float? = null
@@ -204,7 +210,7 @@ class NPCEntity(world: Level) : AgeableMob(CobblemonEntities.NPC, world), Npc, P
val BATTLE_IDS = SynchedEntityData.defineId(NPCEntity::class.java, UUIDSetDataSerializer)
val NPC_PLAYER_TEXTURE = SynchedEntityData.defineId(NPCEntity::class.java, NPCPlayerTextureSerializer)
val LEVEL = SynchedEntityData.defineId(NPCEntity::class.java, EntityDataSerializers.INT)
val HIDE_NAME_TAG = SynchedEntityData.defineId(NPCEntity::class.java, EntityDataSerializers.BOOLEAN)
// val BATTLING = Activity.register("npc_battling")
@@ -255,6 +261,7 @@ class NPCEntity(world: Level) : AgeableMob(CobblemonEntities.NPC, world), Npc, P
builder.define(BATTLE_IDS, setOf())
builder.define(NPC_PLAYER_TEXTURE, NPCPlayerTexture(ByteArray(1), NPCPlayerModelType.NONE))
builder.define(LEVEL, 1)
builder.define(HIDE_NAME_TAG, false)
}
override fun getAddEntityPacket(serverEntity: ServerEntity) = ClientboundCustomPayloadPacket(
@@ -318,6 +325,7 @@ class NPCEntity(world: Level) : AgeableMob(CobblemonEntities.NPC, world), Npc, P
nbt.put(DataKeys.NPC_DATA, MoLangFunctions.writeMoValueToNBT(data))
nbt.put(DataKeys.NPC_CONFIG, MoLangFunctions.writeMoValueToNBT(config))
nbt.put(DataKeys.NPC_LEVEL, IntTag.valueOf(level))
nbt.putBoolean(DataKeys.NPC_HIDE_NAME_TAG, hideNameTag)
nbt.putString(DataKeys.NPC_CLASS, npc.id.toString())
nbt.put(DataKeys.NPC_ASPECTS, ListTag().also { list -> appliedAspects.forEach { list.add(StringTag.valueOf(it)) } })
nbt.put(DataKeys.NPC_VARIATION_ASPECTS, ListTag().also { list -> variationAspects.forEach { list.add(StringTag.valueOf(it)) } })
@@ -383,6 +391,7 @@ class NPCEntity(world: Level) : AgeableMob(CobblemonEntities.NPC, world), Npc, P
override fun load(nbt: CompoundTag) {
npc = NPCClasses.getByIdentifier(ResourceLocation.parse(nbt.getString(DataKeys.NPC_CLASS))) ?: NPCClasses.classes.first()
entityData.set(LEVEL, nbt.getInt(DataKeys.NPC_LEVEL).takeIf { it != 0 } ?: 1)
entityData.set(HIDE_NAME_TAG, nbt.getBoolean(DataKeys.NPC_HIDE_NAME_TAG))
super.load(nbt)
data = MoLangFunctions.readMoValueFromNBT(nbt.getCompound(DataKeys.NPC_DATA)) as VariableStruct
config = if (nbt.contains(DataKeys.NPC_CONFIG)) MoLangFunctions.readMoValueFromNBT(nbt.getCompound(DataKeys.NPC_CONFIG)) as VariableStruct else VariableStruct()
@@ -490,6 +499,7 @@ class NPCEntity(world: Level) : AgeableMob(CobblemonEntities.NPC, world), Npc, P
fun initialize(level: Int) {
variationAspects.clear()
entityData.set(HIDE_NAME_TAG, npc.hideNameTag)
entityData.set(LEVEL, level)
npc.config.forEach { it.applyDefault(this) }
npc.variations.values.forEach { this.variationAspects.addAll(it.provideAspects(this)) }
@@ -31,7 +31,6 @@ import com.cobblemon.mod.common.api.molang.ObjectValue
import com.cobblemon.mod.common.api.net.serializers.PlatformTypeDataSerializer
import com.cobblemon.mod.common.api.net.serializers.PoseTypeDataSerializer
import com.cobblemon.mod.common.api.net.serializers.StringSetDataSerializer
import com.cobblemon.mod.common.api.pokemon.PokemonSpecies
import com.cobblemon.mod.common.api.pokemon.feature.ChoiceSpeciesFeatureProvider
import com.cobblemon.mod.common.api.pokemon.feature.FlagSpeciesFeature
import com.cobblemon.mod.common.api.pokemon.feature.SpeciesFeatures
@@ -150,9 +149,7 @@ import net.minecraft.world.phys.AABB
import net.minecraft.world.phys.Vec2
import net.minecraft.world.phys.Vec3
import org.joml.Matrix3f
import org.joml.Matrix4f
import org.joml.Vector3f
import org.joml.Vector3fc
@Suppress("unused")
open class PokemonEntity(
@@ -1605,7 +1602,6 @@ open class PokemonEntity(
override fun tickRidden(driver: Player, movementInput: Vec3) {
super.tickRidden(driver, movementInput)
this.riding.tick(this, driver, movementInput)
val rotation = this.getControlledRotation(driver)
setRot(rotation.y, rotation.x)
this.yHeadRot = this.yRot
@@ -1674,6 +1670,10 @@ open class PokemonEntity(
return this.riding.controlledRotation(this, controller as Player)
}
override fun onPassengerTurned(entityToUpdate: Entity) {
return this.riding.clampPassengerRotation(this, entityToUpdate as? LivingEntity ?: return)
}
override fun positionRider(passenger: Entity, positionUpdater: MoveFunction) {
if (this.hasPassenger(passenger)) {
val index = passengers.indexOf(passenger).takeIf { it >= 0 && it < seats.size } ?: return
@@ -1689,7 +1689,8 @@ open class PokemonEntity(
positionUpdater.accept(passenger, this.x + rotatedOffset.x, this.y + rotatedOffset.y, this.z + rotatedOffset.z)
if (passenger is LivingEntity) {
passenger.yRot = this.yRot
this.riding.updatePassengerRotation(this, passenger)
this.riding.clampPassengerRotation(this, passenger)
}
}
}
@@ -1781,17 +1782,15 @@ open class PokemonEntity(
private fun sidedCodec(): Codec<Pokemon> = if (this.level().isClientSide) Pokemon.CLIENT_CODEC else Pokemon.CODEC
override fun resolvePokemonScan(): PokedexEntityData? {
return PokemonSpecies.getByIdentifier(this.exposedSpecies.resourceIdentifier)?.let { species ->
PokedexEntityData(
species = species,
form = this.form,
gender = this.pokemon.gender,
aspects = this.aspects,
shiny = this.pokemon.shiny,
level = this.labelLevel(),
ownerUUID = this.ownerUUID
)
}
return PokedexEntityData(
pokemon = pokemon,
disguise = this.effects.mockEffect?.let {
PokedexEntityData.DisguiseData(
species = it.exposedSpecies ?: pokemon.species,
form = it.exposedForm ?: pokemon.form,
)
}
)
}
override fun resolveEntityScan(): LivingEntity {
@@ -34,6 +34,7 @@ import net.minecraft.network.chat.Component
import net.minecraft.network.syncher.EntityDataAccessor
import net.minecraft.world.damagesource.DamageSource
import net.minecraft.world.entity.ai.attributes.Attributes
import net.minecraft.world.item.ItemStack
import net.minecraft.world.level.pathfinder.PathType
/** Handles purely server logic for a Pokémon */
@@ -258,6 +259,8 @@ class PokemonServerDelegate : PokemonSideDelegate {
if (entity.ownerUUID == null && entity.owner == null) {
entity.level().broadcastEntityEvent(entity, 60.toByte()) // Sends smoke effect
if(entity.level().gameRules.getBoolean(CobblemonGameRules.DO_POKEMON_LOOT)) {
val heldItem = (entity as PokemonEntity?)?.pokemon?.heldItemNoCopy() ?: ItemStack.EMPTY
if (!heldItem.isEmpty) entity.spawnAtLocation(heldItem.item)
(entity.drops ?: entity.pokemon.form.drops).drop(entity, entity.level() as ServerLevel, entity.position(), entity.killer)
}
}
@@ -488,6 +488,7 @@ object CobblemonItemGroups {
entries.accept(CobblemonItems.RIBBON_SWEET)
entries.accept(CobblemonItems.AUSPICIOUS_ARMOR)
entries.accept(CobblemonItems.MALICIOUS_ARMOR)
entries.accept(CobblemonItems.SHELL_HELMET)
}
private fun heldItemEntries(displayContext: ItemDisplayParameters, entries: Output) {
@@ -20,6 +20,13 @@ class LinkCableItem : CobblemonItem(Properties()), PokemonEntityInteraction {
override fun processInteraction(player: ServerPlayer, entity: PokemonEntity, stack: ItemStack): Boolean {
val pokemon = entity.pokemon
pokemon.lockedEvolutions.filterIsInstance<TradeEvolution>().forEach { evolution ->
// Prevent Pokémon that require a specific trading partner for evolution (e.g., Shelmet and Karrablast)
// from evolving via link cable. These Pokémon must either be traded with another player or use an
// alternative single-player evolution method.
if (!evolution.requiredContext.originalString.isEmpty()) {
return@forEach
}
// If an evolution is possible non-optional or has been successfully queued we will consume the item and stop
// validate requirements to respect required held items and such.
if (evolution.requirements.all { it.check(pokemon) } && evolution.evolve(pokemon)) {
@@ -23,7 +23,9 @@ class ServerSettingsPacket internal constructor(
val preventCompletePartyDeposit: Boolean,
val displayEntityLevelLabel: Boolean,
val displayEntityNameLabel: Boolean,
val maxPokemonLevel: Int
val maxPokemonLevel: Int,
val maxPokemonFriendship: Int,
val maxDynamaxLevel: Int
) : NetworkPacket<ServerSettingsPacket> {
override val id = ID
override fun encode(buffer: RegistryFriendlyByteBuf) {
@@ -31,9 +33,11 @@ class ServerSettingsPacket internal constructor(
buffer.writeBoolean(Cobblemon.config.displayEntityLevelLabel)
buffer.writeBoolean(Cobblemon.config.displayEntityNameLabel)
buffer.writeInt(Cobblemon.config.maxPokemonLevel)
buffer.writeInt(Cobblemon.config.maxPokemonFriendship)
buffer.writeInt(Cobblemon.config.maxDynamaxLevel)
}
companion object {
val ID = cobblemonResource("server_settings")
fun decode(buffer: RegistryFriendlyByteBuf) = ServerSettingsPacket(buffer.readBoolean(), buffer.readBoolean(), buffer.readBoolean(), buffer.readInt())
fun decode(buffer: RegistryFriendlyByteBuf) = ServerSettingsPacket(buffer.readBoolean(), buffer.readBoolean(), buffer.readBoolean(), buffer.readInt(), buffer.readInt(), buffer.readInt())
}
}
@@ -25,14 +25,14 @@ import net.minecraft.resources.ResourceLocation
* @author Licious
* @since December 29th, 2022
*/
internal class UnvalidatedPlaySoundS2CPacket(
val sound: ResourceLocation,
val category: SoundSource,
val x: Double,
val y: Double,
val z: Double,
val volume: Float,
val pitch: Float
class UnvalidatedPlaySoundS2CPacket(
var sound: ResourceLocation,
var category: SoundSource,
var x: Double,
var y: Double,
var z: Double,
var volume: Float,
var pitch: Float
) : NetworkPacket<UnvalidatedPlaySoundS2CPacket> {
override val id = ID
@@ -18,7 +18,7 @@ import net.minecraft.network.protocol.PacketUtils
import net.minecraft.network.protocol.game.ClientboundAddEntityPacket
import net.minecraft.world.phys.Vec3
abstract class SpawnExtraDataEntityPacket<T: NetworkPacket<T>, E : Entity>(private val vanillaSpawnPacket: ClientboundAddEntityPacket) : NetworkPacket<T> {
abstract class SpawnExtraDataEntityPacket<T: NetworkPacket<T>, E : Entity>(var vanillaSpawnPacket: ClientboundAddEntityPacket) : NetworkPacket<T> {
override fun encode(buffer: RegistryFriendlyByteBuf) {
this.encodeEntityData(buffer)
this.vanillaSpawnPacket.write(buffer)

Some files were not shown because too many files have changed in this diff Show More