Results 1 to 9 of 9
  1. #1
    J's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    East Coast
    Posts
    2,159
    Reputation
    379
    Thanks
    5,762
    My Mood
    In Love

    People. I have lost faith in you.

    Why doesn't ANYONE know how to offset the crosshair for combat arms!? It's been like 4 years now and all of the crosshairs on ALL of the hacks that I've seen are always off. Come on people:

    Code:
    crosshairX = (screenW / 2) - 1
    crosshairY = (screenY / 2) - 1
    DRAW YOUR DAMN CROSSHAIR AT THIS POINT!

    Thank you, that is all.

  2. The Following 3 Users Say Thank You to J For This Useful Post:

    arun823 (10-23-2013),[MPGH]Flengo (10-22-2013),xCyberxx (12-24-2013)

  3. #2
    Ch40zz-C0d3r's Avatar
    Join Date
    Apr 2011
    Gender
    male
    Posts
    839
    Reputation
    44
    Thanks
    400
    My Mood
    Twisted
    o.0
    1 is right if your line has got a size of 2, just simple math but I believe these people arround here cant even code a simple crosshair function on their own :|
    Very sad....

    Progress with my game - "Disbanded"
    • Fixed FPS lag on spawning entities due to the ent_preload buffer!
    • Edit the AI code to get some better pathfinding
    • Fixed the view bug within the sniper scope view. The mirror entity is invisible now!
    • Added a new silencer for ALL weapons. Also fixed the rotation bugs
    • Added a ton of new weapons and the choice to choose a silencer for every weapon
    • Created a simple AntiCheat, noobs will cry like hell xD
    • The name will be Disbanded, the alpha starts on the 18th august 2014



    Some new physics fun (Serversided, works on every client)



    My new AI
    http://www.youtube.com/watch?v=EMSB1GbBVl8

    And for sure my 8 months old gameplay with 2 friends
    http://www.youtube.com/watch?v=Na2kUdu4d_k

  4. #3
    J's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    East Coast
    Posts
    2,159
    Reputation
    379
    Thanks
    5,762
    My Mood
    In Love
    I don't think you know what you're saying. /fp

    Everyone's crosshair is being drawn EXACTLY in the middle of the screen. Yes, that should be sufficient because your supposed to aim EXACTLY in the middle of your screen. But Combat Arms decided to draw their crosshair 1 pixel to the left of the center, and 1 pixel above the center. /fml

  5. #4
    Ch40zz-C0d3r's Avatar
    Join Date
    Apr 2011
    Gender
    male
    Posts
    839
    Reputation
    44
    Thanks
    400
    My Mood
    Twisted
    Your line has got a width so you have to halve it and substract it from the position where you draw it.
    I cant rememeber that my crosshair was off when I drawed it like that..
    Dont tell me I dont know shit :|

    Progress with my game - "Disbanded"
    • Fixed FPS lag on spawning entities due to the ent_preload buffer!
    • Edit the AI code to get some better pathfinding
    • Fixed the view bug within the sniper scope view. The mirror entity is invisible now!
    • Added a new silencer for ALL weapons. Also fixed the rotation bugs
    • Added a ton of new weapons and the choice to choose a silencer for every weapon
    • Created a simple AntiCheat, noobs will cry like hell xD
    • The name will be Disbanded, the alpha starts on the 18th august 2014



    Some new physics fun (Serversided, works on every client)



    My new AI
    http://www.youtube.com/watch?v=EMSB1GbBVl8

    And for sure my 8 months old gameplay with 2 friends
    http://www.youtube.com/watch?v=Na2kUdu4d_k

  6. #5
    ieatyourlvllol's Avatar
    Join Date
    Jul 2009
    Gender
    male
    Posts
    50
    Reputation
    77
    Thanks
    337
    My Mood
    Aggressive
    yeah i seen a post about this before, and wont the snipers crosshair still be off anyway?? im not sure but id rather keep it dead center.

    i did make one myself....took me 10 years to make a damn box >_< lmao

    Code:
    void Crosshair(LPDIRECT3DDEVICE9 pDevice)
    {
    	if (!OneTime)
    	{
    		X = GetSystemMetrics(SM_CXSCREEN) /2;
    		Y = GetSystemMetrics(SM_CYSCREEN) /2;
    		OneTime = !false;
    	}
    	pDevice->SetRenderState(D3DRS_ZENABLE,D3DZB_FALSE);
    
    	FILLRGB(X   , Y-13,   1, +14, Red, pDevice);  //top line
    	FILLRGB(X-13, Y   , +14,   1, Red, pDevice);  //Left line
    	FILLRGB(X +1, Y   , +14,   1, Red, pDevice);  //Right line
    	FILLRGB(X   , Y +1,   1, +14, Red, pDevice);  //Bottom line
    	
    	FILLRGB(X-20, Y-20, +41,   1, Blue, pDevice);  //Top Box Line
    	FILLRGB(X-20, Y-20,   1, +41, Blue, pDevice);  //Left Side Box Line
    	FILLRGB(X+21, Y-20,   1, +41, Blue, pDevice);  //Right Side Box Line
    	FILLRGB(X-20, Y+21, +42,   1, Blue, pDevice);  //Bottom Box Line
    
    	pDevice->SetRenderState(D3DRS_ZENABLE,D3DZB_TRUE);
    }





  7. The Following User Says Thank You to ieatyourlvllol For This Useful Post:

    [MPGH]AVGN (10-22-2013)

  8. #6
    J's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    East Coast
    Posts
    2,159
    Reputation
    379
    Thanks
    5,762
    My Mood
    In Love
    Normally crosshair's are 1 pixels in width. Come on now >_>

  9. #7
    Flengo's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    Ontario, Canada
    Posts
    15,708
    Reputation
    3319
    Thanks
    11,138
    My Mood
    Happy
    I have error things undefined how I do
    I Read All Of My PM's & VM's
    If you need help with anything, just let me know.
     
     
    VM | PM

    Publicist Since 04.04.2015
    Middleman Since Unknown - Unknown
    Global Moderator Since 08.01.2013
    Donator Since 05.29.2013

    Minion+ Since 04.18.2013

    District 187 Minion Since 04.04.2013
    Steam Minion Since 02.26.2013
    WarRock Minion Since 02.19.2013
    A.V.A Minion Since 02.13.2013
    DayZ Minion Since 01.21.2013
    Combat Arms Minion Since 12.26.2012
    Contributor Since 11.16.2012
    Member Since 05.11.2010


  10. #8
    B4NDiT26's Avatar
    Join Date
    Apr 2012
    Gender
    male
    Posts
    1,010
    Reputation
    26
    Thanks
    32
    My Mood
    Shocked
    I don't think that 1 pixel make difference in aiming.

  11. #9
    arun823's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Los Angeles, California
    Posts
    524
    Reputation
    151
    Thanks
    1,887
    My Mood
    Amused
    Quote Originally Posted by J View Post
    I don't think you know what you're saying. /fp

    Everyone's crosshair is being drawn EXACTLY in the middle of the screen. Yes, that should be sufficient because your supposed to aim EXACTLY in the middle of your screen. But Combat Arms decided to draw their crosshair 1 pixel to the left of the center, and 1 pixel above the center. /fml
    Due to the fact these individuals fail to use ViewPort function or any intelligent function to receive screen size and draw according to the resolution.

    Code:
    D3DVIEWPORT9 Viewport;
    
    DWORD ScreenX = (Viewport.Width / 2) - 1;
    DWORD ScreenY = (Viewport.Height / 2) - 1;
    Should draw perfectly on any resolution now
    Last edited by arun823; 10-23-2013 at 08:59 PM.
    Reversing is the only way to move forward.

  12. The Following User Says Thank You to arun823 For This Useful Post:

    J (10-23-2013)

Similar Threads

  1. [Solved] You have lost connection to the server. Try again in a moment.
    By nate1999 in forum Combat Arms Help
    Replies: 3
    Last Post: 07-04-2013, 06:14 PM
  2. You have lost connection with the server...
    By TweaKx in forum Combat Arms Help
    Replies: 19
    Last Post: 11-14-2010, 12:09 PM
  3. Replies: 18
    Last Post: 04-23-2009, 10:56 PM
  4. You Have Lost Connection [Error: -1]
    By Raggii in forum Combat Arms Hacks & Cheats
    Replies: 6
    Last Post: 08-16-2008, 10:54 AM
  5. i have come to kill you
    By ikki in forum General
    Replies: 28
    Last Post: 10-08-2007, 10:07 PM