Question about a attribute inside a rule?
TRowe007
Member Posts: 71
I have a dialog between two actors, and the one ask the name of the other. So my issue is that the conversation continues before the keyboard input in added. But when the keyboard input is enter and done is clicked the name still doesn't show up, just a blank space alone the next line in the conversation. I know GS continues running always, my attribute that has a {blank} box waiting for a name to be inputted by the keyboard just get saved as blank before the player can enter his name. Mac has a "is not" dope down ability but PC doesn't, so I have no way to keep it blank until something is added. Is there another way of holding off on GS saving the blank box until something is added?
Answers
My recommendation, which I shared with you, is:
If game.text is "" (just leave the expression field blank)
.....
Then
.....
Else
Change Table Cell
Value: attribute game.text
And be sure to reset game.text to a blank string before the player types in text each time.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
It wont let me I tried it automatically come up "contains"
{Input Actor} with an attribute inside the actor named TempInput
Display Text ....
Rule:
touch is pressed
If: (self.TempInput) to {blank} Note: Its blank so that players name from the keyboard input goes in place of that.
Do:
Keyboard Input:
change following attribute: (self.TempInput)
(Rule:)
If: (self.TempInput) ? {Blank} ( *Note: This is where is should have "is not" but PC doesn't have no option for it.
Do:
Change Table Value:
Table: ConversationTB
Row: (game.ConversationNumber)
Column: 1 Value: (self.TempInput)
Save Table: Input TB
Change Attribute: (self.TempInput) to {Blank}
Change Attribute: (game.ConversationNumber) to (game.ConversationNumber)+1
I'm hoping someone who uses Creator for PC can chime in since I don't have access to it.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
I know it would be nice, you've been a great help I appreciate everything. Maybe when I get my MacBook pro I won't have these problems anymore. lol
@jamie_c Any idea?
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User