How to make an attribute for a cell in a table?

ofekezofekez Member, PRO Posts: 95

Hello,
I want to make an attribute for a specific cell, Is it possible?

BR,
Ofek

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    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

  • ofekezofekez Member, PRO Posts: 95

    Yes i have already watched few videos but there is nothing showing on about an attribute for a specific cell...

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    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

  • ofekezofekez Member, PRO Posts: 95

    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

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    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

  • ofekezofekez Member, PRO Posts: 95
    edited January 2015

    @tatiang said:
    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:

    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

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    edited January 2015

    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

  • ofekezofekez Member, PRO Posts: 95
    edited January 2015

    @tatiang said:
    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...

    Thank you but i think i'll wait for the PC users comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    Okay but have you tried my last suggestion? That will work.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • ofekezofekez Member, PRO Posts: 95
    edited January 2015

    @tatiang said:
    Okay but have you tried my last suggestion? That will work.

    Actually i dont know how. but when i tried it, some actors have change their movement direction...

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    When you quote text, be sure to leave an extra space after the quoted text. I fixed your post for you.

    Actually i dont know how. but when i tried it, some actors have change their movement direction...

    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

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922

    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.

Sign In or Register to comment.