Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers AppGameKit Corner / CreateText not sync-ing

Author
Message
LordCucumber77
4
Years of Service
User Offline
Joined: 7th Mar 2015
Location:
Posted: 9th Mar 2015 22:18
Hey all,

I am trying to get a CreateText to display a global integer (like a score). Now I've figured out how to display the global integer, which is set to 0 by default, but for the life of me I cannot get it to update when the integer supposedly increases value. This value increase happens under certain circumstances from within a function. Being a global integer, should it not update every time the sync() command is passed? Or is this a hard limit that the function prevents me from doing?

How would you more experienced people go about this?

A confused vegetable
Funnell7
8
Years of Service
User Offline
Joined: 8th Sep 2011
Location: UK, England
Posted: 9th Mar 2015 22:57
When you create the text object, it will be created with the value of your variable at the time of creation. If you want to update the text object then you must use the following with the new value (just pass the same variable again)...

SetTextString( iTextIndex, string )

Using AppGameKit V2 Tier 1

Login to post a reply

Server time is: 2020-02-20 13:23:06
Your offset time is: 2020-02-20 13:23:06