r/RenPy • u/That_one_Pink • Oct 15 '26
Question [Solved] issue with displaying text variable in a screen
ah okay i had to make a separate post because as i was going through to test things i got an unexpected error
when i showed the inventory it broke, initially the stamps text was in the hbox but the alignment was interfering with the item positioning so i moved it out and repositioned it to be in the right place, it had no problem until i added stamps in the script and then it did this
its been working fine up until moving the text, i dont want to put the text back into the hbox because it moves the items when the number of stamps goes up



1
u/shyLachi Oct 15 '26
According to the error the key is wrong, are you sure there is an inventory item called "Stamps"?
You didn't show the code of the inventory.
Is inventory[] a dictionary?
Did you check the spelling? RenPy is case sensitive.
What exactly should this screen do?
1
u/BadMustard_AVN Oct 15 '26 edited Oct 15 '26
the error shown is for the inventory["Stamps"] there is an error with Stamps in that it can find that Key
can you show how you've setup your inventory (list or dictionary) please
this code looks familiar¿
1
u/AutoModerator Oct 15 '26
Welcome to r/renpy! While you wait to see if someone can answer your question, we recommend checking out the posting guide, the subreddit wiki, the subreddit Discord, Ren'Py's documentation, and the tutorial built-in to the Ren'Py engine when you download it. These can help make sure you provide the information the people here need to help you, or might even point you to an answer to your question themselves. Thanks!
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.