[Modding Tool] (Alpha 8) Extended Xml Commands, Bullet Class

Started by mrofa, August 08, 2014, 05:33:15 PM

Previous topic - Next topic

mrofa

This is a free resource/example of extended commands for projectiles in xml.
Its ready to use but its still experimental so if you find any bugs or have questions or if your a programmer and you cry looking at the code, any feedback is nice to see.

Here is a link to example minimod with this commands in use.
In dev console spawn weapons "Boomerang" and "Boomerang2".


Settings default is used when you dont use that command in your xml.
int value = only full digits like 1 , 2 , 3...
bool value = true or false
string value = names or texts i.e. <defName> in xml is a string

Commands in xml:

<RotationSpeed> (default setting 0) int value. As name say its a rotation speed of projectile in flight, higher the value, faster its rotates.

<ReturnToOwner> (default setting false) bool value. On impact it will create a projectile that will fly back to its owner ( likea bummerang), require specified projectile to fly back.

<ReturnThingdef> (default setting null) string value. This is a def name of projectile that will fly back to its owner, this projectile cant be the same as projectile that will lunch it, so as in example mod to make a boomerang you need 2 projectiles. If this field is not set ReturnToOwner will not work.

<ThingDefOnImpact> (default setting null) string value. This will create a item on projectile impact, like in example mod when projectiles create metal on impact.

<DmgEffOnImpact> (default setting false) bool value. This is damage calculation if its false, target will not be demaged when hit, even if projectile have set damage value, so if you want your projectiles to do damage at all turn this to true setting.

<TryIgnite> (default setting false) bool value. This if true will set on fire anything it can on projectile impact.

<IgniteOnFlight> (default setting false) bool value. If true it will try to set on fire anything that is in projectile square during projecitle flight.

<TicksPerFlightIgnite> (default setting 15) int value. This setting is how often IgniteOnFlight will try to ignite, lower the value the often it will try to ignite, its counted in ingame ticks,  250 ticks is around 4,3 sec(use calculator :D).
Caution 15 is in my opinion optimal value if you want it to be the most often, lower values can be a bit performance heavier.

<IncapChance > (default setting 0) int value. Chance to forcfully incapitade the pawn. It is somhow kinda limited, since incaping can only start from cerian level of hp, so if pawn hp level is higher than incap level then his hp will be lower to incap level and he will be force incapitaded.
All i do is clutter all around.

Shinzy

Quote from: mrofa on August 08, 2014, 05:33:15 PM
<ThingDefOnImpact> (default setting null) string value. This will create a item on projectile impact, like in example mod when projectiles create metal on impact.

I think I'm in love
Can that create a pawn?
the possibilities =P my brain can't take it

Rabid squirrel launcher anyone? ;D

mrofa

#2
Not sure never tired ;p

Edit: no it cant create pawns.

Edit2: but its a good idea will add it tommorow :)
All i do is clutter all around.

Haplo

I have also something for free usage.
It was more of a small test for me, but feel free to use it if you want:
A weapon, that gives you a short feel-good-thought with every shot fired :)

Extended Armory 1.0.0

Shinzy

Quote from: Haplo on August 09, 2014, 03:37:44 PM
I have also something for free usage.
It was more of a small test for me, but feel free to use it if you want:
A weapon, that gives you a short feel-good-thought with every shot fired :)

Extended Armory 1.0.0

Quote from: mrofa on August 08, 2014, 05:33:15 PM
<DmgEffOnImpact> (default setting false) bool value. This is damage calculation if its false, target will not be demaged when hit, even if projectile have set damage value, so if you want your projectiles to do damage at all turn this to true setting.

Now combine these two and you can make super soakers =P *applause*

RawCode

protip:

with custom code injected by assembly you allowed to do ANYTHING you like.
just anything, no limits.
ever if game does not support thing by default, you always can perform runtime memory patch.

Bog

Does this still work with Alpha 6?

...

Also, if a moderator sees this thread it should probably be moved over to modding tools.
Divergence of Civilization Lead Developer (in this case that's the fancy way of saying "Only Developer")

Project Armoury Developer (New huge 2.13 Release now live!)

Shinzy

Quote from: Bog on August 15, 2014, 06:33:47 PM
Does this still work with Alpha 6?
Same question!

I entirely forgot this one!
And more over, is it tomorrow yet? =P

Quote from: mrofa on August 08, 2014, 06:09:23 PMEdit2: but its a good idea will add it tommorow :)

I really wanted to make some more Mechanoids
one of them being huge glob of metal tossing tiny melee bugs around

though I kinda abandoned this one for now. Trying to tend too many fires at once =P


Bog

#8
Quote from: Shinzy on August 15, 2014, 07:12:22 PM
And more over, is it tomorrow yet? =P

Quote from: mrofa on August 08, 2014, 06:09:23 PMEdit2: but its a good idea will add it tommorow :)

I really wanted to make some more Mechanoids
one of them being huge glob of metal tossing tiny melee bugs around
You could even make replicators! A creature that shoots really slowly but spawns more of itself. Then you'd have to focus on killing them all before they overrun you.

...and assuming it's true, does that mean you'd reconsider the rabid boomrat launcher? ;D
Divergence of Civilization Lead Developer (in this case that's the fancy way of saying "Only Developer")

Project Armoury Developer (New huge 2.13 Release now live!)

mrofa

Sorry guys got catch up with some RL stuff.
Current link dont work on a6, and if it works it wont dmg anything. Managed to get it working thrugh, and trying to make the pawns to spawn, but kinda hit a wall with squad brain for humanoids or canepids, animals seems to spawn fine.
Well nothing like a bummerang that spawns insane squierrls :D
So i will update current version to a6 in few hours when/if i wake up, and will try to thinker with pawns.

Replicators are quite nice idea, but it require programming skills , which i dont have :D
Then again i try to look in some haplo MAI code, maybe will figure something out.
Anyways atm except updated to a6 version i cant promiss anything.
All i do is clutter all around.

Bog

Quote from: mrofa on August 15, 2014, 08:42:37 PM
Sorry guys got catch up with some RL stuff.
Current link dont work on a6, and if it works it wont dmg anything. Managed to get it working thrugh, and trying to make the pawns to spawn, but kinda hit a wall with squad brain for humanoids or canepids, animals seems to spawn fine.
Well nothing like a bummerang that spawns insane squierrls :D
So i will update current version to a6 in few hours when/if i wake up, and will try to thinker with pawns.

Replicators are quite nice idea, but it require programming skills , which i dont have :D
Then again i try to look in some haplo MAI code, maybe will figure something out.
Anyways atm except updated to a6 version i cant promiss anything.
Don't worry about it too much. Personally I'm very willing to wait, and I imagine everybody else is as well.
Divergence of Civilization Lead Developer (in this case that's the fancy way of saying "Only Developer")

Project Armoury Developer (New huge 2.13 Release now live!)

mrofa

Ok did update the link with a6 version
All i do is clutter all around.

Bog

Quote from: mrofa on August 16, 2014, 07:36:13 AM
Ok did update the link with a6 version
Awesome. It worked for updating the spinning and returning Project Armoury weapons, thanks a lot. ;D
Divergence of Civilization Lead Developer (in this case that's the fancy way of saying "Only Developer")

Project Armoury Developer (New huge 2.13 Release now live!)


mrofa

Updated to A7 by Haplo
So all credits to him on this since he didnt burst in tears when he seen my code :D
All i do is clutter all around.