Starting new VN Structure
This commit is contained in:
@ -0,0 +1,44 @@
|
||||
// Copyright (c) 2022 Dominic Masters
|
||||
//
|
||||
// This software is released under the MIT License.
|
||||
// https://opensource.org/licenses/MIT
|
||||
|
||||
#pragma once
|
||||
#include "scene/components/Components.hpp"
|
||||
#include "scene/components/display/material/SimpleTexturedMaterial.hpp"
|
||||
|
||||
namespace Dawn {
|
||||
class SimpleVisualNovelBackground : public SceneItemComponent {
|
||||
public:
|
||||
SimpleTexturedMaterial *material;
|
||||
MeshHost *meshHost;
|
||||
|
||||
/**
|
||||
* Create a simple Visual Novel Background prefab.
|
||||
*
|
||||
* @param scene Scene to add this background to.
|
||||
* @return Created background Scene Item.
|
||||
*/
|
||||
static SimpleVisualNovelBackground * create(Scene *scene);
|
||||
|
||||
/**
|
||||
* Construct a Simple Visual Novel Background. Simple Background is used
|
||||
* for a quick up and running Visual Novel scene, but does not have any
|
||||
* special effects or controls beyond updating a texture and mesh.
|
||||
*
|
||||
* @param item Scene Item this background belongs to.
|
||||
*/
|
||||
SimpleVisualNovelBackground(SceneItem *item);
|
||||
|
||||
std::vector<SceneItemComponent*> getDependencies() override;
|
||||
void onStart() override;
|
||||
|
||||
/**
|
||||
* Set the texture for the background. Auto updates the material and the
|
||||
* dimensions of the internal quad.
|
||||
*
|
||||
* @param texture Texture to use.
|
||||
*/
|
||||
void setTexture(Texture *texture);
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user