[Mod] Firearms [0.2.0] [firearms]
Re: [Mod] Firearms [0.2.0] [firearms]
Can a gun be made to switch between different fire modes, e.g. single shot, semi automatic, burst, automatic?
Slightly related: what about modifications installed on a gun like e.g. an assault rifle with underbarrel grenadelauncher/shotgun/flamethrower? (modifications could be just a different fire mode, e.g. cycle semi, full, underbarrel, back to semi)
Slightly related: what about modifications installed on a gun like e.g. an assault rifle with underbarrel grenadelauncher/shotgun/flamethrower? (modifications could be just a different fire mode, e.g. cycle semi, full, underbarrel, back to semi)
- rubenwardy
- Moderator
- Posts: 6978
- Joined: Tue Jun 12, 2012 18:11
- GitHub: rubenwardy
- IRC: rubenwardy
- In-game: rubenwardy
- Location: Bristol, United Kingdom
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
This mod doesn't work. You can shoot someone at point blank range with an M9 pistol, and it doesn't hit or damage them. The M9 does damage, but very inefficiently.
- rubenwardy
- Moderator
- Posts: 6978
- Joined: Tue Jun 12, 2012 18:11
- GitHub: rubenwardy
- IRC: rubenwardy
- In-game: rubenwardy
- Location: Bristol, United Kingdom
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
Code: Select all
2015-11-20 11:48:24: ERROR[Main]: ServerError: Runtime error from mod 'firearmslib' in callback environment_Step(): .../rubenwardy/.minetest/mods/mt-firearms/firearmslib/bullet.lua:20: attempt to compare nil with number
2015-11-20 11:48:24: ERROR[Main]: stack traceback:
2015-11-20 11:48:24: ERROR[Main]: .../rubenwardy/.minetest/mods/mt-firearms/firearmslib/bullet.lua:20: in function 'is_inside'
2015-11-20 11:48:24: ERROR[Main]: .../rubenwardy/.minetest/mods/mt-firearms/firearmslib/bullet.lua:72: in function 'find_collision_point'
2015-11-20 11:48:24: ERROR[Main]: .../rubenwardy/.minetest/mods/mt-firearms/firearmslib/bullet.lua:110: in function 'on_step'
2015-11-20 11:48:24: ERROR[Main]: ....minetest/mods/mt-firearms/firearmslib/pureluaentity.lua:45: in function '__do_step'
2015-11-20 11:48:24: ERROR[Main]: ....minetest/mods/mt-firearms/firearmslib/pureluaentity.lua:197: in function <....minetest/mods/mt-firearms/firearmslib/pureluaentity.lua:194>
2015-11-20 11:48:24: ERROR[Main]: /usr/local/share/minetest/builtin/game/register.lua:355: in function </usr/local/share/minetest/builtin/game/register.lua:335>
- rubenwardy
- Moderator
- Posts: 6978
- Joined: Tue Jun 12, 2012 18:11
- GitHub: rubenwardy
- IRC: rubenwardy
- In-game: rubenwardy
- Location: Bristol, United Kingdom
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
I've done some debugging. Here is the crashing function in firearmslib, with added debug output:
here is the code that calls it (see comment for exact position):
The output is:
Which means that x1, y1, z1, x2, y2, z2 = nil
It's probably time for me to sleep now, but I'll investigate more tomorrow.
Code: Select all
local function is_inside(px, py, pz, x1, y1, z1, x2, y2, z2)
--print(("*** DEBUG: Is inside? p=(%f,%f,%f), minp=(%f,%f,%f), maxp=(%f,%f,%f)"):format(px, py, pz, x1, y1, z1, x2, y2, z2))
if px and py and pz and x1 and y1 and z1 and x2 and y2 and z2 then
return (
(px >= x1) and (px <= x2)
and (py >= y1) and (py <= y2)
and (pz >= z1) and (pz <= z2)
)
else
print("Error: " .. dump({ px=px, py=py, pz=pz, x1=x1, y1=y1, z1=z1, x2=x2, y2=y2, z2=z2 }))
return false
end
end
Code: Select all
local function find_collision_point(objtype, pos, node_or_obj)
-- TODO:
-- This should return the actual point where the bullet
-- "collided" with it's target, or nil if it did not "hit".
if objtype == "node" then
local boxes
local def = minetest.registered_nodes[node_or_obj.name]
if not (def and def.walkable) then return end
if (def.drawtype == "nodebox") and def.node_box and def.node_box.fixed then
boxes = def.node_box.fixed
else
boxes = full_box
end
local px, py, pz =
pos.x - math.floor(pos.x) + 0.5,
pos.y - math.floor(pos.y) + 0.5,
pos.z - math.floor(pos.z) + 0.5
if type(boxes[1]) == "number" then
local x1, y1, z1, x2, y2, z2 = unpack(boxes)
if is_inside(px, py, pz, x1, y1, z1, x2, y2, z2) then
return pos
end
else
for _, box in ipairs(boxes) do
local x1, y1, z1, x2, y2, z2 = unpack(box)
if is_inside(px, py, pz, x1, y1, z1, x2, y2, z2) then
return pos
end
end
end
elseif objtype == "object" then
local objpos = node_or_obj:getpos()
local px, py, pz =
pos.x - objpos.x,
pos.y - objpos.y,
pos.z - objpos.z
local x1, y1, z1, x2, y2, z2
if node_or_obj:is_player() then
x1, y1, z1, x2, y2, z2 = -0.25, -0.5, -0.25, 0.25, 1.25, 0.25
else
local e = node_or_obj:get_luaentity()
if not (e and e.collisionbox) then
return
end
x1, y1, z1, x2, y2, z2 = unpack(e.collisionbox)
end
-- this is where it is called from:
if is_inside(px, py, pz, x1, y1, z1, x2, y2, z2) then
return pos
end
end
end
Code: Select all
Error: {
pz = -1.8512248349521,
px = 0.52047790073571,
py = 1.0474177973035
}
It's probably time for me to sleep now, but I'll investigate more tomorrow.
Re: [Mod] Firearms [0.2.0] [firearms]
First I must say that this mod is awesome. I like all the guns, bullets and the counter. But there is only one thing wrong - this not work with mobs! Any suggestion what to do? I would like to use it with mobs redo...
I know that this is not new mod, many things could change in game engine and other modes since the firearms last update, but maybe it is any chance to use firearms now?
I know that this is not new mod, many things could change in game engine and other modes since the firearms last update, but maybe it is any chance to use firearms now?
- TheReaperKing
- Member
- Posts: 531
- Joined: Sun Nov 22, 2015 21:36
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
I believe what has to happen is that the damage groups have to be set up like fleshy, etc. I'm testing out different stuff and hopefully I can figure it out!
Become A Real Life Superhero - http://SuperheroHill.com
Project Lead of the Doom 3 Mod Last Man Standing - http://Doom3Coop.com
Project Lead of Platinum Arts Sandbox Free 3D Game Maker - http://SandboxGameMaker.com
Youtube Channel - https://www.youtube.com/user/PlatinumArtsKids
Project Lead of the Doom 3 Mod Last Man Standing - http://Doom3Coop.com
Project Lead of Platinum Arts Sandbox Free 3D Game Maker - http://SandboxGameMaker.com
Youtube Channel - https://www.youtube.com/user/PlatinumArtsKids
-
- Member
- Posts: 46
- Joined: Fri Jun 03, 2016 18:21
- GitHub: LapisWolf
- IRC: LapisWolf
- In-game: LapisWolf
Re: [Mod] Firearms [0.2.0] [firearms]
which mobs do they damage other than players?
cdb_yuId0gpEgnYo
- TheReaperKing
- Member
- Posts: 531
- Joined: Sun Nov 22, 2015 21:36
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
They don't damage anything.
Become A Real Life Superhero - http://SuperheroHill.com
Project Lead of the Doom 3 Mod Last Man Standing - http://Doom3Coop.com
Project Lead of Platinum Arts Sandbox Free 3D Game Maker - http://SandboxGameMaker.com
Youtube Channel - https://www.youtube.com/user/PlatinumArtsKids
Project Lead of the Doom 3 Mod Last Man Standing - http://Doom3Coop.com
Project Lead of Platinum Arts Sandbox Free 3D Game Maker - http://SandboxGameMaker.com
Youtube Channel - https://www.youtube.com/user/PlatinumArtsKids
- Desour
- Member
- Posts: 1472
- Joined: Thu Jun 19, 2014 19:49
- GitHub: Desour
- IRC: Desour
- In-game: DS
- Location: I'm scared that if this is too exact, I will be unable to use my keyboard.
Re: [Mod] Firearms [0.2.0] [firearms]
found a bug:
use the night vision on day, instead of deactivating scroll in hotbar, everything seems to be dark
use the night vision on day, instead of deactivating scroll in hotbar, everything seems to be dark
he/him; Codeberg; GitHub; ContentDB; public personal TODO list; "DS" is preferred (but often too short)
- Diamond knight
- Member
- Posts: 475
- Joined: Sun Apr 19, 2015 19:50
- GitHub: Diamondknight
- In-game: Ferrumprinceps
- Location: Chilling in Constantinople
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
suggestion: make a setting for using entities as the line of sight is even more buggy then entities right now but line of sight should still stay in and be fixed
My modding team: https://github.com/basilea-rhomaion
- Christian9
- Member
- Posts: 338
- Joined: Fri Sep 19, 2014 20:29
- In-game: Christian9
- Location: Hell Creek
Re: [Mod] Firearms [0.2.0] [firearms]
Quick Question, may I use the api for a project of mine?
- azekill_DIABLO
- Member
- Posts: 7507
- Joined: Wed Oct 29, 2014 20:05
- GitHub: azekillDIABLO
- In-game: azekill_DIABLO
- Location: OMICRON
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
FAlse they damage mila mobs.TheReaperKing wrote:They don't damage anything.
Gone, but not dead. Contact me on discord: azekill_DIABLO#6565
DMs are always open if you want to get in touch!
DMs are always open if you want to get in touch!
-
- Member
- Posts: 100
- Joined: Wed Nov 29, 2017 17:33
- In-game: IanniPowerup
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
I AM IMPRESED !! This is amazing . Tho it doesn't look exactly like the image . Anyway all this would need is sound
- rubenwardy
- Moderator
- Posts: 6978
- Joined: Tue Jun 12, 2012 18:11
- GitHub: rubenwardy
- IRC: rubenwardy
- In-game: rubenwardy
- Location: Bristol, United Kingdom
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
This mod is quite broken and crashes quite a lot. I suggest trying shooter or ranged weaponsIanniPowerup!!! wrote:I AM IMPRESED !! This is amazing . Tho it doesn't look exactly like the image . Anyway all this would need is sound
- azekill_DIABLO
- Member
- Posts: 7507
- Joined: Wed Oct 29, 2014 20:05
- GitHub: azekillDIABLO
- In-game: azekill_DIABLO
- Location: OMICRON
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
Well, I use it on 4.16 and it has no pb. It even works with CME.rubenwardy wrote: This mod is quite broken and crashes quite a lot.
Well, simple shooter doesn't even work minetest 0.4.16... but the other looks very nice, will try it out!I suggest trying shooter or ranged weapons
Gone, but not dead. Contact me on discord: azekill_DIABLO#6565
DMs are always open if you want to get in touch!
DMs are always open if you want to get in touch!
- rubenwardy
- Moderator
- Posts: 6978
- Joined: Tue Jun 12, 2012 18:11
- GitHub: rubenwardy
- IRC: rubenwardy
- In-game: rubenwardy
- Location: Bristol, United Kingdom
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
Works perfectly fine on CTFazekill_DIABLO wrote:Well, simple shooter doesn't even work minetest 0.4.16... but the other looks very nice, will try it out!
- azekill_DIABLO
- Member
- Posts: 7507
- Joined: Wed Oct 29, 2014 20:05
- GitHub: azekillDIABLO
- In-game: azekill_DIABLO
- Location: OMICRON
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
oh. this mod. okay. last time I tried it crashed. anyway firewarms still works fine!
Gone, but not dead. Contact me on discord: azekill_DIABLO#6565
DMs are always open if you want to get in touch!
DMs are always open if you want to get in touch!
-
- Member
- Posts: 100
- Joined: Wed Nov 29, 2017 17:33
- In-game: IanniPowerup
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
and? Why not all entities ?azekill_DIABLO wrote:FAlse they damage mila mobs.TheReaperKing wrote:They don't damage anything.
- azekill_DIABLO
- Member
- Posts: 7507
- Joined: Wed Oct 29, 2014 20:05
- GitHub: azekillDIABLO
- In-game: azekill_DIABLO
- Location: OMICRON
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
I only had tried with them at the time I said this. Actually they seems to damage everything!
Gone, but not dead. Contact me on discord: azekill_DIABLO#6565
DMs are always open if you want to get in touch!
DMs are always open if you want to get in touch!
Re: [Mod] Firearms [0.2.0] [firearms]
I might have encountered a bug... Or an issue. I'm not really sure if this is caused on my part but-
After enabling the mod through a freshly created world (No others mods), it spews out this error "2017-12-22 22:00:02: ERROR[Main]: generateImage(): Could not load image "firearms_medkit_inv.png" while building texture; Creating a dummy image" and as you might have guessed, the med-kit item doesn't have a texture, I checked the textures folder and it exist, but for some reason it can't render it in-game.
EDIT: Also no sounds and I'm using 0.4.16
After enabling the mod through a freshly created world (No others mods), it spews out this error "2017-12-22 22:00:02: ERROR[Main]: generateImage(): Could not load image "firearms_medkit_inv.png" while building texture; Creating a dummy image" and as you might have guessed, the med-kit item doesn't have a texture, I checked the textures folder and it exist, but for some reason it can't render it in-game.
EDIT: Also no sounds and I'm using 0.4.16
- azekill_DIABLO
- Member
- Posts: 7507
- Joined: Wed Oct 29, 2014 20:05
- GitHub: azekillDIABLO
- In-game: azekill_DIABLO
- Location: OMICRON
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
actually, there's a small typo in the name of the texture. For sounds, i don't know. I have them. (btw: i have no hud for aiming or reticle like I aways had, is this normal?)
Gone, but not dead. Contact me on discord: azekill_DIABLO#6565
DMs are always open if you want to get in touch!
DMs are always open if you want to get in touch!
Re: [Mod] Firearms [0.2.0] [firearms]
nice mod !
but when i shoot the bazooka it makes me crash
and i cant find the sniper
but nice mod !
but when i shoot the bazooka it makes me crash
and i cant find the sniper
but nice mod !
6qJF0AfOu745Hwbz4uWr9TEmyDB0BQ73
Re: [Mod] Firearms [0.2.0] [firearms]
and when any explosions happen it makes me chrash
6qJF0AfOu745Hwbz4uWr9TEmyDB0BQ73
Re: [Mod] Firearms [0.2.0] [firearms]
when i make an explosin grenade/bazooka makes me crash the screen shot :
http://zupimages.net/viewer.php?id=19/40/sy4c.png
and
http://zupimages.net/viewer.php?id=19/40/9yvr.png
http://zupimages.net/viewer.php?id=19/40/sy4c.png
and
http://zupimages.net/viewer.php?id=19/40/9yvr.png
6qJF0AfOu745Hwbz4uWr9TEmyDB0BQ73
- rubenwardy
- Moderator
- Posts: 6978
- Joined: Tue Jun 12, 2012 18:11
- GitHub: rubenwardy
- IRC: rubenwardy
- In-game: rubenwardy
- Location: Bristol, United Kingdom
- Contact:
Re: [Mod] Firearms [0.2.0] [firearms]
This mod is very broken. I suggest using "shooter" by stujones
Who is online
Users browsing this forum: No registered users and 11 guests