Autocomplete mod name prefix for items

This commit is contained in:
Van
2026-01-02 21:32:54 +03:00
parent 275f54c7b7
commit 6db2e9f77a
5 changed files with 28 additions and 33 deletions

View File

@@ -8,7 +8,7 @@ local Plant = modInfo.require('Plant')
Plant:new({
settings = {
name = 'plants:plants',
name = 'plants',
description = 'Plant',
tiles = { "test_plant.png" },
place_param2 = 3,
@@ -21,10 +21,13 @@ local ts = TileSheet:new('plants_test_sheet.png', 16, 16)
for i=0, 3 do
Plant:new({
settings = {
name = 'plants:plant'..tostring(i),
name = 'plant'..tostring(i),
description = 'Plant',
tiles = { ts:t(i,0) },
place_param2 = 3,
},
})
end
core.log(dump(core.registered_nodes))

View File

@@ -243,7 +243,7 @@ local tsT = TileSheet:new("soils_turfs_sheet.png", 16, 16)
Node:new({
settings = {
name = 'soils:turf_swamp',
name = 'turf_swamp',
tiles = {tsT:t(0,0), ts:t(6, 0), ts:t(6,0)..'^'..tsT:t(0,1)},
groups = {
dig_immediate = 2,