Space Engineers

Space Engineers

WHAM | Whip's Homing Advanced Missile Script
724 kommentarer
Whiplash141  [ophavsmand] 27. sep. kl. 10:01 
You can do several things:
1. in LAMP, use precise mode with the argument "precise_on", lock on to a different area on the ship, and use the "retask" argument to send any active missiles to that new target
2. use "Max aim dispersion (m)" in WHAM custom data to specify a randomized impact point radius
Liliathe 27. sep. kl. 7:27 
I have a small question.
My ship is using LAMP and WHAM missiles. I look on target with camera turret (camera mode) and fire 2 missiles . First one always hits (nicely) but if target got damaged to the point of splitting or center of target grid gor vaporized with first missile , the second one just don't knwo what to hit and just akwardly fly around.
What I could do in situation liek that other than just :
a) kill any missiles that don't know where to go with command
b) shoot 1 missile at the time.
I want to have swarm of missiles but don't want them to just get so lost.
Whiplash141  [ophavsmand] 23. aug. kl. 14:26 
idk if that is a mod or something, so I dont know if they behave like regular warheads. In any event though, you can set up a timer to trigger arbitrary actions at specific ranges from the target using its custom data and adding it to the missile group
Whiplash141  [ophavsmand] 6. aug. kl. 22:01 
No because nothing guarantees that when the program compiles that the other blocks on the missile are built. In fact it is very likely that the program will compile before several critical components are present making that an unreliable method.
Based_Stickman 6. aug. kl. 21:45 
could it be set to connect on wham initialization when its being built? So that it basically connects immediately if possible
Whiplash141  [ophavsmand] 6. aug. kl. 20:31 
the program has no way of knowing when all blocks are available. If you have a timer set up to build them, i'd set up the toggle there
Based_Stickman 6. aug. kl. 12:15 
Can we get an auto connect toggle for missiles so they they will auto refuel when they are built.... i know you can use the event controller but it barely works most times because Keen....
Whiplash141  [ophavsmand] 3. juli kl. 21:20 
The script itself will not turn off the connector, but you can add a timer to the missile that can be triggered on any stage of the missile to execute whatever custom logic you desire
Based_Stickman 3. juli kl. 19:48 
i have an event controller on the launch platform to auto connect to any new missile to fill them and it sometimes will reconnect with the missile as its launches, which is why i wanted to know if the script cant just turn off the connector
Whiplash141  [ophavsmand] 3. juli kl. 5:43 
If it is in the middle group, the connector is disconnected on launch
Based_Stickman 2. juli kl. 12:31 
can Wham automatically turn off the missile connector or do i need to have a timer on my missile to do it?
Whiplash141  [ophavsmand] 17. juni kl. 17:24 
@dead: I saw you posted in Help/Questions, so I'll move the discussion there
Wildreaper390 17. juni kl. 9:24 
my WHAM and LAMP are showing no error but everytime i reopen my game my missile groups all switch to "missile 1" i have 6 missiles. When i manually switch them back and fire the missiles they dont disconnect or engage instead they just blow up after a while.
Whiplash141  [ophavsmand] 16. maj kl. 11:08 
It's a game limitation, you can only mitigate the effects, not prevent them
DazeyDream 16. maj kl. 5:29 
Err, I'm not well versed in arcane speak, is this something I can do?
Whiplash141  [ophavsmand] 15. maj kl. 18:44 
It is the programmable block compiling on the main thread. The way to mitigate is to stagger building of missiles to the scripts compile at different ticks.

