2k21 shot stick push down
15 posts
• Page 1 of 2 • 1, 2
2k21 shot stick push down
Hello
I am want to test something out. In the game you push the right stick up or down to start the shot then aim at a target with the same stick. I can get the aim after the shot starts to work but can't get the start of the shot to work. My only guess is that the game will only recognize a real 0 to100 movement of the stick as legitimate.
So question is how do you accomplish that? I was thinking maybe a for loop. I dont know the gpc equivalent.
Also let me know if this has already been accomplished. I havent seen it though.
I am want to test something out. In the game you push the right stick up or down to start the shot then aim at a target with the same stick. I can get the aim after the shot starts to work but can't get the start of the shot to work. My only guess is that the game will only recognize a real 0 to100 movement of the stick as legitimate.
So question is how do you accomplish that? I was thinking maybe a for loop. I dont know the gpc equivalent.
Also let me know if this has already been accomplished. I havent seen it though.
-
Nefliminator - Staff Sergeant
- Posts: 14
- Joined: Tue Feb 18, 2020 2:37 am
Re: 2k21 shot stick push down
Here is an example of how to gradually push the stick by pressing the Cross/A button:
- Code: Select all
fix32 value;
main {
if(get_val(BUTTON_16)) {
if(event_active(BUTTON_16)) {
value = 0.0;
combo_run(MoveStick);
}
set_val(STICK_1_Y, 100.0);
}
}
combo MoveStick {
set_val(STICK_1_Y, value);
wait(1);
set_val(STICK_1_Y, value);
if(abs(++value) <= 100.0) {
combo_restart(MoveStick);
}
wait(0);
}
ConsoleTuner Support Team
-
J2Kbr - General of the Army
- Posts: 20323
- Joined: Tue Mar 18, 2014 1:39 pm
Re: 2k21 shot stick push down
i found out the perfect shot on the game but i need help moving to dpad so i can do fancy dribble my shots go in 90 percent of the time even against online but i cant dribble because i need to use down on the analog stick.
you need to have a high rated shooter and turn shot meter off but use shot stick
main {
set_val(STICK_1_X,-18);
}
if someone could help with making that for dpad i would appreciate it
you need to have a high rated shooter and turn shot meter off but use shot stick
main {
set_val(STICK_1_X,-18);
}
if someone could help with making that for dpad i would appreciate it
-
cullenmac - Sergeant First Class
- Posts: 18
- Joined: Sat Mar 24, 2018 3:41 am
Re: 2k21 shot stick push down
Ok thanks. I will try that out tonight.
I saw your post cullenmac. I think your method was the way I was doing it to begin with but then they patched 2k21 and added it a part about the aim on the meter changes by how fast you pull the right stick down. So im going to have to write something for the right stick pull speed.
I saw your post cullenmac. I think your method was the way I was doing it to begin with but then they patched 2k21 and added it a part about the aim on the meter changes by how fast you pull the right stick down. So im going to have to write something for the right stick pull speed.
-
Nefliminator - Staff Sergeant
- Posts: 14
- Joined: Tue Feb 18, 2020 2:37 am
Re: 2k21 shot stick push down
If you use that code its not timing based but aimed so you dont have to worry about lag. on my team tripple threat online ive won 15 games in a row with klay thompson , i just flick the stick down with that code instant green , only issue is that its catch and shoot because your behind the back and thru the legs is disabled due to the code making the shot stick to go straight down, in my career i have a level 75 pg 90 rated three ball with only 6 of my 25 shooting badges and he never misses in park or rec as long as he has open shot. if i could get that code moved to the dpad than it would be even better because you could break down players and instant green .
-
cullenmac - Sergeant First Class
- Posts: 18
- Joined: Sat Mar 24, 2018 3:41 am
Re: 2k21 shot stick push down
All you do is put the name of your function in the run_combo. If you put anything on left it will make the camera options popup each time you push it unless you disable the actual button input somehow.
11 is down, 10 is up, 13 is right.
11 is down, 10 is up, 13 is right.
- Code: Select all
if(event_active(BUTTON_11))
{
combo_run(slow_shot);
}
-
Nefliminator - Staff Sergeant
- Posts: 14
- Joined: Tue Feb 18, 2020 2:37 am
Re: 2k21 shot stick push down
I figured it out with yall's help. This code pulls the stick back slow enough that it puts the aimer all the way to left each time. There is probably a more efficient way but it is working for now haha.
- Code: Select all
fix32 v;
main
{
if(get_val(BUTTON_11))
{
if(event_active(BUTTON_11))
{
v = 0.0;
combo_run(slow_shot);
}
}
}
combo slow_shot
{
set_val(STICK_1_Y, v);
wait(1);
set_val(STICK_1_Y, v);
if(abs(v) <= 100.0)
{
combo_restart(slow_shot);
v = v+2.0;
}
else
{
combo_run(shot_wait);
}
wait(0);
}
combo shot_wait
{
set_val(STICK_1_Y, 95.0);
set_val(STICK_1_X, -30.0);
wait(800);
}
Last edited by Nefliminator on Sat Sep 19, 2020 7:44 am, edited 1 time in total.
-
Nefliminator - Staff Sergeant
- Posts: 14
- Joined: Tue Feb 18, 2020 2:37 am
Re: 2k21 shot stick push down
you are the man i adjusted my shot to -32 green all the time
-
cullenmac - Sergeant First Class
- Posts: 18
- Joined: Sat Mar 24, 2018 3:41 am
Re: 2k21 shot stick push down
Hey, so I added a dribbling script to this shooting script and for some reason it disables the shooting script IG and only the dribbling works. It doesn't output any errors after pressing F7. How do I fix this so that both scripts work simultaneously?
- Code: Select all
#include <titanone.gph>
fix32 v;
main
{
if(get_val(BUTTON_10))
{
if(event_active(BUTTON_10))
{
v = 0.0;
combo_run(slow_shot);
}
}
{
if(event_press(PS4_L3)){combo_run(LM);}
}
}
combo slow_shot
{
set_val(STICK_1_Y, v);
wait(1);
set_val(STICK_1_Y, v);
if(abs(v) <= 100.0)
{
combo_restart(slow_shot);
v = v+2.0;
}
else
{
combo_run(shot_wait);
}
wait(0);
}
combo shot_wait
{
set_val(STICK_1_Y, 95.0);
set_val(STICK_1_X, -32.0);
wait(800);
}
combo LM
{ set_val(PS4_R2, 100);
set_val(PS4_RX, 100);
set_val(PS4_RY, 0);
wait(160);
}
-
Chapstick - Staff Sergeant
- Posts: 11
- Joined: Sat Jun 13, 2020 1:12 am
Re: 2k21 shot stick push down
I dont 100% know without testing but try....
- Code: Select all
main
{
if(get_val(BUTTON_10))
{
if(event_active(BUTTON_10))
{
v = 0.0;
combo_run(slow_shot);
}
}
else if(event_press(PS4_L3))
{
combo_run(LM);
}
}
-
Nefliminator - Staff Sergeant
- Posts: 14
- Joined: Tue Feb 18, 2020 2:37 am
15 posts
• Page 1 of 2 • 1, 2
Return to GPC2 Script Programming
Who is online
Users browsing this forum: No registered users and 77 guests