Sewer Scenarios Mod

Post » Mon May 06, 2013 8:40 pm

**This mod requires both The Scorchers DLC and The Sewers preorder DLC**


This mod adds the Sewer missions to the Scenario list, both versions, so it essentially adds 18 short scenarios to the end of the scenario list that can be played on any difficulty and with a choice of 3 loadouts

Updated link to v1.1 (27/03/2013)

https://docs.google.com/file/d/0B8oe-HhxJ93QQ1RQa3VyQ2k3OUE/edit?usp=sharing

Updates
  • Sewer loot missions are now marked complete when the player touches the skulls on sticks model at the loot piles normal location.
Fixes
  • VMTR Issue with nailgun, nailgun is now displayed correctly in the mod.
  • VMTR Issue with scenario map and loadout images, these are now displayed correctly.
As ever, If you find any bugs let me know so I can try get it fixed.
User avatar
Chris Johnston
 
Posts: 3392
Joined: Fri Jul 07, 2006 12:40 pm

Post » Mon May 06, 2013 8:24 pm

Would you in the future make some other addons that doesn't require scorchers dlc (I can't reach it in my country )?
User avatar
Soku Nyorah
 
Posts: 3413
Joined: Tue Oct 17, 2006 1:25 pm

Post » Tue May 07, 2013 8:06 am

Yeah definitely. I just made this one because I thought the sewer jobs should be in the scenario listings, but the scenario mode was only made available with the scorchers dlc unfortunately, so this mod needs it.

Hopefully my other mods won't need any of the dlcs though.
User avatar
Emma Parkinson
 
Posts: 3401
Joined: Wed Jul 26, 2006 5:53 pm

Post » Mon May 06, 2013 7:07 pm

I got all dlc except this one (scorchers) I hope in the future it will be available at my country
User avatar
Mario Alcantar
 
Posts: 3416
Joined: Sat Aug 18, 2007 8:26 am

Post » Mon May 06, 2013 6:44 pm

I've updated the mod and the first post to a version 1.1

I managed to set up the sewer loot missions so that even though the loot pile isn't spawned in scenario mode the job is marked complete when the player touches the maps skeleton_pile_x entity (or more specifically, when they get to within a really short range of it).

This behaviour is entirely handled by the main_script.script which is a good example of how we can effect how maps play even without access to the maps files themselves.

The script itself has 2 main parts to it. First there's:
if ( !sys.getGameStateInt("gamestateint/wasteland1/intro/dan_waitforcarentrance") ){  sys.print("^2Player never rode in Dans Buggy... probably a scenario spawn, checking maps...\n");  string thisMap = sys.getMapPath();  sys.wait(3);  if ( (thisMap == "game/wasteland1/sewer_level_01/") && ($player1.isJobInProgress( @job ("jobs/wasteland1/sewer_1")))){   fixSewers("breakable/skeleton_pile_607", ( @job ("jobs/wasteland1/sewer_1" )));  }else if ( (thisMap == "game/wasteland1/sewer_level_02/") && ($player1.isJobInProgress( @job ("jobs/wasteland1/sewer_2")))){   fixSewers("breakable/skeleton_pile_614", ( @job ("jobs/wasteland1/sewer_2" )));  }else if ( (thisMap == "game/wasteland1/sewer_level_03/") && ($player1.isJobInProgress( @job ("jobs/wasteland1/sewer_3")))){   fixSewers("breakable/skeleton_pile_489", ( @job ("jobs/wasteland1/sewer_3" )));  }else if ( (thisMap == "game/wasteland1/sewer_level_04/") && ($player1.isJobInProgress( @job ("jobs/wasteland1/sewer_4")))){   fixSewers("breakable/skeleton_pile_882", ( @job ("jobs/wasteland1/sewer_4" )));  }else if ( (thisMap == "game/wasteland1/sewer_level_05/") && ($player1.isJobInProgress( @job ("jobs/wasteland1/sewer_5")))){   fixSewers("breakable/skeleton_pile_813", ( @job ("jobs/wasteland1/sewer_5" )));  }else if ( (thisMap == "game/wasteland1/sewer_level_06/") && ($player1.isJobInProgress( @job ("jobs/wasteland1/sewer_6")))){   fixSewers("breakable/skeleton_pile_582", ( @job ("jobs/wasteland1/sewer_6" )));  }else if ( (thisMap == "game/wasteland1/sewer_level_07/") && ($player1.isJobInProgress( @job ("jobs/wasteland1/sewer_7")))){   fixSewers("breakable/skeleton_pile_787", ( @job ("jobs/wasteland1/sewer_7" )));  }else if ( (thisMap == "game/wasteland2/sewer_level_08/") && ($player1.isJobInProgress( @job ("jobs/wasteland2/sewer_8")))){   fixSewers("breakable/skeleton_pile_1082", ( @job ("jobs/wasteland2/sewer_8" )));  }else if ( (thisMap == "game/wasteland2/sewer_level_09/") && ($player1.isJobInProgress( @job ("jobs/wasteland2/sewer_9")))){   fixSewers("breakable/skeleton_pile_857", ( @job ("jobs/wasteland2/sewer_9" )));  }else {   sys.print("^2No Match for map AND in-progress job. Not one of the sewer scenarios, the current Map is :" + thisMap + "\n");  }}
This block is inside the script_main() function (ok, it really should be a separate function or even two functions). It checks that the gamestateint for Dans initial entrance cue is 0, during normal gameplay this should always be 1 ( I think). I've used the check as a basic "Is it a scenario load?" check.

The next block is a set of if statements checking if the loaded map and job in progress match our specific sewer level requirements and if they do it calls the function fixSewers, passing it the name of the breakable/skeleton_pile entity for the map and the loot job for the map.

The fixSewers function contains:
void fixSewers(string skullsName,decl job){entity skulls = sys.getEntity( skullsName );string jobName = sys.getDeclName(job);if (sys.isEntityValid(skulls)){  sys.println("^2Success: ^0Skulls on sticks model found " + skullsName );  if ( sys.isValidDecl( job ) ){   while( $player1.isJobInProgress( job)){	sys.wait(3);	while (( $player1.distanceTo( skulls) <= 400) && ( $player1.isJobInProgress( job))){	 sys.wait(0.2);	 if (( $player1.distanceTo( skulls) <= 75) && ( $player1.isJobInProgress( job))){	  sys.println("^2Success: ^0Player touched Skulls on Sticks model \"" + skullsName +"\"");	  sys.print("^2Success: ^0Marking Job \""+ jobName + "\" complete");	  $player1.completeJob( job );	  sys.trigger( skulls, $player1);	 }	}   }  } else {   sys.print("^2Error: ^0Job Decl \""+ jobName + "\" not found, unable to complete job");  }}else{  sys.print("^2Error: ^0Skulls on Sticks model \""+ skullsName + "\" not found");}
This function checks that the name of the skulls on sticks model is correct and that the entity is in the map, and that the job passed is a real job. While the players distance from the skulls entity is &--#62; 400 it waits for 3 seconds then checks again, once the player gets to within 400 units of the entity the wait period between checks is decreased to 0.2 seconds. Finally once the player gets within 75 units of the entity the job is marked complete (so the player can leave the scenario map) and the entity is triggered (which triggers it's fade animation).
User avatar
J.P loves
 
Posts: 3487
Joined: Thu Jun 21, 2007 9:03 am


Return to Othor Games