Skip to content

Commit

Permalink
v2.0.0 (#13)
Browse files Browse the repository at this point in the history
* another null obj fix

* starting work on v2.0.0

* quick fixin

* update charhandler

* cleanup in replaceChar

* use hxjsonast instead of haxe.json

* I have a better idea

* some refactoring

* new alias for gf

* Merge pull request #8 from experiment/freeplay-dj-change

* add the option

* started 2.0.0 changelog

* bpm for random

* decrease the frame by 1 again

* pico json patch to fix the offsets for cheer

* code format

* code cleanup

* some timer stuff

* don't configure the icon if the icon id is the same

* the icon grid now scrolls relative to the song's bpm

* cap the bpm speed

* quick null obj ref bugfix

* beathit already does this for us

* some more traces

* minor optimization

* add more information to the trace

* nevermind this is way too spammy

* fix pico-dark not playing the pico results anim

* bugfix: Prevent re-opening of the CharacterMenu substate when already open

* rework the icon grid a little to scroll diagonally

* i think this is a better word for it

* use a static variable for speed

* complete save data overhaul

* more 2.0.0 changelog + update a trace

* small changes to the migration function

* new `voiceID` variable + rework suffixes

* fix inconsistency

* oops

* quick fix

* switch back to bf dj if the character id isnt owned

* add trace

* change this

* use currentCharacterId instead of bf

* add null checks

* quick fix

* improved alignment for scrolling

* update changelog

* character lerping stuff in progress

* code format

* simplify ui fixes

* adjust offsets

* null check for ischaracterunlocked

* typewriter effect for description

* only the currently selected character will dance now

* implement mouse scrolling

* working reimplementation of lockedchill

* remove unused var

* `loadJSONDataCache()` already checks for this

* some quick fixes

* update

* get the bpm for freeplayrandom instead of a hardcoded value

* quick fix

* small camera bop

* small changes

* bugfix: destory the character substate if it still exists when opening freeplay

* code format

* 10pm changes

* update `newGraphic` offsets to compensate

* add bf burp

* significant reformat

* guess the formatter changed its mind

* i figured it out

* might as well

* fix this

* small modification to formatting

* changes made on a saturday night

* refactor controls to use playersettings controls

* optimized spritesheet for locked man

* you can now spam

* lol

* update the version rule

* new script event for when the substate is opened

* you can partially skip the unlock anim now

* remove this

* move preferences to a stringmap

* update charactermenu to account for the map change

* update

* ok i found the issue

* update changelog to reflect recent changes

* oops

* missed this too

* fixed wrong date

* play the right animation for lock

* code format

* move variants to a separate mod

* make the hotkey no longer bind to a boolean

* update changelog

* jump to default after resetting

* bugfix: Fix the description text cutting off

* a slightly better implementation

* replace indexof with contains

* replace more instances

* add traces

* literally could not tell you why the character sprites randomly began disappearing

* aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

* ok it's fixed for real this time

* how about...?

* fix for animateatlas characters

* finally fix it

* code format

* swap the order of these

* add a trace

* fix for story mode

* functionality for loading and saving data to json for debugging

* make the debug features only accessible on debug builds

* code format

* change dumping to save the json directly instead of prompting

* use full path instead

* reorganize the code

* lol

* a better way of checking for a debug build

* add useful variables to the flixel watch window

* update changelog

* lol

* code format

* write to example mods

* quick platform check

* clean up

* code format

* pass the save data to freeplayDJReplace

* holding shift now skips the unlock animation

* small optimizations

* description text is now automatically resized to fit in the box

* edit gitignore

* code format

* null check

* AAAAAAAAAAAAAA

* maybe?

* remove repeated lines

* create chardesc once instead of every time the character is changed

* fix formatting errors

* code cleanup + add intro swap frame

* A better way of replacing the results animations

* fix some copypastes lol

* move charhandler to a variable instead of calling modulehandler everytime

* remove unused import

* quick fixes

* update the changelog to reflect the latest changes

* fix: reset the font size and letter spacing to default

* code format and other stuff

* charHandler -> CharacterHandler

* it sounded like a good idea at the time, but...

* rework the 2.0.0 entry in the changelog

* visual indicator for variations

* update changelog

* curCharID -> currentCharacterID

* move some stuff around

* brand new char select icon

* fix for results

* CLIP IT AND SHIP IT

* i think that's everything
  • Loading branch information
AbnormalPoof authored Dec 17, 2024
1 parent c39ebf6 commit ce8bdaa
Show file tree
Hide file tree
Showing 28 changed files with 2,912 additions and 1,929 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# macOS garbage data
.DS_Store
__MACOSX/

# Dumped Funker Selector save data
data/FS_dumpedSave.json
57 changes: 49 additions & 8 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,48 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [2.0.0] - 2024-12-17
### Added
- The Freeplay DJ will now change if your character is associated with a Playable Character (and has valid Freeplay DJ data).
- You can disable this in the Options Menu.
- This also changes the backing text to what you set in the Playable Character data.
- Added 2 new Script Events that fire when you enter/exit the Character Menu SubState.
### Changed
- **Complete UI makeover and refactor**:
- Characters are now shown next to eachother in a scrollable layout
- Character descriptions are now shown with a typewriter effect.
- In addition, the description text is resized dynamically to fit the text box.
- Text might be a bit unreadable the longer it is, so be careful!
- You can now use the scroll wheel to navigate.
- The menu now uses your controls as configured in the Options Menu.
- The icon grid now scrolls digonally, the scroll speed is relative to the current song's BPM.
- The speed is capped at 300 BPM. I don't want to give you motion sickness.
- There is now a visual indicator for character variations, the menu will tell you how many variations are available if any exist.
- Press the DEBUG MENU key (look in Options -> Controls to see what it's mapped to) to see the variation and associated songs.
- **Your characters might be positioned weird, please update your character positions in the JSON data.**
- **The menu might take a while to load when it's opened for the first time, especially if "Preload Sprites" is disabled!!**
- Completely reworked the save data system. Internally, everything is now one object instead of multiple.
- Your save data will be migrated!
- Reworked the structure for suffixes in the JSON data.
- **This is a breaking change for characters which use suffixes!**
- Please see the documentation for the new structure.
- Added several new values in the JSON data:
- `speaker`: An alias for the GF character type.
- `voiceID`: A custom ID that can be used in place of the character ID when using Vocal Replacement.
- `introSwapFrame`: The frame where the turntable stops moving and the character appears in the Freeplay DJ's intro animation.
- This is used when swapping out DJs, the default value is 3.
- You can now skip the unlock animation by holding shift before the animation is played.
- If "Random" is selected, the BPM is now obtained from the song metadata instead of using a hardcoded value.
- Reworked how the Result Screen animations/music are swapped out.
- This should have no effect on the functionality itself, it's simply a code refactor.
- The icon in Freeplay has been remade, it now shows the health icon of your currently selected Playable Character.
### Fixed
- Fixed Pico's results animations not playing if Pico (Playable) was used on Week 2 Erect.
- Fixed a bug where the Character Menu SubState can be re-opened if it was already open.
### Removed
- All the Boyfriend / Pico variants have been moved to a separate mod.
- Removed the `size` and `offsets` properties from the JSON description data as the description text is now dynamically resized.

## [1.5.2] - 2024-10-23
### Fixed
- Fixed an issue where Character Data wasn't parsed properly if the Character ID is different from the JSON filename.
Expand All @@ -19,12 +61,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
## [1.5.0] - 2024-10-22
### Added
- The characters now bop to the BPM of the currently selected song in Freeplay.
- New `mustUnlock` variable for JSON characters. If enabled, your character will become locked until you meet a requirement specified in the JSON file.
- Please see the documentation on how to do this.
- A brand new unlock system. You can assign an unlock condition for your character.
- Please see the documentation on how to do this.
- In addition: Pico (Playable), Pico (Christmas), Daddy Dearest and all the Boyfriend variants are now locked, requiring you to complete their specified requirements to unlock them.
- You'll probably be seeing the unlock animation a LOT if you already completed them. This is only done once!
- There's also a new `unlockCondition` variable for description data in turn.
- The window title will change if you're in the Character Menu.
- The window title will now change if you're in the Character Menu.
- Added better visual feedback for selecting a character.
- New option which allows you to change the SFX used in the menu. Currently, you can only switch between `Funkin' Main Menu` and `Funkin' Character Select`
### Changed
Expand All @@ -48,7 +89,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
- This is due to functions in the code that do not work on v0.5.0.
- Please use v0.5.1 instead.

## [1.4.0] - 2024-09-12
## [1.4.0] - 2024-09-30
### Added
- v0.5.0 support.
- You can now have multiple song IDs for Character Variations as an Array.
Expand Down Expand Up @@ -85,7 +126,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
- Optimized a few spots in the `charSelect` module and `CharacterMenu` substate.
- Refactored vocal replacement. `PlayState.instance.voices` is now replaced properly instead of the hacky way of setting `PlayState.instance.currentChart.characters.player` and basically running with it.
- Use a more memory-efficient method for "Preload Sprites".
### Fixed
### Fixed
- Fixed "Preload Sprites" doing the opposite of what it was supposed to do.
- In addition, disabling the option will now remove the sprites from memory.
- Fixed a random Null Object Reference from occuring when "Default" was selected.
Expand All @@ -99,7 +140,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
- Added a count to the UI which shows the current character, and the total amount of characters for the current page.
### Changed
- Gave the entire UI a fresh coat of paint. If the current character is a JSON Character, they will have their sprites displayed, along with a neat little description about them!
- The UI now uses PhantomMuff by Cracsthor! Allows for text resizing, making the UI less cluttered in general.
- The UI now uses PhantomMuff by Cracsthor! Allows for text resizing, making the UI less cluttered in general.
- With this UI overhaul comes some new options related to it:
- Simplify UI: Simplifies the UI if it's too much.
- Preload Sprites: Wether to preload the character sprites or not.
Expand All @@ -122,4 +163,4 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),

## [1.0.0] - 2024-07-21
### Added
- Pretty much everything.
- Pretty much everything.
4 changes: 4 additions & 0 deletions _merge/data/players/pico.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[
{ "op": "replace", "path": "/freeplayDJ/text1", "value": "PICO PICO PICO" },
{ "op": "replace", "path": "/freeplayDJ/animations/4/offsets", "value": [970, 270] }
]
4 changes: 2 additions & 2 deletions _polymod_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
"description": "Adds a Character Select in Freeplay! No more needing to replace Boyfriend or Pico for reskins.",
"author": "kagaminerinlen",
"api_version": "0.5.0",
"mod_version": "1.5.2",
"mod_version": "2.0.0",
"license": "MIT"
}
}
20 changes: 0 additions & 20 deletions data/funkerSelector/bf-car.json

