From 25c10d205dae3727218b8f2e62fac7f3c352ab30 Mon Sep 17 00:00:00 2001 From: EliteMasterEric Date: Fri, 12 Jan 2024 06:35:41 -0500 Subject: [PATCH] Some positioning fixes --- source/funkin/ui/debug/charting/ChartEditorState.hx | 8 ++++---- .../ui/debug/charting/handlers/ChartEditorAudioHandler.hx | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/source/funkin/ui/debug/charting/ChartEditorState.hx b/source/funkin/ui/debug/charting/ChartEditorState.hx index 64a2f19ed..dda779917 100644 --- a/source/funkin/ui/debug/charting/ChartEditorState.hx +++ b/source/funkin/ui/debug/charting/ChartEditorState.hx @@ -213,7 +213,7 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState /** * The X position of the note preview area. */ - public static final NOTE_PREVIEW_X_POS:Int = 350; + public static final NOTE_PREVIEW_X_POS:Int = 320; /** * The Y position of the note preview area. @@ -383,11 +383,11 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState if (audioVisGroup != null && audioVisGroup.playerVis != null) { - audioVisGroup.playerVis.y = Math.max(gridTiledSprite.y, GRID_INITIAL_Y_POS); + audioVisGroup.playerVis.y = Math.max(gridTiledSprite.y, GRID_INITIAL_Y_POS - GRID_TOP_PAD); } if (audioVisGroup != null && audioVisGroup.opponentVis != null) { - audioVisGroup.opponentVis.y = Math.max(gridTiledSprite.y, GRID_INITIAL_Y_POS); + audioVisGroup.opponentVis.y = Math.max(gridTiledSprite.y, GRID_INITIAL_Y_POS - GRID_TOP_PAD); } } } @@ -4756,7 +4756,7 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState // Visibly center the Dad health icon. if (healthIconDad != null) { - var xOffset = 45 + (healthIconDad.width / 2); + var xOffset = 75 + (healthIconDad.width / 2); healthIconDad.x = (gridTiledSprite == null) ? (0) : (GRID_X_POS - xOffset); var yOffset = 30 - (healthIconDad.height / 2); healthIconDad.y = (gridTiledSprite == null) ? (0) : (GRID_INITIAL_Y_POS - NOTE_SELECT_BUTTON_HEIGHT) + yOffset; diff --git a/source/funkin/ui/debug/charting/handlers/ChartEditorAudioHandler.hx b/source/funkin/ui/debug/charting/handlers/ChartEditorAudioHandler.hx index 0edba7357..d7fbd42c2 100644 --- a/source/funkin/ui/debug/charting/handlers/ChartEditorAudioHandler.hx +++ b/source/funkin/ui/debug/charting/handlers/ChartEditorAudioHandler.hx @@ -188,19 +188,19 @@ class ChartEditorAudioHandler state.audioVisGroup.playerVis.realtimeVisLenght = Conductor.instance.getStepTimeInMs(16) * 0.00195; state.audioVisGroup.playerVis.daHeight = (ChartEditorState.GRID_SIZE) * 16; state.audioVisGroup.playerVis.detail = 1; - state.audioVisGroup.playerVis.y = Math.max(state.gridTiledSprite?.y ?? 0.0, ChartEditorState.GRID_INITIAL_Y_POS); + state.audioVisGroup.playerVis.y = Math.max(state.gridTiledSprite?.y ?? 0.0, ChartEditorState.GRID_INITIAL_Y_POS - ChartEditorState.GRID_TOP_PAD); state.audioVocalTrackGroup.playerVoicesOffset = state.currentSongOffsets.getVocalOffset(charId); return true; case DAD: state.audioVocalTrackGroup.addOpponentVoice(vocalTrack); state.audioVisGroup.addOpponentVis(vocalTrack); - state.audioVisGroup.opponentVis.x = 435; + state.audioVisGroup.opponentVis.x = 405; state.audioVisGroup.opponentVis.realtimeVisLenght = Conductor.instance.getStepTimeInMs(16) * 0.00195; state.audioVisGroup.opponentVis.daHeight = (ChartEditorState.GRID_SIZE) * 16; state.audioVisGroup.opponentVis.detail = 1; - state.audioVisGroup.opponentVis.y = Math.max(state.gridTiledSprite?.y ?? 0.0, ChartEditorState.GRID_INITIAL_Y_POS); + state.audioVisGroup.opponentVis.y = Math.max(state.gridTiledSprite?.y ?? 0.0, ChartEditorState.GRID_INITIAL_Y_POS - ChartEditorState.GRID_TOP_PAD); state.audioVocalTrackGroup.opponentVoicesOffset = state.currentSongOffsets.getVocalOffset(charId);