New user please help

How would you go about making a boss fight it a level for a 2d platformer games similar to the classic platformer of old. I'm wanting to add fights like this to specific points in each level but don't know how to go about it.

Comments

  • IceboxIcebox Member Posts: 1,485

    What do you want your boss to do ?? You need to work it out based on your logic , for example if you want your boss to keep moving left and right ,

    you can put a collide actor on the edges of the scene (right and left), and create a self boolean name it self.rightleft

    then add 2 rules ( this is just an option , there are other better ways)

    in your boss actor ,
    if overlaps or collides with collide actor ( if the boss touches the collide actors
    change attribute ( self.rightleft to not(self.rightleft) ( switch rightleft boolean to true or false)

    create another rule if self.rightleft is false
    move to the left
    otherwise move to the right

    if you want him to animate while moving
    if self. motion linear velocity x is not = 0 animate walk animation ( so the walking animation will trigger when the boss is moving)

    if you want your actor to loose health when it collides with the boss . create a self.health integer put a number you want ( you can put 100 or 10 or 20 any number) lets say we put 100
    if actor overlaps or collides with boss , change self.health to self.health - 10 for example so now everytime the actor touches the boss it will loose 10 hp.

    if you want your actor to die when the health is 0
    if self.health <= 0
    destroy or death animation.

    its all based on logic , so i think you should learn the basics first before you go into more details, there are many ways to do certain things, you can move the actor several ways , you can make your conditions based on different things , if your moving , if your image is rotated , if your actor is not moving , if your position is something, if your size is bigger or smaller , if a boolean is true or false , if an integer is 1 or 0 .

    You should know what the attributes do , how to use them , how to use them in an effective way , how to think like a computer , how to create logic that doesnt contradict , it might take a couple of days or couple of hours depending on how you learn it. But if you want to do something specific just give an example cause the information you gave is unfortunately not enough, and hopefully the forums has many helpful members that are willing to help, wish you the best :) .

Sign In or Register to comment.