AntumDeluge 2017-06-07 00:19:29 -07:00
parent 523535c32b
commit c7fbe64e30
4 changed files with 6 additions and 17 deletions

View File

@ -38,7 +38,7 @@ The game includes the mods from the default [minetest_game](https://github.com/m
* [enchanting][] ([GPL / WTFPL / CC BY-SA-NA][lic.enchanting]) -- version: [13ea31c Git][ver.enchanting] *2016-12-16*
* equipment/
* [airtanks][] ([MIT][lic.airtanks]) -- version: [5787956 Git][ver.airtanks] *2017-05-13*
* [slingshot][] ([MIT][lic.slingshot] / [CC0][lic.cc0]) -- version: [dffa38f Git][ver.slingshot] *2017-06-01*
* [slingshot][] ([MIT][lic.slingshot] / [CC0][lic.cc0]) -- version: [7af8719 Git][ver.slingshot] *2017-06-07*
* [xtraarmor][] ([CC BY-SA][lic.ccbysa3.0]) -- version: 0.3
* farming/
* [crops][] ([LGPL / CC BY-SA / CC BY / CC0][lic.crops]) -- version: [2b1bb37 Git][ver.crops] *2017-03-31* ([patched][patch.crops])
@ -468,7 +468,7 @@ The game includes the mods from the default [minetest_game](https://github.com/m
[ver.rainbow_ore]: https://github.com/FsxShader2012/rainbow_ore/tree/6e77693
[ver.signs_lib]: https://github.com/minetest-mods/signs_lib/tree/3e00159
[ver.simple_protection]: https://github.com/SmallJoker/simple_protection/tree/23c024f
[ver.slingshot]: https://github.com/AntumDeluge/mtmod-slingshot/tree/dffa38f
[ver.slingshot]: https://github.com/AntumDeluge/mtmod-slingshot/tree/7af8719
[ver.sneeker]: https://github.com/AntumDeluge/mtmod-sneeker/tree/a56b9c2
[ver.snowdrift]: https://github.com/paramat/snowdrift/tree/fcb0537
[ver.spawneggs]: https://github.com/thefamilygrog66/spawneggs/tree/4650370

View File

@ -1,11 +0,0 @@
-- Craft recipes for slingshot mod
minetest.register_craft({
output = 'slingshot:slingshot',
recipe = {
{'default:steel_ingot', '', 'default:steel_ingot'},
{'', 'default:steelblock', ''},
{'', 'default:steel_ingot', ''},
}
})

View File

@ -3,7 +3,7 @@
slingshot.tmp_throw = {}
slingshot.tmp_throw_timer = 0
slingshot.tmp_time = tonumber(minetest.setting_get('item_entity_ttl')) or 890
slingshot.tmp_time = tonumber(minetest.settings:get('item_entity_ttl')) or 890
minetest.register_globalstep(function(dtime)
@ -15,7 +15,7 @@ minetest.register_globalstep(function(dtime)
if t.timer <= 0 or t.ob == nil or t.ob:getpos() == nil then table.remove(slingshot.tmp_throw, i) return end
for ii, ob in pairs(minetest.get_objects_inside_radius(t.ob:getpos(), 1.5)) do
if (not ob:get_luaentity()) or (ob:get_luaentity() and (ob:get_luaentity().name ~= '__builtin:item')) then
if (not ob:is_player()) or (ob:is_player() and ob:get_player_name(ob) ~= t.user and minetest.setting_getbool('enable_pvp') == true) then
if (not ob:is_player()) or (ob:is_player() and ob:get_player_name(ob) ~= t.user and minetest.settings:get_bool('enable_pvp') == true) then
ob:set_hp(ob:get_hp()-5)
ob:punch(ob, {full_punch_interval=1.0, damage_groups={fleshy=4}}, 'default:bronze_pick', nil)
t.ob:setvelocity({x=0, y=0, z=0})

View File

@ -4,12 +4,12 @@ slingshot.modname = minetest.get_current_modname()
slingshot.modpath = minetest.get_modpath(slingshot.modname)
-- Requires rubber band for slingshot craft recipe
slingshot.require_rubber_band = minetest.setting_getbool('slingshot.require_rubber_band')
slingshot.require_rubber_band = minetest.settings:get_bool('slingshot.require_rubber_band')
if slingshot.require_rubber_band == nil then
slingshot.require_rubber_band = true
end
if minetest.setting_getbool('log_mods') then
if minetest.settings:get_bool('log_mods') then
minetest.log('action', '[slingshot] Require rubber band: ' .. tostring(slingshot.require_rubber_band))
end