[FilterScript] Drive-by Weapon Switch
#1

Hey everyone,

The following script will allow the players on the server to switch their weapon during they're using drive-by (shooting from the vehicle as passengers).

By default, the keys of the weapon switch are Q and E.

Notes:
* The weapon switch will not work if you'll try to switch using the mouse scroll.
* The switch won't work if the next weapon is minigun. Only slots 2, 3, 4, 5 and 6 of the weapons are avilable to switch.

Pastebin link: http://pastebin.com/yYhjqFq3

Enjoy
Reply
#2

Ahh... Why you can switch weapons on foot but you can't in a vehicle? If I ever managed to make my own server, I would definitely use this.
Reply
#3

nice
Reply
#4

תודה עמית יא סקסי
אני מחכה שתפרסם תמערכת פיאמ שלך כמו שעשית
pm 1,2,3,4 בואו לרייס
אגב בחיים לא נראה דברים כאלו מ BLUEREY
--

Ty Bro <3
Reply
#5

Pretty good, nice work, tested it.
Reply
#6

Quote:
Originally Posted by _DownLoaD_
Посмотреть сообщение
תודה עמית יא סקסי
אני מחכה שתפרסם תמערכת פיאמ שלך כמו שעשית
pm 1,2,3,4 בואו לרייס
אגב בחיים לא נראה דברים כאלו מ BLUEREY
--

Ty Bro <3
אתה מתכוון ל-מערכת הודעות פרטיות... -.-
ותדבר באנגלית בפורום הזה..
Reply
#7

Use only English on this section please...
Reply
#8

Not bad. However I have one question, 'What does the following thing do?'.

pawn Код:
new pweapon[MAX_PLAYERS] = {0,...};

//What does this? {0,...}
I never used this so I'm wondering what it is.
Reply
#9

This sets ALL slots of the array pweapon to 0 :P
Reply
#10

Quote:
Originally Posted by Cypress
Посмотреть сообщение
Not bad. However I have one question, 'What does the following thing do?'.

pawn Код:
new pweapon[MAX_PLAYERS] = {0,...};

//What does this? {0,...}
I never used this so I'm wondering what it is.
Yup, NaS's answer is right.

using this for example:
pawn Код:
new array[3] = {0,1,2};
setting the array at start of the script, to 0 on the first cell, 1 on the second, etc.
using {0,...} will set all of the cells to 0.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)