Page 4 of 9

Posted: Mon Feb 18, 2013 23:36
by deivan
Well, I launched 20 rockets and the game is slowing down... More and more, I stop him before crash. I have messages about error loading textures and a debug file with 7MB. Very bad. Is easy to reproduce this problem. Start a new game give to yourself the rocket launcher and rockets, chose a target and make 20 shots in the same area. You see the same problem, I think.

Posted: Mon Feb 18, 2013 23:43
by deivan
The debug is full of this type of lines...
20:46:49: VERBOSE[ServerThread]: scriptapi_luaentity_activate: id=2101
20:46:49: VERBOSE[ServerThread]: virtual std::string LuaEntitySAO::getStaticData()
20:46:50: VERBOSE[ServerThread]: ServerEnvironment::addActiveObjectRaw(): Added id=2102; there are now 2102 active objects.
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_add: id=2102 name="firearms:explosion_smoke"
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_activate: id=2102
20:46:50: VERBOSE[ServerThread]: virtual std::string LuaEntitySAO::getStaticData()
20:46:50: VERBOSE[ServerThread]: ServerEnvironment::addActiveObjectRaw(): Added id=2103; there are now 2103 active objects.
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_add: id=2103 name="firearms:explosion_smoke"
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_activate: id=2103
20:46:50: VERBOSE[ServerThread]: virtual std::string LuaEntitySAO::getStaticData()
20:46:50: VERBOSE[ServerThread]: ServerEnvironment::addActiveObjectRaw(): Added id=2104; there are now 2104 active objects.
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_add: id=2104 name="firearms:explosion_smoke"
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_activate: id=2104
20:46:50: VERBOSE[ServerThread]: virtual std::string LuaEntitySAO::getStaticData()
20:46:50: VERBOSE[ServerThread]: ServerEnvironment::addActiveObjectRaw(): Added id=2105; there are now 2105 active objects.
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_add: id=2105 name="firearms:explosion_smoke"
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_activate: id=2105
20:46:50: VERBOSE[ServerThread]: virtual std::string LuaEntitySAO::getStaticData()
20:46:50: INFO: sigint_handler(): Ctrl-C pressed, shutting down.
20:46:50: VERBOSE[ServerThread]: ServerEnvironment::addActiveObjectRaw(): Added id=2106; there are now 2106 active objects.
20:46:50: VERBOSE[ServerThread]: scriptapi_luaentity_add: id=2106 name="firearms:explosion_smoke"

Posted: Mon Feb 18, 2013 23:52
by Topywo
I think it's because the explosion_smoke is an entity. I guess at a certain point they will be deleted or slow down your system, because it's trying to keep record of all the data about the entities (smoke) and probably busy creating and removing them. As far as I know the only thing that helps is not shooting that much.

Posted: Tue Feb 19, 2013 01:11
by deivan
I love if the rocket convert items in small versions, like many rocks, in the actual method all is vanished. :-o

Posted: Mon Feb 25, 2013 20:22
by kaeza
deivan wrote:I love if the rocket convert items in small versions, like many rocks, in the actual method all is vanished. :-o
The "explosion" code is based off PilzAdam's TNT mod. I removed that feature due to the (sheer ^ 2) amount of objects which would be generated by people shooting a sheer amount of rockets.

This mod was initially intended for "disposable", quick match worlds; you create a world, a few players join for a match, someone gets bored from being a 1337 fragger, the other users get bored of being fragged, the server shuts down, the world is deleted, and the cycle is repeated.

BTW, DO NOT SHOOT *ANY* WEAPON REPEATEDLY! Due to bugs(?) in the entity handling in the engine, the game may crash, lag or do other weird things when there are tons of entities.

Posted: Sat Mar 02, 2013 04:23
by xavier108
Im gonna use this for my crossfire map in half life for minetest

Posted: Sat Mar 02, 2013 22:11
by Likwid H-Craft
Hey, Kaeza I made a minigun :) now all it needs is auto fire when hold down, mouse 1!

And I am working on, more you see soon. oh and I added it ammo to for it, and you are free to use it long as you get it working like a minigun ;)

Posted: Sun Mar 03, 2013 00:06
by Likwid H-Craft
Done with the minigun.

Right now working now it own sound and, add more weapons :) hey can you, maybe I don't know...Add mine as a version? yours is the official one and mine the unofficial one!

