[Change] Stop firing before starting to jump into hyperspace.

This commit is contained in:
Allanis 2013-12-06 20:59:24 +00:00
parent 4176b20749
commit da4b261de7
4 changed files with 8 additions and 7 deletions

View File

@ -174,10 +174,6 @@ function final_talk()
-- ESS Trinity becomes collective now.
trinity:setFaction("Collective")
-- Some music.
music.load("galacticbattle")
music.play()
final_fight = 3
misn.timerStart("final_talk", rnd.int(4000, 5000))
else if final_fight == 3 then

View File

@ -929,6 +929,8 @@ static int ai_getlandplanet(lua_State* L) {
static int ai_hyperspace(lua_State* L) {
int dist;
pilot_shootStop(cur_pilot, 0);
pilot_shootStop(cur_pilot, 1);
dist = space_hyperspace(cur_pilot);
if(dist == 0.) return 0;

View File

@ -245,9 +245,9 @@ void pilot_shootStop(Pilot* p, const int secondary) {
}
}
} else { /* Secondary weapons. */
o = p->secondary->outfit;
if(p->secondary == NULL) return; /* No secondary weapon. */
if(o == NULL) return; /* No secondary weapon. */
o = p->secondary->outfit;
if(outfit_isBeam(o) && (p->secondary->beamid > 0)) {
beam_end(p->id, p->secondary->beamid);

View File

@ -1728,8 +1728,11 @@ void player_jump(void) {
player_message("You are moving too fast to enter hyperspace.");
else if(i == -3)
player_message("You do not have enough fuel to hyperspace jump.");
else
else {
player_message("Preparing for hyperspace.");
pilot_shootStop(player, 0);
pilot_shootStop(player, 1);
}
}
/**