0

尽管我到处寻找我认为可能找到答案的地方,但我无法弄清楚如何正确记录函数“struct Entity * NewEntity()”,以便在 doxywizard 运行时显示为记录。

它只是一直告诉我:“警告:文件 entity.h 的成员 NewEntity()(函数)没有记录。”

然而,代码是:

/***********************************************************************************************//*
* @fn   struct Entity* NewEntity()
*
* @brief    Initialises single entity.
* @return   null if it fails, else finds empty spot in entity manager to use to make a new entity
* @author   br66
* @date     3/30/2017
**************************************************************************************************/
struct Entity* NewEntity()
{
    int i;

    for (i = 0; i < 255; i++)
    {
        if (_entityM[i].m_active == 0)
        {
            // clear that space, just in case there's anything left over from its last use
            memset(&_entityM[i], 0, sizeof(struct Entity));

            _entityM[i].m_active = 1;

            // any entity defaults? stay tooooooned

            _entity_max_recorded++;

            return &_entityM[i];
        }
    }

    return NULL;
}

阅读文档,它告诉我确保记录头文件,但它没有改变任何东西,我仍然收到警告。

4

1 回答 1

1

你有两个评论块。/****...***/ /* @fn... */

doxygen 没有查看第二条评论。

一个 doxygen 注释块应该以一个额外的 '*' 开头/** @fn... */

于 2017-05-08T07:10:39.577 回答