Click here to Skip to main content
14,775,008 members
Home » Discussions » C#
   

C#

 
AnswerRe: download files Pin
Member 1447263829-May-19 1:23
MemberMember 1447263829-May-19 1:23 
GeneralRe: download files Pin
Richard MacCutchan29-May-19 2:35
mveRichard MacCutchan29-May-19 2:35 
AnswerRe: download files Pin
Richard Deeming29-May-19 1:42
mveRichard Deeming29-May-19 1:42 
QuestionC# using get set. Why is this failing? Pin
Brian_TheLion28-May-19 20:52
MemberBrian_TheLion28-May-19 20:52 
AnswerRe: C# using get set. Why is this failing? Pin
Member 1356638328-May-19 21:14
MemberMember 1356638328-May-19 21:14 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion28-May-19 21:22
MemberBrian_TheLion28-May-19 21:22 
GeneralRe: C# using get set. Why is this failing? Pin
Member 1356638328-May-19 21:31
MemberMember 1356638328-May-19 21:31 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion28-May-19 21:37
MemberBrian_TheLion28-May-19 21:37 
This is the code that player.cs is called from.
I added a TEST button.
lblGold.text is a label on the form.

<pre lang="c#">
using Engine;

namespace SuperAdventure
{
public partial class SuperAdventure : Form
{
private Player _player;

public SuperAdventure()
{
InitializeComponent();

Location location = new Location(1, "Home", "This is your house.");


_player = new Player(10, 10, 20, 0, 1);

Update();

}

private void btnTest_Click(object sender, EventArgs e)
{
_player.Gold = 30;
// lblGold.Text = _player.Gold.ToString();
Update();
}
public void Update()
{
lblHitPoints.Text = _player.CurrentHitPoints.ToString();
lblGold.Text = _player.Gold.ToString();
lblExperience.Text = _player.ExperiencePoints.ToString();
lblLevel.Text = _player.Level.ToString();
}
}
}</pre>
AnswerRe: C# using get set. Why is this failing? Pin
lmoelleb28-May-19 21:39
Memberlmoelleb28-May-19 21:39 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion29-May-19 1:24
MemberBrian_TheLion29-May-19 1:24 
GeneralRe: C# using get set. Why is this failing? Pin
lmoelleb29-May-19 3:27
Memberlmoelleb29-May-19 3:27 
AnswerRe: C# using get set. Why is this failing? Pin
Member 1356638329-May-19 6:30
MemberMember 1356638329-May-19 6:30 
GeneralRe: C# using get set. Why is this failing? Pin
Dave Kreskowiak29-May-19 8:18
mveDave Kreskowiak29-May-19 8:18 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion29-May-19 15:50
MemberBrian_TheLion29-May-19 15:50 
GeneralRe: C# using get set. Why is this failing? Pin
Dave Kreskowiak29-May-19 17:23
mveDave Kreskowiak29-May-19 17:23 
GeneralRe: C# using get set. Why is this failing? Pin
Member 798912229-May-19 5:38
MemberMember 798912229-May-19 5:38 
GeneralRe: C# using get set. Why is this failing? Pin
Richard MacCutchan29-May-19 6:58
mveRichard MacCutchan29-May-19 6:58 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion29-May-19 15:44
MemberBrian_TheLion29-May-19 15:44 
GeneralRe: C# using get set. Why is this failing? Pin
Dave Kreskowiak29-May-19 17:26
mveDave Kreskowiak29-May-19 17:26 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion29-May-19 19:23
MemberBrian_TheLion29-May-19 19:23 
GeneralRe: C# using get set. Why is this failing? Pin
lmoelleb2-Jun-19 23:46
Memberlmoelleb2-Jun-19 23:46 
AnswerRe: C# using get set. Why is this failing? Pin
OriginalGriff28-May-19 21:41
mveOriginalGriff28-May-19 21:41 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion29-May-19 1:36
MemberBrian_TheLion29-May-19 1:36 
GeneralRe: C# using get set. Why is this failing? Pin
Pete O'Hanlon29-May-19 1:43
mvePete O'Hanlon29-May-19 1:43 
GeneralRe: C# using get set. Why is this failing? Pin
Brian_TheLion29-May-19 15:41
MemberBrian_TheLion29-May-19 15:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.