New GTA V Scripts - Discussion Post

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

New GTA V Scripts - Discussion Post

Postby GTAthrowawayaccount » Sat Dec 05, 2015 12:32 am

This is my first week as a Titan One owner, and these are my first 2 scripts. It took me most of the week to learn how to make them, but they're still not perfect.

:smile0314:
GTA V
Marksman Pistol and Flare Gun
Reload Animation Skip
PLUS Refill All Ammo In 3 Seconds
http://www.consoletuner.com/gpclib/?s=1060

:smile0313:
GTA V
Musket Reload Animation Skip
PLUS Refill All Ammo In 3 Seconds
http://www.consoletuner.com/gpclib/?s=1061

If you play GTA, try them out and let me know what you think.

I should mention that the "skip reload animation" glitch does not work in first person or in a vehicle.
The "Refill All Ammo" script wont work on last gen because it never received the update that included the option to refill ammo from the interaction menu, but the "Reload Animation Skip" scripts should work on all consoles if you change the buttons in the script. Once I know that I have these the best that they can be, I'll make a version for PS3 and test them out on my PS3 as well.
Last edited by GTAthrowawayaccount on Sat Dec 05, 2015 7:17 am, edited 1 time in total.
User avatar
GTAthrowawayaccount
Sergeant Major
Sergeant Major
 
Posts: 98
Joined: Fri Nov 27, 2015 11:55 pm

Re: New GTA V Scripts - Discussion Post

Postby Elvish » Sat Dec 05, 2015 4:33 am

Congratulations on getting a few scripts out in your first week!

Just wanted to let you know that your script names are a bit lengthy, which is fine. However, "Marksman_Pistol_and_Flare_Gun_Reload_Animation_Skip_PLUS_Refill_All_Ammo_In_3_Seconds" is so long the titles runs off the page when viewing the library page for it. Again, that is fine. But you may want to consider shortening the title so that the entire thing can be read while viewing it within the script library.
User avatar
Elvish
Captain
Captain
 
Posts: 531
Joined: Tue Jun 09, 2015 4:57 am

Re: New GTA V Scripts - Discussion Post

Postby GTAthrowawayaccount » Sat Dec 05, 2015 6:42 am

Yeah, I was wondering why it was doing that... but now I realize that it was because I used underscores instead of spaces and it was counted as one word. I played with it a little and found out that you can have all 128 allotted characters on a single line as long as you don't use any spaces or punctuation, which I found to be interesting and entertaining for a moment. I changed the name so it doesn't run off the page now. Playing around with the underscores to manipulate the spacing was kind of fun. :smile0204:
Do you play GTA V with your Titan One? Join the ConsoleTuner crew I made! viewtopic.php?f=22&t=3954
User avatar
GTAthrowawayaccount
Sergeant Major
Sergeant Major
 
Posts: 98
Joined: Fri Nov 27, 2015 11:55 pm

Re: New GTA V Scripts - Discussion Post

Postby J2Kbr » Sat Dec 05, 2015 9:55 am

GTA V is one the games that I most receive scripts requests. Thank you very much for sharing your scripts. It will be very useful for many users! :)
ConsoleTuner Support Team
User avatar
J2Kbr
General of the Army
General of the Army
 
Posts: 20323
Joined: Tue Mar 18, 2014 1:39 pm

Re: New GTA V Scripts - Discussion Post

Postby GTAthrowawayaccount » Sat Dec 05, 2015 2:57 pm

Then I think I'll fit in just fine around here, because GTA is the ONLY game I play, and I just caught the scripting bug.
Do you play GTA at all J2Kbr? Or perhaps there's a moderator of this site that does.... It would be nice to get some feedback from anyone that plays GTA and knows what they're doing when it comes to script writing.
Do you play GTA V with your Titan One? Join the ConsoleTuner crew I made! viewtopic.php?f=22&t=3954
User avatar
GTAthrowawayaccount
Sergeant Major
Sergeant Major
 
Posts: 98
Joined: Fri Nov 27, 2015 11:55 pm

Re: New GTA V Scripts - Discussion Post

Postby J2Kbr » Mon Dec 07, 2015 11:41 am

this year was probably the year that I have less played games ... really missing that. GTA V still in my list of games the I must play.
ConsoleTuner Support Team
User avatar
J2Kbr
General of the Army
General of the Army
 
Posts: 20323
Joined: Tue Mar 18, 2014 1:39 pm

Re: New GTA V Scripts - Discussion Post

Postby Prototype » Fri Dec 11, 2015 4:34 pm

I own GTA V since one month but don't have played so much, i will try your scripts.
Console tuner since my 1st controller.
Scripting, a game in the game.
Believe or dare, It's Titanic! :smile0517:
User avatar
Prototype
Major General
Major General
 
Posts: 3251
Joined: Sun Dec 16, 2012 1:43 pm

Re: New GTA V Scripts - Discussion Post

Postby GTAthrowawayaccount » Sat Dec 12, 2015 12:59 am

prototype wrote:I own GTA V since one month but don't have played so much, i will try your scripts.

Please let me know what buttons you think would be best for the weapons. I'm planning on making a mini-gamepack with them and my other scripts, so that they can all be used without changing slots. I think I have them all short enough to fit together in 1 script under 4096 bytes, I just want to make sure I have the best buttons to trigger the reload animation skipping scripts. I want them to feel comfortable enough to use the button combo regularly, without that button combo possibly interfering with normal gameplay (by being triggered accidentally when doing something else). What system do you use? (I use PS3 and PS4)
Do you play GTA V with your Titan One? Join the ConsoleTuner crew I made! viewtopic.php?f=22&t=3954
User avatar
GTAthrowawayaccount
Sergeant Major
Sergeant Major
 
