Space Engineers

Space Engineers

WeaponCore Autofire Script
73 kommentarer
BAKADAKALAKA556 3. juli kl. 15.14 
is there a way to get auto locking of grids using the script but not firing? almost like a fire control radar
Bodyboarder2528 9. juni kl. 0.01 
hey is this still compatible with the latest WC as it doesnt seem to fire and might need to change it to a different mode
TangoZulu 29. nov. 2023 kl. 20.03 
@BAKADAKALAKA556 Not sure if you have figured it out yet, but I think your issue is not using the open and close brackets []
Example: [Auto-Fire] Homing missiles
Example 2: Homing Missiles [Auto-Fire]
BAKADAKALAKA556 10. okt. 2023 kl. 23.00 
i can't seem to get the script to work I created a group called Auto-Fire. is the script broken or am I missing something?
Jackaroo 24. apr. 2023 kl. 9.58 
69th comment this works so well
Spec-Ops Mexican 7. mars 2023 kl. 11.59 
What mods are supported? I seem to have the issue of the ai not targeting anything or firing the missiles
Fury 31. des. 2022 kl. 9.57 
If it gives you another data point, I have this script working with the archer series right now. I tweaked the logic to fire when something is targeted rather than just when a target is on the threat list, but other than that it's pretty much untouched. I have noticed some of the homing missiles go through changes, though. I think the archer series gained the ability to dumb-fire when there's no target, for example.
Sigmund Froid  [skaper] 30. des. 2022 kl. 5.27 
I'll have to give it a look, if the group is initialized correctly there shouldn't be a reason why it doesn't work unless WC has made bigger changes to homing missiles that the m-12 isn't using.
Nightraid [Mine] 30. des. 2022 kl. 2.38 
Hi, tried this and it works with the m-12 swarmer. My problem is it does not work with other homing missiles like M-2 or the 42/58 archer series. Any idea why is that?
Sigmund Froid  [skaper] 26. nov. 2022 kl. 4.48 
Thank you! While I am certainly not the best programmer I had hoped others would be able to make use of it.
Fury 25. nov. 2022 kl. 17.30 
That makes more sense. Yeah, this just fires missiles automatically when you have a target now. I appreciate all your WC work by the way. I've been able to figure out a lot of how the mod works by reading your scripts as examples.
Sigmund Froid  [skaper] 25. nov. 2022 kl. 14.40 
Sorry for the late reply, yes that was the intention, although since I made this things changed, and it might just be a limitation of weaponcore now, never really did any testing on this again.
Fury 9. nov. 2022 kl. 20.05 
As long as I'm in the comments, I might as well ask you to confirm something. Is it possible for this script to fire homing weapons without a player targeting something first, or will it only work with human intervention?
Fury 9. nov. 2022 kl. 20.01 
I ran into the "illegal characters" error too. It's just the MyIni.Get calls choking on the group name. Your description says to use the tag "[Auto-Fire]" in the name of the weapon group, but "[" and "]" are not valid characters. The script works fine when I use "Auto-Fire" as the tag instead. Maybe you updated the script but not the description at some point?
Sigmund Froid  [skaper] 30. juni 2022 kl. 8.48 
I'll take a look at that later, that's new...
GodShake 30. juni 2022 kl. 8.28 
the script gives an error "illegal characters /r /n etc."
Sigmund Froid  [skaper] 12. mars 2022 kl. 3.26 
It appears I haven't applied the changes of last month here on Steam yet, the script should now work again
Bodyboarder2528 12. mars 2022 kl. 3.01 
hi im getting Weaponcore Api is failing. could this be due to the latest updates?
Sigmund Froid  [skaper] 29. nov. 2021 kl. 11.33 
I'd have to do some investigating but if I can detect it using the Api it should be quite easy to do.
ribera1945e 29. nov. 2021 kl. 2.22 
Are there any plans to support weapons that require lock-on by pressing NumPad0?
Bodyboarder2528 11. okt. 2021 kl. 2.10 
cheers
Sigmund Froid  [skaper] 11. okt. 2021 kl. 1.08 
Yes CoreSystems fixed the bug with FireOnce so now the script should work like before.
Bodyboarder2528 10. okt. 2021 kl. 19.11 
does this work with coresystems still?
Sigmund Froid  [skaper] 1. okt. 2021 kl. 3.02 
The update just now should allow you to shoot weapons until they reload, and fix a CoreSystems bug.
Sigmund Froid  [skaper] 30. sep. 2021 kl. 14.13 
I'll see about it. Might publish it separately though.
The Caveman 30. sep. 2021 kl. 13.53 
i did it with timers, but i wanted a script way to do it. i have to have 1 timer per launcher, gets pcu heavy and intensive on the server. May just incorporate this along side of that.
ATF_Coldblooded Carebear || 30. sep. 2021 kl. 8.37 
lvlercttv you could always use timer block for this but pending on how many launcher you will need à similar amount +1 of timer block the first will set to activate the launcher and Twigger the the second one TB... and the last one Twigger the first one. The extra one is set to stop all TB ...
This was my novice way I found to do this in sequence.
The Caveman 30. sep. 2021 kl. 0.58 
i was just wondering if there was a way to fire a weapon for a set time, then move to the next, fire for the same time, wash rinse repeat
Sigmund Froid  [skaper] 30. sep. 2021 kl. 0.19 
Sadly I barely have any access to the ammo of a weapon via the api. Maybe I'm just overlooking a vanilla way to do it but so far I haven't found anything.
The Caveman 29. sep. 2021 kl. 23.11 
Just out of curiosity, could this be setup to fire 1 or 2 weapons at a time, until empty, then move to the next set?


