Post new topic    
Transparent color in Backdrops vs. Plotscripting 
 PostSun Sep 15, 2019 8:10 pm
Send private message Reply with quote
Forgive me if there was a thread on this at one point (didn't find one when I searched, just to make sure I'm not adding to a pile of inquiries about this).

I noticed that if I utilize the "Show Backdrop" command with an image intended to have some transparency in the background, it does not account for allowing transparency (and there didn't appear to be a command or even argument to affect whether or not to account for transparency). So I have a backdrop with a neon-pink background that was intended to be transparent which won't play nice when being called via scripting.

Is there a way to account for transparency when scripting? If not, it's perfectly okay; I'll probably do a workaround by using the backdrop on the two text boxes that go up with it and only have the script call the first one (making the first one connect to the second in-engine, since scripting seems to allow that behavior) and then move on to the rest of the scene.
- George R. Powell (Setu Firestorm)
Digital Music Composer, Writer, Creator
Wingspread Creations
Metal King Slime
Send private message
 
 PostMon Sep 16, 2019 12:34 pm
Send private message Reply with quote
I'm going to add an argument to "show backdrop" to control transparency; that's an oversight.

In the meantime, although you can't set the transparency with "show backdrop" you can if you display a backdrop slice instead. Slices were added since you last used the engine. A slice is like an HTML element, eg a sprite or a rectange or an invisible container. Almost all graphics (eg maps, npcs, textboxes) are slices and can be manipulated by scripts. https://rpg.hamsterrepublic.com/ohrrpgce/Slices

Code:

plotscript, a cutscene, begin
  variable (sl)
  # Newly created slices default to displaying above the map but below textboxes, and are transparent
  # (You would have to write "set sprite trans (sl, false)" to make it opaque)
  sl := load backdrop sprite (10)
 
  show text box (10)
  # ...etc

  free slice (sl)
end
 
 PostSat Sep 28, 2019 3:15 am
Send private message Reply with quote
Awesome! Thank you much!

The whole "Slice" thing is new to me from when I last used OHRRPGCE, and is high on my To-Do list of researching since I've seen some of the games listed here that appear to have put the concept to work, and if the mechanic is what I think it is, it will make a LOT of cool effects possible that were very cumbersome to pull off in years past.

I have the Wiki page for Slices bookmarked (from the OHR Wiki site), so I can start reading up on it.
- George R. Powell (Setu Firestorm)
Digital Music Composer, Writer, Creator
Wingspread Creations
Display posts from previous: