How to control a turret in MOBA game

I am using photonserver for my moba game develope,and I know some server side coding,but I don’t know how to control the turret and mini soldier’s AI. Like when a hero or mini soldier enters the turret’s attack area,how do a turret know and attack. I am using unity to develope the client,but I don’t want to control the turrets in the client side. Please help me,thanks a lot.

Answers

  • hi, @hxfdean

    we are developing tool for networking, not games. so, we are not the best source of knowlege in this area.
    i can give you pices of advise only related to our server.

    1. i would recommend for you to use plugin. it will be easier to develop then modifing load balancing code
    2. inside plugin you may start timer that will tick every 50 -100 ms. during handling this tick you may excecute all AI logic
    3. i assume you will need something like AI map for your level. it may contain trigger areas, tracks for monsters and so on. using trigger area you may check if player is in some area he might be attacked buy turret.

    best,
    ilya
Sign In or Register to comment.