• 0

# im making my first mugen character which is a troglodyte Dungeons & Dragons: Tower of Doom and i need help coding a certain projectile

## Question

its kind of a long story, i never made a mugen character before, i decided to make a troglodyte from Dungeons & Dragons: Tower of Doom for mugen since nobody has done this before (or atleast i dont know if theres a version of him someone made for mugen) and im trying to make him as accurate as i can.

so there's this attack where he throws a oil sack on the ground (i think its oil...if its not then idk) and then it burns, its something like that.

now the problem is, how the heck do i code that? i've searched in the internet looking for answers on how to code curving projectiles and stuff like that but i didnt found anything, does anyone here know the necessary code to curving projectiles? if you do,then answer please.

also sorry if my english is bad, im actually brazilian.

## Recommended Posts

• 0

I'm not the best at explaining things, but I pasted a bit of code as an example on how to do arcing projectiles. This is merely an example so be sure to experiment on your own.

;------------------------------------------------------------------------------------------------

[Statedef 1000]
type    = A<---------------Make sure the type is A(air) since you're tossing the flask up in the air
movetype= A<-----------Naturally, this should be set A given it's a projectile Attack
physics = N<------------Since gravity shouldn't have the same effect on a small incendiary as it does a smelly fish monster, set this to N
anim = 1000<-------------Oil flask animation(set this value to whatever number the Oil flask animation is in the .Air file, You can open air files with any version of Fighter Factory)
sprpriority = 2
velset = 2,-11<-----------The left number is horizontal velocity(how fast it goes forward) while the right number is vertical velocity(how fast it moves upward).

[State 1000, Gravity]<----This block triggers gravity to activate, this is so the Oil Flask doesn't fly upward endlessly. It also creates the arc for the move.
type = Gravity
trigger1 = 1

[State 1000, Gravity Alt] <-Alternatively, this block can be used instead. This one will give you more control of Flask's trajectory, but playtesting is recommended as it's easier to mess up
Trigger1 = 1<------------Setting this to 1 means it's active during the entire time the flask is out. You can also try Animtime >=(insert number) if you want to specify when gravity triggers
y = .4<------------------This value influences the gravity effect on the flask. Make sure you place a decimal next to number(like how it's shown in the example) or the gravity will be too strong

[State 1000, end]<-----This block is imperative since it's needed for the flask to burst into flames when it hits the ground
type = ChangeState
trigger1 = pos y > -vel y<This is generally enough for this to work, though you can play around with this if you think the Flask bursts too high above the ground or too far below.
value = 1010<----------Set this value to the state number that has the flask burst into flames.

##### Share on other sites

• 0

thanks for the answer! im going to try this now.

## Create an account

Register a new account

×

• Back

• #### Mugen Software

• Back
• Mugen Software

• Back