How to make an attribute for a cell in a table?
ofekez
Member, PRO Posts: 95
Hello,
I want to make an attribute for a specific cell, Is it possible?
BR,
Ofek
Comments
Have you watched any videos related to tables? Start by Googling tables gamesalad. That should help you get started.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Yes i have already watched few videos but there is nothing showing on about an attribute for a specific cell...
Well, tables columns can have an attribute type (integer, boolean, text, etc.) but individual cells cannot. If you make a specific column an integer type, for example, then every cell in that column will be an integer. Rows cannot have attribute types because they would then conflict with the column types.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Thank you, But what if i want to make an actually attribute? like:
(if "specific call" is > then "Score" Then), How do i do that?
BR,
Ofek
You would use the Numeric Expression in the rule condition drop down. Not sure how that looks in the PC version but here it is in the Mac version:
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Thank you for the help but in PC the only option i can choose from is "ALL" of "ANY".
Lets wait to see what is the solution for PC users.
Thank you very much anyway!
BR,
Ofek
The other option is to store the table cell value in an attribute like this:
Change Attribute game.highScore to tableCellValue(tableName,1,3)
If attribute game.highScore > game.score then...
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Thank you but i think i'll wait for the PC users comments
Okay but have you tried my last suggestion? That will work.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Actually i dont know how. but when i tried it, some actors have change their movement direction...
When you quote text, be sure to leave an extra space after the quoted text. I fixed your post for you.
You asked about how to make an attribute for a table cell and then about how to compare that attribute to another, such as score. I have no idea what you mean by "some actors have change their movement direction." This is the first you've mentioned anything about movement. Were you able to store the table cell value in an attribute? For example, can you then display the value using Display Text?
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
It sounds like you are not understanding how to write logic. Watch my GSLogic series and it will help you understand. Just click the link in my signature.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS