rapid fire on/off
4 posts
• Page 1 of 1
rapid fire on/off
im trying to make a gears of war ultimate edition script. im not very good at this so i use the visual script. is there a way to have rapid fire turn off and on with button combo or something like it. Also someone made a script for weapon sliding so if i translate the visual script to the regular script will i have to just copy and paste it in there. any support would be appreciated. sorry im noob to this.
-
srbtattoo - Sergeant Major
- Posts: 72
- Joined: Wed Apr 15, 2015 10:50 pm
Re: rapid fire on/off
You may be able to setup an on/off toggle in visual scripting using the Logic area. That is going to get REALLY messy in the visual scripting panel most likely though. I would try to have you switch and stick to manual coding. Use the visual scripting to make small snippets of code that you aren't sure about and then convert them to raw GPC code to see how it's done.
For a toggle, we typically do something like this:
The X = !X part basically is a toggle switch. Each time you hold SHARE and then tap CROSS, the rapid fire mod will toggle on and off.
For a toggle, we typically do something like this:
- Code: Select all
if (get_val(PS4_SHARE) && event_press(PS4_CROSS)) {
RapidFireOn = !RapidFireOn;
}
if (RapidFireOn && get_val(PS4_R2)) {
combo_run(RapidFireCombo);
}
The X = !X part basically is a toggle switch. Each time you hold SHARE and then tap CROSS, the rapid fire mod will toggle on and off.
ConsoleTuner Support Team
-
perfecthuntr - Major
- Posts: 897
- Joined: Wed Jan 14, 2015 8:35 am
- Location: Tennessee
Re: rapid fire on/off
I try'd this in a script I'm trying to write and it come up with an error that says """syntax error, unexpected IF 'if, """ and I have been putting like define RT = XB1_RT; for each button that the script uses but it only works in "GtunerIV" if you paste the titan one conversion code at the top of the script to make it work for titan two. So since define isn't for the gtunerIv software what do you use?
-
DUCKMO3W - Sergeant First Class
- Posts: 22
- Joined: Sat Jan 10, 2015 9:29 pm
Re: rapid fire on/off
The above script is not complete, here is a full version for it:
- Code: Select all
int RapidFireOn;
main {
if (get_val(PS4_SHARE) && event_press(PS4_CROSS)) {
RapidFireOn = !RapidFireOn;
}
if (RapidFireOn && get_val(PS4_R2)) {
combo_run(RapidFireCombo);
}
}
combo RapidFireCombo {
set_val(RapidFireCombo, 100);
wait(40);
set_val(RapidFireCombo, 0);
wait(30);
set_val(RapidFireCombo, 0);
}
ConsoleTuner Support Team
-
J2Kbr - General of the Army
- Posts: 20323
- Joined: Tue Mar 18, 2014 1:39 pm
4 posts
• Page 1 of 1
Return to GPC1 Script Programming
Who is online
Users browsing this forum: No registered users and 69 guests