Code Monkey home page Code Monkey logo

castle_gates's People

Contributors

facedeer avatar fluxionary avatar julius-d avatar louisroyer avatar niklp09 avatar panquesito7 avatar smalljoker avatar swissalps avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

castle_gates's Issues

Doors won't open if more that 2 blocks wide

Just as the title says, if I make a door that is more than 2 blocks wide, the doors will no longer open.

I made a door that was 4 tall and 3 wide and it stopped opening at all. But if I make it (n) Tall and only 2 wide it will open.

[edited for readability]

[edit 2] When I make a door that is 2 wide once it opens or closes the door starts blinking for about 3 seconds

Some kind of crash

One of my users reported this:

[10-03 09:32] User11@VBld VanessaE: Portcullis Bars cause [VE-Creative] to crash.
...later...
[10-03 14:12] User11@VBld when you touch portcullisbars on [VE-Creative,] the server crashes...

Here's what I find in my logs related to it:

2018-10-03 15:28:57: ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from mod '' in callback item_OnPlace(): ...ods/dreambuilder_modpack/castle_gates/gate_functions.lua:16: attempt to index field 'top' (a nil value)
2018-10-03 15:28:57: ERROR[Main]: stack traceback:
2018-10-03 15:28:57: ERROR[Main]:       ...ods/dreambuilder_modpack/castle_gates/gate_functions.lua:16: in function 'get_dirs'
2018-10-03 15:28:57: ERROR[Main]:       ...ods/dreambuilder_modpack/castle_gates/gate_functions.lua:157: in function 'get_door_layout'
2018-10-03 15:28:57: ERROR[Main]:       ...ods/dreambuilder_modpack/castle_gates/gate_functions.lua:321: in function 'on_rightclick'
2018-10-03 15:28:57: ERROR[Main]:       /usr/local/share/minetest/builtin/game/item.lua:423: in function </usr/local/share/minetest/builtin/game/item.lua:416>

From what I gather, the person above who triggered the crash is not the same person who placed the offending gate, if that matters.

User-unfriendly + Lacks documentation

Not a single word in the doc mod allowed me to use this mod correctly. When I trigger gates I placed they fly to the sky. With hinders they started swinging in arbitrary directions.

Invalid craft recipes

In gate_slots.lua, the whole of the following section is invalid. I suspect that every mention of portcullis_slot should be gate_slot, since that matches the names of the nodes defined just above.

` minetest.register_craft({
output = mod_name..":"..material.name.."_portcullis_slot 3",
recipe = {
{material.craft_material,"",material.craft_material},
{material.craft_material,"",material.craft_material},
{material.craft_material,"",material.craft_material},
},
})

minetest.register_craft({
    output = mod_name..":"..material.name.."_portcullis_slot",
    type = "shapeless",
    recipe = {mod_name..":"..material.name.."_portcullis_slot_reverse"},
})
minetest.register_craft({
    output = mod_name..":"..material.name.."_portcullis_slot_reverse",
    type = "shapeless",
    recipe = {mod_name..":"..material.name.."_portcullis_slot"},
})

if burn_time > 0 then
    minetest.register_craft({
        type = "fuel",
        recipe = mod_name..":"..material.name.."_portcullis_slot",
        burntime = burn_time * 2,
    })
    minetest.register_craft({
        type = "fuel",
        recipe = mod_name..":"..material.name.."_portcullis_slot_reverse",
        burntime = burn_time * 2,
    })  
end`

gate_functions.lua:406: attempt to index a nil value

Not sure what was attempted by the user.

2021-09-12 19:46:47: ERROR[Main]: ServerError: AsyncErr: environment_Step: Runtime error from mod '' in callback environment_Step(): ...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:406: attempt to index a nil value
2021-09-12 19:46:47: ERROR[Main]: stack traceback:
2021-09-12 19:46:47: ERROR[Main]: 	...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:406: in function 'func'
2021-09-12 19:46:47: ERROR[Main]: 	...ive1/5.4.1/Minetest_live/bin/../builtin/common/after.lua:26: in function 'func'
2021-09-12 19:46:47: ERROR[Main]: 	...inetest_live/bin/../builtin/profiler/instrumentation.lua:106: in function <...inetest_live/bin/../builtin/profiler/instrumentation.lua:100>
2021-09-12 19:46:47: ERROR[Main]: 	...ve1/5.4.1/Minetest_live/bin/../builtin/game/register.lua:422: in function <...ve1/5.4.1/Minetest_live/bin/../builtin/game/register.lua:406>
2021-09-12 19:46:47: ERROR[Main]: stack traceback: corrupted double-linked list

