Skip to content

Commit

Permalink
WIP dialogue boxes maintenance
Browse files Browse the repository at this point in the history
  • Loading branch information
Yoshubs authored and Yoshubs committed Sep 27, 2021
1 parent 807f6b4 commit d53d566
Show file tree
Hide file tree
Showing 26 changed files with 345 additions and 156 deletions.
Binary file added assets/images/UI/simplylove/base/combo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"position": [515, 370],
"textPos": [200, 480],
"scale": 5.4,
"antialiasing": false,
"singleFrame": true,
"doFlip": false,
"bgColor": [255, 255, 255],
"states": {
"normal": {
"open": ["Spirit Textbox spawn instance 1"],
"default": ["Spirit Textbox spawn instance 1"]
}
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions assets/images/dialogue/boxes/dialogueBox-evil/dialogueBox-evil.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<TextureAtlas imagePath="dialogueBox-evil.png">
<!-- Created with Adobe Animate version 20.0.0.17400 -->
<!-- http://www.adobe.com/products/animate.html -->
<SubTexture name="Spirit Textbox spawn instance 10000" x="0" y="0" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10001" x="0" y="0" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10002" x="259" y="0" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10003" x="259" y="0" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10004" x="0" y="155" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10005" x="0" y="155" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10006" x="259" y="155" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10007" x="259" y="155" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10008" x="0" y="310" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10009" x="0" y="310" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10010" x="259" y="310" width="249" height="145"/>
<SubTexture name="Spirit Textbox spawn instance 10011" x="259" y="310" width="249" height="145"/>
</TextureAtlas>
Binary file removed assets/images/menus/base/title/FELogo.png
Binary file not shown.
Binary file added assets/images/menus/base/title/foreverlogo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions assets/images/menus/base/title/foreverlogo.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version='1.0' encoding='utf-8'?>
<TextureAtlas imagePath="foreverlogo.png">
<SubTexture name="forever bop0000" x="0" y="0" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
<SubTexture name="forever bop0001" x="1578" y="0" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
<SubTexture name="forever bop0002" x="0" y="976" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
<SubTexture name="forever bop0003" x="1578" y="976" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
<SubTexture name="forever bop0004" x="0" y="1952" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
<SubTexture name="forever bop0005" x="1578" y="1952" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
<SubTexture name="forever bop0006" x="0" y="2928" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
<SubTexture name="forever bop0007" x="1578" y="2928" width="1578" height="976" frameX="0" frameY="0" frameWidth="1578" frameHeight="976" />
</TextureAtlas>
18 changes: 18 additions & 0 deletions assets/songs/roses/dialogue.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"box": "dialogueBox-pixel",
"boxState": "normal",
"dialogue": [
{
"portrait": "senpai",
"expression": "mad",
"text": "Not bad for an ugly worm."
},
{
"text": "But this time I'll rip your nuts off \nright after your girlfriend \nfinishes gargling mine."
},
{
"portrait": "bf-pixel",
"text": "Bop beep be be skdoo bep"
}
]
}
3 changes: 0 additions & 3 deletions assets/songs/roses/rosesDialogue.txt

This file was deleted.

4 changes: 2 additions & 2 deletions assets/songs/senpai/dialogue.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
{
"portrait": "senpai",
"expression": "normal",
"text": "Ah, a new fair maiden has come in search of true love!"
"text": "Ah, a new fair maiden has come \nin search of true love!"
},
{
"text": "A serenade between gentlemen shall decide where her beautiful heart shall reside."
"text": "A serenade between gentlemen \nshall decide where her beautiful \nheart shall reside."
},
{
"portrait": "bf-pixel",
Expand Down
3 changes: 0 additions & 3 deletions assets/songs/senpai/senpaiDialogue.txt

This file was deleted.

23 changes: 23 additions & 0 deletions assets/songs/thorns/dialogue.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"box": "dialogueBox-evil",
"boxState": "normal",
"dialogue": [
{
"portrait": "senpai",
"expression": "mad",
"text": "Direct contact with real humans, \nafter being trapped in here for \nso long..."
},
{
"text": "and HER of all people."
},
{
"text": "I'll make her father pay for what \nhe's done to me and all the \nothers,,,,"
},
{
"text": "I'll beat you and make you take \nmy place."
},
{
"text": "You don't mind your bodies \nbeing borrowed right? It's only \nfair..."
}
]
}
5 changes: 0 additions & 5 deletions assets/songs/thorns/thornsDialogue.txt

