Hi, for this mod I made a lua script that makes bullets have realistic trajectories: it will calculate it based on the kinetic energy and the sharpness ot the bullet. It can work in other mods too: to use it simply create a bullet (MOPixel) that is an actor (otherwise lua won't work) and attatch the script "Ballistics.lua" to it, it will do the rest.
I also made an alt-fire script, since it doesn't use any global variables, it shouldn't conflict with any other mod, that also means all weapons with this script are independant from one another(e.g if you have two K98k and with one of them you shoot a grenade, the other won't shoot, same concerning cooldown time, ammo count...etc)
Here are some weapons that use these scripts:
SMGs:MP40: Shoots 9mm parabellum. Damage:2-3, range: medium, fire rate: 600/min full-auto. Alt-fire: HE hand grenade(press num1).
Thompson: Cheap, shoots .45ACP rounds: Damage:3-4, range: short, fire rate: 850/min full-auto. Alt-fire: frag hand grenade(press num1).
Sten: Shoots 9mm parabellum, like the MP40, lighter and cheaper but less reliable: tends to jam whan held by the clip or when 32 rounds are loaded.
MGsBAR: Shoots 7.62x63mm bullets. Damage:6-7, range: long, fire rate: 450/min full auto.
MG42: Shoots 7.92x57mm bullets. Damage:8-10, range: very long, fire rate: 1300/min full-auto, 50 rounds.
Heavy MG42: Shoots 7.92x57mm bullets. Damage:8-10, range: very long, fire rate: 1300/min full-auto, heavier and longer to reload but has 300 rounds.
Rifles:K98k: Karabiner 98 kurz: Shoots 7.92x57mm bullets. Damage:8, range: very long, fire rate: bolt action rifle. Alt-fire: frag rifle grenade(press num1 or z), has 2 grenades.
K98k (Bayonet): The same with a bayonet, also has grenades.
K98k (Grenades): The same with infinite grenades, and a 2nd alt fire: HEAT rifle grenade(press num2 or x).
Scoped K98k: The same with a scope, no grenades.
Gewehr43: Shoots 7.92x57mm bullets. Damage:8, range: very long, fire rate: semi-auto.
Gewehr43 (Scoped): The same with a scope.
PZB39: Shoots Patrone 318 (7.92x118mm) bullets. Damage:30, range: very long, fire rate: slow. Good against light tanks at medium range and heavier tanks at close range. Works also well as a standard rifle. Can penetrate thin bunker walls. Don't shoot while jumping (or flying)!
S-18/100: Shoots 20×105mm rounds. Damage:50, range: very long, fire rate: slow. Good against light tanks at long range and heavier tanks at medium-close range. Works also well as a standard rifle. Can penetrate thin bunker walls. Don't shoot while jumping (or flying)! Alt-fire(num1 or Z): Incendiary round.
STG44: Sturmgewehr 44: Sturmgewehr 44: The first modern assault rifle, shoots 7.92x33mm rounds: Damage:4-5, range: medium-long, fire rate: 500/min full-auto, quite accurate, but expensive.
M1 Garand: Shoots 7.62x63mm bullets. Damage:6, range: long, fire rate: semi-auto. Alt-fire: HE rifle grenade(press num1 or z), has 2 grenades.
M1 Garand (Bayonet): The same with a bayonet, also has grenades.
M1 Garand (Grenades): The same with infinite grenades, and a 2nd alt fire: Thermite rifle grenade(press num2 or x).
Scoped M1 Garand: The same with a scope, no grenades.
Shotgun: Very deadly but very short range.
Pistols:Luger: Shoots 9mm parabellum. Damage:2, range: short, fire rate: semi-auto.
Mauser M712 Schnellfeuer: Shoots 7,62x25mm bullets. Damage:2-3, range: medium, fire rate: 1000/min full auto.
Colt M1911: Shoots .45ACP. Damage:3 range: very short, fire rate: semi auto.
Grenades:Stielhandgranate: High explosive stick grenade, medium range.
Mk 2 grenade: Frag grenade, short range.
Thermite Grenade: Can pierce doors and armours easily, also works well as an incendiary device. A well placed grenade can pierce even the hardest tanks such as metal slug ones.
Mines:S-Mine 35: An anti-infantry shrapnel based bounding mine nicknamed "bouncing betty" by allied soldiers, can be used by a soldier(like a grenade, will automatically burrow) or by a dropship (just drop it). Some won't detonate, but that's to be expected with any kind of mine.
AT-Mine: A highly penetrative shaped charge anti-tank mine, succesfully tested against Metal Slug tanks. Light actors won't detonate it, can be used by a soldier(like a grenade, will automatically burrow) or by a dropship (just drop it). Some won't detonate, but that's to be expected with any kind of mine.
Rocket Launchers:Panzerschreck HE: An 88mm rocket launcher loaded with High Explosive (HE) rockets: Large blast radius but low penetrative effect, good against groups of infantry and light vehicles.
Panzerschreck HEAT: An 88mm rocket launcher loaded with High Explosive Anti Tank (HEAT) shaped charge rockets: Small oriented blast radius but high penetrative effect, good against bunkers and vehicles. Succesfully tested against Metal Slug tanks.
M1 Rocket Launcher "Bazooka" HE: A 60.07mm rocket launcher loaded with High Explosive (HE) rockets: Large blast radius but low penetrative effect, good against groups of infantry and light vehicles.
M1 Rocket Launcher "Bazooka" HEAT: A 60.07mm rocket launcher loaded with High Explosive Anti Tank (HEAT) shaped charge rockets: Small oriented blast radius but high penetrative effect, good against bunkers and vehicles. Succesfully tested against Metal Slug tanks.
Panzerfaust 30: A light disposable HEAT warhead launcher. Max range: 30m.
Panzerfaust 60: A light disposable HEAT warhead launcher. More powerful than the PZF30. Max range: 60m.
Panzerfaust 100: A light disposable HEAT warhead launcher. More powerful than the PZF60. Max range: 100m.
If you want to learn how to make shaped charges like the ones I use for my HEAT weapons, here is a tutorial:
viewtopic.php?f=1&t=19826Others:Mortar: A bit overpowered so if you don't like it, just comment it out, but please try it at least once, aim with an angle >= 45°. Very effective against infantry.
Here are the cooldown times for the alt-fires:HE hand grenade: 4s
Frag hand grenade: 4s
HE rifle grenade: 1s
Frag rifle grenade: 1s
HEAT rifle grenade: 3s
Thermite rifle grenade: 3s
20mm Incendiary round: 4s
During the cooldown time you can't alt-fire and 2nd alt-fire but you can still
standard fire.I would accept any help concerning the sprites.
Please comment. Do not hesitate to make suggestions.Thanks to Lambda ,MaximDude, Zyther96, Thereddragon and Deathbringer for their sprites.Here for the download:V2.25:_WWII massacre activity added
V2.24:
_Compatible with b26
V2.23:
Attachment:
File comment: |
_new panzerschreck sprite(by naxete)
BallisticsV2.23.rar [3.26 MiB]
Downloaded 1122 times
V2.22:
Some minor fixes(guns exploding, being thrown out of your hands, ...etc)
V2.21:
_mac compatibility issue fixed, thanks to dutchsmoker for the fix.
V2.20:
_Bullets won't "spray" anymore.
_Alt fire grenades will now have Vg=Va+Vt instead of Vg=Vt, where Vg=velocity of the grenade when it appears, Va=velocity of the actor trowing(alt firing) the grenade and Vt=Base velocity for trowing a grenade.
That means that now if you alt-fire a grenade while running or flying , it will go further.
_STG44 Alt-Fire added: Timed HE grenade(3s)
_STG44(scoped) Alt-Fire added: Timed HE grenade(3s)
_Mortar added, a bit overpowered so if you don't like it, just comment it out, but please try it at least once, aim with an angle >= 45°.
V2.12:
_New colt sprite(by Darkhunter21, modified by deathbringer)
_Fixed Garand ejecting clip
V2.11:
_Updated descriptions
_Modified Thompson Alt-fire
V2.1:
_Z and X can now be used instead of num1 and num2
_S-18/100 added
_S-18/100 alt-fire added
V2.0:
_Alt fire script added
_K98k Alt fires added
_K98k (Grenades) added
_M1 Alt fires added
_M1 Garand (Grenades) added
_MP40 Alt fire added
_Thompson Alt fire added
_MG42 offsets corrected
_MG42 has less recoil
_Thompson offsets corrected
_PZB impact sound added
_Panzerfausts will gib when dropped:V1.9:_PZB39 added, Gewehr43 added, Gewehr43 (scoped) added, New Panzerschreck sprite (by Deathbringer), New Panzerfaust sprite (by Deathbringer), Louder sounds:V1.81:Less terrain rape:V1.8:Heavy MG42 Added, Panzerfaust 30 added, Panzerfaust 60 added, Panzerfaust 100 added, Mauser M712 Schnellfeuer added, modified Panzerschreck sprite:V1.7:MG42 Added, Bazooka HE added, Bazooka HEAT added:V1.6:Even more reliable AT-Mines, Panzerschreck HE added, Panzerschreck HEAT addedV1.52:New AT-Mines Burrowing technique: they aren't hidden anymore but about 95% of them should work now, just don't drop two on the same spot: