rafalh / dashfaction

A community patch for the Red Faction (2001) FPS game
https://www.factionfiles.com/ff.php?action=file&id=6252
Mozilla Public License 2.0
61 stars 11 forks source link

Alias spectate command to camera2 in SP, add help strings for cheat commands #287

Open GooberRF opened 1 month ago

GooberRF commented 1 month ago

This PR:

Resolves #206

is-this-c commented 1 month ago

Personally I do not see usefulness especially for camera1 camera2 camera3 and heehoo.

GooberRF commented 1 month ago

Personally I do not see usefulness especially for camera1 camera2 camera3 and heehoo.

is-this-c commented 1 month ago

I do not like check_can_use_cheat_cmd. It can print to console but it is supposed to be just a check. It also checks if the level is loaded which should not be part of its scope.

Further handle_camera_command can be simplified. It does not need to take mode. It can call call_target and then check the camera mode.

cameraX: With the amount of times I've heard people (even relatively experienced players) make comments like "wait, how do I get back to first person?" after entering camera2 or camera3, I have absolutely no reservations about adding help strings that do nothing but simply inform those who may be unaware.

. cmd exists.

GooberRF commented 1 month ago

It can print to console but it is supposed to be just a check.

Good point, fixed.

It also checks if the level is loaded which should not be part of its scope.

I disagree. It's a relevant factor and while the original game does not, it is vastly more intuitive to tell a player who enters a command why that command had no effect, rather than simply telling them nothing.

Further handle_camera_command can be simplified. It does not need to take mode. It can call call_target and then check the camera mode.

Good point as well, I've refactored that code to address this.

. cmd exists.

It does, and I'm a huge fan of it. It does not, however, serve even a somewhat similar purpose or address the same issue that this PR does.