Destiny 2 - Strafe&Shoot but keep the aim on target
7 posts
• Page 1 of 1
Destiny 2 - Strafe&Shoot but keep the aim on target
Hi, working on a strafe script while shooting, how do i keep Stick_1_X on the same position during the strafe &shooting?
- Code: Select all
main {
if (get_actual(BUTTON_8) >= 50.0) {
if(get_actual(BUTTON_5)) {
combo_run(RapidFire);
combo_run(AutoStrafe);
} else {
combo_stop(RapidFire);
combo_stop(AutoStrafe);
}
}
}
combo RapidFire {
set_val(BUTTON_5, 100);
wait (231); //Value for Bygones
set_val(BUTTON_5, 0);
wait (231);
}
combo AutoStrafe {
set_val(STICK_2_X, 100);
wait(300);
set_val(STICK_2_X, 0);
wait(100);
set_val(STICK_2_X, -100);
wait(300);
set_val(STICK_2_X, 0);
wait(100);
}
-
monty34 - Command Sergeant Major
- Posts: 165
- Joined: Wed Jun 28, 2017 7:25 pm
Re: Destiny 2 - Strafe&Shoot but keep the aim on target
When triggering the strafe you can save the x and y values and apply for a certain time, overwriting the stick values from the controller. However, it seems this is not what you want achieve as the values will be fixed and your target will be moving. In this case not sure if can be done, as the device does not have knowledge of what is happening on the game (screen) to track the target (unless like in Fortnite which has strong aim assist).
ConsoleTuner Support Team
-
J2Kbr - General of the Army
- Posts: 20323
- Joined: Tue Mar 18, 2014 1:39 pm
Re: Destiny 2 - Strafe&Shoot but keep the aim on target
Hi, as i´m a xim mouse user, i´m searching for something which apply a constant increase of the Stick_1_X over a given time.
As example, when i apply below code i want a increase of 0.1 per ms of Stick_1_X from 1 to 300ms.
As example, when i apply below code i want a increase of 0.1 per ms of Stick_1_X from 1 to 300ms.
- Code: Select all
set_val(STICK_2_X, 100);
wait(300);
-
monty34 - Command Sergeant Major
- Posts: 165
- Joined: Wed Jun 28, 2017 7:25 pm
Re: Destiny 2 - Strafe&Shoot but keep the aim on target
monty34 wrote:As example, when i apply below code i want a increase of 0.1 per ms of Stick_1_X from 1 to 300ms.
- Code: Select all
set_val(STICK_2_X, 100);
wait(300);
Is this right?
- Code: Select all
fix32 x_val;
init{
combo_run(one);
}
// When this code is active. STICK_1_X value will increase by 0.1, per ms. for 300ms.
combo one {
set_val(STICK_2_X, 100);
wait(300);
}
main {
if(one) x_val += 0.1;
set_val(STICK_1_X, x_val);
}
-
Sillyasskid - Captain
- Posts: 574
- Joined: Sat May 14, 2016 3:07 am
Re: Destiny 2 - Strafe&Shoot but keep the aim on target
Thanks, this code helps me to go in the right direction. Still some work to do for me, but now i´ve a better idea what to do.
-
monty34 - Command Sergeant Major
- Posts: 165
- Joined: Wed Jun 28, 2017 7:25 pm
Re: Destiny 2 - Strafe&Shoot but keep the aim on target
Monty34, any updates to if you got this working?
-
grarrg - Sergeant Major
- Posts: 91
- Joined: Thu May 31, 2018 6:49 pm
Re: Destiny 2 - Strafe&Shoot but keep the aim on target
Hi, i've currently no time to work on this, but it's still on my to do list.
-
monty34 - Command Sergeant Major
- Posts: 165
- Joined: Wed Jun 28, 2017 7:25 pm
7 posts
• Page 1 of 1
Return to GPC2 Script Programming
Who is online
Users browsing this forum: No registered users and 61 guests