Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 2, 2013, 4:42:46 PM (11 years ago)
Author:
zifloria
Message:

invader almost done

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/invaders/src/modules/invader/InvaderEnemy.cc

    r9859 r9862  
    5656        if (player != NULL)
    5757        {
    58             float newZ = abs(getPosition().x - player->getPosition().x) * (player->getPosition().z - getPosition().z);
     58            float newZ = 2/(pow(abs(getPosition().x - player->getPosition().x) * 0.01, 2) + 1) * (player->getPosition().z - getPosition().z);
    5959            // if (newZ < 0)
    6060            //     newZ = (-100 < newZ)?-100:newZ;
Note: See TracChangeset for help on using the changeset viewer.