Non-threaded

Forums » Feature Wishing Well » Read Thread

Suggestions for improvements and additions to the site.
This feature was rejected 12/12/2007: You can do this through scripting - talk to TSMPaul

Pictures Shown by Variables

17 years ago
I don't know if this is possible, but if you could create variables for pictures I would be pleased. By this I mean that you can make pictures only appear if a certain variable is at a certain number, or change the pictures depending on variables. It would be very useful for storygames that use the mapping technique.

Pictures Shown by Variables

17 years ago
i need this for cryptode 2 but i bet you this will be too hard for alex to make or it wont be made for a year...

Pictures Shown by Variables

17 years ago
Yeah, I thought it would be hard. I've no idea how to do it. Maybe if he made something like the IPB Code in some forums where you can put in certain types of html, and make one of them for the editor and one of the features could be using the IMG SRC tag, which meant you could put it within hidden text. Just a thought.

But otherwise, yeah, it'll probably be a year until it gets done.

Pictures Shown by Variables

17 years ago
I think you could do this through the $PAGETEXT variable - you know how you can use HTML in $PAGETEXT? Just use the IMG SRC tag.

Pictures Shown by Variables

16 years ago
i asked 4 this once but thay denided it

Pictures Shown by Variables

16 years ago

"i asked 4 this once but thay denided it"

 

Did you say pleasesese?

Pictures Shown by Variables

16 years ago

no y

 

Pictures Shown by Variables

16 years ago
(Pssst... He didn't get it)

Pictures Shown by Variables

16 years ago

In case you need more instructions, this is what to stick in your page script:

$PAGETEXT := $PAGETEXT + "<br><br>" + "<img src='/i/?5984 ' style='float:right;margin:5px'>"

The number after the question mark must be the ID number of your picture. Ie, replace ?5984 with your own picture's number. To find out it's number, go to MY PICTURES, left click on an image, and the picture will open in a new window. Look at your internet address bar, and instead of a web page showing, there should be a question mark and a number. That's the number you need.

To change whether it is on the right, in the middle, or at the top of the text, change the word after 'float:' in the script. To see what options you can use for aligning the picture, add a picture to a page the normal way, right click on it in the page editor, and select IMAGE PROPERTIES. There's a drop-down box called Align in the bottom left, with the different options you can use. Just insert the word you want into the script I typed above, after the word 'float:' to make the picture display that way in your script.

That script above will add the picture at the bottom of the page (or beneath any text already entered in your script). If you want the image at the top, use this script, and make it the first line in your script:

$PAGETEXT := "<img src='/i/?5984 ' style='float:text top;margin:5px'>" + "<br><br>" + $PAGETEXT

(I think I've got the script's right, but haven't tested them recently)

Pictures Shown by Variables

16 years ago

I forgot about the variable bit :)

Say you've got a map picture displaying on each page, and you've got images of the different locations as maps. You might think of a number to assign to each location, and if the %MAP variable is that number, then it shows the map for that location. Anyhow, you just do it like:

IF %MAP = 15 THEN $PAGETEXT := $PAGETEXT + "<br><br>" + "<img src='/i/?5984 ' style='float:right;margin:5px'>"

Just insert the variable check at the front of the script line that displays the image. I'm not sure what sort of variable/image use you have in mind, but just make it so if the variable you want equals a certain number, then the image number is the picture you want displayed.

Pictures Shown by Variables

16 years ago
(and all the script lines in the two messages above are a single line of script code, not two lines. The forum message displayer always wraps words onto a second line, but they're a single line of code.)

Pictures Shown by Variables

16 years ago
TP you are a living god, thank you!

Pictures Shown by Variables

16 years ago

Holy cow TSM - nice work around.  Well done.

march

Pictures Shown by Variables

16 years ago
Figured this out a while ago. Thanks to tsmpaul for pointing it out.