summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorepoch <epoch@thebackupbox.net>2020-04-14 06:09:59 -0500
committerepoch <epoch@thebackupbox.net>2020-04-14 06:09:59 -0500
commitb459d3c8c98e5ca7b62a1a5677e5594b146ff84d (patch)
tree306082e6d4a6fc12539351f35f62ac2d6d63ee23 /src
parent5645a847566870877c026f58c80732599136a6ab (diff)
downloadhackvr-b459d3c8c98e5ca7b62a1a5677e5594b146ff84d.tar.gz
hackvr-b459d3c8c98e5ca7b62a1a5677e5594b146ff84d.zip
now draw a cursor at the mouse location. useful in the fb version
Diffstat (limited to 'src')
-rw-r--r--src/graphics_c3.c11
-rw-r--r--src/graphics_c3.h1
2 files changed, 9 insertions, 3 deletions
diff --git a/src/graphics_c3.c b/src/graphics_c3.c
index 98c2c25..2af58d7 100644
--- a/src/graphics_c3.c
+++ b/src/graphics_c3.c
@@ -483,11 +483,16 @@ void draw_screen() {
//this should be minimap shit
//draw a line from the center to 80 away from the center in the angle of what should point at the mouse.
- /*draw_c2_line((c2_t){0,0},gra_global.mouse);
+ //draw_c2_line((c2_t){0,0},gra_global.mouse);
+ set_color();
+ draw_c2_line(c2_add(gra_global.mouse,(c2_t){0,1}) , c2_add(gra_global.mouse,(c2_t){0,5}) );
+ draw_c2_line(c2_add(gra_global.mouse,(c2_t){0,-1}) , c2_add(gra_global.mouse,(c2_t){0,-5}) );
+ draw_c2_line(c2_add(gra_global.mouse,(c2_t){1,0}) , c2_add(gra_global.mouse,(c2_t){5,0}) );
+ draw_c2_line(c2_add(gra_global.mouse,(c2_t){-1,0}) , c2_add(gra_global.mouse,(c2_t){-5,0}) );
set_color();
//if(points_on_same_side_of_line(gra_global.mouse,(c2_t){80,80},(c2_t){0,0},(c2_t){0,80})) {
- draw_c2_line((c2_t){0,0},rotate_c2((c2_t){80,0},(c2_t){0,0},points_to_angle((c2_t){0,0},gra_global.mouse)));
- //}*/
+ //draw_c2_line((c2_t){0,0},rotate_c2((c2_t){80,0},(c2_t){0,0},points_to_angle((c2_t){0,0},gra_global.mouse)));
+ //}
flipscreen();
}
diff --git a/src/graphics_c3.h b/src/graphics_c3.h
index 3f9fb78..7ea5c74 100644
--- a/src/graphics_c3.h
+++ b/src/graphics_c3.h
@@ -2,6 +2,7 @@
#define _HACKVR_GRAPHICS_H_
#include <idc.h>
+#include "common.h"
struct gra_global {
unsigned int width;