|
Star Wolves 3D space RPG with deep strategy and tactical elements |
|
Thread Tools | Display Modes |
#11
|
|||
|
|||
Sorry guys, was out this weekend, missed this thread.
@Guomindong: you don't want to edit AI.ini because those are global parameters. Well, unless you want to make global changes You were correct, explosion radius for each missile is inside Rockets.xml. However, you must look at the detonator's radius instead of the one for the missile. Each missile has a definition and a detonation, that's how they work. For easy stuff like damage and radius you just edit the detonation. You can refer to this post here or the other posts in that thread. I was working on some "bowling ball" missiles which bump a ship far away instead of inflicting much damage, but it got funny and weird when you kick capital ships away lol. |
#12
|
|||
|
|||
Quote:
E.G. The explosion_distance on LRM's is between 1.5 and 5. The explosion distance on a MIRV cluster is 20. Yes, this parameter is on the detonator MIRV clusters do not deal damage in a radius >10 times larger than LRMs. Rather they explode >10 times further away from their target to release their payload. This is how rockets work From Modules: This describes where it pulls descriptions, how the module fits into the module slots, cost, acceptable range of fire, angle of fire, etc Code:
<HomingRocket name="LRM2"> <short_name>#M_Name_LRM2</short_name> <hint>#M_Hint_LRM2</hint> <short_desc>#M_SDesc_LRM2</short_desc> <long_desc>#M_LDesc_LRM2</long_desc> <mesh_name>Rl_lrm2</mesh_name> <flat_image>missile_LRM2</flat_image> <hit_points>10000</hit_points> <mass>5</mass> <disable_trade/> <cost>350</cost> <technology/> <attach_type/> <recharge_time>6</recharge_time> <viewing_angle>20</viewing_angle> <dispersion>1</dispersion> <min_distance>20</min_distance> <max_distance>450</max_distance> <max_rocket_count>2</max_rocket_count> <seeking_time>3</seeking_time> <RocketParams> <rocket_name>LRM2_M</rocket_name> <seeker_name>Seeker_B</seeker_name> <detonator_name>ALR_det</detonator_name> </RocketParams> From Rockets Code:
<RocketCarcass name="LRM2_M"> <short_name>#M_Name_LRM2</short_name> <hint>#M_Hint_LRM2</hint> <short_desc/> <long_desc>#M_Hint_LRM2</long_desc> <mesh_name>small_rocket</mesh_name> <flat_image/> <hit_points>10</hit_points> <mass>50</mass> <disable_trade/> <cost/> <technology/> <EPR>0.05</EPR> <explosion_script>rocket_explosion</explosion_script> <work_sound/> <silence/> <max_speed>35</max_speed> <steering_power>0.3</steering_power> </RocketCarcass> And Code:
<DistanceDetonator name="ALR_det"> <time_to_live>35</time_to_live> <damage>200</damage> <explosion_distance>1.5</explosion_distance> </DistanceDetonator> Explosion distance is NOT the size of the explosion. Testing this is easier. Set that value to 20, watch as no missile you launch does any damage. Now change it back to 1.5 and then change damage to 2000. Watch as any missile you launch destroys multiple wings. The size of the explosion is entirely determined by the damage of the explosion. This is why you can modify SRMs to be MIRVs. Because each individual missile would do a small amount of damage and so the entire explosion would not be large. Otherwise, if you say, increase the damage of all SRMs by a factor of 3, you will get missiles that do huge amounts of damage with huge AoE. This is what i was trying to avoid. The AoE. and Code:
<HomingSeeker name="Seeker_B"> <accuracy>3</accuracy> <anti_jammer>20</anti_jammer> </HomingSeeker> In general you can mix and match any of these to create a missile you want. You can also change the detonator type to ImpactDetonator but that is not recommended (it works just fine) since that makes missiles that are shot down explode on their own. This is both very strong (enemies that shoot missiles at you when you have active Anti-Missile up generally tend to explode very fast) but very bad. Enemies that are close to you and shoot missiles will have the anti-missile blow you both up. Such, if you want to modify the radius of damage from the explosion you have to do it through AI.ini or some other method which I have not encountered yet. The only question is what the other two parameters at the end of the tack in ai.ini do. Rastix says they do nothing. Looking over ai.ini again i tend to believe him (since i see text after semi-colons) Last edited by Goumindong; 12-06-2010 at 03:40 AM. |
#13
|
|||
|
|||
Hmm, didn't do enough testing to notice - sorry guys, looks like I need to update the info there. It worked for my mod since I lowered warhead damage a lot (and hence low aoe). The jamming isn't a problem because we can see how it works in another script.
Well unless Rastix has another way to let you decouple the aoe from the damage then I have no idea. Don't really feel like reinstalling to test either, there are too many hidden limitations in the game. Maybe when Ashes of Victory comes out. |
#14
|
|||
|
|||
The fact that you lowered the explosion distances is also likely why you see rockets doing more "pushing". Warheads that explode close to a target are more likely to actually collide with the target before exploding (there is some amount of delay before they actually pop). And if they collide with the target then they will transfer momentum just like anything else.
|
#15
|
|||
|
|||
If you want some fun with missiles try modding alien poison missile (poison detonator). Only this missile uses special editable poisoning script. It's a common script file so you put in it any effect you want. For example you can add real blast wave with Push/Move function, effect which strips enemies of shields, disable their engines, spawn some friendly mercenaries on their backs. You can make a nasty "Marked for Death" perk and deliver it to anyone caught in the explosion radius. Possibilities are countless.
Last edited by Goblin Wizard; 12-07-2010 at 08:07 PM. |
#16
|
|||
|
|||
Quote:
that could fix my problem. But I can't seem to find these properties you're discussing in the shippoisoning script. It seems like all that does is tell the game whether or not a ship can be poisoned and the rest is hard coded in the poisondetonator just like anything else. I mean, I suppose i could make a poisondetonator which did a lot of damage for like 1 second in a very small radius. But then missiles would penetrate shields and you couldn't shoot them at aliens. edit: XML schema seems to indicate that the poisondetonator is just as hardwired as the rest. What would be interesting is if i could create a sub extension off of poisondetonator or distance detonator in order to do what I want. Or if i could add another parameter to the schema of impactdetonator and have the game actually use it. Last edited by Goumindong; 12-07-2010 at 11:51 PM. |
#17
|
|||
|
|||
Quote:
Last edited by Trucidation; 12-07-2010 at 11:38 PM. |
#18
|
|||
|
|||
Quote:
Below you have an example how the ShipPoisoning script may look. Code:
function ShipCanBePoisoned(ship) pilot = ship:GetPilot(); if not (GetCurrentLocation() == "x220") or not (GetCurrentLocation() == "Precursors") or not (GetCurrentLocation() == "DisonSphere") then if (pilot == nil) then return FALSE; else if (GetQuestLabel("warhead_type") == "depol") then ship:SetShield(0); ship:PlayFX("Depol.bfx"); return FALSE; elseif (GetQuestLabel("warhead_type") == "blast") then return FALSE; else return TRUE; end; end; else if (pilot == nil) then return FALSE; else if (pilot:HavePerk("Alien")) then return FALSE; else return TRUE; end; end; end; end; --function ShipCanBePoisoned(ship) -- pilot = ship:GetPilot(); ---- flight = pilot:GetFlight(); -- -- if not (GetCurrentLocation() == "x220") or not (GetCurrentLocation() == "Precursors") or not (GetCurrentLocation() == "DisonSphere") then -- if (pilot == nil) then -- return FALSE; -- else ---- (GetQuestLabel("warhead_type") == blast) then -- ship:SetShield(0); ---- flight:Stop(); ---- ship:ApplyImpulse(100, Vector3(0, 1, 0)); ---- myfunction(); -- return FALSE; ---- else ---- return FALSE; -- end; -- else -- if (pilot == nil) then -- return FALSE; -- else -- if (pilot:HavePerk("Alien")) then -- return FALSE; -- else -- return TRUE; -- end; -- end; -- end; --end; The main problem is that this script is connected with every poison detonator you make. It's hard to find good ifs to make it works differently for each type of missile. To make it work like normal missile you have to set poisoning effect damage to 0 and time to something like 1s or even 0.1s. |
#19
|
|||
|
|||
Yea, I am trying to think of what info we can pull off the ship or from a global area that would help us but I am failing pretty hard at it.
|
#20
|
|||
|
|||
I don't know exactly what you want to do but you can check through the scripts how the phrase "ship:" is used. You'll have an idea about functions working directly with ship like "ship:GetPilot()". Check this Manual too.
Last edited by Goblin Wizard; 12-09-2010 at 06:28 AM. |
|
|