Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • i am currently trying to use this for my enemy

    Player character has 8-directional movement

    The enemy has a bouncing ball movement

    Conditions

    - Pick one of Enemy

    - Y position of Player is greater or equal to Y position of Enemy - 80

    - Y position of Player is less or equal to Y position of Enemy + 80

    - X position of Player is greater or equal to X position of Enemy - 80

    - X position of Player is less or equal to X position of Enemy + 80

    Events
    - Set internal flag 0 of Enemy to ON
    - Set alterable value A of Enemy to 0

    Conditions

    - Internal flag 0 of Enemy is ON

    Events
    - Have Enemy look at (0,0) relative to Player
    - Add 1 to alterable value A of Enemy

    Conditions

    - Alterable value A of Enemy equals 30

    Events
    - Set alterable value A of Enemy to 0
    - Set internal flag 0 of Enemy to OFF

    Conditions

    - Internal flag 0 of Enemy is OFF

    Events
    - Have Enemy look in random direction (have an arrow on all of them)

    questions:what does this do?
    Events
    - Have Enemy look at (0,0) relative to Player

    question: how do you do this?
    Events
    - Have Enemy look at (0,0) relative to Player

    This example spoke of having - Several (invisible) active objects for pathfinding purposes but i never found a update.

    question: would they have been for alt movment? building on or adding to the bouncing ball movement?

    in my game i have adapted this to suit but my enemy sprite hotspot cannot be moved to centre position interfears with anim

    consequence: folows player but does not lose intrest and realy hard to beat you have to trap him behind a obstical in order to get a shot at him.

    thanks for taking the time to read all this and if you can help id be most gratefull.

  • - What does it do:
    It makes the enemy look in the direction of the player's hotspot.

    - How to do it:
    Add an action for Enemy called "look in direction of" or similar. There you can select the player and specify a relative offset (which you could use to make up for a bad hotspot).

    - Invisible objects:
    Not sure what this might be about.

    - Enemy hotspot:
    I dont think that has to do with the enemy being hard to shake off. You can always lower the following range (the 80s) at which the enemy "sees" the player, and you can make him give up quicker (the 30), but this only happens once the player is out of range.


    There are entirely other ways to do AI, of course.. my favorite is to have your enemies shoot invisible small objects out in front of them that have their alterable value set to an "ID" of the enemy (which you'd give the enemies by spreading a number).
    If those objects hit an obstacle destroy them.
    If one hits the player, find the enemy with the ID, and store the position where the player was when he got hit, and the direction he was moving when it happened - make the enemy run towards that position and once reaching it, proceed in the direction that player was facing.
    You might want to shoot the objects directly at the player once he was seen and in some more random angles when not.
    If applied correctly, you get some nice enemies to play hide & seek with.

    <span style="font-style: italic">&quot;I'm not saying you don't know what you are talking about, but I don't know what you're talking about.&quot;</span>

  • thanks im still learning mmf and realy like your idea.
    shoot invisable shot
    If one hits the player, find the enemy with the ID, and store the position where the player was when he got hit, and the direction he was moving when it happened - make the enemy run towards that position and once reaching it, proceed in the direction that player was facing.
    going to see if i can do it myself thou im a newbee and might have to come back for help.
    thanks

  • hi random i have used the following code however ive got stuck i want the enemy to activate a sheild if he has been hit by at least two player bullets i have tryed but the shield just appears and does not follow the enemy could you help?
    heres the code:
    Conditions
    o - Enemy collides with Left Marker
    Events
    o -> Set direction of Enemy to RIGHT

    Conditions
    o - Enemy collides with Right Marker
    Events
    o - Set direction of Enemy to LEFT

    Conditions
    o - Every 00'20
    Events
    o - Have Enemy shoot Sight Detector at speed 50 (in his current direction)

    Conditions
    o - Number of Sight Detector is greater than 0
    Events
    o - Add 1 to alterable value A of Sight Detector

    Conditions
    o - Alterable value A of Sight Detector equals 10
    Events
    o - Destroy Sight Detector


    Conditions
    o - Sight Detector collides with Player
    o - Internal flag 0 of Enemy is OFF
    Events
    o - Set internal flag 0 of Enemy to ON

    Conditions
    o - Sight Detector collides with Player
    o - Internal flag 0 of Enemy is ON
    Events
    o - Set alterable value A of Enemy to 0

    Conditions
    o - Internal flag 0 of Enemy is ON
    Events
    o - Add 1 to alterable value A of Enemy

    Conditions
    o - Alterable value A of Enemy equals 20
    Events
    o - Set alterable value A of Enemy to 0
    o - Set internal flag 0 of Enemy to OFF

    Conditions
    o - Internal flag 0 of Enemy is ON
    Events
    o - Set speed of Enemy to 0

    Conditions
    o - Internal flag 0 of Enemy is OFF
    Events
    o - Set speed of Enemy to <your choice - whatever speed you want the enemy to walk at>


    Conditions
    o - Internal flag 0 of Enemy is ON
    o - Alterable value B of Enemy equals 0
    Events
    o - Set alterable value B of Enemy to 20
    o - Have Enemy shoot Enemy Bullet at speed <whatever's appropriate for your game>

    Conditions
    o - Alterable value B of Enemy is greater than 0
    Events
    o - Subtract 1 from alterable value B of Enemy

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!