Destiny w/ Keyboard and Mouse

Gtuner Plugins support. MaxAim, MaxRemapper, Combo Magick, Game Rec.

Destiny w/ Keyboard and Mouse

Postby Contract Killer » Sun Aug 10, 2014 7:58 am

Hi everyone so I recently got my Titan One mainly for the upcoming game Destiny and to not play like crap on a console. More to the point I've gotten everything set up and it works great, but what's the easiest way to add a macro for a keyboard/mouse to console set up?
I know some basics about coding (what I eventually want to go into for a career). It seems like it should just be as simple as adding an "if" clause into some GPC script, but I have not idea how to code in this language/context. Pretty much I'm thinking of something along the lines of this:

//
v = macro key for super regularly L and R bumpers pressed simultaneously
m3 = melee
f = grenade
//

if "v" is pressed
(
press m3
press f
)

I'm just not 100% sure how to translate this into GPC script and how that even works with using a keyboard and mouse. The max aim plugin is just a keyboard and mouse to controller remap right? So how do you add code into that is basically what this boils down to? Any help is greatly appreciated.

Sincerely,
Contract Killer
User avatar
Contract Killer
Staff Sergeant
Staff Sergeant
 
Posts: 15
Joined: Wed Aug 06, 2014 12:26 am

Re: Destiny w/ Keyboard and Mouse

Postby J2Kbr » Sun Aug 10, 2014 12:53 pm

Welcome to our community!

yes, you can add GPC script into a MaxAim game layout.
Your pseudo code can be implemented like this:
Code: Select all
main {
    // Bind any Keyboard key to CEMU_EXTRA9 in MaxAim DI.
    if(get_val(CEMU_EXTRA9)) {
        set_val(PS4_R1, 100);
        set_val(PS4_L1, 100);
    }
}
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: Destiny w/ Keyboard and Mouse

Postby Contract Killer » Mon Aug 11, 2014 8:08 am

Awesome thanks for the help, but could you explain your code just a bit? I've taken a few basic java classes and understand most of it except the trigger for your if statement. It just confuses me why it's not something like
if(CMEU_EXTRA9 >= 100)
{
//code
}
Then it would check if the extra key has been pressed for 100miliseconds (or more) followed by executing the combo.

The other thing I'm not sure about is how do I add GPC code to a MaxAim layout? It just seems like you assign the keyboard keys to the controller followed by entering capture mode, but where do you alter the actual code? Sorry if I'm asking a lot of questions. The user manual for crossing over keyboard/mouse to console could use a bit more detailed explanations for adding code.
User avatar
Contract Killer
Staff Sergeant
Staff Sergeant
 
Posts: 15
Joined: Wed Aug 06, 2014 12:26 am

Re: Destiny w/ Keyboard and Mouse

Postby J2Kbr » Mon Aug 11, 2014 10:18 am

Contract Killer wrote:Awesome thanks for the help, but could you explain your code just a bit? I've taken a few basic java classes and understand most of it except the trigger for your if statement. It just confuses me why it's not something like
if(CMEU_EXTRA9 >= 100) { /*code*/ }
Then it would check if the extra key has been pressed for 100miliseconds (or more) followed by executing the combo.

To check how long a button is being pressed you need use "get_ptime" function, here is an example:
Code: Select all
main {
    // Test if CEMU_EXTRA9 is pressed and
    // if the pressing time is higher then 100ms
    if(get_val(CEMU_EXTRA9) && get_ptime(CEMU_EXTRA9) >= 100) {
        // Code
    }
}


Contract Killer wrote:The other thing I'm not sure about is how do I add GPC code to a MaxAim layout? It just seems like you assign the keyboard keys to the controller followed by entering capture mode, but where do you alter the actual code? Sorry if I'm asking a lot of questions. The user manual for crossing over keyboard/mouse to console could use a bit more detailed explanations for adding code.

