Automatic pistols, finally! -1 reply

Please wait...

Guest

I didn't make it!

0 XP

 
#1 11 years ago

Probably more of you have already figured out how to make automatic pistols, but since I haven't seen any threads aboutit I decided to start one. Basially, I wanted to give my trusty ol' beretta the burst fire capability of th military version so i started messing around with the rate of fire and adding different firing modes to the weapon configuration files which did nothing at all! so i started comparing the files of pistols and automatic weapons and right at the beginning of the weapon files you'll find lines like this: class = WP_AK74 or class = WP_GROZA or class = WP_LR300 or class = WP_PM or class = WP_HPSA and additionally all automatic weapons have an extra line after the fire dispersion base which pistols don't have; control inertion factor. so for example for the mp5 you'll find something like this: fire_dispersion_base = 0.25;0.33 control_inertion_factor = 1.07f i realized that these were really the only things that differenciated pistols from automatic weapons so i started messing around with the beretta.:D [wpn_beretta]:identity_immunities GroupControlSection = spawn_group discovery_dependency = $spawn = "weapons\beretta" ; option for Level Editor $npc = on ; option for Level Editor $prefetch = 8 scheduled = off ; option for ALife Simulator cform = skeleton [COLOR=red]class = WP_LR300[/COLOR] min_radius = 0 max_radius = 50 description = enc_weapons1_wpn-beretta ef_weapon_type = 5 ;----------------------------------------------------------------------------------- cost = 900 ;300 ammo_limit = 120 ammo_current = 96 ammo_elapsed = 16 [COLOR=red]ammo_mag_size = 30[/COLOR] ammo_class = ammo_9x19_fmj, ammo_9x19_pbp [COLOR=red]fire_modes = 1, 3[/COLOR] hand_dependence = 1 single_handed = 1 slot = 1 animation_slot = 1 ; type of the animation that will be used

;----------------------------------------------------------------------------------- fire_dispersion_base = 0.26 [COLOR=red]control_inertion_factor = 1.01f[/COLOR] cam_relax_speed = 8;1.3 cam_dispersion = 0.65 cam_dispersion_inc = 0.0 cam_dispertion_frac = 1.0 cam_max_angle = 20.0 cam_max_angle_horz = 10.0 cam_step_angle_horz = 0.9 fire_dispersion_condition_factor = 5 misfire_probability = 0.005 condition_shot_dec = 0.00130 ;----------------------------------------------------------------------------------- ; ttc hit_power = 0.52 hit_impulse = 125 hit_type = fire_wound PDM_disp_base = 1.0 PDM_disp_vel_factor = 0.8 PDM_disp_accel_factor = 0.8 PDM_crouch = 1.0 PDM_crouch_no_acc = 1.0 use_aim_bullet = true time_to_aim = 1.0 fire_distance = 1000 bullet_speed = 360 [COLOR=red]rpm = 350 rpm_empty_click = 350[/COLOR] ; end ttc [COLOR=black]and thats it just by changing the class of the weapon to that of an automatic one, adding different fire modes and the control inertion factor u have an automatic pistol!! you can have any sort of fire mode that you want, -1 being full auto., and maybe instead of having a 3 shot burst mode u can have a 5 or 10 shot burst mode, though being realistic it won't be very efficient. neither will the auto. fire :( unless you started messing around with all the accuracy parameters. [/COLOR] enjoy!:D:D btw how can i render the 3d models of the weapons, items and so on?




jzuidema

I'd rather just drink beer

50 XP

3rd May 2007

0 Uploads

13 Posts

0 Threads

#2 11 years ago

very nice I must say. It was allready speculated that it was all due to the weaponclass in the xml files, but youre the first one I see putting it clear on paper :) thanks for this, ill be having fun with my pistols and shotties now!




jzuidema

I'd rather just drink beer

50 XP

3rd May 2007

0 Uploads

13 Posts

0 Threads

#3 11 years ago

and another question: how do you change tthese things for assault rifles and snipers, cause they have 2 strings with classes? for example, the vintorez rifle has 2 lines:

class = WP_VINT and weapon_class = sniper_rifle anyone a solution for that?




niphty

GF makes me horny

50 XP

28th March 2007

0 Uploads

102 Posts

0 Threads

#4 11 years ago

That's confused me for a long time, as well, jzuidema. As far as I've been able to tell, only CLASS really does anything. weapon_class may be an older, unused property, or it might still tie in to some things.. like how the AI uses the weapon, something we can't really check easily ;)




RogueNavySEAL

Innocence proves nothing.

50 XP

29th April 2007

0 Uploads

28 Posts

0 Threads

#5 11 years ago

nice job i tryed to make an auto gauss (like the SAW (squad automatic weapon) with a 200 round clip and automatic) the auto didnt work so i got rid of it now hopefuly i can make it full auto thanks