Issue with a line in Version


Hello everyone, i’m new here and downloaded Xenko today, and then decided to mess around with the FPS example.

Now, I don’t know programming besides understanding what the code does partially, I actually do visual programming in Unreal 4 with Blueprint (You guys should add one, it would be nice), but then I’ve noticed something odd in my testing.

It seems that the public float Cooldown{ get; set; } doesn’t work as it should, no mater what kind of value you insert, the debug in VS and in print text states that the value is 0.4, however, if you turn into private variable or rename it, it will work as it should.

Am I doing something wrong?


I haven’t run that example but looking at the code on gitlab. In the WeaponScript I see the line public float Cooldown { get; set; } = 0.3f;. But in the MainScene it is set to 0.4. So when it loads the scene it is setting it to 0.4. 0.3 is just the default. If you want to change it in the scene you have to open the MainScene; Select the “Camera” entity. In the property grid you should see a “Weapon Script” and be able to change the Cooldown.