Why do scripts compile on the main thread? Idk :(
DazeyDream 15. maj kl. 16:44 
version for below comment
Version="170.22.2" Date = "2024/05/03" CompatVersion = "95.0.0"
DazeyDream 15. maj kl. 16:43 
When welding wham missiles, there is a jolt of lag presumably when the programming block with wham in gets built. It's fine when the server has fights with these missiles pre-built, but the jolts of lag mid fight when wham blocks are built are a concern. Is there a way I can reduce this jolt of lag?
JawsExil98 19. jan. kl. 21:45 
Is it possible to make this fire and forget? (I did NOT understand a single word in here)
Whiplash141  [ophavsmand] 13. jan. kl. 12:24 
That is not an error associated with this script or any script for that matter. Sounds like you have mods or plugins installed.
Drunken Operator 12. jan. kl. 19:51 
it did not
Drunken Operator 12. jan. kl. 19:44 
I fire 1 missile and everything works correctly, but upon the launch of the second missile i get the error "Error: Cannot Find the Blueprint File" spammed over and over again and have to restart my game, i am in a testing world so i removed the old target and made a new one, but it isnt working correctly, going to test again and see if re targeting after a game restart fixes my issue
Yoghurt 18. dec. 2024 kl. 12:07 
I see! Thanks. The remote control I was just wondering about because it would be cool to be able to sometimes control it and for example escort some other ship with torpedoes, or to launch and print a bunch of them before sending them to a target to get a more overwhelming amount at once. But I get stuff like that wouldn't fit in the script.
Whiplash141  [ophavsmand] 18. dec. 2024 kl. 11:27 
"Sometimes it seems the missile switches target when I just switch lock."

That indicates that the missile does not have its own lock on your target. If a missile has no target of its own, it flies in semi-active guidance mode and attempts to track whatever LAMP is actively painting. Once it has a lock of its own, it only listens to LAMP updates associated with its actively guided target.

You can set "Antenna name mode" to "MissileStatus" to troubleshoot the homing status of each missile through its antenna name.

"Another question, is there a way to take over control of the missile manually through the remote block?"

I mean you can try, but the script will actively fight you as that is not intended functionality. You can always manually launch via RC and steer it in yourself.
Yoghurt 18. dec. 2024 kl. 11:22 
I feel like I'm getting mixed behaviour. Does a launched missile switch target itself if you switch your lock to a different target mid-flight? I assumed that was what the retask command is for. Sometimes it seems the missile switches target when I just switch lock. Sometimes it works as I intend where I launch 1 missile at one target and another at a different target before the first has hit. How does it work?

Another question, is there a way to take over control of the missile manually through the remote block?
Whiplash141  [ophavsmand] 4. dec. 2024 kl. 11:04 
Performance and the fact that almost every server uses only 3km sync distance anyways
nanuzacih 4. dec. 2024 kl. 6:41 
And why is the range only 5km?
Whiplash141  [ophavsmand] 21. okt. 2024 kl. 9:48 
That is a your game problem, not the script. Submit a big report to KSWH.
Mischief_Master 20. okt. 2024 kl. 18:17 
Missles work great, exept for the fact that IT CORRUPTS THE GAME FOR THE HOST the second i launch it....sooo its worhless
Mo 2. okt. 2024 kl. 19:02 
Thanks a lot!
Whiplash141  [ophavsmand] 2. okt. 2024 kl. 15:06 
"Is there any where to read about the available guidance algorithms?"
Uhhhhh... I keep forgetting to finish the writeup lol
Whiplash141  [ophavsmand] 2. okt. 2024 kl. 15:05 
"Does script works well with top mounted cameras from automaton update?"
Yep

"Does spinning (miscellaneous parameter of WHAM) affect effectiveness of missile?"
Yep. Higher spin makes it more difficult for the missile to track a maneuvering target

"What spin rate is safe?"
Honestly depends on the missile itself. The heavier/less maneuverable the missile, the worse the effect spinning has on responsiveness

"Can I compensate for the lack of side cameras on two out of four sides with spinning of missile?"
Yes. WHAM will use whatever cameras are facing the target that it can find.
Mo 2. okt. 2024 kl. 12:29 
Hello. Thanks again for your great script!
Does script works well with top mounted cameras from automaton update? (Nothing obscures the view)
Does spinning (miscellaneous parameter of WHAM) affect effectiveness of missile? What spin rate is safe?
Can I compensate for the lack of side cameras on two out of four sides with spinning of missile?
Based_Stickman 1. okt. 2024 kl. 15:27 
Is there any where to read about the available guidance algorithms?
Whiplash141  [ophavsmand] 1. sep. 2024 kl. 13:44 
Guidance delay only delays activation of steering. The rest of the launch staging is entirely unaffected.

If you have no thrusters name tagged with "Detach", set the "Detach duration" to 0.
Grimir 1. sep. 2024 kl. 13:02 
Sadly changing the Guidance Delay will only Delay. for the Rocket to do anything at all.

I am not using any Mods. And i am using both the latest version of WHAM and LAMP.
Whiplash141  [ophavsmand] 31. aug. 2024 kl. 11:56 
Have you tried longer guidance delays? That below configuration only gives the missile 0.5 seconds to get out of the tube.
Grimir 31. aug. 2024 kl. 10:37 
Pardon my intrusion.
As of late, my Missiles start turning while within the Welding Chamber.

Whereas before, the would leave the Chamber/Bay/Silo - whatever you might call it.
And then start turning.

I have medled with the Settings;
[Delays]
Guidance delay (s)=1.5
Stage 1: Disconnect delay (s)=1
Stage 2: Detach duration (s)=2
Stage 3: Main ignition delay (s)=0

To try and adjust this issue.
I even tried using Missiles from your Viper Demonstration BP.
but they do the same, on all of my Grids.

Even ones i build arround your Viper showcase.
The pasted Viper on its own, works just like a charm.

Thank you very much for all the neat Creations you share with the community.
Whiplash141  [ophavsmand] 25. aug. 2024 kl. 0:27 
Not for super precise things, no
Redstar 24. aug. 2024 kl. 23:24 
Yes, I require a specific sequence of events before detonation, so I use a timer. I assume it's not viable?
Whiplash141  [ophavsmand] 24. aug. 2024 kl. 21:03 
Correction: range times attempt to estimate the radius of the target and account for that. Again, it is no where near as precise as camera based detonation. Are you using timers for detonation instead of the built in detonation range?
Redstar 24. aug. 2024 kl. 14:17 
That is rather odd. Because, for example, when I set the range of a timer at 5 meters, if the structure (either ship or station) is large enough, there is a high chance it will explode extremely prematurely. Like, even 100 meters before reaching the target. Whereas against a fighter it will explode at the assigned distance without issue. Any idea what might be causing this and how to fix it? Perhaps some weird center of mass glitch with specific ship shapes?
Whiplash141  [ophavsmand] 24. aug. 2024 kl. 13:00 
"Is the distance for the timer triggers calculated in the same way as the distance for the warheads?"

No, the distance for timers is a lot more simple than the distance for warheads. For timers, distance is simply the distance from the center of the target.

The distance for warheads is calculated in several different ways depending on what you have attached to your missile. If you have cameras on your missile, WHAM uses them to do close range proximity scans for very accurate detonations.
Redstar 24. aug. 2024 kl. 8:03 
Hello! A bit of a question! Is the distance for the timer triggers calculated in the same way as the distance for the warheads? Because I've noticed that depending on the target size, I get lots of premature timer activations.
Whiplash141  [ophavsmand] 15. juli 2024 kl. 10:08 
I'm certain, and it sounds like you are running out of power or fuel.

Too down height is configurable in custom data. Please see the full guide for descriptions of all the custom data settings.
ZeroOnii-Chan 15. juli 2024 kl. 7:40 
i did the thing and you sure its 18km ? it gets to 250m/s but after like 5km or so its just poof gone
crashed into the gound even with the top down mode does it have ground avoidance ?
or is there wway to increase the altitude it goes to when launched ?
ZeroOnii-Chan 15. juli 2024 kl. 0:32 
oki thanky you will try that the speed limit is taht the setting in the fuel conservation section ?
does taht mean i need to turn that on ? or if i leave that off will that impact accuratie ?
Whiplash141  [ophavsmand] 14. juli 2024 kl. 14:46 
There is a kill switch built in after around 3 minutes of continuous flight with no intercept. That translates to roughly 18000 meters of flight at max vanilla speeds.

Speed limiting is disable by default, but you can enable it in custom data.

I'd recommend running the stealth_off argument in LAMP so that you can visually track the missiles through the antenna signal.
ZeroOnii-Chan 14. juli 2024 kl. 13:08 
so i setup a silo that fires simple atmo missile but it only seem to hit tarrgets close to silo not the designator ship when i target a structure 7km of the silo in my small ship thats 4km off target it fires and goes towards it but somehow it never gets to it
now i am no genie with this toke me 7h to figure out how it works XD any guidance on it ? is there range killswitch ? does it manage its own speed ? i use mod that allows relative speeds based on mass/thrust ratio is there a way yo limit its speed ?
Whiplash141  [ophavsmand] 16. juni 2024 kl. 10:12 
Reduce the detonation range?