Hi! I am trying to make a boss fight and I already got a bossfight. I wanted to ask for help because I need a attack where the boss jumps to a position (also the boss should not walk while jumping, also ignore this boss script in the charakter. Thats not the real script. The mainscript for the boss is in the serverscriptsserverfolder). It should be something like this:
do I need to tween it? Use math? I have no idea how to script something like this. I already have a animation and the boss script. The boss must jump to a parts position like Point1, Point2, Point3. I would be thankful for any help.
I already made a little part of the script. This part is supposed to play the jump animation.
local function JumpToPosition()
local Jump = Humanoid:LoadAnimation(bossModel.Head.JumpingToSpot)
Jump:Play()
Jump.Stopped:Wait()
...
local r = 50 -- the radius of the circle
local angle = 0
local x = r * math.cos(angle) -- gets the x axis by multiplying the radius by the cosine of angle
local y = r * math.sin(angle) -- gets the y axis by multiplying the radius by the sine of angle
angle += 0.1 -- increase the angle to change the x and y axis overtime
You can make this to a for loop, and math.pi (half circle) as the end value. And yes you can tween it according to the x and y value Tip: you can add the radius with a random number to make it squiggly-like
Edit: I believe you can get the radius of the circle by getting the distance between the boss and the target, and multiply it by 2
yes, I have red parts on the boss-stage where the boss will jump to. I would like to script it like this: Attack(1): Jump to part 1, Attack(2): Jump to part 2. If its possible the boss must also jump from the position where he is. like bowser in mario games. He also jumps from position to position