Upload files to 'mods/rangedweapons'

This commit is contained in:
thunderdog1138 2021-05-26 15:18:58 +00:00
parent 888f36e974
commit 52889661c7
5 changed files with 318 additions and 0 deletions

View File

@ -0,0 +1,64 @@
minetest.register_tool("rangedweapons:remington_rld", {
stack_max= 1,
range = 0,
wield_scale = {x=1.9,y=1.9,z=1.1},
description = "",
loaded_gun = "rangedweapons:remington",
loaded_sound = "rangedweapons_shotgun_reload_b",
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_remington_rld.png",
})
minetest.register_tool("rangedweapons:remington", {
description = "" ..core.colorize("#35cdff","Remington 870\n") ..core.colorize("#FFFFFF", "Ranged damage: 1\n") ..core.colorize("#FFFFFF", "projectiles: 4\n") ..core.colorize("#FFFFFF", "Gun gravity: 5\n") ..core.colorize("#FFFFFF", "Accuracy: 40%\n")..core.colorize("#FFFFFF", "knockback: 5\n") ..core.colorize("#FFFFFF", "Critical chance: 4%\n") ..core.colorize("#FFFFFF", "Critical efficiency: 2.0x\n") ..core.colorize("#FFFFFF", "Ammunition: 12 gauge shells\n") ..core.colorize("#FFFFFF", "Pump delay: 0.8\n")..core.colorize("#FFFFFF", "Clip size: 4\n") ..core.colorize("#27a600", "Gun is ready to fire!\n") ..core.colorize("#fff21c", "Right-click to load in a bullet!\n") ..core.colorize("#FFFFFF", "Gun type: shotgun\n") ..core.colorize("#FFFFFF", "Bullet velocity: 18"),
range = 0,
wield_scale = {x=1.9,y=1.9,z=1.1},
inventory_image = "rangedweapons_remington.png",
RW_gun_capabilities = {
gun_damage = {fleshy=1,knockback=5},
gun_crit = 4,
gun_critEffc = 2.0,
suitable_ammo = {{"rangedweapons:shell",4}},
gun_skill = {"shotgun_skill",20},
gun_icon = "rangedweapons_remington_icon.png",
gun_unloaded = "rangedweapons:remington_rld",
gun_cooling = "rangedweapons:remington_uld",
gun_velocity = 18,
gun_accuracy = 40,
gun_cooldown = 0.8,
gun_gravity = 5,
gun_reload = 0.25,
gun_projectiles = 4,
has_shell = 0,
gun_durability = 275,
gun_smokeSize = 14,
gun_door_breaking = 1,
gun_sound = "rangedweapons_shotgun_shot",
gun_unload_sound = "rangedweapons_shell_insert",
},
on_secondary_use = function(itemstack, user, pointed_thing)
rangedweapons_single_load_gun(itemstack, user, "")
return itemstack
end,
on_use = function(itemstack, user, pointed_thing)
rangedweapons_shoot_gun(itemstack, user)
return itemstack
end,
})
minetest.register_tool("rangedweapons:remington_uld", {
stack_max= 1,
wield_scale = {x=1.9,y=1.9,z=1.1},
range = 0,
description = "" ..core.colorize("#35cdff","Remington 870\n") ..core.colorize("#FFFFFF", "Ranged damage: 1\n") ..core.colorize("#FFFFFF", "projectiles: 4\n") ..core.colorize("#FFFFFF", "Gun gravity: 5\n") ..core.colorize("#FFFFFF", "Accuracy: 40%\n")..core.colorize("#FFFFFF", "knockback: 5\n") ..core.colorize("#FFFFFF", "Critical chance: 4%\n") ..core.colorize("#FFFFFF", "Critical efficiency: 2.0x\n") ..core.colorize("#FFFFFF", "Ammunition: 12 gauge shells\n") ..core.colorize("#FFFFFF", "Pump delay: 0.8\n")..core.colorize("#FFFFFF", "Clip size: 4\n") ..core.colorize("#be0d00", "Right-click, to eject the empty shell!\n") ..core.colorize("#fff21c", "Right-click to load in a bullet!\n") ..core.colorize("#FFFFFF", "Gun type: shotgun\n") ..core.colorize("#FFFFFF", "Bullet velocity: 20"),
inventory_image = "rangedweapons_remington.png",
groups = {not_in_creative_inventory = 1},
on_use = function(user)
minetest.sound_play("rangedweapons_empty", {user})
end,
on_secondary_use = function(itemstack, user, pointed_thing)
eject_shell(itemstack,user,"rangedweapons:remington_rld",0.8,"rangedweapons_shotgun_reload_a","rangedweapons:empty_shell")
return itemstack
end,
})

