Switchable omni/non-omni weapon | |
New weapon ! proof of concept code for switching an omnidirectional turret on and off! It's a omnidirectional turbolaser cannon, when you use it, the omnidirectional turret will be deactivated and the weapon is connected to an extra capacitor (more damage) UPDATED, now the weapon retain the enhancements during the switch ! UPDATED AGAIN: Corrected the bug found by bluesaberist. ANOTHER UPDATE: Patched the code as suggested by darkjoker. Thanks ! Now the weapon is switched correctly when enhanced. AGAIN UPDATE: If weapon is damaged, it won't switch. Thanks to Oddbob for the idea/code. UPDATE: Now the weapon uses Atarlost's switching script so it works in 0.99c. |
|
Categories | Developers Vault, Weapon |
Author | digdug |
Rating | 1 0 |
Added (Last modified) | 02.01.2008 (21.06.2009) |
Game Version | 0.99c |
Filesize | 1.45 KB |
Downloads | 1857 |
Download |
Hey, this mod is great. But I found that I liked it better when I made it shoot two shots, instead of one powerful one, when it's not omni. You should maybe try that for a version two.
Thanks for the feedback bluesaberist.
If you already did it, upload it on xelerus :)
I found a bug. When I had the weapon installed, it functions as three weapons that are switchable between. When I had it unistalled, it only removed one of them. So I have two "ghost weapons" that I can use, niether of which take up a weapon slot or are removeable. One each of omni and non-omni.
I'll up load the double shooting version soon, but the only difference is the damage and adding confuration "dual" (or making a whole new config.)
May I suggest using the following code instead for weapon removal? It seems the current version cannot work well with enhanced weapons.
; Remove previous weapon
(shpRemoveDevice gSource theitem)
(objRemoveItem gSource (itmSetEnhanced (itmCreate (itmGetUNID theitem) 1) store) 1)
AGAIN UPDATE: Now the weapon won't switch if damaged (in order to prevent the player from repairing it by switching)
NOTE to me: switching code do not work in 0.99 correctly. Needs to be updated.
UPDATED! Now the weapon uses Atarlost's switching script so it works in 0.99c.
You must be logged in to post comments!