Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start resolution menu at current resolution #3801

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions game/kernel/common/kmachine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -609,6 +609,14 @@ void pc_get_resolution(u32 id, u32 for_windowed, u32 w_ptr, u32 h_ptr) {
}
}

u32 pc_get_current_height_resolution() {
return Gfx::g_global_settings.game_res_h;
}

u32 pc_get_current_width_resolution() {
return Gfx::g_global_settings.game_res_w;
}

u64 pc_is_supported_resolution(u64 width, u64 height) {
if (Display::GetMainDisplay()) {
return bool_to_symbol(
Expand Down Expand Up @@ -955,6 +963,8 @@ void init_common_pc_port_functions(
make_func_symbol_func("pc-set-window-size!", (void*)pc_set_window_size);
make_func_symbol_func("pc-get-num-resolutions", (void*)pc_get_num_resolutions);
make_func_symbol_func("pc-get-resolution", (void*)pc_get_resolution);
make_func_symbol_func("pc-get-resolution-h", (void*)pc_get_current_height_resolution);
make_func_symbol_func("pc-get-resolution-w", (void*)pc_get_current_width_resolution);
make_func_symbol_func("pc-is-supported-resolution?", (void*)pc_is_supported_resolution);

// -- INPUT RELATED --
Expand Down
7 changes: 0 additions & 7 deletions goal_src/jak1/engine/anim/joint-exploder.gc
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,13 @@
(:methods
(new (symbol type int) _type_)))


(deftype joint-exploder-static-joint-params (structure)
((joint-index int16)
(parent-joint-index int16)))


(deftype joint-exploder-static-params (basic)
((joints (array joint-exploder-static-joint-params))))


(deftype joint-exploder-joint (structure)
((next int16)
(prev int16)
Expand All @@ -41,21 +38,18 @@
(transv vector :inline)
(prev-pos vector :inline)))


(deftype joint-exploder-joints (basic)
((num-joints int32)
(joint joint-exploder-joint :inline :dynamic :offset 16))
(:methods
(new (symbol type joint-exploder-static-params) _type_)))


(deftype joint-exploder-list (structure)
((head int32)
(pre-moved? symbol)
(bbox-valid? symbol)
(bbox bounding-box :inline)))


(deftype joint-exploder (process-drawable)
((parent-override (pointer process-drawable) :overlay-at parent)
(die-if-below-y float)
Expand All @@ -79,7 +73,6 @@
(:states
joint-exploder-shatter))


(defmethod asize-of ((this joint-exploder-joints))
(the-as int (+ (-> this type size) (* 176 (-> this num-joints)))))

Expand Down
11 changes: 0 additions & 11 deletions goal_src/jak1/engine/camera/cam-layout.gc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
(debug-t float)
(debug-step float)))


(define *CAM_LAYOUT-bank*
(new 'static
'cam-layout-bank
Expand All @@ -35,7 +34,6 @@

(deftype clm-basic (basic) ())


(deftype clm-item-action (structure)
((button uint64)
(options uint64)
Expand All @@ -45,13 +43,11 @@
(parm1-basic basic :offset 24)
(parm1 symbol :overlay-at parm1-basic)))


(deftype clm-item (clm-basic)
((description string)
(button-symbol symbol)
(action clm-item-action :inline)))


(deftype clm-list-item (basic)
((description string)
(track-val symbol)
Expand All @@ -62,18 +58,15 @@
(val-parm1 symbol :overlay-at val-parm1-basic)
(actions (array clm-item-action))))


(deftype clm-list (clm-basic)
((tracker symbol)
(cur-list-item int32)
(items (array clm-list-item))))


(deftype clm (basic)
((title string)
(items (array clm-basic))))


(define *volume-point-current* 0)

(define *volume-point* (new 'debug 'vector-array 1000))
Expand All @@ -85,7 +78,6 @@
(deftype volume-descriptor-array (inline-array-class)
((data plane-volume :inline :dynamic :offset 16)))


(set! (-> volume-descriptor-array heap-base) (the-as uint 24))

(define *volume-descriptor-current* 0)
Expand All @@ -105,7 +97,6 @@
(:states
cam-layout-active))


(defun cam-layout-print ((arg0 int) (arg1 int) (arg2 string))
(let* ((s5-0 (-> *display* frames (-> *display* on-screen) frame debug-buf))
(gp-0 (-> s5-0 base)))
Expand Down Expand Up @@ -299,7 +290,6 @@
(axis vector)
(disp string)))


(defun interp-test ((arg0 (function vector vector vector float vector float none)) (arg1 interp-test-info))
(let ((s3-0 (new-stack-vector0))
(gp-0 (new-stack-vector0)))
Expand Down Expand Up @@ -1446,7 +1436,6 @@
(force-on int32)
(force-off int32)))


(defbehavior clmf-cam-flag-toggle cam-layout ((arg0 int) (arg1 int))
(let ((s4-0 (/ arg0 8))
(gp-0 (new 'stack 'clmf-cam-flag-toggle-info)))
Expand Down
2 changes: 0 additions & 2 deletions goal_src/jak1/engine/camera/cam-master.gc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
(down-move-to-pitch-on-ground float)
(pitch-off-blend float)))


(define *CAMERA_MASTER-bank*
(new 'static
'camera-master-bank
Expand Down Expand Up @@ -958,7 +957,6 @@
(deftype list-keeper (process)
((dummy float)))


(defstate list-keeper-active (camera-master)
:code
(behavior ()
Expand Down
5 changes: 0 additions & 5 deletions goal_src/jak1/engine/camera/cam-states-dbg.gc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
((speed float)
(rot-speed degrees)))


(define *CAM_POINT_WATCH-bank* (new 'static 'cam-point-watch-bank :speed 1600.0 :rot-speed (degrees 0.6)))

(defstate cam-point-watch (camera-slave)
Expand Down Expand Up @@ -64,7 +63,6 @@
((speed float)
(rot-speed degrees)))


(define *CAM_FREE-bank* (new 'static 'cam-free-bank :speed 1600.0 :rot-speed (degrees 0.6)))

(defun cam-free-floating-input ((arg0 vector) (arg1 vector) (arg2 symbol) (arg3 int))
Expand Down Expand Up @@ -253,7 +251,6 @@
(up vector :inline)
(tm matrix :inline)))


(defun cam-free-floating-move ((arg0 matrix) (arg1 vector) (arg2 vector) (arg3 int))
(if (logtest? (-> *cpad-list* cpads arg3 valid) 128) (return (the-as vector #f)))
(if (= *master-mode* 'menu) (return (the-as vector #f)))
Expand Down Expand Up @@ -301,14 +298,12 @@
(orbit-off vector :inline)
(radius-lerp float)))


(deftype CAM_ORBIT-bank (basic)
((RADIUS_MAX float)
(RADIUS_MIN float)
(TARGET_OFF_ADJUST float)
(ORBIT_OFF_ADJUST float)))


(define *CAM_ORBIT-bank*
(new 'static 'CAM_ORBIT-bank :RADIUS_MAX 61440.0 :RADIUS_MIN 409.6 :TARGET_OFF_ADJUST 81.92 :ORBIT_OFF_ADJUST 81.92))

Expand Down
8 changes: 0 additions & 8 deletions goal_src/jak1/engine/camera/cam-states.gc
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,6 @@
(max-fov float)
(min-fov float)))


(define *CAM_EYE-bank*
(new 'static 'cam-eye-bank :rot-speed 364.0889 :max-degrees 12743.111 :max-fov 11650.845 :min-fov 6189.511))

Expand Down Expand Up @@ -354,7 +353,6 @@
((rot-speed float)
(tilt-degrees float)))


(define *CAM_BILLY-bank* (new 'static 'cam-billy-bank :rot-speed 364.0889 :tilt-degrees -1820.4445))

(defstate cam-billy (camera-slave)
Expand Down Expand Up @@ -750,7 +748,6 @@
((los-coll-rad meters)
(los-coll-rad2 meters)))


(define *CAM_STRING-bank* (new 'static 'cam-string-bank :los-coll-rad (meters 1) :los-coll-rad2 (meters 0.5)))

(defun cam-string-find-position-rel! ((arg0 vector))
Expand Down Expand Up @@ -820,7 +817,6 @@
(lat-dist float)
(vert-dist float)))


(deftype collide-los-dist-info (structure)
((min-par float)
(max-par float)
Expand All @@ -832,7 +828,6 @@
(max-vn float)
(count int32)))


(defun dist-info-init ((arg0 collide-los-dist-info))
(set! (-> arg0 min-par) 1.0)
(set! (-> arg0 max-par) 0.0)
Expand Down Expand Up @@ -898,7 +893,6 @@
(straddle collide-los-dist-info :inline)
(lateral-valid symbol)))


(defun los-cw-ccw ((arg0 (inline-array collide-cache-tri))
(arg1 vector)
(arg2 vector)
Expand Down Expand Up @@ -1735,7 +1729,6 @@
(max-y meters)
(min-y meters)))


(define *CAM_STICK-bank*
(new 'static 'cam-stick-bank :max-z (meters 30) :min-z (meters 5) :max-y (meters 15) :min-y (meters 2)))

Expand Down Expand Up @@ -1873,7 +1866,6 @@
(max-y meters)
(min-y meters)))


(define *CAM_BIKE-bank*
(new 'static 'cam-bike-bank :max-z (meters 6) :min-z (meters 10) :max-y (meters 3) :min-y (meters 5)))

Expand Down
Loading
Loading