View File

@ -0,0 +1,74 @@
minetest.register_tool("rangedweapons:rpg_rld", {
description = "" ..core.colorize("#35cdff","rpg7\n") ..core.colorize("#FFFFFF", "Direct contact damage: 20\n")..core.colorize("#FFFFFF", "Accuracy: 100%\n") ..core.colorize("#FFFFFF", "direct contact knockback: 35\n") ..core.colorize("#FFFFFF", "Gun crit chance: 10%\n")..core.colorize("#FFFFFF", "Critical efficiency: 3x\n") ..core.colorize("#FFFFFF", "Reload delay: 1.0\n")..core.colorize("#FFFFFF", "Clip size: 1\n") ..core.colorize("#FFFFFF", "Gun gravity: 5\n")..core.colorize("#FFFFFF", "Ammunition: rockets\n")..core.colorize("#FFFFFF", "Gun type: rocket launcher\n") ..core.colorize("#FFFFFF", "Bullet velocity: 25"),
range = 0,
wield_scale = {x=2.5,y=2.5,z=3.75},
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_rpg_rld.png",
RW_gun_capabilities = {
gun_damage = {fleshy=20,knockback=35},
gun_crit = 10,
gun_critEffc = 3.0,
suitable_ammo = {{"rangedweapons:rocket",1}},
gun_skill = {"",1},
gun_icon = "rangedweapons_rpg_icon.png",
gun_unloaded = "rangedweapons:rpg_rld",
gun_cooling = "rangedweapons:rpg",
gun_velocity = 25,
gun_accuracy = 100,
gun_cooldown = 1.0,
gun_reload = 1.0,
gun_projectiles = 1,
gun_smokeSize = 15,
gun_durability = 150,
gun_unload_sound = "",
gun_sound = "rangedweapons_rocket",
},
on_secondary_use = function(itemstack, user, pointed_thing)
rangedweapons_reload_gun(itemstack, user)
return itemstack
end,
on_use = function(itemstack, user, pointed_thing)
rangedweapons_shoot_gun(itemstack, user)
return itemstack
end,
})
minetest.register_tool("rangedweapons:rpg", {
description = "" ..core.colorize("#35cdff","rpg7\n") ..core.colorize("#FFFFFF", "Direct contact damage: 20\n")..core.colorize("#FFFFFF", "Accuracy: 100%\n") ..core.colorize("#FFFFFF", "direct contact knockback: 35\n") ..core.colorize("#FFFFFF", "Gun crit chance: 10%\n")..core.colorize("#FFFFFF", "Critical efficiency: 3x\n") ..core.colorize("#FFFFFF", "Reload delay: 1.0\n")..core.colorize("#FFFFFF", "Clip size: 1\n") ..core.colorize("#FFFFFF", "Gun gravity: 5\n")..core.colorize("#FFFFFF", "Ammunition: rockets\n")..core.colorize("#FFFFFF", "Gun type: rocket launcher\n") ..core.colorize("#FFFFFF", "Bullet velocity: 25"),
range = 0,
wield_scale = {x=2.5,y=2.5,z=3.75},
inventory_image = "rangedweapons_rpg.png",
RW_gun_capabilities = {
gun_damage = {fleshy=20,knockback=35},
gun_crit = 10,
gun_critEffc = 3.0,
suitable_ammo = {{"rangedweapons:rocket",1}},
gun_skill = {"",1},
gun_icon = "rangedweapons_rpg_icon.png",
gun_unloaded = "rangedweapons:rpg_rld",
gun_cooling = "rangedweapons:rpg",
gun_velocity = 25,
gun_accuracy = 100,
gun_cooldown = 1.0,
gun_reload = 1.0,
gun_projectiles = 1,
gun_smokeSize = 15,
gun_durability = 150,
gun_unload_sound = "",
gun_sound = "rangedweapons_rocket",
gun_unload_sound = "rangedweapons_shell_insert",
},
on_secondary_use = function(itemstack, user, pointed_thing)
rangedweapons_reload_gun(itemstack, user)
return itemstack
end,
on_use = function(itemstack, user, pointed_thing)
rangedweapons_shoot_gun(itemstack, user)
return itemstack
end,
})