Posted: Sun Mar 03, 2013 04:55
by kaeza
How am I supposed to test it if you don't provide a link? ;)

Posted: Mon Mar 04, 2013 18:24
by kaeza
*BUMP*
Merged HybridDog's textures. Thank you for the nice textures :)

Posted: Fri Mar 22, 2013 19:37
by mcwillis08
whoa kaeza this mod is awesome!

Posted: Sat Mar 23, 2013 02:09
by kaeza
mcwillis08 wrote:whoa kaeza this mod is awesome!
Thanks! Happy fragging :)

Posted: Thu Apr 04, 2013 13:31
by Mihobre
Likwid H-Craft wrote:I will if I know how make one -_-
I know how you feel...(nods eyebrows understandingly)

Posted: Thu Apr 04, 2013 20:44
by jmil6137
it wont it work on the 4.6 version why

Posted: Thu Apr 04, 2013 20:47
by kaeza
jmil6137 wrote:it wont it work on the 4.6 version
Care to explain why?
Follow the instructions on this topic, but instead of creating a new topic post the error here.
BTW: Did you rename the folder to just "firearms" ?

Posted: Thu Apr 04, 2013 20:52
by jmil6137
um no ill go do that now thanks

Posted: Fri Apr 26, 2013 02:25
by kaeza
Herp Derp Hurr Durr!
Big Update!

- Now adds a (minimalist) HUD showing ammo in clip and in inventory.
- Support for different crosshairs for every weapon.
- Bullets now travel at the speed of light! No more ugly entities!

More to come soon :)

Edit: Requires the latest engine from git.

Posted: Fri Apr 26, 2013 07:56
by xavier108
I seem to have a problem.A error like this shows
15:47:30: ERROR[main]: ServerError: LuaError: error: ...-0.4.6\bin\..\mods\minetest\firearms/firearmslib.lua:392: attempt to call method 'hud_set_flags' (a nil value)
Can you help me
I'm currently using minetest 0.4.6
Mods that I also installed
Butter_creeper mod
forcefield mod
fireworks mod
clock mod

Posted: Fri Apr 26, 2013 22:01
by kaeza
xavier108 wrote:I seem to have a problem.A error like this shows
15:47:30: ERROR[main]: ServerError: LuaError: error: ...-0.4.6\bin\..\mods\minetest\firearms/firearmslib.lua:392: attempt to call method 'hud_set_flags' (a nil value)
Can you help me
I'm currently using minetest 0.4.6
Mods that I also installed
Butter_creeper mod
forcefield mod
fireworks mod
clock mod
You need a newer version of MT. The stuff that is needed was added yesterday.

Posted: Sat Apr 27, 2013 01:16
by aldobr
Now we need a zombies mod...

Left 4 Minetest

Posted: Sat Apr 27, 2013 06:37
by kaeza
Small update!
- Added reloading and "empty" sounds.

Posted: Sat Apr 27, 2013 15:07
by Bas080
No entities, very nice! Except for rockets and grenades(which i agree should be visible). But that way you can play without lagy entities. BIG THUMBS UP.

Now we need FPS modes items that spawn ammo and weapons. Or you could craft while bullets are flying over your head. :P

Can't wait to have a PVP with snipers.

Posted: Sat Apr 27, 2013 15:17
by kaeza
Bas080 wrote:No entities, very nice! Except for rockets and grenades(which i agree should be visible). But that way you can play without lagy entities. BIG THUMBS UP.

Now we need FPS gamemode items that spawn ammo and weapons. Or you could craft while bullets are flying over you head. :P

Can't wait to have a PVP with snipers.
Hmm... I think I will split the mod into a modpack.
One mod will provide the base library (firearmslib.lua, explosion.lua, kutils.lua), another one will provide guns (pistol, shotgun, rifle, etc), another one for destructive weapons (launchers, so they can be easily removed if desired), and another one for item spawners.

Posted: Sat Apr 27, 2013 16:36
by kaeza
Hybrid Dog wrote:How can I load a weapon?
Shift+Click (or whatever key you assigned to 'Sneak'+Click)

Posted: Sat Apr 27, 2013 16:42
by kaeza
Hybrid Dog wrote:Zeg9 edited the tnt mod so that it supports protects.
Ah thanks for the info! I will look into that later.