Nothing to say..
This commit is contained in:
parent
3437130216
commit
ebb8c1e303
@ -1,6 +1,6 @@
|
|||||||
#############################################################################
|
#############################################################################
|
||||||
# Makefile for building: Unuk-QT
|
# Makefile for building: Unuk-QT
|
||||||
# Generated by qmake (2.01a) (Qt 4.7.3) on: Sat Dec 17 23:40:48 2011
|
# Generated by qmake (2.01a) (Qt 4.7.3) on: Mon Dec 19 22:05:17 2011
|
||||||
# Project: Unuk-QT.pro
|
# Project: Unuk-QT.pro
|
||||||
# Template: app
|
# Template: app
|
||||||
# Command: /usr/bin/qmake-qt4 -spec /usr/share/qt4/mkspecs/linux-g++ CONFIG+=debug -o Makefile Unuk-QT.pro
|
# Command: /usr/bin/qmake-qt4 -spec /usr/share/qt4/mkspecs/linux-g++ CONFIG+=debug -o Makefile Unuk-QT.pro
|
||||||
@ -68,8 +68,7 @@ SOURCES = ../src/libUnuk/Debug.cpp \
|
|||||||
../src/Unuk/Game.cpp \
|
../src/Unuk/Game.cpp \
|
||||||
../src/libUnuk/MapElement.cpp \
|
../src/libUnuk/MapElement.cpp \
|
||||||
../src/libUnuk/MapEntities.cpp \
|
../src/libUnuk/MapEntities.cpp \
|
||||||
../src/libUnuk/FPS.cpp \
|
../src/libUnuk/FPS.cpp
|
||||||
../src/libUnuk/DialogueBox.cpp
|
|
||||||
OBJECTS = Debug.o \
|
OBJECTS = Debug.o \
|
||||||
main.o \
|
main.o \
|
||||||
Input.o \
|
Input.o \
|
||||||
@ -95,8 +94,7 @@ OBJECTS = Debug.o \
|
|||||||
Game.o \
|
Game.o \
|
||||||
MapElement.o \
|
MapElement.o \
|
||||||
MapEntities.o \
|
MapEntities.o \
|
||||||
FPS.o \
|
FPS.o
|
||||||
DialogueBox.o
|
|
||||||
DIST = /usr/share/qt4/mkspecs/common/g++.conf \
|
DIST = /usr/share/qt4/mkspecs/common/g++.conf \
|
||||||
/usr/share/qt4/mkspecs/common/unix.conf \
|
/usr/share/qt4/mkspecs/common/unix.conf \
|
||||||
/usr/share/qt4/mkspecs/common/linux.conf \
|
/usr/share/qt4/mkspecs/common/linux.conf \
|
||||||
@ -196,7 +194,7 @@ qmake: FORCE
|
|||||||
|
|
||||||
dist:
|
dist:
|
||||||
@$(CHK_DIR_EXISTS) .tmp/Unuk-QT1.0.0 || $(MKDIR) .tmp/Unuk-QT1.0.0
|
@$(CHK_DIR_EXISTS) .tmp/Unuk-QT1.0.0 || $(MKDIR) .tmp/Unuk-QT1.0.0
|
||||||
$(COPY_FILE) --parents $(SOURCES) $(DIST) .tmp/Unuk-QT1.0.0/ && $(COPY_FILE) --parents ../src/libUnuk/Debug.h ../src/Libs/wglext.h ../src/Libs/glxext.h ../src/libUnuk/Input.h ../src/libUnuk/Rect.h ../src/libUnuk/Timer.h ../src/libUnuk/Font.h ../Constants.h ../src/Unuk/Constants.h ../src/libUnuk/ApplySurface.h ../src/Unuk/Globals.h ../src/libUnuk/ImageLoader.h ../src/libUnuk/TextureManager.h ../src/libUnuk/Texture.h ../src/libUnuk/Text.h ../src/libUnuk/MapTile.h ../src/libUnuk/Map.h ../src/libUnuk/Button.h ../src/libUnuk/ButtonToggle.h ../src/libUnuk/MainMenu.h ../src/libUnuk/ParticleEmitter.h ../src/libUnuk/IngameMenu.h ../src/libUnuk/Collision.h ../src/libUnuk/Character.h ../src/libUnuk/NPC.h ../src/Unuk/Player.h ../src/Unuk/Game.h ../src/libUnuk/MapElement.h ../src/libUnuk/MapEntities.h ../src/libUnuk/FPS.h ../src/libUnuk/DialogueBox.h .tmp/Unuk-QT1.0.0/ && $(COPY_FILE) --parents ../src/libUnuk/Debug.cpp ../src/Unuk/main.cpp ../src/libUnuk/Input.cpp ../src/libUnuk/Timer.cpp ../src/libUnuk/Font.cpp ../src/libUnuk/ApplySurface.cpp ../src/Unuk/Globals.cpp ../src/libUnuk/Rect.cpp ../src/libUnuk/ImageLoader.cpp ../src/libUnuk/TextureManager.cpp ../src/libUnuk/Texture.cpp ../src/libUnuk/Text.cpp ../src/libUnuk/Map.cpp ../src/libUnuk/Button.cpp ../src/libUnuk/ButtonToggle.cpp ../src/libUnuk/ParticleEmitter.cpp ../src/libUnuk/MainMenu.cpp ../src/libUnuk/IngameMenu.cpp ../src/libUnuk/Collision.cpp ../src/libUnuk/Character.cpp ../src/libUnuk/NPC.cpp ../src/Unuk/Player.cpp ../src/Unuk/Game.cpp ../src/libUnuk/MapElement.cpp ../src/libUnuk/MapEntities.cpp ../src/libUnuk/FPS.cpp ../src/libUnuk/DialogueBox.cpp .tmp/Unuk-QT1.0.0/ && (cd `dirname .tmp/Unuk-QT1.0.0` && $(TAR) Unuk-QT1.0.0.tar Unuk-QT1.0.0 && $(COMPRESS) Unuk-QT1.0.0.tar) && $(MOVE) `dirname .tmp/Unuk-QT1.0.0`/Unuk-QT1.0.0.tar.gz . && $(DEL_FILE) -r .tmp/Unuk-QT1.0.0
|
$(COPY_FILE) --parents $(SOURCES) $(DIST) .tmp/Unuk-QT1.0.0/ && $(COPY_FILE) --parents ../src/libUnuk/Debug.h ../src/Libs/wglext.h ../src/Libs/glxext.h ../src/libUnuk/Input.h ../src/libUnuk/Rect.h ../src/libUnuk/Timer.h ../src/libUnuk/Font.h ../Constants.h ../src/Unuk/Constants.h ../src/libUnuk/ApplySurface.h ../src/Unuk/Globals.h ../src/libUnuk/ImageLoader.h ../src/libUnuk/TextureManager.h ../src/libUnuk/Texture.h ../src/libUnuk/Text.h ../src/libUnuk/MapTile.h ../src/libUnuk/Map.h ../src/libUnuk/Button.h ../src/libUnuk/ButtonToggle.h ../src/libUnuk/MainMenu.h ../src/libUnuk/ParticleEmitter.h ../src/libUnuk/IngameMenu.h ../src/libUnuk/Collision.h ../src/libUnuk/Character.h ../src/libUnuk/NPC.h ../src/Unuk/Player.h ../src/Unuk/Game.h ../src/libUnuk/MapElement.h ../src/libUnuk/MapEntities.h ../src/libUnuk/FPS.h .tmp/Unuk-QT1.0.0/ && $(COPY_FILE) --parents ../src/libUnuk/Debug.cpp ../src/Unuk/main.cpp ../src/libUnuk/Input.cpp ../src/libUnuk/Timer.cpp ../src/libUnuk/Font.cpp ../src/libUnuk/ApplySurface.cpp ../src/Unuk/Globals.cpp ../src/libUnuk/Rect.cpp ../src/libUnuk/ImageLoader.cpp ../src/libUnuk/TextureManager.cpp ../src/libUnuk/Texture.cpp ../src/libUnuk/Text.cpp ../src/libUnuk/Map.cpp ../src/libUnuk/Button.cpp ../src/libUnuk/ButtonToggle.cpp ../src/libUnuk/ParticleEmitter.cpp ../src/libUnuk/MainMenu.cpp ../src/libUnuk/IngameMenu.cpp ../src/libUnuk/Collision.cpp ../src/libUnuk/Character.cpp ../src/libUnuk/NPC.cpp ../src/Unuk/Player.cpp ../src/Unuk/Game.cpp ../src/libUnuk/MapElement.cpp ../src/libUnuk/MapEntities.cpp ../src/libUnuk/FPS.cpp .tmp/Unuk-QT1.0.0/ && (cd `dirname .tmp/Unuk-QT1.0.0` && $(TAR) Unuk-QT1.0.0.tar Unuk-QT1.0.0 && $(COMPRESS) Unuk-QT1.0.0.tar) && $(MOVE) `dirname .tmp/Unuk-QT1.0.0`/Unuk-QT1.0.0.tar.gz . && $(DEL_FILE) -r .tmp/Unuk-QT1.0.0
|
||||||
|
|
||||||
|
|
||||||
clean:compiler_clean
|
clean:compiler_clean
|
||||||
@ -493,9 +491,6 @@ FPS.o: ../src/libUnuk/FPS.cpp ../src/libUnuk/FPS.h \
|
|||||||
../src/libUnuk/Timer.h
|
../src/libUnuk/Timer.h
|
||||||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o FPS.o ../src/libUnuk/FPS.cpp
|
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o FPS.o ../src/libUnuk/FPS.cpp
|
||||||
|
|
||||||
DialogueBox.o: ../src/libUnuk/DialogueBox.cpp ../src/libUnuk/DialogueBox.h
|
|
||||||
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o DialogueBox.o ../src/libUnuk/DialogueBox.cpp
|
|
||||||
|
|
||||||
####### Install
|
####### Install
|
||||||
|
|
||||||
install: FORCE
|
install: FORCE
|
||||||
|
@ -36,8 +36,7 @@ HEADERS += ../src/libUnuk/Debug.h \
|
|||||||
../src/Unuk/Game.h \
|
../src/Unuk/Game.h \
|
||||||
../src/libUnuk/MapElement.h \
|
../src/libUnuk/MapElement.h \
|
||||||
../src/libUnuk/MapEntities.h \
|
../src/libUnuk/MapEntities.h \
|
||||||
../src/libUnuk/FPS.h \
|
../src/libUnuk/FPS.h
|
||||||
../src/libUnuk/DialogueBox.h
|
|
||||||
SOURCES += ../src/libUnuk/Debug.cpp \
|
SOURCES += ../src/libUnuk/Debug.cpp \
|
||||||
../src/Unuk/main.cpp \
|
../src/Unuk/main.cpp \
|
||||||
../src/libUnuk/Input.cpp \
|
../src/libUnuk/Input.cpp \
|
||||||
@ -63,5 +62,4 @@ SOURCES += ../src/libUnuk/Debug.cpp \
|
|||||||
../src/Unuk/Game.cpp \
|
../src/Unuk/Game.cpp \
|
||||||
../src/libUnuk/MapElement.cpp \
|
../src/libUnuk/MapElement.cpp \
|
||||||
../src/libUnuk/MapEntities.cpp \
|
../src/libUnuk/MapEntities.cpp \
|
||||||
../src/libUnuk/FPS.cpp \
|
../src/libUnuk/FPS.cpp
|
||||||
../src/libUnuk/DialogueBox.cpp
|
|
||||||
|
@ -9,14 +9,14 @@ Button::~Button(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void Button::SetOutRGB(Uint8 r, Uint8 g, Uint8 b) {
|
void Button::SetOutRGB(Uint8 r, Uint8 g, Uint8 b) {
|
||||||
button.SetRGB(r, g, b);
|
_button.SetRGB(r, g, b);
|
||||||
_mouseOutColour.r = r;
|
_mouseOutColour.r = r;
|
||||||
_mouseOutColour.g = g;
|
_mouseOutColour.g = g;
|
||||||
_mouseOutColour.b = b;
|
_mouseOutColour.b = b;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Button::SetOutRGB(SDL_Color colour) {
|
void Button::SetOutRGB(SDL_Color colour) {
|
||||||
button.SetRGB(colour);
|
_button.SetRGB(colour);
|
||||||
_mouseOutColour = colour;
|
_mouseOutColour = colour;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -33,7 +33,7 @@ void Button::SetOverRGB(SDL_Color colour) {
|
|||||||
void Button::SetXY(int xArg, int yArg) {
|
void Button::SetXY(int xArg, int yArg) {
|
||||||
x = xArg;
|
x = xArg;
|
||||||
y = yArg;
|
y = yArg;
|
||||||
button.SetXY(x, y);
|
_button.SetXY(x, y);
|
||||||
|
|
||||||
_text.SetXY(x + 10, y + 10);
|
_text.SetXY(x + 10, y + 10);
|
||||||
}
|
}
|
||||||
@ -56,36 +56,36 @@ void Button::SetText(string textArg) {
|
|||||||
|
|
||||||
w = _text.GetWidth();
|
w = _text.GetWidth();
|
||||||
h = _text.GetHeight();
|
h = _text.GetHeight();
|
||||||
button.SetWidthHeight(w + 20, h + 15);
|
_button.SetWidthHeight(w + 20, h + 15);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Button::CheckMouseOver(void) {
|
bool Button::CheckMouseOver(void) {
|
||||||
if(event.motion.x > button.GetX() && event.motion.x < button.GetX() + button.GetWidth()) {
|
if(event.motion.x > _button.GetX() && event.motion.x < _button.GetX() + _button.GetWidth()) {
|
||||||
if(event.motion.y > button.GetY() && event.motion.y < button.GetY() + button.GetHeight()) {
|
if(event.motion.y > _button.GetY() && event.motion.y < _button.GetY() + _button.GetHeight()) {
|
||||||
button.SetRGB(_mouseOverColour.r, _mouseOverColour.g, _mouseOverColour.b);
|
_button.SetRGB(_mouseOverColour.r, _mouseOverColour.g, _mouseOverColour.b);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
button.SetRGB(_mouseOutColour);
|
_button.SetRGB(_mouseOutColour);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Button::Render(void) {
|
void Button::Render(void) {
|
||||||
button.Draw();
|
_button.Draw();
|
||||||
_text.Render();
|
_text.Render();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Button::Render(int xArg, int yArg) {
|
void Button::Render(int xArg, int yArg) {
|
||||||
button.Draw(xArg, yArg);
|
_button.Draw(xArg, yArg);
|
||||||
_text.Render(xArg, yArg);
|
_text.Render(xArg, yArg);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Button::RenderLiteral(void) {
|
void Button::RenderLiteral(void) {
|
||||||
button.DrawLiteral();
|
_button.DrawLiteral();
|
||||||
_text.RenderLiteral();
|
_text.RenderLiteral();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Button::RenderLiteral(int xArg, int yArg) {
|
void Button::RenderLiteral(int xArg, int yArg) {
|
||||||
button.DrawLiteral(xArg, yArg);
|
_button.DrawLiteral(xArg, yArg);
|
||||||
_text.RenderLiteral(xArg, yArg);
|
_text.RenderLiteral(xArg, yArg);
|
||||||
}
|
}
|
||||||
|
@ -24,10 +24,10 @@ public:
|
|||||||
|
|
||||||
void SetXY(int xArg, int yArg);
|
void SetXY(int xArg, int yArg);
|
||||||
|
|
||||||
int GetX(void) { return x; }
|
int GetX(void) const { return x; }
|
||||||
int GetY(void) { return y; }
|
int GetY(void) const { return y; }
|
||||||
int GetWidth(void) { return w; }
|
int GetWidth(void) const { return w; }
|
||||||
int GetHeight(void) { return h; }
|
int GetHeight(void) const { return h; }
|
||||||
|
|
||||||
bool CheckMouseOver(void);
|
bool CheckMouseOver(void);
|
||||||
|
|
||||||
@ -46,7 +46,7 @@ private:
|
|||||||
int w;
|
int w;
|
||||||
int h;
|
int h;
|
||||||
|
|
||||||
Rect button;
|
Rect _button;
|
||||||
Text _text;
|
Text _text;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1 +0,0 @@
|
|||||||
#include "DialogueBox.h"
|
|
@ -1,13 +0,0 @@
|
|||||||
#ifndef _DIALOGUEBOX_H_
|
|
||||||
#define _DIALOGUEBOX_H_
|
|
||||||
|
|
||||||
class DialogueBox {
|
|
||||||
public:
|
|
||||||
|
|
||||||
void Set(void);
|
|
||||||
|
|
||||||
private:
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif
|
|
Loading…
Reference in New Issue
Block a user