OpenXcom Forum
Modding => Help => Topic started by: vadracas on April 04, 2020, 07:15:16 pm
-
So I've been thinking of implementing something where if you really need to, you can throw your weapon at an enemy as an attack. My problem is that I have no idea how to move the actual weapon to that location like the generic throw action does. Is that an option accessible to modders?
-
So I've been thinking of implementing something where if you really need to, you can throw your weapon at an enemy as an attack. My problem is that I have no idea how to move the actual weapon to that location like the generic throw action does. Is that an option accessible to modders?
No, it's not a modding option.
Still, I think the idea is hilarious (had it for years myself) and I'd be happy to see it, for the lulz if nothing else :)
Normal throw: normal throw
Ctrl + throw: treat the item as a thrown missile, with damage depending on its weight, as well as new custom modifier(s) to reflect things like hardness or sharpness
-
Is it worth adding this as a thread for OXCE?
-
No, it's a feature that's just not needed.
This is as much of a cosmetic detail (or easter egg) as it gets and it is really not worth the effort needed to implement it.
... now feel free to crucify me.
-
Yeah, not a real request on my part. Just pointing out it would be funny, and I probably would be consistently using it if it existed.
-
But I really wanna throw my sword at someone. :( :( :(
lol, I understand, but I would absolutely use it if it was available.
-
I think you can make a spear, for example, which can be used in hand-to-hand combat and throw if necessary. Just pick it up does not work. ;)
-
I think you can make a spear, for example, which can be used in hand-to-hand combat and throw if necessary. Just pick it up does not work. ;)
Yeah, I know I can do that, but there is a major flaw with the current system. If I implement a "throw" action, it doesn't actually throw the weapon to that tile, meaning that I either have infinite uses of the "throw" action or I lose my weapon completely after I throw.
-
If you can spawn an item where a weapon projectile hits then you could create a melee weapon that also has a single charge of ammo and fires in an arc.
When the melee weapon's ammo is exhausted the weapon is deleted, a new item is then created on the tile that the projectile hit giving the illusion that the weapon was thrown as the projectile.
I think it is already possible to spawn units so perhaps spawning items may also be possible via scripting?
-
If you can spawn an item where a weapon projectile hits then you could create a melee weapon that also has a single charge of ammo and fires in an arc.
When the melee weapon's ammo is exhausted the weapon is deleted, a new item is then created on the tile that the projectile hit giving the illusion that the weapon was thrown as the projectile.
I think it is already possible to spawn units so perhaps spawning items may also be possible via scripting?
Ah yes, the mighty script. Perhaps I'll dig into a way to do that.