First you make the code using Gtuner PRO, as usual. To load the script on MaxAim DI, click on "Load GPC Script", in the "Layout Options" menu. The link below have a little explanation about this procedure:
http://www.consoletuner.com/kbase/layou ... 05691AC0_3
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: Destiny w/ Keyboard and Mouse

Postby Contract Killer » Tue Aug 12, 2014 8:28 am

Awesome I just finished writing and testing my code and it works perfectly :) .
Code: Select all

main
{
    // Sets super to additional input 1.
    if(get_val(CEMU_EXTRA1))
    {
        set_val(XB1_RB, 100);
        set_val(XB1_LB, 100);
    }
   
    // Additional input for weapon change.
    if(get_val(CEMU_EXTRA2))
    {
        // Bind mouse wheel up.
        set_val(XB1_Y, 100);
    }

    // Add additional input for mouse wheel down for weapon change.
    if(get_val(CEMU_EXTRA3))
    {
        // Bind mouse wheel down.
        set_val(XB1_Y, 100);
    }
}


Thanks for all your help. Now I just wait until September 9th when Destiny drops. Those console gamers better watch out their will be PC gamers among them hahaha.
User avatar
Contract Killer
Staff Sergeant
Staff Sergeant
 
Posts: 15
Joined: Wed Aug 06, 2014 12:26 am

Re: Destiny w/ Keyboard and Mouse

Postby J2Kbr » Tue Aug 12, 2014 9:37 am

awesome! I'm glad you got it work!! :joia:
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: Destiny w/ Keyboard and Mouse

Postby PrincessASG » Sun Aug 17, 2014 2:23 am

Quick question from complete noob, so this device has one usb port for input? so how do you get 2 devices like a keyboard and mouse hooked up to it and what keyboard and mouse are you guys using? Forgive me for posting here but this seems a relevant spot to post as i will be purchasing a titanone for Destiny and using a keyboard and mouse as i too suck with a controller.... :ashamed:
User avatar
PrincessASG
Private First Class
Private First Class
 
Posts: 2
Joined: Sun Aug 17, 2014 2:18 am

Re: Destiny w/ Keyboard and Mouse

Postby HardcoreGamer » Sun Aug 17, 2014 2:53 am

so this device has one usb port for input? so how do you get 2 devices like a keyboard and mouse hooked up to it


It should be something like this:

T1 into PS4;
DS4 Plugged into T1;
PC Plugged into T1 via the Pc Prog port;
KB/Mouse into PC/Laptop.

what keyboard and mouse are you guys using


Any Keyboard and mouse should work, I'm using a Azza kb/mouse.
Titan One User's Manual:

http://www.consoletuner.com/kbase/
User avatar
HardcoreGamer
Command Sergeant Major
Command Sergeant Major
 
Posts: 117
Joined: Sun Aug 03, 2014 9:28 pm

Re: Destiny w/ Keyboard and Mouse

Postby PrincessASG » Sun Aug 17, 2014 4:59 am

so this is a pass through device?? i still need a pc to use a keyboard and mouse? It seems like a lot of clutter and stuffing around is all, I thought program device to use the kb and mouse via keymapping or the like save the profile plug it in the console with kb and mouse and plugged into device and away you go, hmm lucky I asked the question, i'm not really going to move my rig into the loungeroom just to play with a keyboard and mouse seems like a waste of money
User avatar
PrincessASG
Private First Class
Private First Class
 
Posts: 2
Joined: Sun Aug 17, 2014 2:18 am

Re: Destiny w/ Keyboard and Mouse

Postby HardcoreGamer » Sun Aug 17, 2014 5:02 am

You could always use a Laptop instead of moving your rig.
Titan One User's Manual:

http://www.consoletuner.com/kbase/
User avatar
HardcoreGamer
Command Sergeant Major
Command Sergeant Major
 
Posts: 117
Joined: Sun Aug 03, 2014 9:28 pm

Next

Return to Gtuner Plugins Support

Who is online

Users browsing this forum: No registered users and 44 guests