WhiteListv2
Addict
- Joined
- Sep 6, 2018
- Posts
- 173
- Reaction
- 37
- Points
- 105
- Age
- 34
Code:
#include<Windows.h>
voidCrosshair(int iLength,int iWidth,DWORD dwColour);bool bDrawCrosshair=true;
int main(){while(!GetAsyncKeyState(VK_ESCAPE)){if(GetAsyncKeyState(VK_F2)&1){
bDrawCrosshair=!bDrawCrosshair;}if(bDrawCrosshair){Crosshair(100,4,0x888888);//change the arguments of this call to get the crosshair like you want it to be}}}
voidCrosshair(int iLength,int iThickness,DWORD dwColour){
HDC hDC=GetDC(NULL);int iSW,iSH;
iSH=GetSystemMetrics(1)/2;
iSW=GetSystemMetrics(0)/2;for(int i=-iThickness/2;i!=iThickness/2+1;++i){for(int j=0;j!=iLength;++j){SetPixel(hDC,iSW+i,iSH-iLength/2+j,dwColour);SetPixel(hDC,iSW-iLength/2+j,iSH+i,dwColour);}}}
CREDIT BY:JASPER