View Issue Details

IDProjectCategoryView StatusLast Update
0002902FSSCPHUDpublic2023-01-30 17:23
Reporterkopachris Assigned ToMjnMixael  
PrioritylowSeveritytweakReproducibilityhave not tried
Status closedResolutionno change required 
Summary0002902: Player engine loop uses forward velocity for volume
DescriptionIn hud.cpp, update_throttle_sound() uses forward velocity to determine what volume the engine loop sound should play at in most cases. Now that we have the ability to use semi-Newtonian physics (as in e.g. Diaspora), we should always use forward thrust to determine engine volume. Otherwise, we end up with no engine volume even when the engine should be working at full thrust.
Additional InformationOrigin: http://www.hard-light.net/forums/index.php?topic=85028.msg1699748

I went ahead and made the change and have attached the patch.
TagsNo tags attached.

Activities

kopachris

2013-07-13 03:02

reporter  

fs2_use_thrust_for_snd.patch (918 bytes)   
Index: hud.cpp
===================================================================
--- hud.cpp	(revision 9729)
+++ hud.cpp	(working copy)
@@ -1886,15 +1886,9 @@
 	if ( timestamp_elapsed(throttle_sound_check_id) ) {
 
 		throttle_sound_check_id = timestamp(THROTTLE_SOUND_CHECK_INTERVAL);
-	
-		if ( object_get_gliding(Player_obj) ) {	// Backslash
-			percent_throttle = Player_obj->phys_info.forward_thrust;
-		} else if ( Ships[Player_obj->instance].current_max_speed == 0 ) {
-			percent_throttle = Player_obj->phys_info.fspeed / Ship_info[Ships[Player_obj->instance].ship_info_index].max_speed;
-		} else {
-			percent_throttle = Player_obj->phys_info.fspeed / Ships[Player_obj->instance].current_max_speed;
-		}
 
+		percent_throttle = Player_obj->phys_info.forward_thrust;
+
 		if ( percent_throttle != last_percent_throttle || Player_engine_snd_loop == -1 ) {
 
 			if ( percent_throttle < ZERO_PERCENT ) {

MjnMixael

2023-01-26 23:10

manager   ~0017150

Last edited: 2023-01-26 23:10

I was looking at implementing this one, but it's unclear based on the request, the attached patch, and the linked conversation what is wanted that's different from normal behavior.

It looks like if ships have glide then the game already uses thrust over speed to set the sound. The attached patch actually removes the other options used by retail/most mods.

Given all of that and that the original requester has been inactive since the day after this was filed almost ten years ago AND that a similar request hasn't come up since then, I'd be in favor of closing this. I will do so in a few days if no one objects.

Issue History

Date Modified Username Field Change
2013-07-13 03:02 kopachris New Issue
2013-07-13 03:02 kopachris File Added: fs2_use_thrust_for_snd.patch
2023-01-26 23:10 MjnMixael Note Added: 0017150
2023-01-26 23:10 MjnMixael Note Edited: 0017150
2023-01-30 17:23 MjnMixael Assigned To => MjnMixael
2023-01-30 17:23 MjnMixael Status new => closed
2023-01-30 17:23 MjnMixael Resolution open => no change required