Skip to content

Commit

Permalink
Merge branch 'gsb' of https://github.com/Goldensunboy/WL4Editor into gsb
Browse files Browse the repository at this point in the history
  • Loading branch information
Goldensunboy committed Dec 6, 2018
2 parents 2e014ad + 810a820 commit eb54c44
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions Dialog/DoorConfigDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ DoorConfigDialog::~DoorConfigDialog()
void DoorConfigDialog::UpdateCurrentDoorData()
{
CurrentRoom->GetDoor(DoorID)->SetDoorType(static_cast<LevelComponents::DoorType>(ui->ComboBox_DoorType->currentIndex() + 1));
CurrentRoom->GetDoor(DoorID)->SetDelta((unsigned char) ui->SpinBox_WarioX->value(), (unsigned char) ui->SpinBox_WarioY->value());
CurrentRoom->GetDoor(DoorID)->SetDelta((signed char) ui->SpinBox_WarioX->value(), (signed char) ui->SpinBox_WarioY->value());
CurrentRoom->GetDoor(DoorID)->SetDoorPlace(
(unsigned char) ui->SpinBox_DoorX->value(),
(unsigned char) (ui->SpinBox_DoorX->value() + ui->SpinBox_DoorWidth->value() - 1),
Expand Down Expand Up @@ -497,7 +497,7 @@ void DoorConfigDialog::on_SpinBox_WarioX_valueChanged(int arg1)
{
(void) arg1;
if(!IsInitialized) return;
tmpCurrentRoom->GetDoor(DoorID)->SetDelta((unsigned char) ui->SpinBox_WarioX->value(), (unsigned char) ui->SpinBox_WarioY->value());
tmpCurrentRoom->GetDoor(DoorID)->SetDelta((signed char) ui->SpinBox_WarioX->value(), (signed char) ui->SpinBox_WarioY->value());
}

/// <summary>
Expand All @@ -510,7 +510,7 @@ void DoorConfigDialog::on_SpinBox_WarioY_valueChanged(int arg1)
{
(void) arg1;
if(!IsInitialized) return;
tmpCurrentRoom->GetDoor(DoorID)->SetDelta((unsigned char) ui->SpinBox_WarioX->value(), (unsigned char) ui->SpinBox_WarioY->value());
tmpCurrentRoom->GetDoor(DoorID)->SetDelta((signed char) ui->SpinBox_WarioX->value(), (signed char) ui->SpinBox_WarioY->value());
}

/// <summary>
Expand Down
6 changes: 3 additions & 3 deletions LevelComponents/Door.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ namespace LevelComponents
unsigned char y1;
unsigned char y2;
unsigned char LinkerDestination;
unsigned char HorizontalDelta;
unsigned char VerticalDelta;
signed char HorizontalDelta;
signed char VerticalDelta;
unsigned char EntitySetID;
unsigned short BGM_ID;
};
Expand Down Expand Up @@ -75,7 +75,7 @@ namespace LevelComponents
void SetEntitySetID(unsigned char _EntitySetID) { DoorEntry.EntitySetID =_EntitySetID; }
void SetGlobalDoorID(int doorId) { DoorID = doorId; }
void SetLinkerDestination(int dest_RoomId) { DoorEntry.LinkerDestination = (unsigned char) dest_RoomId; }
void SetDelta(unsigned char _DeltaX, unsigned char _DeltaY)
void SetDelta(signed char _DeltaX, signed char _DeltaY)
{
DoorEntry.HorizontalDelta = (signed char) _DeltaX;
DoorEntry.VerticalDelta = (signed char) _DeltaY;
Expand Down

0 comments on commit eb54c44

Please sign in to comment.