fix
This commit is contained in:
parent
1248defb9b
commit
f2f4889161
2 changed files with 5 additions and 24 deletions
|
@ -50,7 +50,7 @@ namespace {
|
||||||
.w = 500, .h = 500
|
.w = 500, .h = 500
|
||||||
}, avatar = {
|
}, avatar = {
|
||||||
.current{},
|
.current{},
|
||||||
.pos_x = 0, .pos_y = 0,
|
.pos_x = 10, .pos_y = 0,
|
||||||
.w = 500, .h = 500
|
.w = 500, .h = 500
|
||||||
};
|
};
|
||||||
ADVect::ImageTrack dialogue_bg = {
|
ADVect::ImageTrack dialogue_bg = {
|
||||||
|
@ -249,8 +249,8 @@ namespace ADVect {
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int argc, char* argv[]) {
|
int main(int argc, char* argv[]) {
|
||||||
// std::filesystem::current_path("E:\\Archive\\Projects\\NouVeL\\ADVect\\runtime");
|
std::filesystem::current_path("E:\\Archive\\Projects\\NouVeL\\ADVect\\runtime");
|
||||||
std::filesystem::current_path("/Users/lachrymal/Projects/NouVeL/ADVect/runtime/");
|
// std::filesystem::current_path("/Users/lachrymal/Projects/NouVeL/ADVect/runtime/");
|
||||||
|
|
||||||
NVL::Environment::ENVIRONMENT.enter({
|
NVL::Environment::ENVIRONMENT.enter({
|
||||||
{
|
{
|
||||||
|
@ -293,26 +293,7 @@ int main(int argc, char* argv[]) {
|
||||||
{
|
{
|
||||||
u"Show",
|
u"Show",
|
||||||
NVL::Environment::Variable([](std::vector<NVL::Environment::Variable> args) {
|
NVL::Environment::Variable([](std::vector<NVL::Environment::Variable> args) {
|
||||||
std::string name = NVL::to_std_string(std::get<NVL::String>(NVL::Environment::Variable(args[0]).value));
|
std::get<std::function<NVL::Environment::Variable(std::vector<NVL::Environment::Variable>)>>(args[0].value)({args[1]});
|
||||||
/* NamedImageTrack* t = find_image_track(name);
|
|
||||||
if (t == nullptr) {
|
|
||||||
std::cerr << "ADV: Cannot find ImageTrack " << name << std::endl;
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
auto s = std::get<NVL::String>(NVL::Environment::Variable(args[1]).value);
|
|
||||||
auto s2 = NVL::to_std_string(s);
|
|
||||||
t->current = ADVect::Graphics::GetImageTextureFromFile(s2);
|
|
||||||
}*/
|
|
||||||
if (name == "BG")
|
|
||||||
bg.change(current_time, ADVect::Graphics::GetImageTextureFromFile(NVL::to_std_string(std::get<NVL::String>(NVL::Environment::Variable(args[1]).value))), 200);
|
|
||||||
// bg.current = ADVect::Graphics::GetImageTextureFromFile(NVL::to_std_string(std::get<NVL::String>(NVL::Environment::Variable(args[1]).value)));
|
|
||||||
else if (name == "Avatar")
|
|
||||||
avatar.change(current_time, ADVect::Graphics::GetImageTextureFromFile(NVL::to_std_string(std::get<NVL::String>(NVL::Environment::Variable(args[1]).value))), 200);
|
|
||||||
// avatar.current = ADVect::Graphics::GetImageTextureFromFile(NVL::to_std_string(std::get<NVL::String>(NVL::Environment::Variable(args[1]).value)));
|
|
||||||
else if (name == "BGDialogue")
|
|
||||||
dialogue_bg.current = ADVect::Graphics::GetImageTextureFromFile(NVL::to_std_string(std::get<NVL::String>(NVL::Environment::Variable(args[1]).value)));
|
|
||||||
else
|
|
||||||
std::cerr << "ADV: Cannot find ImageTrack " << name << std::endl;
|
|
||||||
return NVL::Environment::Type::Nil;
|
return NVL::Environment::Type::Nil;
|
||||||
}, 2)
|
}, 2)
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,7 +12,7 @@ include_directories ("include" "../NVL/")
|
||||||
add_subdirectory("ext/freetype")
|
add_subdirectory("ext/freetype")
|
||||||
add_subdirectory("ext/bgfx")
|
add_subdirectory("ext/bgfx")
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
include_directories("include_windows")
|
include_directories("include_windows" "include_windows/SDL2")
|
||||||
target_link_libraries (Game PRIVATE ${PROJECT_SOURCE_DIR}/lib/SDL2.lib ${PROJECT_SOURCE_DIR}/lib/SDL2main.lib NVL freetype bgfx bx)
|
target_link_libraries (Game PRIVATE ${PROJECT_SOURCE_DIR}/lib/SDL2.lib ${PROJECT_SOURCE_DIR}/lib/SDL2main.lib NVL freetype bgfx bx)
|
||||||
elseif (APPLE)
|
elseif (APPLE)
|
||||||
set_target_properties(Game PROPERTIES XCODE_ATTRIBUTE_ENABLE_BITCODE "NO")
|
set_target_properties(Game PROPERTIES XCODE_ATTRIBUTE_ENABLE_BITCODE "NO")
|
||||||
|
|
Loading…
Add table
Reference in a new issue