diff --git a/README.txt b/README.txt index 311f414..3a1f518 100644 --- a/README.txt +++ b/README.txt @@ -1,4 +1,4 @@ -Bedrock Markup Language Mod v1.1 +Bedrock Markup Language Mod v1.2 By Leslie E. Krause Bedrock Markup Language is an extensible markup language and API specifically tailored @@ -32,3 +32,133 @@ DEALINGS IN THE SOFTWARE. For more details: https://opensource.org/licenses/MIT + + +Multimedia License (textures, sounds, and models) +---------------------------------------------------------- + +Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0) + + /textures/emoji_amused.png + by sorcerykid + + /textures/emoji_cheerful.png + by sorcerykid + + /textures/emoji_crying.png + by sorcerykid + + /textures/emoji_frozen_heart.png + by sorcerykid + + /textures/emoji_heartbreak.png + by sorcerykid + + /textures/emoji_kissing.png + by sorcerykid + + /textures/emoji_sad.png + by sorcerykid + + /textures/emoji_smug.png + by sorcerykid + + /textures/emoji_yum.png + by sorcerykid + + /textures/emoji_angry.png + by sorcerykid + + /textures/emoji_cone.png + by sorcerykid + + /textures/emoji_cupid_heart.png + by sorcerykid + + /textures/emoji_frustrated.png + by sorcerykid + + /textures/emoji_heart.png + by sorcerykid + + /textures/emoji_laughing.png + by sorcerykid + + /textures/emoji_silly.png + by sorcerykid + + /textures/emoji_surprised.png + by sorcerykid + + /textures/emoji_annoyed.png + by sorcerykid + + /textures/emoji_confused.png + by sorcerykid + + /textures/emoji_danger.png + by sorcerykid + + /textures/emoji_grin.png + by sorcerykid + + /textures/emoji_hungry.png + by sorcerykid + + /textures/emoji_lock.png + by sorcerykid + + /textures/emoji_sleeping.png + by sorcerykid + + /textures/emoji_unknown.png + by sorcerykid + + /textures/emoji_black_heart.png + by sorcerykid + + /textures/emoji_cool.png + by sorcerykid + + /textures/emoji_disappointed.png + by sorcerykid + + /textures/emoji_happy.png + by sorcerykid + + /textures/emoji_keep_out.png + by sorcerykid + + /textures/emoji_mad.png + by sorcerykid + + /textures/emoji_smitten.png + by sorcerykid + + /textures/emoji_warning.png + by sorcerykid + +You are free to: +Share — copy and redistribute the material in any medium or format. +Adapt — remix, transform, and build upon the material for any purpose, even commercially. +The licensor cannot revoke these freedoms as long as you follow the license terms. + +Under the following terms: + +Attribution — You must give appropriate credit, provide a link to the license, and +indicate if changes were made. You may do so in any reasonable manner, but not in any way +that suggests the licensor endorses you or your use. + +No additional restrictions — You may not apply legal terms or technological measures that +legally restrict others from doing anything the license permits. + +Notices: + +You do not have to comply with the license for elements of the material in the public +domain or where your use is permitted by an applicable exception or limitation. +No warranties are given. The license may not give you all of the permissions necessary +for your intended use. For example, other rights such as publicity, privacy, or moral +rights may limit how you use the material. + +For more details: +http://creativecommons.org/licenses/by-sa/3.0/ diff --git a/init.lua b/init.lua index 5d58fb0..b6b297f 100644 --- a/init.lua +++ b/init.lua @@ -1,5 +1,5 @@ -------------------------------------------------------- --- Minetest :: Bedrock Markup Language (bedrock) +-- Minetest :: Bedrock Markup Language Mod (markup) -- -- See README.txt for licensing and other information. -- Copyright (c) 2016-2019, Leslie Ellen Krause @@ -143,12 +143,14 @@ markup.parse_message = function ( message, vars ) table.insert( cols, { horz = horz, text = text, type = type } ) elseif type == "item" and string.find( c_val, "^[a-zA-Z0-9_]+:[a-zA-Z0-9_]+$" ) then - local itemdef = minetest.registered_items[ c_val ] or ":unknown" - local text = "unknown_item.png" - if itemdef.type == "tool" or itemdef.type == "craft" then - text = itemdef.inventory_image - elseif itemdef.tiles then + local itemdef = minetest.registered_items[ c_val ] + local text + if not itemdef then + text = "unknown_item.png" + elseif itemdef.type == "node" and not itemdef.inventory_image then text = itemdef.tiles[ 1 ] + else + text = itemdef.inventory_image -- always fallback to inventory image end table.insert( cols, { horz = horz, text = text, type = type } ) diff --git a/textures/emoji_amused.png b/textures/emoji_amused.png new file mode 100644 index 0000000..ef66283 Binary files /dev/null and b/textures/emoji_amused.png differ diff --git a/textures/emoji_angry.png b/textures/emoji_angry.png new file mode 100644 index 0000000..40c4ee8 Binary files /dev/null and b/textures/emoji_angry.png differ diff --git a/textures/emoji_annoyed.png b/textures/emoji_annoyed.png new file mode 100644 index 0000000..9fc4955 Binary files /dev/null and b/textures/emoji_annoyed.png differ diff --git a/textures/emoji_black_heart.png b/textures/emoji_black_heart.png new file mode 100644 index 0000000..a772e13 Binary files /dev/null and b/textures/emoji_black_heart.png differ diff --git a/textures/emoji_cheerful.png b/textures/emoji_cheerful.png new file mode 100644 index 0000000..9df9715 Binary files /dev/null and b/textures/emoji_cheerful.png differ diff --git a/textures/emoji_cone.png b/textures/emoji_cone.png new file mode 100644 index 0000000..28dab88 Binary files /dev/null and b/textures/emoji_cone.png differ diff --git a/textures/emoji_confused.png b/textures/emoji_confused.png new file mode 100644 index 0000000..69504f7 Binary files /dev/null and b/textures/emoji_confused.png differ diff --git a/textures/emoji_cool.png b/textures/emoji_cool.png new file mode 100644 index 0000000..e3a84aa Binary files /dev/null and b/textures/emoji_cool.png differ diff --git a/textures/emoji_crying.png b/textures/emoji_crying.png new file mode 100644 index 0000000..119d52b Binary files /dev/null and b/textures/emoji_crying.png differ diff --git a/textures/emoji_cupid_heart.png b/textures/emoji_cupid_heart.png new file mode 100644 index 0000000..a2994ae Binary files /dev/null and b/textures/emoji_cupid_heart.png differ diff --git a/textures/emoji_danger.png b/textures/emoji_danger.png new file mode 100644 index 0000000..5143618 Binary files /dev/null and b/textures/emoji_danger.png differ diff --git a/textures/emoji_disappointed.png b/textures/emoji_disappointed.png new file mode 100644 index 0000000..24a8373 Binary files /dev/null and b/textures/emoji_disappointed.png differ diff --git a/textures/emoji_frozen_heart.png b/textures/emoji_frozen_heart.png new file mode 100644 index 0000000..2eb2ff5 Binary files /dev/null and b/textures/emoji_frozen_heart.png differ diff --git a/textures/emoji_frustrated.png b/textures/emoji_frustrated.png new file mode 100644 index 0000000..072703e Binary files /dev/null and b/textures/emoji_frustrated.png differ diff --git a/textures/emoji_grin.png b/textures/emoji_grin.png new file mode 100644 index 0000000..ef66283 Binary files /dev/null and b/textures/emoji_grin.png differ diff --git a/textures/emoji_happy.png b/textures/emoji_happy.png new file mode 100644 index 0000000..ebda019 Binary files /dev/null and b/textures/emoji_happy.png differ diff --git a/textures/emoji_heart.png b/textures/emoji_heart.png new file mode 100644 index 0000000..8ce0b6f Binary files /dev/null and b/textures/emoji_heart.png differ diff --git a/textures/emoji_heartbreak.png b/textures/emoji_heartbreak.png new file mode 100644 index 0000000..389e005 Binary files /dev/null and b/textures/emoji_heartbreak.png differ diff --git a/textures/emoji_hungry.png b/textures/emoji_hungry.png new file mode 100644 index 0000000..40af60f Binary files /dev/null and b/textures/emoji_hungry.png differ diff --git a/textures/emoji_keep_out.png b/textures/emoji_keep_out.png new file mode 100644 index 0000000..9f6fefc Binary files /dev/null and b/textures/emoji_keep_out.png differ diff --git a/textures/emoji_kissing.png b/textures/emoji_kissing.png new file mode 100644 index 0000000..0cffab7 Binary files /dev/null and b/textures/emoji_kissing.png differ diff --git a/textures/emoji_laughing.png b/textures/emoji_laughing.png new file mode 100644 index 0000000..0c77237 Binary files /dev/null and b/textures/emoji_laughing.png differ diff --git a/textures/emoji_lock.png b/textures/emoji_lock.png new file mode 100644 index 0000000..a4c7297 Binary files /dev/null and b/textures/emoji_lock.png differ diff --git a/textures/emoji_mad.png b/textures/emoji_mad.png new file mode 100644 index 0000000..ecd48c2 Binary files /dev/null and b/textures/emoji_mad.png differ diff --git a/textures/emoji_sad.png b/textures/emoji_sad.png new file mode 100644 index 0000000..be401cd Binary files /dev/null and b/textures/emoji_sad.png differ diff --git a/textures/emoji_silly.png b/textures/emoji_silly.png new file mode 100644 index 0000000..57307f2 Binary files /dev/null and b/textures/emoji_silly.png differ diff --git a/textures/emoji_sleeping.png b/textures/emoji_sleeping.png new file mode 100644 index 0000000..32e06de Binary files /dev/null and b/textures/emoji_sleeping.png differ diff --git a/textures/emoji_smitten.png b/textures/emoji_smitten.png new file mode 100644 index 0000000..192cebd Binary files /dev/null and b/textures/emoji_smitten.png differ diff --git a/textures/emoji_smug.png b/textures/emoji_smug.png new file mode 100644 index 0000000..ded3c87 Binary files /dev/null and b/textures/emoji_smug.png differ diff --git a/textures/emoji_surprised.png b/textures/emoji_surprised.png new file mode 100644 index 0000000..343c77a Binary files /dev/null and b/textures/emoji_surprised.png differ diff --git a/textures/emoji_unknown.png b/textures/emoji_unknown.png new file mode 100644 index 0000000..6e18f6b Binary files /dev/null and b/textures/emoji_unknown.png differ diff --git a/textures/emoji_warning.png b/textures/emoji_warning.png new file mode 100644 index 0000000..88f5f7c Binary files /dev/null and b/textures/emoji_warning.png differ diff --git a/textures/emoji_yum.png b/textures/emoji_yum.png new file mode 100644 index 0000000..40af60f Binary files /dev/null and b/textures/emoji_yum.png differ