[mod] kaeza's/VanessaE's signs library [signs_lib][git]

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

[mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

Image

kaeza's/VanessaE's signs_lib mod

This is kaeza's and my signs library mod, originally forked from PilzAdam's version and rewritten mostly by kaeza to include a number of new features, then rewritten again a couple more times (finding its way into street_signs for a while, where it grew nicely :-) ).

Originally the purpose of the above upstream mods was to just make default signs show their text, via an entity placed right in front. This library is a modernized, feature-enhanced version of that code, which not only allows creation of simple graphical signs, fully writable ones with visible text, and signs with both features, but which allows that text to be colored, and any reasonable size and text amount can be set in any given node definition, with two font resolutions available. Text can be placed anywhere on a sign, in any orientation, with any clipping shape you like, by simply designing the sign's model and text entity properly.

Almost any sign (any shape/model) can be placed-on and thus attached to almost any kind of suitable vertical or horizontal pole or fencepost (or things that resemble them, such as a Pipeworks pipe or tube), as well. Most signs that use the standard rectangular model can also be hung from a ceiling, or standing upright as a yard sign, as well as on posts/poles and walls. Holding shift while placing will force the sign to be placed flat on the target surface, bypassing post/yard/ceiling detection.

Full multi-color text is a key feature of this mod - simply write your text like normal, plus a "#" sign and number 0-9 or letter a-f (e.g. a single hexadecimal digit with a decimal value of - to 15), to change the color of the text that follows it. By default, the text will be displayed in whatever color the sign's default is set for in it's node definition (usually black or white). The color palette follows the good old industry-standard 16-color CGA console palette that we're all familiar with (e.g. the standard Linux terminal/DOS command prompt colors).

Arrow symbols are available by writing "^1" through "^8" (narrow shape) or "^a" through "^h" (wide shape).

Writable signs can be configured to allow for a double-wide font mode (accessible to the user via a switch in the sign's dialog box).

If a sign is writable, its text is visible even when it's flat on a ceiling or floor.

In the case of signs that sit on a pole or post, do note that the pole/post occupies its usual node space, while sign itself still occupies the node space in front of/next to that post. But this probably won't matter in practice, since the idea of a sign is to be read (so you wouldn't want to obscure/obstruct it anyway).

All signs can be designed and configured to allow any or all of these options, and MUCH more.

For complete details on how to use this library with your own mods, see README.md, MODELS.md, and API.md.

Depends: Minetest 5.0 or later, minetest_game default, basic_materials

Recommends: basic_signs, street_signs

Download: https://github.com/mt-mods/signs_lib/ar ... master.zip
...or browse the code: https://github.com/mt-mods/signs_lib

Install: Just copy the mod folder to the usual place and enable it.

License: LGPL v3 for code, CC-by-SA 4.0 for media and everything else.
Attachments
Screenshot_2019-10-11_06-43-17.png
Screenshot_2019-10-11_06-43-17.png (243.09 KiB) Viewed 3896 times
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

redblade7
Member
Posts: 316
Joined: Sun Feb 15, 2015 07:14
IRC: redneonglow redblade7
In-game: redblade7 redblade7_owner

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by redblade7 » Post

Great idea!

Does signs_lib revert whatever happened to homedecor c. March 2015, where the side-to-side unlocked wooden signs don't work anymore? (I noticed the tickets for the homedecor bugs were closed in light of this new mod's creation.)

Also, if I was to update homedecor on my server and install signs_lib, should the existing signs be preserved?

Thank you!
-redblade7, admin of: THE CREATIVE GARDENS (creative), THE VALLEYS (sandbox), and THE DIGITAL FARMS (farming/hunger/shops)

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

This isn't a new mod, really. It's the exact same code that was in the homedecor modpack, merely split off into a separate package.

That aside, I don't seem to have any trouble placing signs at all.

The reason you're having trouble placing the initial sign is because signs_lib is letting the engine handle the facedir prediction. Signs were never meant to be placeable at a right angle to the wall you're pointing at.

Build your wall, then place a block of anything 1 meter behind where you want the sign to go. Then place a sign against it and remove the block. Go around to the back side of the sign, point at it, and hold shift while you place another sign, and it'll be placed flat against the back. Both sides are then writable.
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

u34

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by u34 » Post

is there a solution for umlaute for german users like ü, ä, ö and ß.
how can I enable such signs?

by the way, the game voxelands supports umlaute. Great feature there.

Image
Attachments
voxelands 2015-12-21 12-44-02-58.jpg
voxelands 2015-12-21 12-44-02-58.jpg (65.23 KiB) Viewed 3896 times
Last edited by u34 on Mon Dec 21, 2015 11:46, edited 2 times in total.

User avatar
Fixer
Member
Posts: 904
Joined: Sun Jul 31, 2011 11:23
IRC: Fixer
In-game: Fixer
Location: Ukraine

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by Fixer » Post

Great work!

Martno
Member
Posts: 80
Joined: Thu May 28, 2015 07:09
Location: Hungary

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by Martno » Post

It would be awesome if this mod would handle UTF-8 characters. Is it possible?

