Xentales

Talk about stuff, and if you must, about Xenimus
It is currently 18 Dec 2017 16:27

All times are UTC - 5 hours [ DST ]




Post new topic Reply to topic  [ 11 posts ] 
Author Message
 Post subject: Record cursor movement.
PostPosted: 04 Sep 2017 15:27 
Offline

Joined: 03 Jan 2009 04:02
Posts: 107
I'm trying to record the cursor movement in the game. When I do it shows that the cursor should move x and y but the xenimus cursor stays still and wont move at all...Anyone know how to fix this? Is the cursor embedded into the game somehow?


Top
 Profile  
 
PostPosted: 05 Sep 2017 00:06 
Offline

Joined: 03 Jan 2009 04:02
Posts: 107
Anyone know how to find the cursor memory address??


Top
 Profile  
 
PostPosted: 05 Sep 2017 10:12 
Offline

Joined: 17 Mar 2016 20:33
Posts: 53
If you're using something like cheat engine try guessing at extremes like 0,0 and other corners of your screen when you are in full-screen mode with your screen resolution matching your display resolution.


Top
 Profile  
 
PostPosted: 06 Sep 2017 14:51 
Offline

Joined: 03 Jan 2009 04:02
Posts: 107
How would you search that on cheat engine? You can only search one value and I don't think I can insert commas


Top
 Profile  
 
PostPosted: 06 Sep 2017 16:23 
Offline

Joined: 17 Mar 2016 20:33
Posts: 53
Won't have a comma, it will be two distinct values. Search for the X and Y independently.


Top
 Profile  
 
PostPosted: 07 Sep 2017 02:36 
Offline

Joined: 03 Jan 2009 04:02
Posts: 107
K I'll try that


Top
 Profile  
 
PostPosted: 07 Sep 2017 07:57 
Offline

Joined: 17 Mar 2016 20:33
Posts: 53
Image


Top
 Profile  
 
PostPosted: 07 Sep 2017 12:04 
Offline

Joined: 05 Nov 2007 11:14
Posts: 122
Don't match it to your screen resolution, Xen runs at a static internal resolution and scales to window / screen size.

Edit: Xen UI runs at 2000 x 1200, so the mouse is at 0,0 in top left and 2000,1200 in bottom right


Top
 Profile  
 
PostPosted: 07 Sep 2017 13:41 
Offline

Joined: 17 Mar 2016 20:33
Posts: 53
Huh. Is that normal?


Top
 Profile  
 
PostPosted: 07 Sep 2017 15:04 
Offline

Joined: 05 Nov 2007 11:14
Posts: 122
Eh kinda.

Games usually have the ui as 0 to 1 as a floating point, so every resolution works. Then just move things around based on aspect ratio.

EJ just uses a static number instead of 0 to 1.

I actually found a bug in xenlua today when looking into this, xenlua thinks the mouse is moving all the time because of the quick fix to get it working again when EJ implemented this

Code:
void UIController::ProcessMouseMovement()
{
   //focused on something we can't focus on
   if (m_mousefocus != NULL && !m_mousefocus->CanInteractWithElement(UI_INTERACT_MOUSE_HOVER))
      OnMouseMove();

   //mouse element should always be top on chain
   if (*m_mouseposx != m_lastmousex || *m_mouseposy != m_lastmousey)
   {
      m_lastmousex = *m_mouseposx;
      m_lastmousey = *m_mouseposy;
      m_lastmousex = DWORD(float(m_lastmousex) / 2000 * screenWidth);
      m_lastmousey = DWORD(float(m_lastmousey) / 1200 * screenHeight);
      OnMouseMove();
   }
}


Top
 Profile  
 
PostPosted: 10 Sep 2017 02:46 
Offline

Joined: 03 Jan 2009 04:02
Posts: 107
Xenlua works? Lol it's haven't worked for me after taking a break


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group