follow ya heart
This commit is contained in:
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.2 KiB |
@@ -137,20 +137,19 @@ inline void conversationTextboxUpdate() {
|
|||||||
// Have we finished scrolling?
|
// Have we finished scrolling?
|
||||||
if(TEXTBOX_STATE & TEXTBOX_STATE_SCROLLED) {
|
if(TEXTBOX_STATE & TEXTBOX_STATE_SCROLLED) {
|
||||||
// Is the user trying to go to the next line?
|
// Is the user trying to go to the next line?
|
||||||
BGB_printf("has scrolled");
|
if(INPUT_STATE & J_A) {
|
||||||
if(INPUT_STATE & INPUT_BIND_TEXT_SKIP) {
|
|
||||||
// First, lets figure out if there's any more text to reveal or not.
|
// First, lets figure out if there's any more text to reveal or not.
|
||||||
if((TEXTBOX_ROW_COUNT - TEXTBOX_ROW_CURRENT) >= TEXTBOX_TILES_ROWS) {
|
if((TEXTBOX_ROW_COUNT - TEXTBOX_ROW_CURRENT) < TEXTBOX_TILES_ROWS) {
|
||||||
TEXTBOX_STATE &= ~TEXTBOX_STATE_VISIBLE;
|
TEXTBOX_STATE &= ~TEXTBOX_STATE_VISIBLE;
|
||||||
|
HIDE_WIN;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
TEXTBOX_STATE &= ~(TEXTBOX_STATE_SCROLLED);
|
TEXTBOX_STATE &= ~TEXTBOX_STATE_SCROLLED;
|
||||||
|
TEXTBOX_SCROLL = 0;
|
||||||
TEXTBOX_ROW_CURRENT += TEXTBOX_TILES_ROWS;
|
TEXTBOX_ROW_CURRENT += TEXTBOX_TILES_ROWS;
|
||||||
textboxFillBlank();
|
textboxFillBlank();
|
||||||
BGB_printf("tst");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -161,7 +160,7 @@ inline void conversationTextboxUpdate() {
|
|||||||
if(TEXTBOX_SCROLL == TEXTBOX_CHARS_MAX) {
|
if(TEXTBOX_SCROLL == TEXTBOX_CHARS_MAX) {
|
||||||
TEXTBOX_STATE |= TEXTBOX_STATE_SCROLLED;
|
TEXTBOX_STATE |= TEXTBOX_STATE_SCROLLED;
|
||||||
} else {
|
} else {
|
||||||
tiles[0] = c - 33 + 4;
|
tiles[0] = c - 33 + FONT_DATA_POSITION;
|
||||||
set_win_tiles(
|
set_win_tiles(
|
||||||
1 + (TEXTBOX_SCROLL % TEXTBOX_CHARS_PER_ROW),
|
1 + (TEXTBOX_SCROLL % TEXTBOX_CHARS_PER_ROW),
|
||||||
1 + (TEXTBOX_SCROLL / TEXTBOX_CHARS_PER_ROW),
|
1 + (TEXTBOX_SCROLL / TEXTBOX_CHARS_PER_ROW),
|
||||||
|
@@ -23,6 +23,8 @@
|
|||||||
#define BORDER_TILE_BOTTOM_CENTER BORDER_TILE_BOTTOM_LEFT + 1
|
#define BORDER_TILE_BOTTOM_CENTER BORDER_TILE_BOTTOM_LEFT + 1
|
||||||
#define BORDER_TILE_BOTTOM_RIGHT BORDER_TILE_BOTTOM_CENTER + 1
|
#define BORDER_TILE_BOTTOM_RIGHT BORDER_TILE_BOTTOM_CENTER + 1
|
||||||
|
|
||||||
|
#define TEXTBOX_WIN_Y 0
|
||||||
|
|
||||||
#define TEXTBOX_STATE_VISIBLE (1 << 0)
|
#define TEXTBOX_STATE_VISIBLE (1 << 0)
|
||||||
#define TEXTBOX_STATE_SCROLLED (1 << 1)
|
#define TEXTBOX_STATE_SCROLLED (1 << 1)
|
||||||
|
|
||||||
|
@@ -10,6 +10,6 @@
|
|||||||
#include "BORDER.h"
|
#include "BORDER.h"
|
||||||
// #include "SM.h"
|
// #include "SM.h"
|
||||||
|
|
||||||
#define FONT_DATA_POSITION 0x04
|
#define FONT_DATA_POSITION 0x80
|
||||||
#define BORDER_DATA_POSITION FONT_DATA_POSITION+FONT_IMAGE_TILES
|
#define BORDER_DATA_POSITION FONT_DATA_POSITION+FONT_IMAGE_TILES
|
||||||
// #define SM_DATA_POSITION BORDER_DATA_POSITION+BORDER_IMAGE_TILES
|
// #define SM_DATA_POSITION BORDER_DATA_POSITION+BORDER_IMAGE_TILES
|
||||||
|
@@ -8,6 +8,4 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "libs.h"
|
#include "libs.h"
|
||||||
|
|
||||||
#define INPUT_BIND_TEXT_SKIP J_A
|
|
||||||
|
|
||||||
extern uint8_t INPUT_STATE;
|
extern uint8_t INPUT_STATE;
|
Reference in New Issue
Block a user