Skip to content

Commit

Permalink
really allow 8 effect columns
Browse files Browse the repository at this point in the history
third time is the charm
  • Loading branch information
tildearrow committed Jan 19, 2022
1 parent 6b28190 commit f39e522
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/engine/engine.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include <queue>

#define DIV_VERSION "0.4.5"
#define DIV_ENGINE_VERSION 25
#define DIV_ENGINE_VERSION 26

enum DivStatusView {
DIV_STATUS_NOTHING=0,
Expand Down
2 changes: 1 addition & 1 deletion src/engine/pattern.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
static DivPattern emptyPat;

DivPattern::DivPattern() {
memset(data,-1,256*16*sizeof(short));
memset(data,-1,256*32*sizeof(short));
for (int i=0; i<256; i++) {
data[i][0]=0;
data[i][1]=0;
Expand Down
2 changes: 1 addition & 1 deletion src/engine/pattern.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "safeReader.h"

struct DivPattern {
short data[256][16];
short data[256][32];
SafeReader* compile(int len=256, int fxRows=1);
DivPattern();
};
Expand Down
4 changes: 2 additions & 2 deletions src/gui/gui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1486,7 +1486,7 @@ void FurnaceGUI::drawPattern() {
}
ImGui::EndDisabled();
ImGui::SameLine();
ImGui::BeginDisabled(e->song.pat[i].effectRows>=4);
ImGui::BeginDisabled(e->song.pat[i].effectRows>=8);
snprintf(chanID,256,">##_RCH%d",i);
if (ImGui::SmallButton(chanID)) {
e->song.pat[i].effectRows++;
Expand Down Expand Up @@ -2217,7 +2217,7 @@ void FurnaceGUI::makeUndo(ActionType action) {
for (int i=0; i<e->getTotalChannelCount(); i++) {
DivPattern* p=e->song.pat[i].getPattern(e->song.orders.ord[i][order],false);
for (int j=0; j<e->song.patLen; j++) {
for (int k=0; k<16; k++) {
for (int k=0; k<32; k++) {
if (p->data[j][k]!=oldPat[i]->data[j][k]) {
s.pat.push_back(UndoPatternData(i,e->song.orders.ord[i][order],j,k,oldPat[i]->data[j][k],p->data[j][k]));
}
Expand Down

0 comments on commit f39e522

Please sign in to comment.