mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2024-11-15 14:09:06 +00:00
Merge branch 'experimental' of file:///Users/User/code/coding/Aquaria_fg_clean into experimental
This commit is contained in:
commit
87774839fe
2 changed files with 18 additions and 11 deletions
|
@ -408,9 +408,9 @@ void PathFinding::molestPath(VectorPath &path)
|
|||
}
|
||||
}
|
||||
}
|
||||
std::ostringstream os;
|
||||
/*std::ostringstream os;
|
||||
os << "pushing node [" << i << "] out by (" << n.x << ", " << n.y << ") - dist: " << dist << " maxDist: " << maxDist;
|
||||
debugLog(os.str());
|
||||
debugLog(os.str());*/
|
||||
//path.getPathNode(i)->value += n;
|
||||
normals[i] = n;
|
||||
}
|
||||
|
@ -453,9 +453,9 @@ void PathFinding::molestPath(VectorPath &path)
|
|||
//bowl_loop:
|
||||
sz=path.getNumPathNodes();
|
||||
|
||||
std::ostringstream os;
|
||||
/*std::ostringstream os;
|
||||
os << "kill bowls # " << runs;
|
||||
debugLog(os.str());
|
||||
debugLog(os.str());*/
|
||||
|
||||
for (i = start; i < sz-1; i++)
|
||||
{
|
||||
|
@ -502,9 +502,9 @@ void PathFinding::molestPath(VectorPath &path)
|
|||
*/
|
||||
{
|
||||
path.removeNodes(i+1, lastSuccessNode-1);
|
||||
std::ostringstream os;
|
||||
/*std::ostringstream os;
|
||||
os << "killing bowl: " << i+1 << " - " << lastSuccessNode-1;
|
||||
debugLog(os.str());
|
||||
debugLog(os.str());*/
|
||||
//start = lastSuccessNode - (lastSuccessNode-i);
|
||||
//start = i+1;
|
||||
//i = i+1;
|
||||
|
@ -516,7 +516,7 @@ void PathFinding::molestPath(VectorPath &path)
|
|||
}
|
||||
sz = path.getNumPathNodes();
|
||||
}
|
||||
debugLog("kill bowls done");
|
||||
//debugLog("kill bowls done");
|
||||
sz=path.getNumPathNodes();
|
||||
|
||||
// remove last node
|
||||
|
|
|
@ -3090,6 +3090,11 @@ luaFunc(avatar_isRolling)
|
|||
luaReturnBool(dsq->game->avatar->isRolling());
|
||||
}
|
||||
|
||||
luaFunc(avatar_isSwimming)
|
||||
{
|
||||
luaReturnBool(dsq->game->avatar->isSwimming());
|
||||
}
|
||||
|
||||
luaFunc(avatar_isOnWall)
|
||||
{
|
||||
bool v = dsq->game->avatar->state.lockedToWall;
|
||||
|
@ -5672,13 +5677,14 @@ luaFunc(entity_doCollisionAvoidance)
|
|||
|
||||
int useVel2 = lua_tonumber(L, 6);
|
||||
bool onlyVP = getBool(L, 7);
|
||||
int ignoreObs = lua_tointeger(L, 8);
|
||||
|
||||
if (e)
|
||||
{
|
||||
if (useVel2)
|
||||
ret = e->doCollisionAvoidance(lua_tonumber(L, 2), lua_tointeger(L, 3), lua_tonumber(L, 4), &e->vel2, lua_tonumber(L, 5), onlyVP);
|
||||
ret = e->doCollisionAvoidance(lua_tonumber(L, 2), lua_tointeger(L, 3), lua_tonumber(L, 4), &e->vel2, lua_tonumber(L, 5), ignoreObs, onlyVP);
|
||||
else
|
||||
ret = e->doCollisionAvoidance(lua_tonumber(L, 2), lua_tointeger(L, 3), lua_tonumber(L, 4), 0, lua_tonumber(L, 5));
|
||||
ret = e->doCollisionAvoidance(lua_tonumber(L, 2), lua_tointeger(L, 3), lua_tonumber(L, 4), 0, lua_tonumber(L, 5), ignoreObs);
|
||||
}
|
||||
luaReturnBool(ret);
|
||||
}
|
||||
|
@ -5794,7 +5800,7 @@ luaFunc(entity_followEntity)
|
|||
|
||||
luaFunc(toggleInput)
|
||||
{
|
||||
int v = lua_tointeger(L, 1);
|
||||
bool v = getBool(L, 1);
|
||||
if (v)
|
||||
dsq->game->avatar->enableInput();
|
||||
else
|
||||
|
@ -7716,7 +7722,7 @@ luaFunc(entity_setWeight)
|
|||
luaFunc(pickupGem)
|
||||
{
|
||||
dsq->continuity.pickupGem(getString(L), !getBool(L, 2));
|
||||
luaReturnNil();
|
||||
luaReturnInt(dsq->continuity.gems.size() - 1);
|
||||
}
|
||||
|
||||
luaFunc(setGemPosition)
|
||||
|
@ -8860,6 +8866,7 @@ static const struct {
|
|||
luaRegister(avatar_isBursting),
|
||||
luaRegister(avatar_isLockable),
|
||||
luaRegister(avatar_isRolling),
|
||||
luaRegister(avatar_isSwimming),
|
||||
luaRegister(avatar_isOnWall),
|
||||
luaRegister(avatar_isShieldActive),
|
||||
luaRegister(avatar_setShieldActive),
|
||||
|
|
Loading…
Reference in a new issue