NBA 2K20 Shot Scripts Help (New)

GPC1 script programming for Titan One. Code examples, questions, requests.

NBA 2K20 Shot Scripts Help (New)

Postby sirnike1902 » Thu Jul 09, 2020 3:56 am

Hey, I'm new to Titan 1 and scripting. I'm looking to use a script for NBA 2K20 on Xbox1, on the titan 1, for a perfect release
every time. I want to set it to my custom jump shot. Thanks in advance to whoever helps!
User avatar
sirnike1902
Corporal
Corporal
 
Posts: 5
Joined: Thu Jul 09, 2020 2:34 am

Re: NBA 2K20 Shot Scripts Help (New)

Postby Mad » Thu Jul 09, 2020 8:52 am

Welcome. :smile0201:

Try this, you'll need to adjust shot_time at the top of the script in milliseconds:
Code: Select all
define shot_time = 2000;
 
main {
    if(event_press(XB1_X)) {
      combo_run(TimedShot);
    }
}
 
combo TimedShot {
    set_val(XB1_X, 100);
    wait(shot_time);
}
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
Mad
Major General
Major General
 
Posts: 4536
Joined: Wed May 22, 2019 5:39 am

Re: NBA 2K20 Shot Scripts Help (New)

Postby sirnike1902 » Thu Jul 09, 2020 8:56 pm

Thanks a lot! I will give it a try
User avatar
sirnike1902
Corporal
Corporal
 
Posts: 5
Joined: Thu Jul 09, 2020 2:34 am

Re: NBA 2K20 Shot Scripts Help (New)

Postby usuallyunusual » Sat Jul 11, 2020 11:24 pm

how did it work for you?
Image

Seeing Eye to Eye turned into an Eye for an Eye

Now everyones blind!
User avatar
usuallyunusual
Sergeant Major of the Army
Sergeant Major of the Army
 
Posts: 196
Joined: Sat Sep 06, 2014 6:37 pm

Re: NBA 2K20 Shot Scripts Help (New)

Postby sirnike1902 » Sun Jul 12, 2020 10:29 am

Not really sure where to paste this script. Do I put it right into a game pack slot?
User avatar
sirnike1902
Corporal
Corporal
 
Posts: 5
Joined: Thu Jul 09, 2020 2:34 am

Re: NBA 2K20 Shot Scripts Help (New)

Postby Mad » Sun Jul 12, 2020 10:37 am

sirnike1902 wrote:Not really sure where to paste this script. Do I put it right into a game pack slot?

In Gtuner: File>New>Empty File and then paste the code. Then File>Save.
Select the Programmer tab and under "Compiler Scripts" you should see the file you just saved, drag it to a memory slot and press "Program Device".

I could be wrong, I haven't used the T1. :whistling:
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
Mad
Major General
Major General
 
Posts: 4536
Joined: Wed May 22, 2019 5:39 am

Re: NBA 2K20 Shot Scripts Help (New)

Postby sirnike1902 » Sun Jul 12, 2020 12:38 pm

I've also tried this script and it wont let me put it to a slot.
User avatar
sirnike1902
Corporal
Corporal
 
Posts: 5
Joined: Thu Jul 09, 2020 2:34 am

Re: NBA 2K20 Shot Scripts Help (New)

Postby Mad » Sun Jul 12, 2020 7:49 pm

sirnike1902 wrote:I've also tried this script and it wont let me put it to a slot.

This is a Titan Two script, generally they cannot be converted to work on the T1. Since it's short, I have roughly converted it for you.
Code: Select all
define jShotTimes_X     = 500;
define jShotTimes_UP    = 550;
define jShotTimes_DOWN  = 600;
define jShotTimes_LEFT  = 700;
define jShotTimes_RIGHT = 650;
 
int jShotTime;
 
main {
    if (event_press(XB1_X)) { jShotTime = jShotTimes_X combo_run(cjShot); }// XB1:X button, first time in first line
    if (event_press(XB1_UP)) { jShotTime = jShotTimes_UP combo_run(cjShot); }// dpad up, second time in first line
    if (event_press(XB1_DOWN)) { jShotTime = jShotTimes_DOWN  combo_run(cjShot); }// dpad down, third time in first line
    if (event_press(XB1_LEFT)) { jShotTime = jShotTimes_LEFT  combo_run(cjShot); }// dpad left, fourth time in first line
    if (event_press(XB1_RIGHT)) { jShotTime = jShotTimes_RIGHT  combo_run(cjShot); }// dpad right, fifth time in first line
 
    // only pdad presses longer than 500ms will be recognized by the game
    block(XB1_UP,500);
    block(XB1_DOWN,500);
    block(XB1_LEFT,500);
    block(XB1_RIGHT,500);
}
 
combo cjShot {
    set_val(XB1_X,100); // XB1:X button press
    wait(jShotTime);
    set_val(XB1_X,0); // XB1:X button release
    wait(40);
}
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
Mad
Major General
Major General
 
Posts: 4536
Joined: Wed May 22, 2019 5:39 am

Re: NBA 2K20 Shot Scripts Help (New)

Postby usuallyunusual » Mon Jul 13, 2020 3:10 am

Can i get this same script but for ps4 and titan 2 lol
Image

Seeing Eye to Eye turned into an Eye for an Eye

Now everyones blind!
User avatar
usuallyunusual
Sergeant Major of the Army
Sergeant Major of the Army
 
Posts: 196
Joined: Sat Sep 06, 2014 6:37 pm

Re: NBA 2K20 Shot Scripts Help (New)

Postby Mad » Mon Jul 13, 2020 3:18 am

usuallyunusual wrote:Can i get this same script but for ps4 and titan 2 lol

viewtopic.php?f=26&t=15529#p99979
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
Mad
Major General
Major General
 
Posts: 4536
Joined: Wed May 22, 2019 5:39 am

Next

Return to GPC1 Script Programming

Who is online

Users browsing this forum: No registered users and 69 guests