[MOD] cannons with a lot of features! [2.5] [cannons]
- Achilles
- Member
- Posts: 247
- Joined: Sun Dec 15, 2013 11:55
- In-game: Achilles
- Location: Excuse Me???? -_-
Nice mod, i really like the idea of cannons in Minetest especially as i was planning to build a huge wall around a town to defend it.
Is there any way of making the cannon automatic so that if anyone other than the person who made it gets in range of the cannon they will be killed- A bit like dispensers in Minecraft.
You could also change the mod so that you could add the name of a client/player who you don't want the cannons to fire at.
Just a couple of hints but otherwise i love the mod, thanks
Is there any way of making the cannon automatic so that if anyone other than the person who made it gets in range of the cannon they will be killed- A bit like dispensers in Minecraft.
You could also change the mod so that you could add the name of a client/player who you don't want the cannons to fire at.
Just a couple of hints but otherwise i love the mod, thanks
The Ironic Thing About Common Sense Is That It Isn't Very Common
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
thanksAchilles wrote:Nice mod, i really like the idea of cannons in Minetest especially as i was planning to build a huge wall around a town to defend it.
Is there any way of making the cannon automatic so that if anyone other than the person who made it gets in range of the cannon they will be killed- A bit like dispensers in Minecraft.
You could also change the mod so that you could add the name of a client/player who you don't want the cannons to fire at.
Just a couple of hints but otherwise i love the mod, thanks
i dont know what the dispensers mod is doing, but you can combine this with the mesecons mod:
its possible to build some mesecons wires to the cannon and a player detector wich detects the "enemy" and give a impulse to the cannon(s). than the cannon will shot to the last possition they had shot.
Re: [MOD] cannons with a lot of NEW features! [2.0] [cannons
Great mod. Few questions
How do you break the cannon?
I take it "muni" is ammunition. It took me a little while to figure out that stacks of cannon balls are not able to be used for ammunition - you have to use a single ball.
How do you break the cannon?
I take it "muni" is ammunition. It took me a little while to figure out that stacks of cannon balls are not able to be used for ammunition - you have to use a single ball.
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.0] [cannons
you can break (dig) the cannon only if they is empty (no muni and no gunpowder).
have you ever sean a cannon, that shoots a stack of balls? only a single ball can be shooted all other is unreal. stacks only designed to save space in chests or for decoration.
have you ever sean a cannon, that shoots a stack of balls? only a single ball can be shooted all other is unreal. stacks only designed to save space in chests or for decoration.
Re: [MOD] cannons with a lot of NEW features! [2.0] [cannons
Well there was grapeshot and cannister shot, so yes cannons *can* shoot multiple balls (though I presumed the stack didn't refer to those). However in my defence I've never seen a cannon you could load with 99 balls, so an entirely unknown (perhaps just to me) "semi-automatic cannon" has been modelled - check out the magazine on that baby!!! So from real-world experience it would be reasonable to think that the cannon would be using balls from a stack (though admittedly these would usually be placed next to the cannon for firing or in the hold for storage rather than actually 'attached' to the cannon :-paddi wrote:have you ever sean a cannon, that shoots a stack of balls? only a single ball can be shooted all other is unreal. stacks only designed to save space in chests or for decoration.
PS On that note (just for my curiosity) why did you create your cannon as a kind of turret and in two parts - I've never seen anything similar for a 'full-sized' cannon (as opposed to a more modern turret gun, or one of the smaller portable cannon that were developed), and would have thought the recoil would knock it over if it was built. Not that I particularly mind, it just seems a bit strange to have to dig a hole in the ground or the deck to sink the frame (not a carriage as no wheels) of the cannon into (to maintain a more realistic low centre of gravity), then have to attach the cannon barrel separately.
PPS I guess this ruins my next non-reality suggestion for a fireworks version - I'd really like to be able to trigger my ship to fire all cannons at once (as you've allowed with mesecons), but instead of cannon balls it fires an exploding ball with fireworks (like an average fireworks rocket). [Actually don't worry, someones allready done fireworks, so I'll probably just modify the fireworks mod viewtopic.php?id=3473to to have a display around my ship]
PPPS, where do I find the optional bucket and fire mods, and what are they used for?
LOL
David
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.0] [cannons
ok ur right :) but not all cannonballs can stacked up to 99 the mithrill can only stacked to 9.
maybe that could be an easteregg in the next version.
i dont know, maybe in another game there is missing the bucket or fire so its in dependencies
this is because minetest, does not support multiple textures to a single node, so a "singlenode" cannon would look realy ugly.dgm5555 wrote:Well there was grapeshot and cannister shot, so yes cannons *can* shoot multiple balls (though I presumed the stack didn't refer to those). However in my defence I've never seen a cannon you could load with 99 balls, so an entirely unknown (perhaps just to me) "semi-automatic cannon" has been modelled - check out the magazine on that baby!!! So from real-world experience it would be reasonable to think that the cannon would be using balls from a stack (though admittedly these would usually be placed next to the cannon for firing or in the hold for storage rather than actually 'attached' to the cannon :-p
thats also a reason, that i used the 2 parts cannondgm5555 wrote:PS On that note (just for my curiosity) why did you create your cannon as a kind of turret and in two parts - I've never seen anything similar for a 'full-sized' cannon (as opposed to a more modern turret gun, or one of the smaller portable cannon that were developed), and would have thought the recoil would knock it over if it was built. Not that I particularly mind, it just seems a bit strange to have to dig a hole in the ground or the deck to sink the frame (not a carriage as no wheels) of the cannon into (to maintain a more realistic low centre of gravity), then have to attach the cannon barrel separately.
XD /me likes that ideadgm5555 wrote:PPS I guess this ruins my next non-reality suggestion for a fireworks version - I'd really like to be able to trigger my ship to fire all cannons at once (as you've allowed with mesecons), but instead of cannon balls it fires an exploding ball with fireworks (like an average fireworks rocket). [Actually don't worry, someones allready done fireworks, so I'll probably just modify the fireworks mod viewtopic.php?id=3473to to have a display around my ship]
maybe that could be an easteregg in the next version.
the buket and the fire mod are included in minetest_game. the bucket is need to create salt wich is used for gunpowder, and the fire is need for the burning ballsdgm5555 wrote:PPPS, where do I find the optional bucket and fire mods, and what are they used for?
i dont know, maybe in another game there is missing the bucket or fire so its in dependencies
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
Small Update
NEW FEATURES FOR VERSION 2.1- changed craft reziep for steel ball, because it conflicted with another mod
- the config can made now in world dir (cannons.conf)
also a lot of thanks for over 400 Downloads!
-
- Member
- Posts: 22
- Joined: Mon Jun 02, 2014 20:21
- GitHub: LotekHeavy
- IRC: lotek
- In-game: lotek
- Location: Switzerland
- Contact:
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
does this mod is compatible with the latest minetest (e.g. 0.4.10). In my case everything works, but no damage on players or the environment happens.
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
yes of course. i just tried all out and it works realy fine, does this only happen with a special cannonball?lotek wrote:does this mod is compatible with the latest minetest (e.g. 0.4.10). In my case everything works, but no damage on players or the environment happens.
and it does not work if the other player is too close to the cannon. then the ball will fly through it.
damage to the environment does only take the exploding or the fire cannonball all others only damage players and mobs
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
you accidently named the bronze cannon "bronze_canon" in the items.lua folder.
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
i just want to say thanks for more than 600 downloads!
- Krock
- Developer
- Posts: 4650
- Joined: Thu Oct 03, 2013 07:48
- GitHub: SmallJoker
- Location: Switzerland
- Contact:
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
addi wrote:i just want to say thanks for more than 600 downloads!
No problem, buddy; It's a great mod!
Look, I programmed a bug for you. >> Mod Search Engine << - Mods by Krock - DuckDuckGo mod search bang: !mtmod <keyword here>
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
i was just surprised, i thougt nobody is using it.
- philipbenr
- Member
- Posts: 1897
- Joined: Fri Jun 14, 2013 01:56
- GitHub: philipbenr
- IRC: philipbenr
- In-game: robinspi
- Location: United States
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
It is great, and I think that tit should be used more, if at all possible.
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
I have it installed on my server. I don't have damage enabled. We like to use it for the looks.addi wrote:i was just surprised, i thougt nobody is using it.
In single player I do sometimes play with it to destroy stuff
Thanks for the great mod.
Many of my mods are now a part of Minetest-mods. A place where you know they are maintained!
A list of my mods can be found here
A list of my mods can be found here
- FreeLikeGNU
- Member
- Posts: 280
- Joined: Tue Oct 28, 2014 02:50
- GitHub: FreeLikeGNU
- IRC: freelikegnu
- In-game: FreeLikeGNU
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
please fix your git clone link in your original post to:
git clone https://bitbucket.org/kingarthursteam/cannons.git
thanks!
git clone https://bitbucket.org/kingarthursteam/cannons.git
thanks!
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
thanks for reporting, fixedFreeLikeGNU wrote:please fix your git clone link in your original post to:
git clone https://bitbucket.org/kingarthursteam/cannons.git
thanks!
- Krock
- Developer
- Posts: 4650
- Joined: Thu Oct 03, 2013 07:48
- GitHub: SmallJoker
- Location: Switzerland
- Contact:
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
When shooting with an explosive cannon bullet (normal cannon, on a stone mainstay)
Code: Select all
10:31:00: ERROR[main]: ServerError: E:\Programme\minetest\bin\..\mods\cannons/cannonballs.lua:32: at
tempt to index field 'tiles' (a nil value)
10:31:00: ERROR[main]: stack traceback:
10:31:00: ERROR[main]: E:\Programme\minetest\bin\..\mods\cannons/cannonballs.lua:32: in function 'o
n_node_hit'
10:31:00: ERROR[main]: E:\Programme\minetest\bin\..\mods\cannons/functions.lua:263: in function <E:
\Programme\minetest\bin\..\mods\cannons/functions.lua:243>
Look, I programmed a bug for you. >> Mod Search Engine << - Mods by Krock - DuckDuckGo mod search bang: !mtmod <keyword here>
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
it seems you hit a node wich used tile_images instead of tiles. its fixed now in version 2.1.1Krock wrote:When shooting with an explosive cannon bullet (normal cannon, on a stone mainstay)Code: Select all
10:31:00: ERROR[main]: ServerError: E:\Programme\minetest\bin\..\mods\cannons/cannonballs.lua:32: at tempt to index field 'tiles' (a nil value) 10:31:00: ERROR[main]: stack traceback: 10:31:00: ERROR[main]: E:\Programme\minetest\bin\..\mods\cannons/cannonballs.lua:32: in function 'o n_node_hit' 10:31:00: ERROR[main]: E:\Programme\minetest\bin\..\mods\cannons/functions.lua:263: in function <E: \Programme\minetest\bin\..\mods\cannons/functions.lua:243>
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
I wonder if this mod could become a Scorched Earth mod. It would be nice to be able to enter the compass angle, the vertical angle, and the power into the cannon in order to make this more of an artillery simulator. And an ICBM shot. haha.
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
This would be too modern. Ill not add such a feature to this mod. But if you want you can mod my mod to add that.bobomb wrote:I wonder if this mod could become a Scorched Earth mod. It would be nice to be able to enter the compass angle, the vertical angle, and the power into the cannon in order to make this more of an artillery simulator. And an ICBM shot. haha.
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
I added in a few bits of code to make the ball stacks slightly more than decorative.
add to each register_node for the stacks
I also thought about modifying the node boxes so that, if you take a ball from the stack, the visual will remove the ball too.
- - r-click ball stack with empty hand to get one ball of same material
- r-click with a ball of the same material to add it back to the stack
- stack max balls = 4
- take four balls and the stack is removed from the world
Code: Select all
function cannons.on_construct_ball_stack(pos)
local node = minetest.get_node_or_nil(pos)
local material = string.split(node.name, "_")[2]
local meta = minetest.get_meta(pos)
meta:set_int("usecount", 0)
meta:set_string("material", material)
end
function cannons.on_rightclick_ball_stack(pos, node, player, itemstack)
if not player or not player:is_player() then
return
end
local meta = minetest.get_meta(pos)
local count = meta:get_int("usecount")
local material = meta:get_string("material")
if itemstack:is_empty() then
player:set_wielded_item(itemstack:add_item("cannons:ball_"..material))
count = count + 1
else
if (itemstack:get_name() == "cannons:ball_"..material) and (count > 0) then
count = count - 1
itemstack:take_item(1)
end
end
if count == 4 then
minetest.remove_node(pos)
else
meta:set_int("usecount", count)
end
end
Code: Select all
on_construct = function(pos)
cannons.on_construct_ball_stack(pos)
end,
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
cannons.on_rightclick_ball_stack(pos, node, player, itemstack)
end
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Re: [MOD] cannons with a lot of NEW features! [2.1] [cannons
great idea :)
Ill apply it to the mod, if you agree.
btw: this code can be shortened and optimized:
change to this:
;-)
Ill apply it to the mod, if you agree.
btw: this code can be shortened and optimized:
Code: Select all
on_construct = function(pos)
cannons.on_construct_ball_stack(pos)
end,
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
cannons.on_rightclick_ball_stack(pos, node, player, itemstack)
end
Code: Select all
on_construct = cannons.on_construct_ball_stack,
on_rightclick = cannons.on_rightclick_ball_stack
- addi
- Member
- Posts: 666
- Joined: Thu Sep 20, 2012 03:16
- GitHub: adrido
- Location: Black-Forest, Germany
Update to version 2.5:
Update to version 2.5:
New Features:
Version 2.5 [13.06.2015]
other downloads
New Features:
- Cannonball stack is not longer decoration only.
place a cannonball on another (right click) will create a stack of it.
left click a stack to get a cannonball. - Supports TNT now!
If the TNT mod is enabled (mostly on singleplayer) you can use tnt gunpowder as gunpowder, and you can shoot tnt blocks now!
Warning: Dont shoot too fast or your cannon will explode ;-P - Nice voxellike meshnodes now.
get rid of this ugly 2-part cannonstands. Old cannonstands will be converted. - Uses "default" formspec style now to fit into Mintest Game.
- fixed infinite stacks
- fixed cannonstand craftreziep
- converted sound files from stereo to mono to make OpenAl happy
Version 2.5 [13.06.2015]
other downloads
Last edited by addi on Mon Jun 29, 2015 06:45, edited 1 time in total.
Who is online
Users browsing this forum: No registered users and 38 guests