mirror of
https://github.com/open-goal/jak-project
synced 2026-07-07 14:13:45 -04:00
Hook Jak 1 into ImGUI actor filter (#2157)
This commit is contained in:
@@ -646,6 +646,9 @@ void InitMachine_PCPort() {
|
||||
// profiler
|
||||
make_function_symbol_from_c("pc-prof", (void*)prof_event);
|
||||
|
||||
// debugging tools
|
||||
make_function_symbol_from_c("pc-filter-debug-string?", (void*)pc_filter_debug_string);
|
||||
|
||||
// init ps2 VM
|
||||
if (VM::use) {
|
||||
make_function_symbol_from_c("vm-ptr", (void*)VM::get_vm_ptr);
|
||||
|
||||
@@ -548,6 +548,14 @@
|
||||
(defun-debug add-debug-text-3d ((arg0 symbol) (arg1 bucket-id) (arg2 string) (arg3 vector) (arg4 font-color) (arg5 vector2h))
|
||||
"Draw text at the given point. arg4 is the font-color index. arg5 is an offset and can be #f."
|
||||
(when arg0
|
||||
(#when PC_PORT
|
||||
;; Check to see if the string should be filtered or not
|
||||
(when (pc-filter-debug-string? arg2 (vector-vector-distance arg3 (target-pos 0)))
|
||||
;;(format #t "got: ~S~%" arg2)
|
||||
;; no-op the function!
|
||||
(return #f)
|
||||
)
|
||||
)
|
||||
(cond
|
||||
(*debug-draw-pauseable*
|
||||
(let ((v1-2 (get-debug-text-3d)))
|
||||
|
||||
@@ -391,3 +391,4 @@
|
||||
;; These were made by us.
|
||||
|
||||
(define-extern vm-ptr (function int pointer))
|
||||
(define-extern pc-filter-debug-string? (function string float symbol))
|
||||
|
||||
Reference in New Issue
Block a user