For my reference 897

Could not load image "xpanes_space.png"

2020-04-11 18:45:07: ERROR[Main]: generateImage(): Could not load image "xpanes_space.png" while building texture; Creating a dummy image
2020-04-11 18:45:07: ERROR[Main]: generateImage(): Could not load image "xpanes_space.png" while building texture; Creating a dummy image

Seems like this png has vanished from the xpanes mod. You may want to replace it?

Line 70 of doors.lua asks for that png

Recipe collision with 3d_armor

The recipe for castle_gates:wood_gate_slot collides with the recipe for wooden boots of 3d_armor.

Could either of you change their recipe so we can have both mods without collisions?

For my reference 1557

attempt to perform arithmetic on field 'z' (a nil value)

@FaceDeer thank you for restoring this mod, I really appreciate your efforts to fix these issues. :)

I've found another, this time related to the gate's swing. I've built this drawbridge:

screenshot

Everything works as expected if you click on the hinged panels (i.e. the drawbridge lifts and stops against the tower's wall) but if you click on any of the other panels (castle_gates:gate_panel) the game crashes dumping this error:

--- LOG START

ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from mod 'default' in callback item_OnPlace(): ...chi/minetest-stable-0.4/bin/../builtin/common/vector.lua:68: attempt to perform arithmetic on field 'z' (a nil value)

ERROR[Main]: stack traceback:

ERROR[Main]: ...chi/minetest-stable-0.4/bin/../builtin/common/vector.lua:68: in function 'direction'

ERROR[Main]: ...games/hamlets_quest/mods/castle_gates/gate_functions.lua:258: in function 'get_door_layout'

ERROR[Main]: ...games/hamlets_quest/mods/castle_gates/gate_functions.lua:320: in function 'on_rightclick'

ERROR[Main]: .../Giochi/minetest-stable-0.4/bin/../builtin/game/item.lua:347: in function <.../Giochi/minetest-stable-0.4/bin/../builtin/game/item.lua:340>

--- LOG END

It seems to have the same issue with field Y, I don't know about others.

Redundant code?

I was having an issue with arrow_slits in castle_masonry, but looking at the code led me to this sub project. It seemed to me that the section of code for portcullis was not needed (or referenced anywhere else AFAICT) and was causing the issues. I commented it out and the arrow slits stuff started working (see https://github.com/minetest-mods/castle_masonry/issues/5). I'm not confident enough to create a patch/pull request.

Commented out code in castle/castle_gates/gate_slots.lua is as follows

    -- minetest.register_craft({
    -- output = mod_name..":"..material.name.."_portcullis_slot 3",
    -- recipe = {
    --      {material.craft_material,"",material.craft_material},
    --      {material.craft_material,"",material.craft_material},
    --      {material.craft_material,"",material.craft_material},
    --      },
    -- })

    -- minetest.register_craft({
    --      output = mod_name..":"..material.name.."_portcullis_slot",
    --      type = "shapeless",
    --      recipe = {mod_name..":"..material.name.."_portcullis_slot_reverse"},
    -- })
    -- minetest.register_craft({
    --      output = mod_name..":"..material.name.."_portcullis_slot_reverse",
    --      type = "shapeless",
    --      recipe = {mod_name..":"..material.name.."_portcullis_slot"},
    -- })

    -- if burn_time > 0 then
    --      minetest.register_craft({
    --              type = "fuel",
    --              recipe = mod_name..":"..material.name.."_portcullis_slot",
    --              burntime = burn_time * 2,
    --      })
    --      minetest.register_craft({
    --              type = "fuel",
    --              recipe = mod_name..":"..material.name.."_portcullis_slot_reverse",
    --              burntime = burn_time * 2,
    --      })
    -- end

Mesecon integration

Seems like it should be pretty straightforward to set these gates to be triggerable by mesecon signals, investigate that at some point (filing issue to myself to ensure I don't forget).

gate_functions.lua:149: in function 'get_door_layout' leads to core.check_player_privs expects a player or playername as argument.

On two separate occasions, some action related to castle_gates lead to a nullref. Unfortunately I don't know, what exactly the player did or what castle_gates node was involved.

First:

2021-01-20 02:38:02: ERROR[Main]: ServerError: AsyncErr: environment_Step: Runtime error from mod '' in callback environment_Step(): ...tlive1/.minetest/mods/monitoring/metrictypes/counter.lua:42: core.check_player_privs expects a player or playername as argument.
2021-01-20 02:38:02: ERROR[Main]: stack traceback:
2021-01-20 02:38:02: ERROR[Main]: 	[C]: in function 'error'
2021-01-20 02:38:02: ERROR[Main]: 	...mtlive1/5.3.0/Minetest_live/bin/../builtin/game/misc.lua:11: in function 'f'
2021-01-20 02:38:02: ERROR[Main]: 	...tlive1/.minetest/mods/monitoring/metrictypes/counter.lua:42: in function 'check_player_privs'
2021-01-20 02:38:02: ERROR[Main]: 	...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:149: in function 'get_door_layout'
2021-01-20 02:38:02: ERROR[Main]: 	...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:330: in function 'trigger_gate'
2021-01-20 02:38:02: ERROR[Main]: 	...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:395: in function 'func'
2021-01-20 02:38:02: ERROR[Main]: 	...ive1/5.3.0/Minetest_live/bin/../builtin/common/after.lua:20: in function 'globalstep'
2021-01-20 02:38:02: ERROR[Main]: 	...mtlive1/.minetest/mods/monitoring/builtin/globalstep.lua:32: in function <...mtlive1/.minetest/mods/monitoring/builtin/globalstep.lua:24>
2021-01-20 02:38:02: ERROR[Main]: 	...ve1/5.3.0/Minetest_live/bin/../builtin/game/register.lua:429: in function <...ve1/5.3.0/Minetest_live/bin/../builtin/game/register.lua:413>
2021-01-20 02:38:02: ERROR[Main]: stack traceback:

Second:

021-02-06 11:00:25: ERROR[Main]: ServerError: AsyncErr: environment_Step: Runtime error from mod '' in callback environment_Step(): ...tlive1/.minetest/mods/monitoring/metrictypes/counter.lua:42: core.check_player_privs expects a player or playername as argument.
2021-02-06 11:00:25: ERROR[Main]: stack traceback:
2021-02-06 11:00:25: ERROR[Main]: 	[C]: in function 'error'
2021-02-06 11:00:25: ERROR[Main]: 	...mtlive1/5.3.0/Minetest_live/bin/../builtin/game/misc.lua:11: in function 'f'
2021-02-06 11:00:25: ERROR[Main]: 	...tlive1/.minetest/mods/monitoring/metrictypes/counter.lua:42: in function 'check_player_privs'
2021-02-06 11:00:25: ERROR[Main]: 	...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:149: in function 'get_door_layout'
2021-02-06 11:00:25: ERROR[Main]: 	...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:330: in function 'trigger_gate'
2021-02-06 11:00:25: ERROR[Main]: 	...e/mtlive1/.minetest/mods/castle_gates/gate_functions.lua:395: in function 'func'
2021-02-06 11:00:25: ERROR[Main]: 	...ive1/5.3.0/Minetest_live/bin/../builtin/common/after.lua:20: in function 'globalstep'
2021-02-06 11:00:25: ERROR[Main]: 	...mtlive1/.minetest/mods/monitoring/builtin/globalstep.lua:32: in function <...mtlive1/.minetest/mods/monitoring/builtin/globalstep.lua:24>
2021-02-06 11:00:25: ERROR[Main]: 	...ve1/5.3.0/Minetest_live/bin/../builtin/game/register.lua:429: in function <...ve1/5.3.0/Minetest_live/bin/../builtin/game/register.lua:413>
2021-02-06 11:00:25: ERROR[Main]: stack traceback:

For my reference 189

Screenshots

The readme should contain screen shots of the various gates

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.