View File

@ -0,0 +1,76 @@
minetest.register_tool("rangedweapons:rpk_r", {
stack_max= 1,
wield_scale = {x=1.75,y=1.75,z=1.3},
description = "",
rw_next_reload = "rangedweapons:rpk_rr",
load_sound = "rangedweapons_rifle_clip_in",
range = 0,
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_rpk_rld.png",
})
minetest.register_tool("rangedweapons:rpk_rr", {
stack_max= 1,
wield_scale = {x=1.75,y=1.75,z=1.3},
description = "",
rw_next_reload = "rangedweapons:rpk_rrr",
load_sound = "rangedweapons_rifle_reload_a",
range = 0,
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_rpk.png",
})
minetest.register_tool("rangedweapons:rpk_rrr", {
stack_max= 1,
wield_scale = {x=1.75,y=1.75,z=1.3},
description = "",
rw_next_reload = "rangedweapons:rpk",
load_sound = "rangedweapons_rifle_reload_b",
range = 0,
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_rpk.png",
})
minetest.register_tool("rangedweapons:rpk", {
stack_max= 1,
wield_scale = {x=1.75,y=1.75,z=1.3},
description = "" ..core.colorize("#35cdff","rpk\n") ..core.colorize("#FFFFFF", "Gun damage: 7\n") ..core.colorize("#FFFFFF", "accuracy: 60%\n") ..core.colorize("#FFFFFF", "Gun knockback: 6\n") ..core.colorize("#FFFFFF", "Gun Critical chance: 12%\n")..core.colorize("#FFFFFF", "Critical efficiency: 3.0x\n") ..core.colorize("#FFFFFF", "Reload delay: 2.0\n") ..core.colorize("#FFFFFF", "Clip size: 75\n") ..core.colorize("#FFFFFF", "Ammunition: 7.62mm rounds\n") ..core.colorize("#FFFFFF", "Rate of fire: 0.10(full-auto)\n") ..core.colorize("#FFFFFF", "Gun type: heavy machinegun\n") ..core.colorize("#FFFFFF", "Block penetration: 10%\n")
..core.colorize("#FFFFFF", "Enemy penetration: 25%\n") ..core.colorize("#FFFFFF", "Bullet velocity: 55"),
range = 0,
inventory_image = "rangedweapons_rpk.png",
RW_gun_capabilities = {
automatic_gun = 1,
gun_damage = {fleshy=7,knockback=6},
gun_crit = 12,
gun_critEffc = 3.0,
suitable_ammo = {{"rangedweapons:762mm",75}},
gun_skill = {"heavy_skill",55},
gun_magazine = "rangedweapons:drum_mag",
gun_icon = "rangedweapons_rpk_icon.png",
gun_unloaded = "rangedweapons:rpk_r",
gun_velocity = 55,
gun_accuracy = 70,
gun_cooldown = 0.1,
gun_reload = 2.0/4,
gun_projectiles = 1,
has_shell = 1,
gun_gravity = 0,
gun_durability = 2250,
gun_smokeSize = 5,
gun_mob_penetration = 25,
gun_node_penetration = 10,
gun_unload_sound = "rangedweapons_rifle_clip_out",
gun_sound = "rangedweapons_ak",
},
on_secondary_use = function(itemstack, user, pointed_thing)
rangedweapons_reload_gun(itemstack, user)
return itemstack
end,
inventory_image = "rangedweapons_rpk.png",
})

View File

