mirror of
https://github.com/ApfelTeeSaft/PlanetFleet.git
synced 2026-08-26 19:33:38 +00:00
22 lines
764 B
C++
22 lines
764 B
C++
#include <solUtil.h>
|
|
|
|
#include "gameObject.h"
|
|
#include "gameObjectListbox.h"
|
|
#include "gameObjectFrameController.h"
|
|
|
|
namespace battleship{
|
|
using namespace std;
|
|
using namespace vb01;
|
|
using namespace vb01Gui;
|
|
using namespace gameBase;
|
|
|
|
GameObjectListbox::GameObjectListbox(bool ul, Vector2 pos, Vector2 size, vector<string> lines, int maxDisplay, string fontPath) : Listbox(pos, size, lines, maxDisplay, fontPath), unitListbox(ul) {}
|
|
|
|
void GameObjectListbox::onClose(){
|
|
GameObjectFrameController *ufCtr = GameObjectFrameController::getSingleton();
|
|
GameObject::Type type = (unitListbox ? GameObject::Type::UNIT : GameObject::Type::RESOURCE_DEPOSIT);
|
|
ufCtr->addGameObjectFrame(GameObjectFrame(selectedOption, type));
|
|
ufCtr->setPlacingFrames(true);
|
|
}
|
|
}
|