This file was deleted.

6 changes: 3 additions & 3 deletions source/ForeverAssets.hx
Original file line number Diff line number Diff line change
Expand Up @@ -185,9 +185,9 @@ class ForeverAssets
newStaticArrow.updateHitbox();
newStaticArrow.antialiasing = false;

newStaticArrow.addOffset('static', -67, -75);
newStaticArrow.addOffset('pressed', -67, -75);
newStaticArrow.addOffset('confirm', -67, -75);
newStaticArrow.addOffset('static', -67, -50);
newStaticArrow.addOffset('pressed', -67, -50);
newStaticArrow.addOffset('confirm', -67, -50);

case 'chart editor':
newStaticArrow.loadGraphic(Paths.image('UI/forever/base/chart editor/note_array'), true, 157, 156);
Expand Down
75 changes: 42 additions & 33 deletions source/Init.hx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,15 @@ import openfl.filters.ColorMatrixFilter;

using StringTools;

/**
Enumerator for settingtypes
**/
enum SettingTypes
{
Checkmark;
Selector;
}

/**
This is the initialisation class. if you ever want to set anything before the game starts or call anything then this is probably your best bet.
A lot of this code is just going to be similar to the flixel templates' colorblind filters because I wanted to add support for those as I'll
Expand All @@ -36,93 +45,94 @@ class Init extends FlxState
public static var gameSettings:Map<String, Dynamic> = [
'Downscroll' => [
false,
0,
Checkmark,
'Whether to have the strumline vertically flipped in gameplay.',
NOT_FORCED
],
'Auto Pause' => [true, 0, '', NOT_FORCED],
'FPS Counter' => [true, 0, 'Whether to display the FPS counter.', NOT_FORCED],
'Auto Pause' => [true, Checkmark, '', NOT_FORCED],
'FPS Counter' => [true, Checkmark, 'Whether to display the FPS counter.', NOT_FORCED],
'Memory Counter' => [
true,
0,
Checkmark,
'Whether to display approximately how much memory is being used.',
NOT_FORCED
],
'Debug Info' => [false, 0, 'Whether to display information like your game state.', NOT_FORCED],
'Debug Info' => [false, Checkmark, 'Whether to display information like your game state.', NOT_FORCED],
'Reduced Movements' => [
false,
0,
Checkmark,
'Whether to reduce movements, like icons bouncing or beat zooms in gameplay.',
NOT_FORCED
],
'Stage Darkness' => [
0,
1,
Checkmark,
Selector,
'Darkens non-ui elements, useful if you find the characters and backgrounds distracting.',
NOT_FORCED
],
'Display Accuracy' => [true, 0, 'Whether to display your accuracy on screen.', NOT_FORCED],
'Display Accuracy' => [true, Checkmark, 'Whether to display your accuracy on screen.', NOT_FORCED],
'Disable Antialiasing' => [
false,
0,
Checkmark,
'Whether to disable Anti-aliasing. Helps improve performance in FPS.',
NOT_FORCED
],
'No Camera Note Movement' => [
false,
0,
Checkmark,
'When enabled, left and right notes no longer move the camera.',
NOT_FORCED
],
'Use Forever Chart Editor' => [
true,
0,
Checkmark,
'When enabled, uses the custom Forever Engine chart editor!',
NOT_FORCED
],
'Disable Note Splashes' => [
false,
0,
Checkmark,
'Whether to disable note splashes in gameplay. Useful if you find them distracting.',
NOT_FORCED
],
// custom ones lol
'Offset' => [0, 3],
'Offset' => [Checkmark, 3],
'Filter' => [
'none',
1,
Selector,
'Choose a filter for colorblindness.',
NOT_FORCED,
['none', 'Deuteranopia', 'Protanopia', 'Tritanopia']
],
"UI Skin" => ['default', 1, 'Choose a UI Skin for judgements, combo, etc.', NOT_FORCED, ''],
"Note Skin" => ['default', 1, 'Choose a note skin.', NOT_FORCED, ''],
"Framerate Cap" => [120, 1, 'Define your maximum FPS.', NOT_FORCED, ['']],
"Opaque Arrows" => [false, 0, "Makes the arrows at the top of the screen opaque again.", NOT_FORCED],
"Opaque Holds" => [false, 0, "Huh, why isnt the trail cut off?", NOT_FORCED],
"UI Skin" => ['default', Selector, 'Choose a UI Skin for judgements, combo, etc.', NOT_FORCED, ''],
"Note Skin" => ['default', Selector, 'Choose a note skin.', NOT_FORCED, ''],
"Framerate Cap" => [120, Selector, 'Define your maximum FPS.', NOT_FORCED, ['']],
"Opaque Arrows" => [false, Checkmark, "Makes the arrows at the top of the screen opaque again.", NOT_FORCED],
"Opaque Holds" => [false, Checkmark, "Huh, why isnt the trail cut off?", NOT_FORCED],
'Ghost Tapping' => [
false,
0,
Checkmark,
"Enables Ghost Tapping, allowing you to press inputs without missing.",
NOT_FORCED
],
'Centered Notefield' => [false, 0, "Center the notes, disables the enemy's notes."],
'Centered Notefield' => [false, Checkmark, "Center the notes, disables the enemy's notes."],
"Custom Titlescreen" => [
false,
0,
Checkmark,
"Enables the custom Forever Engine titlescreen! (only effective with a restart)",
FORCED
],
'Skip Cutscenes' => [false, 0, 'Skip the cutscenes in story mode. (Includes Dialogue)'],
'SM-like Judgements' => [
false,
0,
"Fixes the judgements to the camera instead of to the world itself, making them easier to read."
'Skip Text' => [
'never',
Selector,
'Decides whether to skip cutscenes and dialogue in gameplay. May be always, only in freeplay, or never.',
NOT_FORCED,
['never', 'freeplay only', 'always']
],
'Display Miss Count' => [
'Fixed Judgements' => [
false,
0,
"When enabled, displays the amount of combo breaks you have in a song."
Checkmark,
"Fixes the judgements to the camera instead of to the world itself, making them easier to read."
],

];
Expand Down Expand Up @@ -188,8 +198,7 @@ class Init extends FlxState
// apply saved filters
FlxG.game.setFilters(filters);

// Some additional changes to default HaxeFlixel settings, both for ease of debugging
// and usability.
// Some additional changes to default HaxeFlixel settings, both for ease of debugging and usability.
FlxG.fixedTimestep = false; // This ensures that the game is not tied to the FPS
FlxG.mouse.useSystemCursor = true; // Use system cursor because it's prettier
FlxG.mouse.visible = false; // Hide mouse on start
Expand Down
6 changes: 5 additions & 1 deletion source/gameFolder/gameObjects/Stage.hx
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,11 @@ class Stage extends FlxTypedGroup<FlxBasic>

var daPixelZoom = PlayState.daPixelZoom;

public var foreground:FlxTypedGroup<FlxBasic>;

public function new(curStage)
{
super();

this.curStage = curStage;

/// get hardcoded stage type if chart is fnf style
Expand Down Expand Up @@ -83,6 +84,9 @@ class Stage extends FlxTypedGroup<FlxBasic>
PlayState.curStage = curStage;
}

// to apply to foreground use foreground.add(); instead of add();
foreground = new FlxTypedGroup<FlxBasic>();

//
switch (curStage)
{
Expand Down
5 changes: 2 additions & 3 deletions source/gameFolder/gameObjects/userInterface/ClassHUD.hx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ class ClassHUD extends FlxTypedGroup<FlxBasic>
iconP2.y = healthBar.y - (iconP2.height / 2);
add(iconP2);

scoreBar = new FlxText(FlxG.width / 2, healthBarBG.y + 50, 0, scoreDisplay, 20);
scoreBar = new FlxText(FlxG.width / 2, healthBarBG.y + 40, 0, scoreDisplay, 20);
scoreBar.setFormat(Paths.font("vcr.ttf"), 16, FlxColor.WHITE, CENTER, FlxTextBorderStyle.OUTLINE, FlxColor.BLACK);
updateScoreText();
scoreBar.scrollFactor.set();
Expand Down Expand Up @@ -136,8 +136,7 @@ class ClassHUD extends FlxTypedGroup<FlxBasic>
if (displayAccuracy)
{
scoreBar.text += ' // Accuracy: ' + Std.string(Math.floor(Timings.getAccuracy() * 100) / 100) + '%' + Timings.comboDisplay;
if (Init.trueSettings.get('Display Miss Count'))
scoreBar.text += ' // Combo Breaks: ' + Std.string(PlayState.misses);
scoreBar.text += ' // Combo Breaks: ' + Std.string(PlayState.misses);
scoreBar.text += ' // Rank: ' + Std.string(Timings.returnScoreRating().toUpperCase());
}

Expand Down
Loading

0 comments on commit d53d566

Please sign in to comment.