Skip to content

Commit

Permalink
rename public variables and add version
Browse files Browse the repository at this point in the history
  • Loading branch information
maxklenk committed Feb 9, 2018
1 parent 81bbab5 commit b26fc3e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 9 deletions.
15 changes: 9 additions & 6 deletions Scripts/StomtAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ namespace Stomt
/// </summary>
public class StomtAPI : MonoBehaviour
{
[HideInInspector]
private string Version = "2.1.0";

#region Inspector Variables
[SerializeField]
[Tooltip("The application ID for your game. Create one on https://www.stomt.com/dev/my-apps/.")]
Expand All @@ -35,8 +38,8 @@ public class StomtAPI : MonoBehaviour
public StomtLang lang;
public string defaultLanguage;
public bool ForceDefaultLanguage;
public bool DisableDefaultLabels;
public bool DebugDisableConfigFile = false;
public bool SendDefaultLabels = true;
public bool DebugMode = false;
private StomtConfig _config = null;
public StomtConfig config {
get {
Expand Down Expand Up @@ -145,7 +148,7 @@ void Awake()
{
this.restServerURL = "https://rest.stomt.com";
this.stomtURL = "https://stomt.com";
this.DebugDisableConfigFile = false;
this.DebugMode = false;
}

NetworkError = false;
Expand All @@ -159,7 +162,7 @@ void Awake()

void Start()
{
if (DebugDisableConfigFile)
if (DebugMode)
{
this.config.SetLoggedin(false);
this.config.SetSubscribed(false);
Expand Down Expand Up @@ -192,7 +195,7 @@ public StomtTrack initStomtTrack()
stomtTrack.device_platform = Application.platform.ToString();
stomtTrack.device_id = SystemInfo.deviceUniqueIdentifier;
stomtTrack.sdk_type = "Unity" + Application.unityVersion;
stomtTrack.sdk_version = "Beta - 2.0";
stomtTrack.sdk_version = this.Version;
stomtTrack.sdk_integration = Application.productName;
stomtTrack.target_id = this.TargetID;

Expand Down Expand Up @@ -303,7 +306,7 @@ public StomtCreation initStomtCreation()
{
StomtCreation stomtCreation = new StomtCreation(this);

stomtCreation.DisableDefaultLabels = DisableDefaultLabels;
stomtCreation.DisableDefaultLabels = !SendDefaultLabels;

stomtCreation.target_id = this.TargetID;
stomtCreation.lang = this.lang.getLanguage();
Expand Down
6 changes: 3 additions & 3 deletions Scripts/StomtPopup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ public class StomtPopup : MonoBehaviour
public KeyCode _toggleKey = KeyCode.F1;
public string DisplayGameName;
public Texture2D ProfileImageTexture;
public bool LogFileUpload = true;
public bool UploadLogFile = true;
public bool PrefetchTarget = false;
public bool ShowCloseButton = true;
public bool ShowDefaultText = true; // Activates the would/because text
Expand Down Expand Up @@ -281,7 +281,7 @@ private IEnumerator Show()
_screenshot.ReadPixels(new Rect(0, 0, Screen.width, Screen.height), 0, 0);

// Get Logs
if (this.LogFileUpload)
if (this.UploadLogFile)
{
if (this._log != null)
{
Expand Down Expand Up @@ -856,7 +856,7 @@ private void handleStomtSending()
}

// attach logs
if (this.LogFileUpload)
if (this.UploadLogFile)
{
stomtCreation.attachLogs(this._log);
}
Expand Down

0 comments on commit b26fc3e

Please sign in to comment.