Multi-Mode Formula

Jump to navigation Jump to search
Revision as of 8 September 2017 at 10:22.
This is the thread's initial revision.

Multi-Mode Formula

I was working for a micro bot and I found a new type of multi-mode movement system.(I think)
Simply it is:
  • Complexity starts from 0.
  • Every time the bot dies, it increases the complexity.
  • Every time the enemy fires call setAhead(getDir(complexity)).
    public double getDir(int complexity) {
        double extraMove; 
        double moveDir = extraMove = 1.0 / complexity;
        for(int i = 1; i < complexity; i++) {
            moveDir += Math.sin(getTime() / i / (10.0 / (complexity + 1)));
        }
        return Math.signum(moveDir) * ((extraMove + 18) * (complexity + 1));
    }
Just with this code these happen:
  • First round: Musashi trick.
  • Second round: Stop'n go.
  • Third round: Random(not actually random) stop'n go.
  • Fourth round: Musashi trick + stop'n go + not random.
  • Fifth round: Oscillator movement.

Any thoughts?

    Dsekercioglu (talk)11:22, 8 September 2017