Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Instant weapon change
#11
(02-19-2015, 17:18)Nekochan Wrote:
(02-19-2015, 16:36)rvyASVP Wrote:
(02-19-2015, 16:24)Nekochan Wrote: Try this function instead of 'switchtoweaponimmediate':
Code:
self SetSpawnWeapon("wep");

Else you can try following:
Code:
self TakeWeapon("wep"); // takes weapon without anim
self GiveWeapon("wep");
self SwitchToWeapon(Immediate)("wep");
.. or put SetSpawnWeapon instead

so instead of the 'wep' i should put in a wepon or am i wrong?

(02-19-2015, 16:36)rvyASVP Wrote:
(02-19-2015, 16:24)Nekochan Wrote: Try this function instead of 'switchtoweaponimmediate':
Code:
self SetSpawnWeapon("wep");

Else you can try following:
Code:
self TakeWeapon("wep"); // takes weapon without anim
self GiveWeapon("wep");
self SwitchToWeapon(Immediate)("wep");
.. or put SetSpawnWeapon instead

so instead of the 'wep' i should put in a wepon or am i wrong?

nice dat finally works as planned ^^
but theres another thing, if i do that while the spas is doing this reload thing to put another bullet in the chamber, the intervention is going to shoot right after that...
i dont know but is there any way to fix dat?

Put a delay? ( wait .05; )

ok and now the last point how can i define a variable for every secondary and primary so i can do this without putting the special weapon to the code?
Reply

#12
(02-19-2015, 17:42)rvyASVP Wrote:
(02-19-2015, 17:18)Nekochan Wrote:
(02-19-2015, 16:36)rvyASVP Wrote:
(02-19-2015, 16:24)Nekochan Wrote: Try this function instead of 'switchtoweaponimmediate':
Code:
self SetSpawnWeapon("wep");

Else you can try following:
Code:
self TakeWeapon("wep"); // takes weapon without anim
self GiveWeapon("wep");
self SwitchToWeapon(Immediate)("wep");
.. or put SetSpawnWeapon instead

so instead of the 'wep' i should put in a wepon or am i wrong?

(02-19-2015, 16:36)rvyASVP Wrote:
(02-19-2015, 16:24)Nekochan Wrote: Try this function instead of 'switchtoweaponimmediate':
Code:
self SetSpawnWeapon("wep");

Else you can try following:
Code:
self TakeWeapon("wep"); // takes weapon without anim
self GiveWeapon("wep");
self SwitchToWeapon(Immediate)("wep");
.. or put SetSpawnWeapon instead

so instead of the 'wep' i should put in a wepon or am i wrong?

nice dat finally works as planned ^^
but theres another thing, if i do that while the spas is doing this reload thing to put another bullet in the chamber, the intervention is going to shoot right after that...
i dont know but is there any way to fix dat?

Put a delay? ( wait .05; )

ok and now the last point how can i define a variable for every secondary and primary so i can do this without putting the special weapon to the code?

Check weaponClass. I don't remember how it works. Try to search for "weaponClass". So with weaponClass you can get the type of weapon ( smg, lmg, assault, etc ).
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply

#13
(02-19-2015, 20:01)Nekochan Wrote:
(02-19-2015, 17:42)rvyASVP Wrote:
(02-19-2015, 17:18)Nekochan Wrote:
(02-19-2015, 16:36)rvyASVP Wrote:
(02-19-2015, 16:24)Nekochan Wrote: Try this function instead of 'switchtoweaponimmediate':
Code:
self SetSpawnWeapon("wep");

Else you can try following:
Code:
self TakeWeapon("wep"); // takes weapon without anim
self GiveWeapon("wep");
self SwitchToWeapon(Immediate)("wep");
.. or put SetSpawnWeapon instead

so instead of the 'wep' i should put in a wepon or am i wrong?

(02-19-2015, 16:36)rvyASVP Wrote: so instead of the 'wep' i should put in a wepon or am i wrong?

nice dat finally works as planned ^^
but theres another thing, if i do that while the spas is doing this reload thing to put another bullet in the chamber, the intervention is going to shoot right after that...
i dont know but is there any way to fix dat?

Put a delay? ( wait .05; )

ok and now the last point how can i define a variable for every secondary and primary so i can do this without putting the special weapon to the code?

Check weaponClass. I don't remember how it works. Try to search for "weaponClass". So with weaponClass you can get the type of weapon ( smg, lmg, assault, etc ).

i finally got it... it was self.Primary/secondaryWeapon or Name i dont remember Big Grin
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  instant sprint rvyASVP 6 4,570 05-06-2015, 22:41
Last Post: Nekochan

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.