mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2025-02-09 13:24:01 +00:00
Merge branch 'experimental' of file:///Users/User/code/coding/Aquaria_fg_clean into experimental
This commit is contained in:
commit
7375a4879d
9 changed files with 36 additions and 9 deletions
|
@ -24,6 +24,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
#include "AquariaProgressBar.h"
|
||||
#include "tinyxml.h"
|
||||
#include "ModSelector.h"
|
||||
#include <algorithm>
|
||||
|
||||
#ifdef BBGE_BUILD_VFS
|
||||
#include "ModDownloader.h"
|
||||
|
@ -684,7 +685,7 @@ bool ModIconOnline::fixIcon()
|
|||
statusIcon = new Quad("modselect/ico_update", pos);
|
||||
statusIcon->alpha.interpolateTo(0.5f, 0.5f, -1, true, true);
|
||||
}
|
||||
else
|
||||
else
|
||||
statusIcon = new Quad("modselect/ico_check", pos);
|
||||
}
|
||||
|
||||
|
@ -819,7 +820,7 @@ void MenuIconBar::init()
|
|||
MenuIcon *ico;
|
||||
int y = (-height / 2) - 35;
|
||||
|
||||
|
||||
|
||||
ico = new MenuIcon(0);
|
||||
ico->label = dsq->continuity.stringBank.get(2027);
|
||||
ico->useQuad("modselect/installed");
|
||||
|
|
|
@ -2365,6 +2365,7 @@ void SceneEditor::loadScene()
|
|||
dsq->game->loadEntityTypeList();
|
||||
dsq->loadElementEffects();
|
||||
dsq->continuity.loadSongBank();
|
||||
dsq->continuity.stringBank.load();
|
||||
}
|
||||
|
||||
void SceneEditor::saveScene()
|
||||
|
|
|
@ -36,6 +36,7 @@ extern "C"
|
|||
#include "Web.h"
|
||||
#include "GridRender.h"
|
||||
#include "AfterEffect.h"
|
||||
#include <algorithm>
|
||||
|
||||
#include "../BBGE/MathFunctions.h"
|
||||
|
||||
|
@ -2502,7 +2503,7 @@ luaFunc(entity_setBoneLock)
|
|||
Bone *b = 0;
|
||||
if (lua_isuserdata(L, 3))
|
||||
b = bone(L, 3);
|
||||
|
||||
|
||||
bl.entity = e2;
|
||||
bl.bone = b;
|
||||
bl.on = true;
|
||||
|
@ -2926,7 +2927,7 @@ luaFunc(entity_playSfx)
|
|||
if(sfx.vol <= 0)
|
||||
sfx.vol = 1;
|
||||
sfx.loops = lua_tonumber(L, 5);
|
||||
|
||||
|
||||
float fadeOut = lua_tonumber(L, 6);
|
||||
sfx.maxdist = lua_tonumber(L, 7);
|
||||
sfx.relative = false;
|
||||
|
@ -8506,6 +8507,11 @@ luaFunc(castLine)
|
|||
return 3;
|
||||
}
|
||||
|
||||
luaFunc(getUserInputString)
|
||||
{
|
||||
luaReturnStr(dsq->getUserInputString(getString(L, 1), getString(L, 2), true).c_str());
|
||||
}
|
||||
|
||||
|
||||
luaFunc(inv_isFull)
|
||||
{
|
||||
|
@ -8657,6 +8663,12 @@ luaFunc(text_setAlign)
|
|||
luaReturnNil();
|
||||
}
|
||||
|
||||
luaFunc(text_getHeight)
|
||||
{
|
||||
BaseText *txt = getText(L);
|
||||
luaReturnNum(txt ? txt->getHeight() : 0.0f);
|
||||
}
|
||||
|
||||
luaFunc(loadShader)
|
||||
{
|
||||
int handle = 0;
|
||||
|
@ -8690,7 +8702,7 @@ luaFunc(shader_setAsAfterEffect)
|
|||
|
||||
if(core->afterEffectManager)
|
||||
done = core->afterEffectManager->setShaderPipelinePos(handle, pos);
|
||||
|
||||
|
||||
luaReturnBool(done);
|
||||
}
|
||||
|
||||
|
@ -9313,6 +9325,7 @@ static const struct {
|
|||
luaRegister(getObstruction),
|
||||
luaRegister(findPath),
|
||||
luaRegister(castLine),
|
||||
luaRegister(getUserInputString),
|
||||
|
||||
luaRegister(isFlag),
|
||||
|
||||
|
@ -9705,6 +9718,7 @@ static const struct {
|
|||
luaRegister(text_setFontSize),
|
||||
luaRegister(text_setWidth),
|
||||
luaRegister(text_setAlign),
|
||||
luaRegister(text_getHeight),
|
||||
|
||||
luaRegister(loadShader),
|
||||
luaRegister(createShader),
|
||||
|
|
|
@ -13,6 +13,7 @@ public:
|
|||
virtual void setWidth(int width) = 0;
|
||||
virtual void setFontSize(int sz) = 0;
|
||||
virtual void setAlign(Align a) = 0;
|
||||
virtual float getHeight() = 0;
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -72,7 +72,7 @@ public:
|
|||
void autoKern();
|
||||
void setBitmapFontEffect(BitmapFontEffect bfe);
|
||||
void render();
|
||||
float getHeight();
|
||||
virtual float getHeight();
|
||||
void unloadDevice();
|
||||
void reloadDevice();
|
||||
|
||||
|
|
|
@ -3561,7 +3561,11 @@ void Core::pollEvents()
|
|||
case SDL_KEYDOWN:
|
||||
{
|
||||
#if __APPLE__
|
||||
if ((event.key.keysym.sym == SDLK_q) && (event.key.keysym.mod & KMOD_GUI))
|
||||
#if SDL_VERSION_ATLEAST(2, 0, 0)
|
||||
if ((event.key.keysym.sym == SDLK_q) && (event.key.keysym.mod & KMOD_GUI))
|
||||
#else
|
||||
if ((event.key.keysym.sym == SDLK_q) && (event.key.keysym.mod & KMOD_META))
|
||||
#endif
|
||||
#else
|
||||
if ((event.key.keysym.sym == SDLK_F4) && (event.key.keysym.mod & KMOD_ALT))
|
||||
#endif
|
||||
|
|
|
@ -47,6 +47,11 @@ void DebugFont::setFontSize(int sz)
|
|||
fontDrawSize = sz;
|
||||
}
|
||||
|
||||
float DebugFont::getHeight()
|
||||
{
|
||||
return fontDrawSize * lines.size() * 1.5f; // vspc in render()
|
||||
}
|
||||
|
||||
void DebugFont::formatText()
|
||||
{
|
||||
std::string text;
|
||||
|
|
|
@ -33,6 +33,7 @@ public:
|
|||
void setFontSize(int sz);
|
||||
int getNumLines() { return lines.size(); }
|
||||
virtual void setAlign(Align align);
|
||||
virtual float getHeight();
|
||||
protected:
|
||||
int fontDrawSize, textWidth;
|
||||
void formatText();
|
||||
|
|
|
@ -21,7 +21,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
#ifndef BBGE_VECTOR_H
|
||||
#define BBGE_VECTOR_H
|
||||
|
||||
#include <math.h>
|
||||
#include <cmath>
|
||||
#include <float.h>
|
||||
#include <vector>
|
||||
#include "Event.h"
|
||||
|
@ -374,7 +374,7 @@ public:
|
|||
#ifdef BBGE_BUILD_WINDOWS
|
||||
return _isnan(x) || _isnan(y) || _isnan(z);
|
||||
#elif defined(BBGE_BUILD_UNIX)
|
||||
return isnan(x) || isnan(y) || isnan(z);
|
||||
return std::isnan(x) || std::isnan(y) || std::isnan(z);
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue