Question about use of fix32

GPC2 script programming for Titan Two. Code examples, questions, requests.

Question about use of fix32

Postby pablosscripts » Mon Sep 26, 2016 2:01 am

I noticed that only get_val is fix32 now, not event_release. Just wondering whether this was intentional? It seems a tiny bit inconsistent when I have such precision when it comes to pressing the button but not releasing it. Here's an example of my code:

Image
Setup: XIM Apex, T2, K780 keyboard, G Pro Wireless mouse, SteelSeries 4HD pad, DXRacer armrest, LucidSound LS30 headset, Netduma router, Ubiquiti UniFi AP LR

My R6 script: https://youtu.be/x-9NtxyySVM
User avatar
pablosscripts
Brigadier General
Brigadier General
 
Posts: 1976
Joined: Tue Nov 24, 2015 6:27 am

Re: Question about use of fix32

Postby UK_Wildcats » Mon Sep 26, 2016 4:36 am

See the below.

J2Kbr wrote:You are correct in your examples. And also on the scenarios, a int -100 to 100 has "only" 200 points of resolution, on the other hand, a fix32 -in the same range- have 13,333,333 points of resolution. For regular buttons this should not make any difference, but in case of mouse translation the extra resolution will have a significant positive impact.
User avatar
UK_Wildcats
Brigadier General
Brigadier General
 
Posts: 2243
Joined: Thu Jan 08, 2015 6:53 pm

Re: Question about use of fix32

Postby J2Kbr » Mon Sep 26, 2016 3:10 pm

'event_release' returns a Boolean value, TRUE or FALSE depending if a entry was released or not. And 'get_val' returns the current value of the entry, which is a fix32 type.
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: Question about use of fix32

Postby pablosscripts » Tue Sep 27, 2016 12:56 am

Ah makes sense. Thank you.
Setup: XIM Apex, T2, K780 keyboard, G Pro Wireless mouse, SteelSeries 4HD pad, DXRacer armrest, LucidSound LS30 headset, Netduma router, Ubiquiti UniFi AP LR

My R6 script: https://youtu.be/x-9NtxyySVM
User avatar
pablosscripts
Brigadier General
Brigadier General
 
Posts: 1976
Joined: Tue Nov 24, 2015 6:27 am


Return to GPC2 Script Programming

Who is online

Users browsing this forum: No registered users and 146 guests