i have 10 Missile pods and they take 7 seconds to fire all missiles in them and 58 seconds to reload, i want to set up something to fire one at a time, then move to the next, without timers.... to create a continuous stream
Bodyboarder2528 14. sep. 2021 kl. 13.41 
Ash just informed me "the API was broken until a few days ago, if this person is still encountering issues can you please ask them to report them in the CoreSystems discord"
Bodyboarder2528 14. sep. 2021 kl. 4.29 
oh that needs to be changed now lol as MES needs WC v2 if people want the WC features now also WC v1 is not getting much support now as im in their discord
Sigmund Froid  [skaper] 14. sep. 2021 kl. 3.59 
As I said the backround API doesn't work there isn't much I can do about that. In fact I can't even isolate if this bug would occur if CoreSystems is properly working. Again refer to the description of CoreSystems, it is not intended to be used by normal users at this time and when finished will be merged with WeaponCore
Bodyboarder2528 14. sep. 2021 kl. 3.05 
it doesnt crash but also doesnt trigger the weapons to fire
Sigmund Froid  [skaper] 14. sep. 2021 kl. 2.36 
I don't know actually do anything about this yet. the issue is that loading CoreSystems manually breaks weaponCore already according to its description. As such I can say that my script does not crash, however the api functions do not work as they should.
Sigmund Froid  [skaper] 14. sep. 2021 kl. 1.01 
Looking at WeaponCore/CoreSystems I can't see anything specific which should break this script. I'll check on it later to see if anything pops up ingame.
Bodyboarder2528 13. sep. 2021 kl. 17.11 
Can you please make one that works with coreparts which is weaponcore v2
Fischchen 19. aug. 2021 kl. 6.20 
This dosent seem to work
Syphond 5. juli 2021 kl. 22.12 
Also the script seems to limit missile range to 3.5k even though they have an engagement range of 10k
Syphond 5. juli 2021 kl. 21.37 
Not sure if this is a bug or just something to do with how things work, but the script will continue to launch missiles since it detects an enemy grid even though the enemy grid has nothing the missiles will track on it. basicly if the enemy is listed in the entity list it keeps firing reguardless if the missile can home in. This leads to expensive costs on lost missiles. Is there anything that can be done about this.
pyro557 29. apr. 2021 kl. 5.31 
I dont know if i am doing something wrong(which is pretty likely i havent played or modded space engineers in quite awhile until now) but when i put the tag in my homing rockets dont fire i can only use them manually the first time i built my m8s they fired on something without the script then got destroyed i rebuilt them and with or without the script they wont auto fire.
Kaito 23. apr. 2021 kl. 9.31 
Could this replace Whip's Weapon Salvo script?
Bodyboarder2528 11. apr. 2021 kl. 3.45 
it started working again on restart so idk whats going on lol
Sigmund Froid  [skaper] 11. apr. 2021 kl. 2.14 
@Myth ︻デ 一 People reported something like this on the homing missile mod recently. I'll still look into it though maybe something is broken on my end.

@bodyboarder what does the script print in the terminal control window?
Myth 10. apr. 2021 kl. 15.55 
This just makes the homing missiles fire forever, even when no enemy grid is in range.
Bodyboarder2528 9. apr. 2021 kl. 6.07 
ok this has now stopped working for me
Bodyboarder2528 2. apr. 2021 kl. 5.26 
it works for me on DS been using it all day
Sigmund Froid  [skaper] 2. apr. 2021 kl. 4.51 
@BloodyBathSalt In my testing I couldn't reproduce the issue so far could you maybe give me the name of the WeaponGroup you wanted to use.
Sigmund Froid  [skaper] 2. apr. 2021 kl. 3.12 
Possibly it seems Darkstar updated the API I'll have to check.
BloodyBathSalt 2. apr. 2021 kl. 1.12 
is this script broken now? It doesn't seem to fire the missiles and when I recompile the script it gives me the 'section contains illegal characters' exception