2019-10-14 13:27 EDT


View Issue Details Jump to Notes ] Related Changesets ]
IDProjectCategoryView StatusLast Update
0003023FSSCPuser interfacepublic2014-04-28 07:22
ReporterYarn 
Assigned ToYarn 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
Platformx64OSWindows 7OS Version
Product Version3.7.1 
Target VersionFixed in Version3.7.1 
Summary0003023: [patch] Fix for Vasudan heads cheat
DescriptionCurrently, the heads cheat (activated by typing "humanheadsinside.", including the period, at the Vasudan main hall) does not work properly because the graphic and sound changes are done during mainhall.tbl parsing.

The attached patch fixes this by moving this function from parse_main_hall_table() to main_hall_init(). It also checks the name of the background bitmap 1) to check whether the current main hall is really compatible with the cheat, and 2) to pick the appropriate background bitmap and options animation.
Additional InformationIt's probably a better idea to make this customizable in mainhall.tbl. If such a thing is desirable, I think I can code that up.
TagsNo tags attached.
Attached Files
  • patch file icon VasudanHeadsFix.patch (2,123 bytes) 2014-03-18 16:56 -
    Index: code/menuui/mainhallmenu.cpp
    ===================================================================
    --- code/menuui/mainhallmenu.cpp	(revision 10506)
    +++ code/menuui/mainhallmenu.cpp	(working copy)
    @@ -445,6 +445,29 @@
     	// init tooltip shader						// nearly black
     	gr_create_shader(&Main_hall_tooltip_shader, 5, 5, 5, 168);
     
    +	// are we funny?
    +	if (Vasudan_funny && main_hall_is_vasudan()) {
    +		if (!stricmp(Main_hall->bitmap.c_str(), "vhall")) {
    +			Main_hall->door_sounds.at(OPTIONS_REGION).at(0) = SND_VASUDAN_BUP;
    +			Main_hall->door_sounds.at(OPTIONS_REGION).at(1) = SND_VASUDAN_BUP;
    +			
    +			// set head anim. hehe
    +			Main_hall->door_anim_name.at(OPTIONS_REGION) = "vhallheads";
    +			
    +			// set the background
    +			Main_hall->bitmap = "vhallhead";
    +		} else if (!stricmp(Main_hall->bitmap.c_str(), "2_vhall")) {
    +			Main_hall->door_sounds.at(OPTIONS_REGION).at(0) = SND_VASUDAN_BUP;
    +			Main_hall->door_sounds.at(OPTIONS_REGION).at(1) = SND_VASUDAN_BUP;
    +			
    +			// set head anim. hehe
    +			Main_hall->door_anim_name.at(OPTIONS_REGION) = "2_vhallheads";
    +			
    +			// set the background
    +			Main_hall->bitmap = "2_vhallhead";
    +		}
    +	}
    +
     	// load the background bitmap
     	Main_hall_bitmap = bm_load(Main_hall->bitmap);
     	if (Main_hall_bitmap < 0) {
    @@ -2065,23 +2088,6 @@
     		count++;
     	}
     
    -	// are we funny?
    -	if (Vasudan_funny) {
    -		int hall = main_hall_id();
    -
    -		Main_hall_defines.at(GR_640).at(hall).door_sounds.at(OPTIONS_REGION).at(0) = SND_VASUDAN_BUP;
    -		Main_hall_defines.at(GR_640).at(hall).door_sounds.at(OPTIONS_REGION).at(1) = SND_VASUDAN_BUP;
    -		Main_hall_defines.at(GR_1024).at(hall).door_sounds.at(OPTIONS_REGION).at(0) = SND_VASUDAN_BUP;
    -		Main_hall_defines.at(GR_1024).at(hall).door_sounds.at(OPTIONS_REGION).at(1) = SND_VASUDAN_BUP;
    -
    -		// set head anim. hehe
    -		Main_hall_defines.at(GR_1024).at(hall).door_anim_name.at(OPTIONS_REGION) = "2_vhallheads";
    -
    -		// set the background
    -		Main_hall_defines.at(GR_640).at(hall).bitmap = "vhallhead";
    -		Main_hall_defines.at(GR_1024).at(hall).bitmap = "2_vhallhead";
    -	}
    -
     	// free up memory from parsing the mainhall tbl
     	stop_parse();
     }
    
    patch file icon VasudanHeadsFix.patch (2,123 bytes) 2014-03-18 16:56 +

-Relationships
+Relationships

-Notes

~0015676

The_E (administrator)

Fix committed to trunk@10519.

~0015717

niffiwan (developer)

Attribution
+Notes

+Related Changesets

-Issue History
Date Modified Username Field Change
2014-03-18 16:56 Yarn New Issue
2014-03-18 16:56 Yarn File Added: VasudanHeadsFix.patch
2014-03-23 11:39 The_E Changeset attached => fs2open trunk r10519
2014-03-23 11:39 The_E Note Added: 0015676
2014-03-23 11:39 The_E Status new => resolved
2014-03-23 11:39 The_E Resolution open => fixed
2014-04-28 07:22 niffiwan Assigned To => Yarn
2014-04-28 07:22 niffiwan Note Added: 0015717
2014-04-28 07:22 niffiwan Status resolved => feedback
2014-04-28 07:22 niffiwan Resolution fixed => reopened
2014-04-28 07:22 niffiwan Status feedback => resolved
2014-04-28 07:22 niffiwan Fixed in Version => 3.7.1
2014-04-28 07:22 niffiwan Resolution reopened => fixed
+Issue History