Printing In-Room Object Descriptions from Script

Hi all,

Problem: I have in-room descriptions for various objects in a room. Previously, when my room description has just displayed a message, these have nicely auto-populated. Unfortunately, as this room's description is a script, it has obstinately refused any attempts to print out all the nice in-room-descriptions for objects.

Please excuse the absolutely noob question, I'm sure there's an easy way around it, but after Googling around hopelessly for an hour my object descriptions remain unprinted. After playing around with the foreach script and a bunch of settings, I've been stuck. Thanks a bunch to whomever helps.

Side-note: This is my first game and I'm only about 20 hours in, and my first time posting on the forum! Hi everyone! Quest is rad and I am in love with it. As a non-coder who has been playing INFOCOM games for the last few years, embarking on this quest to create my own has been absolutely rad. I can't wait to learn enough to be a helpful person on this forum rather than just someone flailing around searching on it.


K.V.

Hello and welcome!

(Aren't the INFOCOM games great?)


Could you click Code View, copy the entire text of your game, and paste it in a post here (if it isn't terribly long)?

Just put a line consisting of three backticks above and below the code to keep the formatting intact:


```
CODE GOES HERE.
```

Thanks! It is fairly long and deeply indulgent. But, if you can figure out how to make it work, I would be deeply helpful.

I may edit this to remove the code when the problem is resolved of anxiety of having my rough draft writing just weirdly published and out there. I will do my best to re-edit the post though so the solve is clear to noobies later though.


we've got pms now, but they have a low character count... so unfortunately if you want to keep your game code private, you'll have to use some 3rd party communication software (and/or share your email/mail), and upload/im your game code via it, to the/a person you trust to respect and keep private your code and who can help fix it up for you.


Thanks for the tip! In the future I may do that, but for now whatever's most convenient for whomever is offering to fix my code!


K.V.

The code has been removed on my end.

If you have any more scripts as room descriptions:

  • copy the script
  • click on that room's Script tab
  • paste the script you copied into After entering the room
  • go back and change the room description from Run a script to text, and leave it blank

That should do it.


K.V.

You can go ahead and delete yours.

Let me know once you've copied mine.

👍


image


It certainly works! Awesome! I can't thank you enough. I'll spend some time chewing through what you did, but I have your version of the code saved.

We can clear the code now. Thanks a ton.


This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums