ZeroCore Posted June 2, 2019 Share Posted June 2, 2019 Hi, and I could really use some help with a problem I'm stuck on in the Skyrim CK. I'm trying to make a custom spell whose projectile triggers a script when the projectile hits anything (and I mean anything, be it an actor, a static object, a movable static, water, literally *anything that it can collide with*). In short, here's the tree of it: spell is cast --> projectile launched --> projectile hits literally anything it can hit --> script goes off. Can this be done, and if so, can someone please tell me how? Thanks for any help I can get. Link to comment Share on other sites More sharing options...
IsharaMeradin Posted June 3, 2019 Share Posted June 3, 2019 My Mage's Night Out mod uses a projectile to create an explosion at the point of impact which in turn places an xMarker that contains a script to do things at that location. Sounds like that might be the process you need. Unfortunately, it has been a while and I no longer remember the specifics. That said, you're more than welcome to delve into my mod, figure out how it works and adapt any scripting as necessary. Link to comment Share on other sites More sharing options...
ZeroCore Posted June 3, 2019 Author Share Posted June 3, 2019 (edited) My Mage's Night Out mod uses a projectile to create an explosion at the point of impact which in turn places an xMarker that contains a script to do things at that location. Sounds like that might be the process you need. Unfortunately, it has been a while and I no longer remember the specifics. That said, you're more than welcome to delve into my mod, figure out how it works and adapt any scripting as necessary. I had a look through it, and thanks for the help. It kind of reminds me of the dragon wayfinder mod, to be honest (that one spawns an invisible, mesh-less goat that the dragon locks onto and orbits, and by re-aiming and moving said invisible goat, the dragon's flight path can be altered.Speaking of flight, that's the whole purpose behind this; I made an airship mod that I'm still working on, but am having one problem with; the thing keeps passing through objects, the reason being is that the thing moves by using "translateToRef", and seeks out an invisible XMarkerHeading to align itself to, not caring whether something is in the way or not. I'm trying to make a spell that causes the ship to abruptly halt if it happens to bump into something. My first thought was to have a projectile launched at the invisible XMarkerHeading by the airship itself, which would then hit anything inbetween and trigger an explosion. The explosion was supposed to then set off an enchantment attached to it. The enchantment would have a script on it that would go off and tell the airship to stop moving. This didn't work, as for some reason even though the projectile hit the ground, the effect did not trigger (am wondering if I didn't set up the explosion, spell, projectile, or any combination of the above correctly). I also tried making the explosion big enough to reach the airship and hit it, with a script on the airship using event OnHit to set off a "StopTranslate" function, but for some reason the airship (which is a type movable static) doesn't do anything when an explosion touches it, and will only trigger if hit by a projectile directly. I'd rather not have to have something spawn in, then get deleted, over and over again (to prevent lag and save file bloat) but I do want this ship to work properly. The only other thing that I can think of is to have the XMarkerHeading itself fire a projectile back at the airship and, if it hits, stop the translation. *Edit: The only other thing that I can think of is to copy and retrofit the Archimedes II Satellite Laser Cannon script from Fallout New Vegas. Shortly before firing, the Euclid's C-Finder calls down a large, 3-point targeting laser from the Archimedes II satellite in space. The sighting lasers follow your character's aim around for a moment before the actual weaponized laser beam burns anything in its path to literal piles of ash. I could re-install Fallout New Vegas and have a look at how it works, and see if I can reverse-engineer it for Skyrim (my personal thoughts are that it's probably just some basic trig). I wound up using your method after all. It works, and now just needs some tweeking to make sure it stops when I want the thing to stop. Edited June 3, 2019 by ZeroCore Link to comment Share on other sites More sharing options...
Recommended Posts