Use integer Table value as an image reference ?!
POM
Member Posts: 2,599
Hey ,
I have a table with numbers ..
Now i want to make in my actor a simple change to its image , according to the table values..
Change "self.image" To "Thumbnail"..tableCellValue(game.TB Images , game.RowNumber , 1)..".png"
But apparently i can't , the expression is broken ..
Am i doing it wrong ? or is this feature not accessible at the moment?
EDIT:
I can do a simple workaround, but i want to know if it possible this way..
Roy
I have a table with numbers ..
Now i want to make in my actor a simple change to its image , according to the table values..
Change "self.image" To "Thumbnail"..tableCellValue(game.TB Images , game.RowNumber , 1)..".png"
But apparently i can't , the expression is broken ..
Am i doing it wrong ? or is this feature not accessible at the moment?
EDIT:
I can do a simple workaround, but i want to know if it possible this way..
Roy
Comments
Still having problem .. ill make another check ..
Roy
When the cell value is 0..
this expression :
"Thumbnail"..tableCellValue(game.TB Images , game.RowNumber , 1)..".png"
Is giving the result of : Thumbnail.png
Instead of : Thumbnail0.png
Any other value different than '0' is performing as it should..
Any thoughts ?
Roy
think you may have to just do a rule for when game.RowNumber is O
I had issue when I wanted to labelRows with a number and not text … then try to reference that label with a gameAttribute … would read that as a Row call and never a label
… didn't want to have to redo someBehaviors in many instance … so just made another gameAttribute to update with correct row for image
@};- MH
I will give you MANY flowers next time we meet !
That was the problems .. many thanks !
Roy
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
@FryGuy … my brain is well packaged! )
@};- MH
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
Will make sure you'll get your bouquet of 'Roses of sharon' !!
Roy
weirdly my iPad and Desktop but utilize Hebrew "QWERTY"
don't ask … private matter!
@};- MH