Crash with blank text attribute

FetaboyFetaboy Member, PRO Posts: 191
edited November -1 in Tech Support
I created a game attribute of type text.

I have an actor with a behavior of display text. displaying the text of my created game attribute. As long as there's a value in the new game attribute everything is fine....if I try to run the scene with no value set for the new attribute, gamesalad crashes immediately. I'm trying to have this field start out blank, as I'm using it to build a string via an onscreen keyboard.

Comments

  • CodeMonkeyCodeMonkey Head Chef, Member, PRO Posts: 1,803
    Can you recreate the issue with a totally new project and only one actor, one text attrib, the display text, and the scene?
  • FetaboyFetaboy Member, PRO Posts: 191
    Yes, I got it to crash just now by creating a new project (default template). Added a text attribute to the game called 'txtTesting'. Added an actor with a behavior of display text and set the formula to display the txtTesting field. Added the actor to the scene.

    At this point it didn't crash, but it still said 'Hello World' instead of being blank. I then edited the actor from the scene itself (instead of from the list of actors). After saving, I re-ran and it crashed.
  • JGary321JGary321 Member Posts: 1,246
    All game.attributes must have SOME text. CodeMonkey posted about this before, unless this got fixed & I didn't know about it. (I guess he forgot again. Bad Monkey) Typically I put "nil". However for what you are doing I would so something like this...

    I would type a random name like Bob. Make it so when it initially plays the color is gray & alpha is around .5 (play with these to your delight). Many games do this type of thing where it's a gray faded name in place already. Then when the person starts typing it clears it out.

    Maybe a little more work, but it's all I got for now!
Sign In or Register to comment.