FAQFAQ   SearchSearch   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

#88 - [Bug] Self-Destructed Turret Removal (ADDED)

 
Post new topic   Reply to topic    Drop Shock Forum Index -> Player Council - Closed Tickets
View previous topic :: View next topic  
Author Message
Vanoi
Site Admin


Joined: 25 Aug 2005
Posts: 1403
Location: Avoiding You (The Void)

PostPosted: Mon Mar 25, 2013 11:53 am    Post subject: #88 - [Bug] Self-Destructed Turret Removal (ADDED) Reply with quote

https://sourceforge.net/p/dropshock/tickets/88/

Code:
elseif ($acti->effect == "kill") {
$unitdata[$acti->id]["is_powered"] = 'N';
$unitdata[$acti->id]["is_destroyed"] = "Y";
$unitdata[$acti->id]["i_armor"] = -1;
}


changed to

Code:
elseif ($acti->effect == "kill") {
$destroyedunits[] = $acti->id;
$unitdata[$acti->id]["is_powered"] = 'N';
$unitdata[$acti->id]["is_destroyed"] = "Y";
$unitdata[$acti->id]["i_armor"] = -1;
//Remove Attacks
$weapondata =& $db->getCol("SELECT id from deployed_weapons WHERE i_on_unit=? ",
'id', array($acti->id));
if (DB::isError($weapondata)) { ReportDBError($weapondata); }
if ( (is_array($weapondata)) AND (count($weapondata)>0) ) {
$weapondata = implode(",", $weapondata);
$sqltext ="DELETE FROM deployed_order_attack WHERE weapon_id IN (".$weapondata.") ";
$res =& $db->query($sqltext, Array() );
if (DB::isError($res)) { ReportDBError($res); }
}
unset($weapondata);
}


Otherwise AI Turrets don't remove properly for the unsalvagable removal... I added the targetting removal just 'cause
_________________
The person who will go to great lengths to fight boredom...


Last edited by Vanoi on Fri May 17, 2013 6:48 pm; edited 2 times in total
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Dark Leth
Council Member


Joined: 05 Jul 2005
Posts: 1498

PostPosted: Mon Mar 25, 2013 4:51 pm    Post subject: Reply with quote

Support.
Back to top
View user's profile Send private message
Walterohdim
Site Admin


Joined: 15 Jun 2006
Posts: 1629
Location: Somewhere with lots of doors

PostPosted: Mon Mar 25, 2013 5:12 pm    Post subject: Reply with quote

Support
_________________
Wannabee historian of Tinywarz. Through the building of myth we will build community. M. Scott Peck

Back to top
View user's profile Send private message Visit poster's website
Slayer_666
Council Member


Joined: 20 Dec 2012
Posts: 226

PostPosted: Tue Mar 26, 2013 1:00 am    Post subject: Reply with quote

Yay

Slayer
Back to top
View user's profile Send private message
krisjaniz
Mentor


Joined: 17 May 2009
Posts: 471

PostPosted: Tue Mar 26, 2013 4:33 am    Post subject: Reply with quote

YAY, remove all the turrets!
_________________
Back to top
View user's profile Send private message
sirstephen
Hopeless Romantic


Joined: 01 Jun 2008
Posts: 181

PostPosted: Wed Mar 27, 2013 8:27 pm    Post subject: Reply with quote

lol'd at kris, yea from me
Back to top
View user's profile Send private message AIM Address
Vanoi
Site Admin


Joined: 25 Aug 2005
Posts: 1403
Location: Avoiding You (The Void)

PostPosted: Fri May 17, 2013 6:47 pm    Post subject: Reply with quote

Missing the most important part of the code.

https://sourceforge.net/u/vanoi/dropshock/ci/fb2a471311b14e9dd41129ccdce4b8273542f649/
_________________
The person who will go to great lengths to fight boredom...
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Wakka
Intermediate


Joined: 24 Jan 2013
Posts: 131

PostPosted: Fri May 17, 2013 7:40 pm    Post subject: Reply with quote

Support.
Back to top
View user's profile Send private message
Walterohdim
Site Admin


Joined: 15 Jun 2006
Posts: 1629
Location: Somewhere with lots of doors

PostPosted: Sat May 18, 2013 5:36 am    Post subject: Reply with quote

support
_________________
Wannabee historian of Tinywarz. Through the building of myth we will build community. M. Scott Peck

Back to top
View user's profile Send private message Visit poster's website
corclaork
Council Member


Joined: 26 Aug 2008
Posts: 518
Location: The Mohawk Wasteland

PostPosted: Sat May 18, 2013 7:22 am    Post subject: Reply with quote

Support.

Cor
_________________
"hit or be hit"

in game name : corclark
Back to top
View user's profile Send private message
Trerro
Council Member


Joined: 11 Mar 2008
Posts: 1351

PostPosted: Sat May 18, 2013 11:19 am    Post subject: Reply with quote

Support
_________________
[quote="trumpetguy"]And if you double-integrate a BAIII does it become a BAV?[/quote]

Ok... the intergalactic beer run may have been a bad idea. Whoops!
Back to top
View user's profile Send private message Visit poster's website AIM Address
Frizz
Site Admin


Joined: 10 Jun 2005
Posts: 3814

PostPosted: Sat Sep 21, 2013 1:28 pm    Post subject: Reply with quote

Added,

_f
_________________

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Drop Shock Forum Index -> Player Council - Closed Tickets All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group