This file was deleted.

20 changes: 0 additions & 20 deletions data/funkerSelector/bf-christmas.json

This file was deleted.

20 changes: 0 additions & 20 deletions data/funkerSelector/bf-holding-gf.json

This file was deleted.

21 changes: 0 additions & 21 deletions data/funkerSelector/bf-pixel.json

This file was deleted.

5 changes: 2 additions & 3 deletions data/funkerSelector/bf.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@
"description": {
"text": "The main protagonist of Friday Night Funkin', sporting his iconic blue hair and red-blue cap. Girlfriend loves him, her parents on the other hand..."
},
"characterMenu":
{
"characterMenu": {
"position": [150, 250],
"scale": 1
}
}
}
2 changes: 1 addition & 1 deletion data/funkerSelector/gf.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
},
"characterMenu":
{
"position": [50, 100],
"position": [30, 100],
"scale": 0.7,
"selectedAnim": "cheer"
}
Expand Down
20 changes: 0 additions & 20 deletions data/funkerSelector/pico-christmas.json

This file was deleted.

5 changes: 2 additions & 3 deletions data/funkerSelector/pico-playable.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@
"text": "It's Pico from the 1999 Flash Game: 'Pico's School'! featured as an opponent in Week 3, and as a playable character in WeekEnd 1.",
"unlockCondition": "Beat WeekEnd 1 on any difficulty."
},
"characterMenu":
{
"characterMenu": {
"position": [150, 200],
"scale": 1
},
Expand All @@ -22,4 +21,4 @@
"songVariation": "erect"
}
]
}
}
61 changes: 36 additions & 25 deletions docs/Funker Selector JSON Character Format.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ The mod queries `data/funkerSelector/` at runtime and parses the JSON files in t
"characterID": "bf",
"characterType": "bf",
"description": {
"text": "The main protagonist of Friday Night Funkin', sporting his iconic blue hair and red-blue cap. Girlfriend loves him, her parents on the other hand...",
"size": 35,
"offsets": [0, 0]
"text": "The main protagonist of Friday Night Funkin', sporting his iconic blue hair and red-blue cap. Girlfriend loves him, her parents on the other hand..."
},
"characterMenu":
{
Expand Down Expand Up @@ -61,8 +59,10 @@ The Character ID to use, this is ***needed*** or else the character will not sho
```json
"characterType": "bf"
```
The character type, accepted values are: `bf`, `gf`, `dad`, `player`, and `opponent`.
(`player` and `opponent` are just aliases for `bf` and `dad` respectively.)
The character type, accepted values are: `bf`, `gf`, `dad`, `player`, `speaker`, and `opponent`.
(`player`, `speaker`, and `opponent` are just aliases for `bf`, `gf`, and `dad` respectively.)

---

```json
"mustUnlock": false
Expand All @@ -72,6 +72,21 @@ You'll have to specify an unlock method.

---

```json
"voiceID": "bf"
```
The ID to use for Vocal Replacement, defaults to the character ID.

---

```json
"introSwapFrame": 4
```
The frame where the turntable stops moving and the character appears in the Freeplay DJ's intro animation. This is used for swapping out DJs.
The default value is 3.

---

#### Unlock data
```json
"unlockMethod": {
Expand Down Expand Up @@ -120,58 +135,54 @@ The required difficulties, defaults to `["easy", "normal", "hard"]`.

---

***(These will be grouped together since they serve basically the same functionality.)***
#### Suffix data

```json
"gameOverMusicSuffix": ""
"suffixes": {
"gameOverMusic": "-pico",
"blueBall": "-pico",
"pauseMusic": "-pico"
}
```

```json
"gameOverMusic": "-pico"
```
The music suffix used in the Game Over screen.

```json
"blueBallSuffix": ""
"blueBall": "-pico"
```
The blue ball suffix used in the Game Over screen.

```json
"pauseMusicSuffix": ""
"pauseMusic": "-pico"
```
The music suffix used in the Pause Menu.

You can use pretty much any suffix for these three as long as it's valid (exists in the files, either through a mod or the game's assets).
For example, Boyfriend (Pixel) uses `-pixel`, while Pico (Playable) uses `-pico`!
For example, Boyfriend (Pixel) uses `-pixel`, while Pico (Playable) uses `-pico`.

---

#### Description data

```json
"description": {
"text": "The main protagonist of Friday Night Funkin', sporting his iconic blue hair and red-blue cap. Girlfriend loves him, her parents on the other hand...",
"size": 35,
"offsets": [0, 0]
"text": "The main protagonist of Friday Night Funkin', sporting his iconic blue hair and red-blue cap. Girlfriend loves him, her parents on the other hand..."
}
```
This is a short description of the character, with a few properties:

```json
"text": "The main protagonist of Friday Night Funkin', sporting his iconic blue hair and red-blue cap. Girlfriend loves him, her parents on the other hand..."
```
```
The text itself.

```json
"unlockCondition": "Beat WeekEnd 1 to unlock."
```
The unlock condition that's shown if the character is locked. This overrides the description text!

```json
"size": 35
```
The font size.

```json
"offsets": [0, 0]
```
The offsets for the description. These are ***not*** the actual X and Y coordinates of the text, this is mainly for adjustment.
The unlock condition that's shown if the character is locked. This overrides the description text!

---

Expand Down
File renamed without changes.
Loading

0 comments on commit ce8bdaa

Please sign in to comment.