@ -0,0 +1,75 @@
minetest.register_tool("rangedweapons:scar_r", {
stack_max= 1,
wield_scale = {x=1.7,y=1.7,z=1.25},
description = "",
rw_next_reload = "rangedweapons:scar_rr",
load_sound = "rangedweapons_rifle_clip_in",
range = 0,
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_scar_rld.png",
})
minetest.register_tool("rangedweapons:scar_rr", {
stack_max= 1,
wield_scale = {x=1.7,y=1.7,z=1.25},
description = "",
rw_next_reload = "rangedweapons:scar_rrr",
load_sound = "rangedweapons_rifle_reload_a",
range = 0,
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_scar.png",
})
minetest.register_tool("rangedweapons:scar_rrr", {
stack_max= 1,
wield_scale = {x=1.7,y=1.7,z=1.25},
description = "",
rw_next_reload = "rangedweapons:scar",
load_sound = "rangedweapons_rifle_reload_b",
range = 0,
groups = {not_in_creative_inventory = 1},
inventory_image = "rangedweapons_scar.png",
})
minetest.register_tool("rangedweapons:scar", {
stack_max= 1,
wield_scale = {x=1.7,y=1.7,z=1.25},
description = "" ..core.colorize("#35cdff","FN SCAR 16\n") ..core.colorize("#FFFFFF", "Ranged damage: 9\n") ..core.colorize("#FFFFFF", "Accuracy: 85%\n") ..core.colorize("#FFFFFF", "Gun knockback: 6\n")..core.colorize("#FFFFFF", "Critical chance: 11%\n") ..core.colorize("#FFFFFF", "Critical efficiency: 2.75x\n") ..core.colorize("#FFFFFF", "Ammunition: 7.62mm rounds/5.56mm rounds\n") ..core.colorize("#FFFFFF", "Reload delay: 1.2\n") ..core.colorize("#FFFFFF", "Clip size: 20/30\n") ..core.colorize("#FFFFFF", "Rate of fire: 0.15\n") ..core.colorize("#FFFFFF", "Block penetration: 7%\n")
..core.colorize("#FFFFFF", "penetration: 20%\n") ..core.colorize("#FFFFFF", "Gun type: Assault rifle\n") ..core.colorize("#FFFFFF", "Bullet velocity: 45"),
range = 0,
inventory_image = "rangedweapons_scar.png",
RW_gun_capabilities = {
automatic_gun = 1,
gun_damage = {fleshy=9,knockback=6},
gun_crit = 11,
gun_critEffc = 2.75,
suitable_ammo = {{"rangedweapons:762mm",20},{"rangedweapons:556mm",30}},
gun_skill = {"arifle_skill",50},
gun_magazine = "rangedweapons:assaultrifle_mag",
gun_icon = "rangedweapons_scar_icon.png",
gun_unloaded = "rangedweapons:scar_r",
gun_velocity = 45,
gun_accuracy = 85,
gun_cooldown = 0.15,
gun_reload = 1.2/4,
gun_projectiles = 1,
has_shell = 1,
gun_gravity = 0,
gun_durability = 1600,
gun_smokeSize = 5,
gun_mob_penetration = 20,
gun_node_penetration = 7,
gun_unload_sound = "rangedweapons_rifle_clip_out",
gun_sound = "rangedweapons_ak",
},
on_secondary_use = function(itemstack, user, pointed_thing)
rangedweapons_reload_gun(itemstack, user)
return itemstack
end,
inventory_image = "rangedweapons_scar.png",
})

View File

@ -0,0 +1,29 @@
rweapons_player_dmg_multiplier = 1.0
rweapons_mob_dmg_multiplier = 1.0
rweapons_headshot_dmg_multiplier = 1.75
rweapons_max_gun_efficiency = 300
rweapons_min_gun_efficiency = 40
rweapons_bloodyness = 10
rweapons_gun_crafting = "true"
rweapons_gun_durability = "true"
rweapons_shurikens = "true"
rweapons_handguns = "true"
rweapons_forceguns = "true"
rweapons_javelins = "true"
rweapons_power_weapons = "true"
rweapons_machine_pistols = "true"
rweapons_shotguns = "true"
rweapons_auto_shotguns = "true"
rweapons_smgs = "true"
rweapons_rifles = "true"
rweapons_assault_rifles = "true"
rweapons_heavy_machineguns = "true"
rweapons_revolvers = "true"
rweapons_explosives = "true"
rweapons_glass_breaking = "true"
rweapons_door_breaking = "true"
rweapons_other_weapon_crafting = "true"
rweapons_ammo_crafting = "true"
rweapons_item_crafting = "true"