Double click "cycle" speed

  • #1, z bananeisafreeThursday, 21. April 2016, 11:42 hodinky 9 years ago
    Hi everyone (and probably AFRLme)
    Quick question.
    I would love to usethe double click as quick inspect button.
    The problem, the time that elapse beetween two clicks for the game treat it as a double click is a bit too long (around 300 / 400 ms)
    wich makes double clicking quite hazardous, "false" double clicks happen quite a lot and since every time the character talks she stops... It gets old very quickly.
    the double click speed ingame seems to be independant from my system settings (on windows that is) as I tryed different settings with no visible effects.
    I'm working on a set of conditions with "mouse enter object area" to bypass the issue, but it would be easier to simply be able to reduce the time between two clicks for it to be considered as a double click (not sure if I make myself understood)
    So here is my question : is there to your knowledge a way (scriptable I suppose) to change the double click speed of the game ?

    Have a wonderfull day !

    Cesar

    Fanoušek fóra

    120 Posts


  • #2, z afrlmeThursday, 21. April 2016, 12:51 hodinky 9 years ago
    Nope, sorry mate, not to my knowledge... I checked the mouse section of the editor & the data structure for the scripting side & I don't see anything to allow you to adjust the maximum time between clicks to register as a double click.

    You could potentially create a pause action inside of your left mouse button action in the mouse properties tab that updates a condition & then reverts the condition back to default after x time has passed. You would have to wrap each & everyone of your double click actions inside of an if query for this to work though...

    example of left click action inside of mouse properties tab...
    if 'current character' is on 'current scene'
    if conditions 'can_doubleclick' is false
    change condition 'can_doubleclick' to true
    pause for 100ms
    change condition 'can_doubleclick' to false
    end if
    end if


    example of double click action...
    if condition 'can_doubleclick' is true
    display text 'blah blah blah'
    end if


    P.S: I use a similar wrapping method for all the right click actions in the game I'm currently working on, because I wanted to make sure that right click actions don't get triggered if our character just happens to be standing at the interaction position of an object but also happens to currently be holding an item in their hand. Basically it checks if item held then drop item as opposed to triggering the right click action of an object if the player happens to accidentally - or purposely - right click on a scene object while holding said item.

    Imperátor

    7285 Posts

  • #3, z bananeisafreeThursday, 21. April 2016, 13:12 hodinky 9 years ago
    Thank you for the quick awnser.

    I feared so.
    I was thinking of a condition set of the sort.
    Yours is (unsurprisingly) better though.
    also the tip on the post scriptum is of tremendous value !

    Thank you for the head up, and for being so quick to awnser.
    Have a good day.

    ps: (Yeah, I can PS too !) I'm still a somewhat "advanced begginer" and lots of the "evident basics" eludes me quite a lot.
    As such, I was wondering what was the purpose of the "if 'current character' is on 'current scene'" line ?
    I get what it means, but do not see the full spectre of its utility here.

    Fanoušek fóra

    120 Posts

  • #4, z afrlmeThursday, 21. April 2016, 14:41 hodinky 9 years ago
    Yes, yes, we can all P.S but can you P.P.S? or P.P.P.S? haha. Right, moving on...

    The "if current character is on current scene" query is to prevent the double click stuff from being triggered if the active character is not on the currently displayed scene. You don't have to add that query, I just assumed you didn't need it for when the player isn't supposed to be able to double click things - like when the character isn't on the current scene because you are currently displaying a menu or whatever.

    I was already in the elite stage about 1 minute after I started using Visionaire Studio. Ego much? I didn't need tutorials or anything, as I managede to figure out most things myself with a logical based approach. The only thing I had issue with at first was the Lua syntax on the old wiki site (I #blamealex for that though) as the syntax made absolutely no sense at all.

    Imperátor

    7285 Posts

  • #5, z bananeisafreeFriday, 22. April 2016, 09:31 hodinky 9 years ago
    Damn! That many S !
    I always thought P were ment to be followed by one S and not one more !
    The way the spaghetti monster intented !
    ...
    Also moving on
    ...

    Undertsood. I figured it was something of the sort, but better safe than sorry.
    Yeah my first runs with Visionnaire were ... not as smooth as they seems to have been for you.
    I blame my 2 neurones for being on hollydays during that time, but I'm getting there.
    The scripting part is what really terrifies me right now, so I tend to find every way possible to avoid it.
    But I'm on my way to make some menus ... and I fear its the end of my happy trip to noScript_land.exe .

    Again, thank you for your awnsers

    Fanoušek fóra

    120 Posts

  • #6, z afrlmeFriday, 22. April 2016, 13:16 hodinky 9 years ago
    I think P.S means something along the lines of "post script" or something like that which basically means after text or afterthought, so you can keep on adding as many "P" before the "S" as you like...

    P.P.S would be Post-post script. (afterthought #2)

    Anyway... menus are possible without scripting but scripting will be required if you want to be able to store a players option choices as you will need to be able to read from & write to a config ini file.

    Imperátor

    7285 Posts