Posts: 98
Joined: Fri Nov 27, 2015 11:55 pm

Re: New GTA V Scripts - Discussion Post

Postby Elvish » Sat Dec 12, 2015 2:54 am

GTAthrowawayaccount wrote:Please let me know what buttons you think would be best for the weapons. I'm planning on making a mini-gamepack with them and my other scripts, so that they can all be used without changing slots. I think I have them all short enough to fit together in 1 script under 4096 bytes, I just want to make sure I have the best buttons to trigger the reload animation skipping scripts. I want them to feel comfortable enough to use the button combo regularly, without that button combo possibly interfering with normal gameplay (by being triggered accidentally when doing something else)


According to what we worked on these guns associated with the reload script are always at the top of the rotation wheel. Would it be safe to assume that if the user has the gun on the top of the wheel out that pressing the reload button should always trigger the quick reload script? Also if that is the gun out you can assume two quick trigger pulls would be enough to indicate the user wants to activate the rapidfire shooting, right? Just some ideas.
User avatar
Elvish
Captain
Captain
 
Posts: 531
Joined: Tue Jun 09, 2015 4:57 am

Re: New GTA V Scripts - Discussion Post

Postby Prototype » Mon Dec 14, 2015 9:13 am

GTAthrowawayaccount wrote:
prototype wrote:I own GTA V since one month but don't have played so much, i will try your scripts.

Please let me know what buttons you think would be best for the weapons. I'm planning on making a mini-gamepack with them and my other scripts, so that they can all be used without changing slots. I think I have them all short enough to fit together in 1 script under 4096 bytes, I just want to make sure I have the best buttons to trigger the reload animation skipping scripts. I want them to feel comfortable enough to use the button combo regularly, without that button combo possibly interfering with normal gameplay (by being triggered accidentally when doing something else). What system do you use? (I use PS3 and PS4)

Ok i have try your scripts and it works really fine. For me the best way to trigger the reload animation skipping is to use the right button like that:
Code: Select all
define ACTIV_BUTTON = PS4_RIGHT;
int activ_switch = FALSE;

main {
        if(get_val(ACTIV_BUTTON)) {
            if(event_press(ACTIV_BUTTON)) {
                activ_switch = TRUE;
            }
            if(event_press(PS4_R2)) {
                combo_run(Marksman_Pistol_Reload_Animation_Skip);
                activ_switch = FALSE;
            }
            if(get_ptime(ACTIV_BUTTON) < 500) {
                set_val(ACTIV_BUTTON, 0);
            }
            set_val(PS4_R2, 0);
            } else {
            if(activ_switch) {
                if(get_ptime(ACTIV_BUTTON) < 500){
                    combo_run(Default);
                }
                activ_switch = FALSE;
            }
        }
}

combo Default {
        set_val(ACTIV_BUTTON, 100);
        wait(40);
}

combo Marksman_Pistol_Reload_Animation_Skip {
        //FIRE WEAPON
        set_val(PS4_R2, 100);//goal
        wait(850);
        //OPEN WEAPON WHEEL
        set_val(PS4_L1, 100);//goal
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        set_val(PS4_RY, 0);//safeguard
        set_val(PS4_RX, 0);//safeguard
        wait(17);
        //and SELECT MELEE WEAPON (RY down)
        set_val(PS4_L1, 100);//goal
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        set_val(PS4_RY, 100);//goal
        set_val(PS4_RX, 0);//safeguard
        wait(84);
        //CLOSE WEAPON WHEEL but KEEP RY (down)
        set_val(PS4_L1, 0);//goal
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        set_val(PS4_RY, 100);//goal
        set_val(PS4_RX, 0);//safeguard
        wait(17);
        //STOP RY (down) ---- This is needed to hold the melee weapon breifly
        set_val(PS4_L1, 0);//safeguard   
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        set_val(PS4_RY, 0);//goal
        set_val(PS4_RX, 0);//safeguard
        wait(17);
        //OPEN WEAPON WHEEL
        set_val(PS4_L1, 100);//goal
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        set_val(PS4_RY, 0);//safeguard
        set_val(PS4_RX, 0);//safeguard
        wait(17);
        //and SELECT PISTOL SLOT WEAPON (RY up)
        set_val(PS4_L1, 100); //goal
        set_val(PS4_RY, -100);//goal
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        set_val(PS4_RX, 0);//safeguard
        wait(84);
        //CLOSE WEAPON WHEEL but KEEP RY (up)
        set_val(PS4_L1, 0);//goal
        set_val(PS4_RY, -100);//goal
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_RX, 0);//safeguard
        wait(17);
        //STOP RY (up)
        set_val(PS4_RY, 0);//goal
        set_val(PS4_RX, 0);//safeguard
        set_val(PS4_L1, 0);//safeguard?
        set_val(PS4_L2, 0);//safeguard
        set_val(PS4_R2, 0);//safeguard
        set_val(PS4_LEFT, 0);//safeguard
        set_val(PS4_RIGHT, 0);//safeguard
        wait(17);
    }

Just hold the ACTIV_BUTTON and press R2 quickly to run the combo.
This way you can use R1 as the ACTIV_BUTTON also.
Console tuner since my 1st controller.
Scripting, a game in the game.
Believe or dare, It's Titanic! :smile0517:
User avatar
Prototype
Major General
Major General
 
Posts: 3251
Joined: Sun Dec 16, 2012 1:43 pm

Next

Return to GPC1 Script Programming

Who is online

Users browsing this forum: No registered users and 71 guests