Gamestudio Links
Zorro Links
Newest Posts
zorro license, IB connection
by miwok. 12/06/23 16:32
Newbie Questions
by fairtrader. 12/06/23 11:29
Zorro Trader GPT
by TipmyPip. 12/04/23 11:34
Square root rule
by Smallz. 12/02/23 09:15
RTest not found error
by TipmyPip. 12/01/23 21:43
neural function for Python to [Train]
by TipmyPip. 12/01/23 14:47
Xor Memory Problem.
by TipmyPip. 11/28/23 14:23
Training with command line parameters
by TipmyPip. 11/26/23 08:42
AUM Magazine
Latest Screens
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Who's Online Now
6 registered members (miwok, AndrewAMD, TipmyPip, 3run, Quad, 1 invisible), 645 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
fairtrader, hus, Vurtis, Harry5, KelvinC
19019 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
speed of mouse movement! #419911
03/16/13 15:26
03/16/13 15:26
Joined: Nov 2007
Posts: 318
Brasil, Paraná
NeoNeper Offline OP
Senior Member
NeoNeper  Offline OP
Senior Member

Joined: Nov 2007
Posts: 318
Brasil, Paraná
My game is running at 35 frames per second.
I use the mouse to drag panels menus, but the speed of mouse is much slower, due to this low frames rate.
Has some technique I can use to increase the speed of the mouse, without the need to increase the frames?

PS: I use mouse_map. when I refer to the speed of the mouse I mean the bmap accompanying the mouse. Be the mouse_map or the bmaps that are dragged by it

Last edited by NeoNeper; 03/16/13 15:26.

Please! Use easy words to be translated. because my English is not very good! Grateful.
_______________________________________________________
Re: speed of mouse movement! [Re: NeoNeper] #419916
03/16/13 15:36
03/16/13 15:36
Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Kartoffel Offline
Expert
Kartoffel  Offline
Expert

Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
what about time_step?


POTATO-MAN saves the day! - Random
Re: speed of mouse movement! [Re: Kartoffel] #419965
03/17/13 21:24
03/17/13 21:24
Joined: Nov 2007
Posts: 318
Brasil, Paraná
NeoNeper Offline OP
Senior Member
NeoNeper  Offline OP
Senior Member

Joined: Nov 2007
Posts: 318
Brasil, Paraná
whats? no understand


Please! Use easy words to be translated. because my English is not very good! Grateful.
_______________________________________________________
Re: speed of mouse movement! [Re: NeoNeper] #419967
03/17/13 21:47
03/17/13 21:47
Joined: May 2009
Posts: 5,367
Caucasus
3run Online
Senior Expert
3run  Online
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
NeoNeper@ how do you move the mouse cursor? like this:
Code:
while(1){
    vec_set(mouse_pos.x, mouse_cursor.x);
    wait(1);
}

Or somehow different? If you move it, in a different way, make sure, that you use "time_step" with it:
Code:
camera.pan -= mouse_force.x * time_step;



Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: speed of mouse movement! [Re: 3run] #420015
03/18/13 14:54
03/18/13 14:54
Joined: Nov 2007
Posts: 318
Brasil, Paraná
NeoNeper Offline OP
Senior Member
NeoNeper  Offline OP
Senior Member

Joined: Nov 2007
Posts: 318
Brasil, Paraná
I USE
Code:
while(1){
    vec_set(mouse_pos.x, mouse_cursor.x);
    wait(1);
}



would be the correct way?
mouse_pos.x = mouse_cursor.x * time_step;
mouse_pos.y = mouse_cursor.y * time_step;

?

Last edited by NeoNeper; 03/18/13 14:58.

Please! Use easy words to be translated. because my English is not very good! Grateful.
_______________________________________________________
Re: speed of mouse movement! [Re: NeoNeper] #420020
03/18/13 15:53
03/18/13 15:53
Joined: Jan 2002
Posts: 4,225
Germany / Essen
Uhrwerk Offline
Expert
Uhrwerk  Offline
Expert

Joined: Jan 2002
Posts: 4,225
Germany / Essen
Your code is correct. Don't use the second snippet, i.t. don't multiply with time_step!

You're already using the windows mouse position. If the mouse does not move fast enough for you consider increasing the sensitivity in the control panel.


Always learn from history, to be sure you make the same mistakes again...
Re: speed of mouse movement! [Re: Uhrwerk] #420021
03/18/13 16:39
03/18/13 16:39
Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Kartoffel Offline
Expert
Kartoffel  Offline
Expert

Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
...and just a little tip:
set mouse_mode = 4; once and mouse_pos gets updated automatically.


POTATO-MAN saves the day! - Random
Re: speed of mouse movement! [Re: Kartoffel] #420076
03/19/13 13:05
03/19/13 13:05
Joined: Nov 2007
Posts: 318
Brasil, Paraná
NeoNeper Offline OP
Senior Member
NeoNeper  Offline OP
Senior Member

Joined: Nov 2007
Posts: 318
Brasil, Paraná
yes currently use mouse_mode = 4 and vec_set(mouse_pos.x, mouse_cursor.x);.
But as I reported earlier the speed of the mouse map is related to fps_max.

if I set fps_max = 60; its is good.
the map of the mouse or click and drag of the panels are made in the same speed the mouse but if i SET fps_max = 35; Ohhh. the map of the mouse or click and drag of the panels are made in a long delay.

My main question is: how can accelerate the speed of the drag of the bmaps that follow the mouse, including the mouse map.without the need to use fps_max


Please! Use easy words to be translated. because my English is not very good! Grateful.
_______________________________________________________
Re: speed of mouse movement! [Re: NeoNeper] #420079
03/19/13 14:09
03/19/13 14:09
Joined: May 2009
Posts: 5,367
Caucasus
3run Online
Senior Expert
3run  Online
Senior Expert

Joined: May 2009
Posts: 5,367
Caucasus
NeoNeper@ you are doing something wrong. Cause it works pretty nice on my side. BTW, if you set mouse_mode to 4, there is no need to manually move the mouse position with cursor position, that might cause the problem.


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: speed of mouse movement! [Re: 3run] #420093
03/19/13 16:22
03/19/13 16:22
Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Kartoffel Offline
Expert
Kartoffel  Offline
Expert

Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
you can use
mouse_sync = 1;

...but it looks like it only applies for the mouse cursor image, not mouse_pos - which makes it somehow useless.


POTATO-MAN saves the day! - Random
Page 1 of 2 1 2

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1