Changeset 1360


Ignore:
Timestamp:
May 10, 2012, 9:25:56 AM (9 years ago)
Author:
sam
Message:

orbital: fix a few compilation warnings.

Location:
trunk/orbital
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/orbital/CommandParser.h

    r1327 r1360  
     1//
     2// Orbital
     3//
     4// Copyright: (c) 2012 Various People
     5//
     6
    17#if !defined __COMMANDPARSER_H__
    28#define __COMMANDPARSER_H__
     
    814    {}
    915
    10     virtual void SwitchCommand(char const *&command) { }
     16    virtual void SwitchCommand(char const *&command)
     17    {
     18        (void)command;
     19    }
     20
    1121    bool CheckCommand(char const *keyword, char const *&command)
    12         {
    13                 return (!strncmp(command, keyword, strlen(keyword))
    14             && (command[strlen(keyword)] < 'a' || command[strlen(keyword)] > 'z') \
    15             && (command += strlen(keyword)));
    16         }
     22    {
     23        return (!strncmp(command, keyword, strlen(keyword))
     24          && (command[strlen(keyword)] < 'a' || command[strlen(keyword)] > 'z')
     25          && (command += strlen(keyword)));
     26    }
    1727
    18         void SendCommand(char const *command)
     28    void SendCommand(char const *command)
    1929    {
    2030        for (char const *p = command; p && *p; )
    2131        {
    22                         SwitchCommand(p);
     32            SwitchCommand(p);
    2333
    2434            /* Skip all remaining letters */
  • trunk/orbital/player.h

    r1359 r1360  
    7979        if (rightleft * rightleft + updown * updown > 0.2f)
    8080        {
    81             float norm = sqrt(rightleft * rightleft + updown * updown);
    8281            float angle = atan2(updown, rightleft);
    8382            angle = (int)(angle / (M_PI / 4.f) + 8.5f) * (M_PI / 4.f);
Note: See TracChangeset for help on using the changeset viewer.