Redefinition of ProtoOfItemGiven and other stuff

Ravager69

Sonny, I Watched the Vault Bein' Built!
I've been fighting with some scripting issues lately, re-compiling to be more precise. I use FSE btw.

I take the metzger script from Fallout 2 with RP 1.2 and decompile it with int2ssl. Then I try to recompile it (without altering it at all) and get the "Error! Redefinition of ProtoOfItemGiven" message. I tried including all possible header files in the script, deleting unnecessary lines that appeared after decompiling, copying stuff from the .ssl file included in the Fallout Mapper, setting the ProtoOfItemGiven to some random value...nothing> I'd appreciate any insight on the matter while I'll try to overcome this issue on my own.

Also, is there a good decompiler which would work with Fallout files? So I won't have to waste time on such stuff as now. I tried using Ruby, but for some strange reason it just refuses to work with me (despite following MIB88's instructions to the letter).
 
delete all of this if your adding the header files(they have already been added)

Code:
variable ProtoOfItemGiven;
variable ValueOfRollCheck := 1;
variable Scenery_Creation;
variable Scenery_Creation_Hex;
variable Scenery_Creation_Count;
variable Temp_Scenery_Creation_Hex;
variable Scenery_Creation_Ptr;
variable How_Many_Party_Members_Are_Injured;
variable How_Many_Party_Members_Armed;
variable PartyHealingItem;

procedure checkPartyMembersNearDoor;

variable global_temp;
variable dest_tile;
variable step_tile;
variable in_dialog;
variable forced_node;
variable restock_amt;
variable restock_obj;
variable restock_trash;
variable removed_qty;

procedure checkPartyMembersNearDoor
begin
	if (party_member_obj(16777278) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777278)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777376) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777376)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777377) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777377)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777305) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777305)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777313) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777313)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777323) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777323)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777352) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777352)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777378) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777378)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777368) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777368)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777379) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777379)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777380) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777380)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777295) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777295)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777381) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777381)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777407) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777407)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777411) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777411)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777412) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777412)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777413) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777413)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777481) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777481)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777558) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777558)) <= 5) then begin
			return 1;
		end
	end
	if (party_member_obj(16777600) != 0) then begin
		if (tile_distance_objs(self_obj, party_member_obj(16777600)) <= 5) then begin
			return 1;
		end
	end
	return 0;
end
 
You forgot to include some additional lines to delete, but your advice worked nonetheless. Thanks I bestow upon thee and three cheers as well!
 
Back
Top