Skip to content

Commit

Permalink
Small Fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
dfrood committed Sep 18, 2016
1 parent 8b6eac7 commit 271c75d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions MainForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1389,7 +1389,7 @@ private void buttonDisconnect_Click(object sender, EventArgs e)
radioBoxes.Enabled = false;
radioDaycare.Enabled = false;
radioOpponent.Enabled = false;
radioTrade.Enabled = true;
radioTrade.Enabled = false;
pokeName.Enabled = false;
playerName.Enabled = false;
pokeTID.Enabled = false;
Expand Down Expand Up @@ -1668,7 +1668,7 @@ private void pokeName_Click(object sender, EventArgs e)

private void pokeTID_Click(object sender, EventArgs e)
{
byte[] tidbyte = BitConverter.GetBytes(Convert.ToInt32(TIDNum.Value));
byte[] tidbyte = BitConverter.GetBytes(Convert.ToUInt16((double)TIDNum.Value));
string tidr = ", 0x";
string tid = BitConverter.ToString(tidbyte).Replace("-", tidr);
string pokeTID = "write(" + tidoff + ", (0x" + tid + "), pid=" + pid + ")";
Expand All @@ -1677,7 +1677,7 @@ private void pokeTID_Click(object sender, EventArgs e)

private void pokeTime_Click(object sender, EventArgs e)
{
byte[] hrbyte = BitConverter.GetBytes(Convert.ToInt32(hourNum.Value));
byte[] hrbyte = BitConverter.GetBytes(Convert.ToUInt16((double)hourNum.Value));
string hrr = ", 0x";
string hr = BitConverter.ToString(hrbyte).Replace("-", hrr);
string pokeHr = "write(" + hroff + ", (0x" + hr + "), pid=" + pid + ")";
Expand Down Expand Up @@ -1946,7 +1946,7 @@ private void radioButton1_CheckedChanged(object sender, EventArgs e)

private void pokeSID_Click(object sender, EventArgs e)
{
byte[] sidbyte = BitConverter.GetBytes(Convert.ToInt32(SIDNum.Value));
byte[] sidbyte = BitConverter.GetBytes(Convert.ToUInt16((double)SIDNum.Value));
string sidr = ", 0x";
string sid = BitConverter.ToString(sidbyte).Replace("-", sidr);
string pokeSID = "write(" + sidoff + ", (0x" + sid + "), pid=" + pid + ")";
Expand Down

0 comments on commit 271c75d

Please sign in to comment.