[Change] Stop firing before starting to jump into hyperspace.
This commit is contained in:
parent
4176b20749
commit
da4b261de7
@ -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
|
||||
|
2
src/ai.c
2
src/ai.c
@ -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;
|
||||
|
||||
|
@ -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);
|
||||
|
@ -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);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user