sonitek
0/0 Germ
*Currently quite wondering how that scripting is supposed to work*
Posts: 11
Color Alignment: Blue, Black
|
Post by sonitek on Jul 9, 2018 16:03:03 GMT
So, I have this issue where I'm setting a mask for my text box, so that text won't be put over icons it shouldn't be covering, and it seems like my package doesn't even allow me to put in text with my mask on. None whatsoever. I have my code just below this. What am I doing wrong? My mask might be just dimensions off of the text box's dimension somehow. That could be fixed, however, if that is the issue. It should also be noted that the mask itself is properly made, and transparent where I want the text to be allowed, not white. That might be also a reason to why it doesn't work... But while I try those, if you see a big mistake, it'd be nice if anyone could point to me the mistake I made if they can find it.
EDIT: After fiddling with my mask, making it the exact same dimensions as my text box, and turning the transparent parts into white, I can now write in the box, but the mask has no effect, it seems, and MSE doesn't return any error. I'm starting to wonder if I'm not using the mask properly...
card field: type: text name: card text show statistics: false identifying: false card list visible: false multi line: true tab index: 5
card style: card text: left: 18 top: 284 width: 339 height: 150 z index: 3 alignment: left middle stretch if-overflow mask: hero-box-mask.png font: name: Segoe Print size: 8 max stretch: 0.9
|
|
impspiritguide
2/2 Zombie
Favorite Color: Brown
Posts: 129
Set Hub: http://magicseteditor.boards.net/thread/256/pokemon-thread
Formerly Known As: Imp Elemental Spirit Guide
|
Post by impspiritguide on Jul 9, 2018 16:51:35 GMT
Not exactly sure what your problem is so I'll try to cover all the bases (maybe answer your question by throwing all the answers at you).
MSE masks use black and white (the originals were probably jpegs which show no transparency at all having looked at some of the discussions on developing the original code). The white portions are where the text or image shows through and the black portions are where the image is negated or text is disallowed.
In the templates I'm working on I rarely have a single simple mask (it is generally dependent upon some other factor card type or full art vs regular art etc). So I pretty much have all of the entries that allow it in the scripting brackets so my mask line for you would look like this). I don't think this is a problem but if I get syntax errors I goto this as a fallback.
mask: { "hero-box-mask.png" }
Also here is an example for a text box that looks like this My mask is this specific image
Additionally you will know the mask is working as when you highlight the text box it should make a rough blue line surrounding the appropriate box defined by the mask
If this doesn't solve your problem then reply and include a copy of the mask image.
Also you mention working around icons. It might be possible to use a symbol-font to do what you are wanting (this is like adding the character to this line only you do it in MSE).
EDIT: You might also include the image icon you are working around.
|
|
sonitek
0/0 Germ
*Currently quite wondering how that scripting is supposed to work*
Posts: 11
Color Alignment: Blue, Black
|
Post by sonitek on Jul 9, 2018 17:35:58 GMT
Thank you for your reply. I tried to make it as simple as I could as the mask would need to cover two types of icons. When I say "working around icon", I don't mean something font-able. (I have already somehow managed that without too much difficulty, lucky me. What I mean by working around the icon is basically this... Icons: The two things at the bottom of this image. Attachment DeletedMask used: with the Squares actually fitting over the icons when in Sai. And even then the mask still doesn't seem to affect the shape of the text box itself, so I'm probably doing something very wrong somewhere. Attachment Deleted
|
|
impspiritguide
2/2 Zombie
Favorite Color: Brown
Posts: 129
Set Hub: http://magicseteditor.boards.net/thread/256/pokemon-thread
Formerly Known As: Imp Elemental Spirit Guide
|
Post by impspiritguide on Jul 9, 2018 18:56:26 GMT
Found the problem, You didn't have a coding problem, You have an image problem.
The mask you are using still had some transparency along one side, apparently this is enough to throw off MSE. If you load the image in your image editor and save it as a jpg you should see the difference.
This is the image I did to find out why it wasn't working for me as well. (Note it matches the transparency box in your card frame)
But given the width to height ratios it appears that you have something above this text box so I simply changed the upper transparency to white and blackout out the white borders you had to your black portions and got the following.
I'm not familiar with Sai (I use an old Windows 2000 vintage software for raster images, although I dabble in GIMP just to keep up and help the people I work with). Within most editors there is a way to set the number of colors in an image and I've found that with the masks as long as you aren't using them to fade an image in and out I set the colors to 2. The other option is to save the image as a jpeg. If Sai allows you to work with layers then a trick I often use with transparencies (finding them removing them etc) is to make a solid color image layer in the background (red, grey, purple, depends upon what overlays it). This will allow me to see where my holes still are. There are other tricks (most editors actually save a mask of the transparency as a separate part of the image and you can access this somehow, but that is highly software dependent).
|
|
sonitek
0/0 Germ
*Currently quite wondering how that scripting is supposed to work*
Posts: 11
Color Alignment: Blue, Black
|
Post by sonitek on Jul 10, 2018 3:21:06 GMT
Well, then that clearly fixed my issue. Thanks a whole bunch. For my future masks, I'll just make sure there's no transparency. There's a way to do that in SAI.
|
|