Fixed instant-move towards the current location.
git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@2808 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
Changes towards version 0.7:
|
Changes towards version 0.7:
|
||||||
|
- (debugging) Fixed instant-move towards the current location - SvdB
|
||||||
- Fixed wrong Sa-Matra guards icons after Kohr-Ah win (bug #1001) - Alex
|
- Fixed wrong Sa-Matra guards icons after Kohr-Ah win (bug #1001) - Alex
|
||||||
- Internal ship structures and queues refactoring and cleanup - Alex
|
- Internal ship structures and queues refactoring and cleanup - Alex
|
||||||
- Fix quitting out of IP before the IP is fully set (bug #987) - Michael
|
- Fix quitting out of IP before the IP is fully set (bug #987) - Michael
|
||||||
|
|||||||
@@ -365,8 +365,19 @@ void
|
|||||||
doInstantMove (void)
|
doInstantMove (void)
|
||||||
{
|
{
|
||||||
// Move to the new location:
|
// Move to the new location:
|
||||||
GLOBAL_SIS (log_x) = UNIVERSE_TO_LOGX((GLOBAL (autopilot)).x);
|
if ((GLOBAL (autopilot)).x == ~0 || (GLOBAL (autopilot)).y == ~0)
|
||||||
GLOBAL_SIS (log_y) = UNIVERSE_TO_LOGY((GLOBAL (autopilot)).y);
|
{
|
||||||
|
// If no destination has been selected, use the current location
|
||||||
|
// as the destination.
|
||||||
|
(GLOBAL (autopilot)).x = LOGX_TO_UNIVERSE(GLOBAL_SIS (log_x));
|
||||||
|
(GLOBAL (autopilot)).y = LOGY_TO_UNIVERSE(GLOBAL_SIS (log_y));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// A new destination has been selected.
|
||||||
|
GLOBAL_SIS (log_x) = UNIVERSE_TO_LOGX((GLOBAL (autopilot)).x);
|
||||||
|
GLOBAL_SIS (log_y) = UNIVERSE_TO_LOGY((GLOBAL (autopilot)).y);
|
||||||
|
}
|
||||||
|
|
||||||
// Check for a solar systems at the destination.
|
// Check for a solar systems at the destination.
|
||||||
if (GET_GAME_STATE (ARILOU_SPACE_SIDE) <= 1)
|
if (GET_GAME_STATE (ARILOU_SPACE_SIDE) <= 1)
|
||||||
|
|||||||
Reference in New Issue
Block a user