User avatar
kaeza
Moderator
Posts: 2162
Joined: Thu Oct 18, 2012 05:00
GitHub: kaeza
IRC: kaeza diemartin blaaaaargh
In-game: kaeza
Location: Montevideo, Uruguay
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by kaeza » Post

Martno wrote:It would be awesome if this mod would handle UTF-8 characters. Is it possible?
It's possible, but given that each char is a separate texture, this would increase the distribution size too much. If implemented, will probably include only the characters used in most western scripts (english, spanish, italian, etc.). Textures for other scripts (cyrillic/CJK/etc) would have to be distributed separately.
Your signature is not the place for a blog post. Please keep it as concise as possible. Thank you!

Check out my stuff! | Donations greatly appreciated! PayPal

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

I agree that UTF-8 would be too much.

Support for the full ISO-8859-1 character set should be enough for the main signs_lib distribution.
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

Martno
Member
Posts: 80
Joined: Thu May 28, 2015 07:09
Location: Hungary

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by Martno » Post

I understand. ISO 8859-1 would be much better (that would give me enough character to substitute the missing ones)
I think I can make the missing textures for myself (because I need the missing charcters for my game) but I don't know how to add them to the mod (what code changes would be needed) because I'm a noob at modding. Could somebody explain it to me (if it's not to much to ask). If it's too complicated or hard to explain in a couple of sentence, then never mind.

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

It should just be a matter of naming the glyph textures properly, as hdf_xx.png where xx is the ASCII code, in hex, of the character you want to add.

I don't THINK any changes to signs_lib's code are needed, but perhaps you might have to change the range on line 228 also. If you do, a check for non-existent glyph files within that loop might be needed too. That said, I don't know what would be needed to get Minetest to actually USE that encoding in the formspec.
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

Martno
Member
Posts: 80
Joined: Thu May 28, 2015 07:09
Location: Hungary

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by Martno » Post

Thank you!

User avatar
Fixer
Member
Posts: 904
Joined: Sun Jul 31, 2011 11:23
IRC: Fixer
In-game: Fixer
Location: Ukraine

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by Fixer » Post

VanessaE wrote:I agree that UTF-8 would be too much.

Support for the full ISO-8859-1 character set should be enough for the main signs_lib distribution.
Will be nice to have both ISO-8859-1 and UTF-8 versions. There are players with non-western charsets (Cyrillic, Chinese, Japan, India, and many other).

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

There's no way this mod will ever support the full UTF-8 character set - not with its render-to-sprite-entity method of displaying the text, anyway. If the engine ever gets real text displayed on signs (i.e. without this hack), that may change.

Getting even ISO-8859-1 working is dependent on what character codes Minetest gets from the OS (or irrlicht?) when international text is submitted in a formspec.
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

redblade7
Member
Posts: 316
Joined: Sun Feb 15, 2015 07:14
IRC: redneonglow redblade7
In-game: redblade7 redblade7_owner

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by redblade7 » Post

After recent server and mod updates I've run into a problem with signs, but I'm not sure if homedecor/signs_lib is to blame or not.

Before I file anything on github, does installing signs_lib affect the normal wooden signs in any way (the one in the top left corner)? The problem I'm having is true of those signs too.
-redblade7, admin of: THE CREATIVE GARDENS (creative), THE VALLEYS (sandbox), and THE DIGITAL FARMS (farming/hunger/shops)

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

As long as you're using the current code, it shouldn't have any negative effect on old signs, particularly if you're talking about a world that's never had any version of signs_lib installed. That said, what's the problem?
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

redblade7
Member
Posts: 316
Joined: Sun Feb 15, 2015 07:14
IRC: redneonglow redblade7
In-game: redblade7 redblade7_owner

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by redblade7 » Post

VanessaE wrote:As long as you're using the current code, it shouldn't have any negative effect on old signs, particularly if you're talking about a world that's never had any version of signs_lib installed. That said, what's the problem?
The server has the latest versions of homedecor_modpack and signs_lib, and existed before signs_lib was spun off.

When signs are placed in certain areas (not sure what the differences are), the following happens:

1. The text correctly shows on the sign
2. Teleport/travelnet/turn around, walk away, walk back to the sign
3. The text on the sign will be partially visible, the visible portion changing as you move the mouse
4. Repeat step #2
5. The text on the sign is completely invisible.
6. Have fun playing Minetest
7. Quit the game
8. Come back later
9. Return to step #1

I'm not sure if this is related, but all signs placed directly on the ground are always completely blank.

This started sometime in January 2016, either in installing/updating a mod on the server, or updating the Github version of Minetest, which I recompile when doing that.
Attachments
Step #5 (edited for size)
Step #5 (edited for size)
turnaroundandgobackagain-edit.png (753.48 KiB) Viewed 3896 times
Step #3 (edited for size)
Step #3 (edited for size)
turnaroundandgoback-edit.png (244.32 KiB) Viewed 3896 times
-redblade7, admin of: THE CREATIVE GARDENS (creative), THE VALLEYS (sandbox), and THE DIGITAL FARMS (farming/hunger/shops)

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

You're talking about z-fighting. That's a minor bug in signs_lib, the entities that display the text just need to be moved a little further out from the sign (they're so close that they just exceed irrlicht's/minetest's positioning precision limit, that's all).

It's just a glitch I've been meaning to fix, just never got around to it.

Text disappearing entirely is due to how minetest manages loading and displaying entities, and is not affected by signs_lib (as far as I know).
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

redblade7
Member
Posts: 316
Joined: Sun Feb 15, 2015 07:14
IRC: redneonglow redblade7
In-game: redblade7 redblade7_owner

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by redblade7 » Post

VanessaE wrote:You're talking about z-fighting. That's a minor bug in signs_lib, the entities that display the text just need to be moved a little further out from the sign (they're so close that they just exceed irrlicht's/minetest's positioning precision limit, that's all).

It's just a glitch I've been meaning to fix, just never got around to it.
OK, I can file a bug on Github then, but which project, homedecor_modpack or signs_lib?
Text disappearing entirely is due to how minetest manages loading and displaying entities, and is not affected by signs_lib (as far as I know).
This only happens to the signs affected by the glitch (and ground-mounting of signs_lib signs always appear blank) so I'd imagine it's part of the same problem.
-redblade7, admin of: THE CREATIVE GARDENS (creative), THE VALLEYS (sandbox), and THE DIGITAL FARMS (farming/hunger/shops)

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

file it against signs_lib (and wholly replace your homedecor modpack while you're at it - signs_lib isn't part of it anymore).
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

redblade7
Member
Posts: 316
Joined: Sun Feb 15, 2015 07:14
IRC: redneonglow redblade7
In-game: redblade7 redblade7_owner

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by redblade7 » Post

VanessaE wrote:file it against signs_lib (and wholly replace your homedecor modpack while you're at it - signs_lib isn't part of it anymore).
I upgraded homedecor_modpack when I first installed signs_lib.
-redblade7, admin of: THE CREATIVE GARDENS (creative), THE VALLEYS (sandbox), and THE DIGITAL FARMS (farming/hunger/shops)

redblade7
Member
Posts: 316
Joined: Sun Feb 15, 2015 07:14
IRC: redneonglow redblade7
In-game: redblade7 redblade7_owner

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by redblade7 » Post

redblade7 wrote:
VanessaE wrote:You're talking about z-fighting. That's a minor bug in signs_lib, the entities that display the text just need to be moved a little further out from the sign (they're so close that they just exceed irrlicht's/minetest's positioning precision limit, that's all).

It's just a glitch I've been meaning to fix, just never got around to it.
OK, I can file a bug on Github then, but which project, homedecor_modpack or signs_lib?
Text disappearing entirely is due to how minetest manages loading and displaying entities, and is not affected by signs_lib (as far as I know).
This only happens to the signs affected by the glitch (and ground-mounting of signs_lib signs always appear blank) so I'd imagine it's part of the same problem.
I took a look at the affected signs, and noticed that in every case, the signs are facing east.
-redblade7, admin of: THE CREATIVE GARDENS (creative), THE VALLEYS (sandbox), and THE DIGITAL FARMS (farming/hunger/shops)

Nachtschatten
New member
Posts: 1
Joined: Fri Jan 01, 2016 02:02
In-game: Nachtschatten

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by Nachtschatten » Post

Not sure if this is a problem on my side, but as far as I can see, the Github repository suddenly only contains a few recent commits by kaeza from the 14th of March. Is that just me, or what's going on?

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

Kaeza just collapsed all the old history, since it's all contained in Home Decor's repository anyway, and then added a couple new commits.
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

amadin
Member
Posts: 549
Joined: Tue Jun 16, 2015 16:23

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by amadin » Post

.
Last edited by amadin on Wed May 26, 2021 11:21, edited 1 time in total.

User avatar
VanessaE
Moderator
Posts: 4655
Joined: Sun Apr 01, 2012 12:38
GitHub: VanessaE
IRC: VanessaE
In-game: VanessaE
Location: Western NC
Contact:

Re: [mod] kaeza's/VanessaE's signs library [signs_lib][git]

by VanessaE » Post

Sorry for the uncustomary delay, I've been busy with non-Minetest stuff for a while. I'm not sure I understand what you mean by "indent" in this case.

Meanwhile, a few new features have gone in:
  • Default metal signs in minetest_game have visible text now.
  • Those signs are now used for crafting the colored metal ones in lieu of the previous steel ingot recipies.
  • Some of the colored metal signs have a new default text color (instead of black) to fit their existing style.
  • For coders, you can now specify a default text color and relative location for the text entity. See comments in https://github.com/minetest-mods/signs_lib/issues/5 regarding the text position, and simply add defaultcolor = "<hex digit>" default_color = "<hex digit>" to your node definition to set the color.
For now, the placement behavior and overall style of the default metal signs is unchanged from upstream, aside from having a new texture and visible text. That is, there are no automatic metal yard signs, metal hanging signs, etc. yet, but this will change in the future.
You might like some of my stuff: Plantlife ~ More Trees ~ Home Decor ~ Pipeworks ~ HDX Textures (64-512px)

Post Reply

Who is online

Users browsing this forum: No registered users and 15 guests