mirror of
https://github.com/mt-mods/unifieddyes.git
synced 2024-11-26 17:33:49 +01:00
warn the user to open the color selector
instead of crashing if they have no color set :-)
This commit is contained in:
parent
4dde37c191
commit
6ecb115465
8
init.lua
8
init.lua
@ -655,6 +655,14 @@ function unifieddyes.on_airbrush(itemstack, player, pointed_thing)
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if not painting_with then
|
||||||
|
minetest.chat_send_player(player_name, "*** You need to set a color first.")
|
||||||
|
minetest.chat_send_player(player_name, "*** Right-click any random node to open the color selector,")
|
||||||
|
minetest.chat_send_player(player_name, "*** or shift+right-click a colorized node to use its color.")
|
||||||
|
minetest.chat_send_player(player_name, "*** Be sure to click \"Accept\", or the color you select will be ignored.")
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
if not def.palette then
|
if not def.palette then
|
||||||
minetest.chat_send_player(player_name, "That node can't be colored.")
|
minetest.chat_send_player(player_name, "That node can't be colored.")
|
||||||
return
|
return
|
||||||
|
Loading…
Reference in New Issue
Block a user