repo_name
stringlengths
5
122
path
stringlengths
3
232
text
stringlengths
6
1.05M
BitPaw/BitFireEngine
SystemResource/Source/Network/ProtocolMode.cpp
<gh_stars>1-10 #include "ProtocolMode.h" #define ProtocolInvalid (unsigned int)-1 #define ProtocolHOPOPTS 0 #define ProtocolICMP 1 #define ProtocolIGMP 2 #define ProtocolGGP 3 #define ProtocolIPV4 4 #define ProtocolST 5 #define ProtocolTCP 6 #define ProtocolCBT 7 #define ProtocolEGP 8 #define ProtocolIGP 9 #define Pro...
BitPaw/BitFireEngine
SystemResource/Source/Sound/MP3/MP3.cpp
#include "MP3.h" #include "MP3Header.h" #include "MPEGAudioTag.h" #include "../../File/FileStream.h" #include <cstddef> #include <cstring> BF::FileActionResult BF::MP3::Load(const wchar_t* filePath) { FileStream file; FileActionResult loadingResult = file.ReadFromDisk(filePath); if (loadingResult != FileActionRe...
BitPaw/BitFireEngine
SystemResource/Source/Service/HTTP/HTTPServer.cpp
<reponame>BitPaw/BitFireEngine<filename>SystemResource/Source/Service/HTTP/HTTPServer.cpp #include "HTTPServer.h" #include <cstring> void BF::HTTPServer::MessageParse(const char* message) { } void BF::HTTPServer::OnClientConnected(Client& client) { } void BF::HTTPServer::OnClientDisconnected(Client& client) { } ...
BitPaw/BitFireEngine
SystemResource/Source/Math/Geometry/Matrix4x4.hpp
#pragma once #include "Vector3.hpp" #include "Vector4.hpp" #include "AngleRadians.hpp" #include <cstring> #define XAxisX 0 #define XAxisY 4 #define XAxisZ 8 #define XAxisW 12 #define YAxisX 1 #define YAxisY 5 #define YAxisZ 9 #define YAxisW 13 #define ZAxisX 2 #define ZAxisY 6 #define ZAxisZ 10 #define ZAxisW 14 ...
BitPaw/BitFireEngine
SystemResource/Source/Math/Geometry/Shape/Hexagon.cpp
#include "Hexagon.h"
BitPaw/BitFireEngine
SystemResource/Source/Network/IPVersion.cpp
<gh_stars>1-10 #include "IPVersion.h" /* Check if the given IPv4 is Valid Returns the following: 0 - Valid IPv4 1 - Nullpointer as Parameter 2 - Invalid Character (only 0-9 or .) 3 - Octet too large (>255) 4 - Too long (>15) 5 - Too many Octets (more that 4) */ char BF::IsValidIPv4(const char* ipAdres...
BitPaw/BitFireEngine
SystemResource/Source/Image/PNG/PNGColorTree.cpp
#include "PNGColorTree.h" #include <stdlib.h> #include <string.h> BF::PNGColorTree::PNGColorTree() { memset(children, 0, 16 * sizeof(PNGColorTree*)); index = -1; } unsigned int BF::PNGColorTree::color_tree_add(PNGColorTree* tree, unsigned char r, unsigned char g, unsigned char b, unsigned char a, unsigned index) {...
BitPaw/BitFireEngine
SystemResource/Source/Font/TTF/Chunks/OS2/Panose/TTFLetterform.cpp
<reponame>BitPaw/BitFireEngine<gh_stars>1-10 #include "TTFLetterform.h" BF::TTFLetterform BF::ConvertTTFLetterform(unsigned char letterform) { switch (letterform) { case 0: return BF::TTFLetterform::Any; case 1: return BF::TTFLetterform::NoFit; case 2: return BF::TTFLetterform::NormalContact; case 3: return ...
BitPaw/BitFireEngine
SystemResource/Source/Container/QuadTree/QuadTreePosition.hpp
#pragma once namespace BF { template<typename NumberType> struct QuadTreePosition { public: NumberType X; NumberType Y; QuadTreePosition() { X = 0; Y = 0; } QuadTreePosition(NumberType x, NumberType y) { X = x; Y = y; } }; }
BitPaw/BitFireEngine
SystemResource/Source/Font/TTF/Chunks/TTFOffsetTable.cpp
#include "TTFOffsetTable.h" BF::TTFOffsetTable::TTFOffsetTable() { NumberOfTables = 0; SearchRange = 0; EntrySelctor = 0; RangeShift = 0; }
BitPaw/BitFireEngine
SystemResource/Source/Image/PNG/Chunk/PNGPhysicalPixelDimension.cpp
<filename>SystemResource/Source/Image/PNG/Chunk/PNGPhysicalPixelDimension.cpp #include "PNGPhysicalPixelDimension.h"
BitPaw/BitFireEngine
SystemResource/Source/Sound/MID/MIDINote.cpp
<reponame>BitPaw/BitFireEngine<filename>SystemResource/Source/Sound/MID/MIDINote.cpp #include "MIDINote.h"
BitPaw/BitFireEngine
SystemResource/Source/Model/OBJ/OBJElement.cpp
<reponame>BitPaw/BitFireEngine<filename>SystemResource/Source/Model/OBJ/OBJElement.cpp #include "OBJElement.h" BF::OBJElement::OBJElement() { strcpy(Name, "[N/A]"); Smoothing = 0; MaterialListIndex = -1; } void BF::OBJElement::Allocate(size_t vertexSize, size_t texturePointSize, size_t normalPointSize, size_t ver...
BitPaw/BitFireEngine
SystemResource/Source/Image/PNG/Chunk/PNGTransparency.cpp
<filename>SystemResource/Source/Image/PNG/Chunk/PNGTransparency.cpp #include "PNGTransparency.h"
BitPaw/BitFireEngine
SystemResource/Source/Image/Image.cpp
#include "Image.h" #include "BMP/BMP.h" #include "PNG/PNG.h" #include "TGA/TGA.h" #include "TIFF/TIFF.h" #include "GIF/GIF.h" #include "JPEG/JPEG.h" #include "TIFF/TIFF.h" #include "../File/File.h" #include "../Math/Math.h" #include <cstdlib> #include <cstdio> #include <cwchar> #include "../File/Text.h" BF::Vector...
BitPaw/BitFireEngine
SystemResource/Source/ErrorCode.cpp
<reponame>BitPaw/BitFireEngine #include "ErrorCode.h" #include "OSDefine.h" #if defined(OSUnix) #include <errno.h> #define EOTHER -1 #elif defined(OSWindows) #include <windows.h> #endif int BF::ConvertErrorCode(ErrorCode errorCode) { switch (errorCode) { default: case BF::ErrorCode::UnkownError: return E...
BitPaw/BitFireEngine
SystemResource/Source/Network/IClientListener.hpp
#pragma once #include "IPAdressInfo.h" namespace BF { class IClientListener { public: virtual void OnConnectedToServer(IPAdressInfo& adressInfo) = 0; }; }
BitPaw/BitFireEngine
SystemResource/Source/File/Bash.cpp
<gh_stars>1-10 #include "Bash.h" #include "FileTemporary.h" #include "FileStream.h" BF::FileActionResult BF::Bash::Execute(const char* programPath, bool syncronous) { Pipe pipe; FileActionResult result = pipe.Open(programPath, FileOpenMode::Read); size_t dataLength = 0; unsigned char* data = 0; if (result != Fil...
BitPaw/BitFireEngine
SystemResource/Source/Math/Math.cpp
#include "Math.h" #include <math.h> #include <cstdlib> #include <ctime> #include "Interpolate.h" #include "../OSDefine.h" bool BF::Math::_timerSet = false; const float BF::Math::e = 2.71828182845904523536028747135266249; const float BF::Math::p = 1.32471795724474602596090885447809734; const float BF::Math::a = ...
BitPaw/BitFireEngine
SystemResource/Source/Sound/MID/MIDITrack.cpp
<filename>SystemResource/Source/Sound/MID/MIDITrack.cpp #include "MIDITrack.h" BF::MIDITrack::MIDITrack() { ID = -1; EventData = nullptr; EventDataSize = 0; }
BitPaw/BitFireEngine
SystemResource/Source/Image/JPEG/JPEGFileInfo.cpp
<filename>SystemResource/Source/Image/JPEG/JPEGFileInfo.cpp #include "JPEGFileInfo.h" #include <stdlib.h> BF::JPEGFileInfo::JPEGFileInfo() { Length = 0; Identifier[0] = 0; VersionMajor = 0; VersionMinor = 0; DensityUnits = 0; DensityX = 0; DensityY = 0; ThumbnailX = 0; ThumbnailY = 0; ThumbnailDataSize = 0...
BitPaw/BitFireEngine
SystemResource/Source/Email/EML.cpp
<filename>SystemResource/Source/Email/EML.cpp<gh_stars>1-10 #include "EML.h"
BitPaw/BitFireEngine
SystemResource/Source/Compression/ZLIB/ZLIB.cpp
<reponame>BitPaw/BitFireEngine<filename>SystemResource/Source/Compression/ZLIB/ZLIB.cpp #include "ZLIB.h" #include "ZLIBHeader.h" #include "../../Algorithm/Adler32.h" #include <stdlib.h> BF::ZLIB::ZLIB(unsigned char* inputData, size_t inputDataSize) { Parse(inputData, inputDataSize); } void BF::ZLIB::Parse(uns...
BitPaw/BitFireEngine
SystemResource/Source/Compression/ADAM7/ADAM7.cpp
<gh_stars>1-10 #include "ADAM7.h" /*Try the code, if it returns error, also return the error.*/ #define CERROR_TRY_RETURN(call){\ unsigned error = call;\ if(error) return error;\ } /*shared values used by multiple Adam7 related functions*/ static const unsigned ADAM7_IX[7] = { 0, 4, 0, 2, 0, 1, 0 }; /*x start v...
BitPaw/BitFireEngine
GameCleaved/Source/Main.cpp
//----------------------------------------------------------------------------- //#include "../../ResourceSystem/Source/Network/Client.h" #include "../../BitFireEngine/Source/System/BitFireEngine.h" #include "../../SystemResource/Source/OSDefine.h" #include <stdio.h> #include "CleavedGameSystem.h" #include <signal.h> ...
BitPaw/BitFireEngine
SystemSound/Source/SystemSound.cpp
#include "SystemSound.h" #include <cstdio> #include <string> #include <cassert> BF::SystemSound::SystemSound() { //---<Select Device> _audioDevice = alcOpenDevice(nullptr); if (!_audioDevice) { // Failed to get Sound device ALCenum error; error = alGetError(); if (error != AL_NO_ERROR) { // someth...
BitPaw/BitFireEngine
SystemResource/Source/Model/STL/STL.cpp
<gh_stars>1-10 #include "STL.h" BF::FileActionResult BF::STL::Load(const wchar_t* filePath) { return FileActionResult::Successful; } BF::FileActionResult BF::STL::Save(const wchar_t* filePath) { return FileActionResult::Successful; } BF::FileActionResult BF::STL::ConvertTo(Model& model) { return FileActi...
BitPaw/BitFireEngine
SystemResource/Source/Network/IOSocketMessage.cpp
<filename>SystemResource/Source/Network/IOSocketMessage.cpp #include "IOSocketMessage.h" BF::IOSocketMessage::IOSocketMessage() : IOSocketMessage(0, nullptr, 0) { } BF::IOSocketMessage::IOSocketMessage(int socketID, char* message, size_t messageSize) { SocketID = socketID; Message = message; MessageSize = message...
BitPaw/BitFireEngine
SystemResource/Source/Async/Thread.cpp
#include "Thread.h" BF::Thread::Thread() { ThreadHandle = ThreadIDUnused; } void BF::Thread::Run(ThreadFunction threadFunction, void* parameter) { Thread::Run(ThreadHandle, threadFunction, parameter); } void BF::Thread::Run(ThreadID& threadID, ThreadFunction threadFunction, void* parameter) { #ifdef OSUnix thread...
BitPaw/BitFireEngine
SystemResource/Source/File/FilePersistence.hpp
#pragma once namespace BF { enum class FilePersistence { Permanent, Tempoary }; }
BitPaw/BitFireEngine
SystemSound/Source/AudioSource.cpp
<gh_stars>1-10 #include "AudioSource.h" #include <cassert> BF::AudioSource::AudioSource() { ID = 0; Pitch = 0.4; Volume = 0.02; Position[0] = 0; Position[1] = 0; Position[2] = 0; Velocity[0] = 0; Velocity[1] = 0; Velocity[2] = 0; Looping = true; } void BF::AudioSource::PitchIncrease(float amount) { assert(...
vicgwee/simple-aquarium-telegram-bot
src/lights/lights.cpp
<reponame>vicgwee/simple-aquarium-telegram-bot #include "lights.h" #include "../utils/time.h" /*Timer */ const int timer_states = 8; const int timer_brightness[timer_states] PROGMEM = {10,700,1000,900,900,250,100,0}; const int timer_start[timer_states] PROGMEM = { 7 *60 + 30, 9 *60 + 30, 12*60 + 30, 17*60 ...
vicgwee/simple-aquarium-telegram-bot
src/utils/time.cpp
#include <NTPClient.h> #include <WiFiUdp.h> #include "time.h" uint32_t init_epoch_seconds; uint32_t init_millis; void initTimeClient(){ WiFiUDP ntpUDP; NTPClient timeClient(ntpUDP, "sg.pool.ntp.org", 8*3600, 3600000); timeClient.begin(); if(timeClient.forceUpdate()){ Serial.println(timeClient.getFormatted...
vicgwee/simple-aquarium-telegram-bot
src/main.cpp
#include "comms/commands.h" #include "comms/telegramBot.h" #include "lights/lights.h" #include "utils/time.h" #include "utils/wifi.h" void setup() { initLights(); Serial.begin(1000000L); initOldBotToken(); initWifi(); initBot(); initTimeClient(); updateLights(); sendResetMsg(); } void loop() { if (m...
vicgwee/simple-aquarium-telegram-bot
src/utils/wifi.cpp
<filename>src/utils/wifi.cpp #include "wifi.h" #include "../comms/telegramBot.h" #define WIFI_CONNECT_TIMEOUT 60 #define WIFI_CONFIG_PORTAL_TIMEOUT 60 bool shouldSaveConfig; void saveConfigCallback () { Serial.println(F("Should save config")); shouldSaveConfig = true; } void initWifi(){ WiFiManager wifiManage...
vicgwee/simple-aquarium-telegram-bot
src/comms/commands.cpp
#include "../comms/commands.h" #include "../comms/telegramBot.h" #include "../lights/lights.h" #include "../utils/time.h" const char* commands[] = { "/stats", "/geek_stats", "/toggle_lights", "/increase", "/decrease", "/toggle_timer", "/state" }; const uint8_t n_commands = sizeof(commands)/ sizeof(comm...
ussrcoin/ussrcoin
src/rpcmining.cpp
// Copyright (c) 2010 <NAME> // Copyright (c) 2009-2012 The Bitcoin developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "main.h" #include "db.h" #include "txdb.h" #include "init.h" #include "miner.h" #include...
akash2099/Leet-Code-Problems
104 Maximum Depth of Binary Tree.cpp
static int fastio=[](){ std::ios::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); return 0; }(); /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode() : val(0), left(nullptr), right(nullptr) {} * TreeNo...
akash2099/Leet-Code-Problems
137 Single Number II.cpp
<reponame>akash2099/Leet-Code-Problems /* This is a case of a finite state machine. States of machine- Total three (number appeared once, number appeared twice, number appeared thrice) Action - Incoming bit of one We will need two bits to keep track of the state. So lets take those states as 00, 01 and ...
bxchusun/bxchusun
src/font.cc
<filename>src/font.cc // Copyright 2013 Google Inc. All Rights Reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless requ...
SundeepK/Clone
src/levels/Box2dLis.cpp
#include <levels/Box2dLis.h> Box2dLis::Box2dLis() { } Box2dLis::~Box2dLis() { // TODO Auto-generated destructor stub } void Box2dLis::BeginContact(b2Contact* contact) { std::cout << "begion c++" << std::endl; try { luabind::call_function<void>(m_luaState, "beginCollision"); } catch (luabind::error& e) { st...
SundeepK/Clone
src/Game.cpp
#include <Game.h> #include "B2BoxBuilder.h" #include <functional> Game::Game(b2World& box2dWorld, sf::RenderWindow& renderWindow) :m_b2world(&box2dWorld), m_mainRenderWindow(&renderWindow), m_fixedTimeStepSystem(box2dWorld), m_mapLoader("maps/"), m_tmxLevelLoader(m_mapLoader, box2dWorld, m_anaxWorld, m_sensorSystem)...
SundeepK/Clone
src/main.cpp
<gh_stars>0 #include <SFML/Graphics.hpp> #include <SFML/System.hpp> #include <SFML/Window.hpp> #include <tmx/MapLoader.h> #include <tmx/tmx2box2d.h> #include "B2BoxBuilder.h" #include <functional> #include <iostream> #include "ActionController.h" #include <string> #include <anax/World.hpp> #include <Game.h> int main...
SundeepK/Clone
src/lua-exports/ExportBox2d.cpp
<gh_stars>0 #include <lua-exports/ExportBox2d.h> #include <Box2D/Box2D.h> #include <lua-exports/B2WorldProxy.h> #include <game-objects/GameObjectTag.h> #include <utilities/Bitwise.h> class ExportBox2d::ExportBox2dImpl{ public: ExportBox2dImpl(){} ~ExportBox2dImpl(){} void exportToLua(lua_State *luaState){ ...
SundeepK/Clone
luabindings/luabind/copy_policy.hpp
<gh_stars>0 // Copyright <NAME> 2008. Use, modification and distribution is // subject to the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #ifndef LUABIND_COPY_POLICY_081021_HPP # define LUABIND_COPY_POLICY_081021_HPP # include ...
SundeepK/Clone
src/systems/NinjaSenseRemoverSystem.cpp
#include <systems/NinjaSenseRemoverSystem.h> #include <vector> #include <components/PhysicsComponent.h> #include <Box2D/Box2D.h> #include <components/NinjaDataComponent.h> #include <SFML/System.hpp> #include <iostream> class NinjaSenseRemoverSystem::NinjaSenseRemoverSystemImpl{ public: sf::Clock m_clock; NinjaSen...
SundeepK/Clone
src/game-objects/DeathFloor.cpp
<filename>src/game-objects/DeathFloor.cpp #include <game-objects/DeathFloor.h> #include <components/PhysicsComponent.h> #include <components/DeathBringerComponent.h> #include <iostream> #include <game-objects/GameObjectTag.h> class DeathFloor::DeathFloorImpl{ public: DeathFloorImpl(){} ~DeathFloorImpl(){} void cr...
SundeepK/Clone
src/entity-loaders/InterestPointsEntityLoader.cpp
<filename>src/entity-loaders/InterestPointsEntityLoader.cpp<gh_stars>0 #include "InterestPointsEntityLoader.h" #include <entity-loaders/InterestPointsEntityLoader.h> #include <components/PhysicsComponent.h> #include <components/EndPointCollisionTagComponent.h> #include <components/EndPointTagComponent.h> class Intere...
SundeepK/Clone
src/lua-exports/ExportableToLua.cpp
<reponame>SundeepK/Clone #include <lua-exports/ExportableToLua.h> ExportableToLua::ExportableToLua() { } ExportableToLua::~ExportableToLua() { }
SundeepK/Clone
src/systems/NinjaSenseDetector.cpp
<filename>src/systems/NinjaSenseDetector.cpp<gh_stars>0 #include <systems/NinjaSenseDetector.h> #include <Box2D/Box2D.h> #include <systems/NinjaSenseEntityTagger.h> #include <components/PlayerTagComponent.h> #include <tmx/tmx2box2d.h> #include <SFML/Graphics.hpp> #include <components/PhysicsComponent.h> #include <compo...
SundeepK/Clone
src/systems/OpenGLTextureRenderer.cpp
#include <systems/OpenGLTextureRenderer.h> #include <opengl/TextureLoader.h> class OpenGLTextureRenderer::OpenGLTextureRendererImpl{ public: OpenGLTextureRendererImpl(){ } ~OpenGLTextureRendererImpl(){ } void render(std::vector<anax::Entity>& entities); }; void OpenGLTextureRenderer::OpenGLTextureRendererImp...
SundeepK/Clone
src/game-objects/DynamicRotatingBlade.cpp
#include <game-objects/DynamicRotatingBlade.h> #include <tmx/tmx2box2d.h> #include <iostream> #include <components/PhysicsComponent.h> #include <components/Texcoords.h> #include <components/SplitDirectionComponent.h> class DynamicRotatingBlade::DynamicRotatingBladeImpl{ public: DynamicRotatingBladeImpl(){} ~DynamicR...
SundeepK/Clone
src/PhysicsTimeStepSystem.cpp
#include "PhysicsTimeStepSystem.h" #include <GL/gl.h> #include <GL/glu.h> #include <components/TimeStepComponent.h> class PhysicsTimeStepSystem::PhysicsTimeStepSystemImpl{ public: PhysicsTimeStepSystemImpl(b2World& b2World) : m_world(&b2World){} ~PhysicsTimeStepSystemImpl(){} std::unique_ptr<b2World> m_world;...
SundeepK/Clone
src/systems/BladeUpdateSystem.cpp
#include <systems/BladeUpdateSystem.h> #include <components/BladeComponent.h> #include <components/PhysicsComponent.h> #include <utilities/CollisionUtils.h> #include <game-objects/GameObjectTag.h> #include <iostream> class BladeUpdateSystem::BladeUpdateSystemImpl{ public: BladeUpdateSystemImpl() {} ~BladeUpdateSyst...
SundeepK/Clone
src/game-objects/Rope.cpp
#include <game-objects/Rope.h> #include <components/PhysicsComponent.h> #include <components/Texcoords.h> #include <components/SplitDirectionComponent.h> #include <components/BreakableJointComponent.h> #include <iostream> #include <game-objects/GameObjectTag.h> #include <math.h> class Rope::RopeImpl{ public: RopeImpl...
SundeepK/Clone
src/systems/LevelRestartSystem.cpp
<gh_stars>0 #include <systems/LevelRestartSystem.h> #include <components/PlayerDeadComponent.h> #include <iostream> class LevelRestartSystem::LevelRestartSystemImpl{ public: LevelRestartSystemImpl(TmxBox2dLevelLoader& levelLoader) : m_tmxLoader(&levelLoader) {} ~LevelRestartSystemImpl(){} std::unique_ptr<TmxBox2dL...
SundeepK/Clone
src/utilities/Bitwise.cpp
<filename>src/utilities/Bitwise.cpp #include <utilities/Bitwise.h> Bitwise::Bitwise() { } Bitwise::~Bitwise() { } uint16 Bitwise::band(uint16 a, uint16 b) { return a & b; }
SundeepK/Clone
src/lua-exports/ExportSFML.cpp
<reponame>SundeepK/Clone extern "C" { #include <lua-5.1/src/lua.h> #include <lua-5.1/src/lualib.h> #include <lua-5.1/src/lauxlib.h> } #include <luabind/luabind.hpp> #include <iostream> #include <lua-exports/ExportSFML.h> #include <SFML/System.hpp> #include <tmx/MapLoader.h> #include <tmx/tmx2box2d.h> class ExportSF...
SundeepK/Clone
src/systems/BreakableJointSystem.cpp
<reponame>SundeepK/Clone #include <systems/BreakableJointSystem.h> #include <components/BreakableJointComponent.h> #include <components/PhysicsComponent.h> #include <vector> #include <iostream> #include <game-objects/GameObjectTag.h> class BreakableJointSystem::BreakableJointSystemImpl { public: std::unique_ptr<b2W...
SundeepK/Clone
src/game-objects/RopeBox.cpp
<gh_stars>0 #include <game-objects/RopeBox.h> #include <components/PhysicsComponent.h> #include <components/Texcoords.h> #include <components/SplitDirectionComponent.h> #include <iostream> #include <game-objects/GameObjectTag.h> class RopeBox::RopeBoxImpl { public: RopeBoxImpl() { } ~RopeBoxImpl() { } b2Rope...
SundeepK/Clone
src/systems/NinjaSenseEntityTagger.cpp
<gh_stars>0 #include <systems/NinjaSenseEntityTagger.h> #include <vector> #include <components/NinjaSenseComponent.h> #include <components/Texcoords.h> #include <components/SplitDirectionComponent.h> #include <components/PhysicsComponent.h> #include <iostream> #include <game-objects/GameObjectTag.h> #include <component...
SundeepK/Clone
luabindings/luabind/detail/operator_id.hpp
<filename>luabindings/luabind/detail/operator_id.hpp // Copyright (c) 2003 <NAME> and <NAME> // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without lim...
SundeepK/Clone
src/systems/FilterCollisionsSystem.cpp
#include <systems/FilterCollisionsSystem.h> #include <anax/Entity.hpp> #include <anax/World.hpp> #include <components/IgnoreCollisionComponent.h> #include <vector> #include <SFML/System.hpp> #include <iostream> class FilterCollisionsSystem::FilterCollisionsSystemImpl{ public: sf::Clock m_clock; sf::Time m_maxIgnoreT...
SundeepK/Clone
src/input-events/B2dSplitter.cpp
#include "B2dSplitter.h" #include <TextureMapper.h> #include <components/PhysicsComponent.h> #include <components/Texcoords.h> #include <vector> #include <set> #include <algorithm> #include <opengl/TextureLoader.h> #include <components/SplitDirectionComponent.h> #include <components/IgnoreCollisionComponent.h> #include...
SundeepK/Clone
src/systems/TextureRectRenderSystem.cpp
#include <systems/TextureRectRenderSystem.h> class TextureRectRenderSystem::TextureRectRenderSystemImpl{ public: TextureRectRenderSystemImpl(){ } ~TextureRectRenderSystemImpl() { } void draw(sf::RenderTarget& rt, sf::RenderStates states, std::vector<anax::Entity>& entities) const{ for(auto& entity : entiti...
SundeepK/Clone
luabindings/src/class_info.cpp
<gh_stars>0 // Copyright (c) 2003 <NAME> and <NAME> // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the rights to use, copy, modi...
SundeepK/Clone
src/systems/CameraSystem.cpp
<filename>src/systems/CameraSystem.cpp #include <systems/CameraSystem.h> #include <SFML/OpenGL.hpp> #include <GL/glut.h> #include <Vec.h> #include <components/PhysicsComponent.h> #include <iostream> #include <components/PlayerTagComponent.h> class CameraSystem::CameraSystemImpl { public: CameraSystemImpl(int width, ...
SundeepK/Clone
src/systems/SensorSystem.cpp
<reponame>SundeepK/Clone<filename>src/systems/SensorSystem.cpp<gh_stars>0 #include <systems/SensorSystem.h> #include <components/SensorComponent.h> #include <components/Sensors.h> #include <iostream> class SensorSystem::SensorSystemImpl { public: SensorSystemImpl() { } ~SensorSystemImpl(){ } void incrementSe...
SundeepK/Clone
src/systems/PlayerAnimationSystem.cpp
<reponame>SundeepK/Clone<filename>src/systems/PlayerAnimationSystem.cpp #include <systems/PlayerAnimationSystem.h> #include <components/PlayerControls.h> #include <components/PlayerStateComponent.h> #include <components/PlayerState.h> #include <components/AnimationComponent.h> class PlayerAnimationSystem::PlayerAnimat...
SundeepK/Clone
src/utilities/StringUtils.cpp
<filename>src/utilities/StringUtils.cpp #include <utilities/StringUtils.h> StringUtils::StringUtils() { } StringUtils::~StringUtils() { } std::vector<float> StringUtils::parseListOfFloats(std::string stringToParse) { }
SundeepK/Clone
src/systems/DetectLevelEndSystem.cpp
#include <systems/DetectLevelEndSystem.h> #include <vector> #include <components/SensorComponent.h> #include <components/Sensors.h> #include <components/PlayerTagComponent.h> #include <components/EndPointCollisionTagComponent.h> #include <components/EndPointTagComponent.h> #include <iostream> class DetectLevelEndSyste...
SundeepK/Clone
luabindings/luabind/typeid.hpp
<gh_stars>0 // Copyright <NAME> 2008. Use, modification and distribution is // subject to the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #ifndef LUABIND_TYPEID_081227_HPP # define LUABIND_TYPEID_081227_HPP # include <boost/ope...
SundeepK/Clone
src/utilities/CollisionUtils.cpp
<reponame>SundeepK/Clone #include <utilities/CollisionUtils.h> CollisionUtils::CollisionUtils() { } CollisionUtils::~CollisionUtils() { } bool CollisionUtils::isColliding(b2Contact* contact, uint16 maskA, uint16 maskB) { auto fixtureA = contact->GetFixtureA(); auto fixtureB = contact->GetFixtureB(); auto filter...
SundeepK/Clone
src/systems/PlayerControlsSystem.cpp
#include "PlayerControlsSystem.h" #include <Updateable.h> #include <ActionController.h> #include <components/PlayerControls.h> #include <components/PlayerStateComponent.h> #include <Box2D/Common/b2Math.h> #include <components/PhysicsComponent.h> #include <unordered_map> #include <functional> #include <components/Player...
SundeepK/Clone
luabindings/luabind/detail/object_funs.hpp
<gh_stars>0 // Copyright (c) 2003 <NAME> and <NAME> // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the rights to use, copy, modi...
SundeepK/Clone
src/systems/RemoveDeadEntitySystem.cpp
#include <systems/RemoveDeadEntitySystem.h> #include <vector> #include <components/PhysicsComponent.h> class RemoveDeadEntitySystem::RemoveDeadEntitySystemImpl{ public: RemoveDeadEntitySystemImpl(b2World& box2dWorld) : m_box2dWorld(&box2dWorld){} ~RemoveDeadEntitySystemImpl(){} std::unique_ptr<b2World> m_box2dWor...
SundeepK/Clone
src/game-objects/Boulder.cpp
#include <game-objects/Boulder.h> #include <tmx/MapLoader.h> #include <tmx/tmx2box2d.h> #include <game-objects/GameObjectTag.h> #include <iostream> class Boulder::BoulderImpl { public: BoulderImpl() { } ~BoulderImpl() { } void createEntity(const tmx::MapObject mapObject, b2World& box2dWorld, anax::World& anaxW...
SundeepK/Clone
src/components/Direction.cpp
<filename>src/components/Direction.cpp #include <components/Direction.h> const std::unordered_map<std::string, Direction> DirectionMap::DIRECTION_MAP = { {"right", Direction::RIGHT}, {"left", Direction::LEFT}, {"top", Direction::TOP}, {"down", Direction::DOWN}, {"none", Direction::NONE} }; Direction Direct...
SundeepK/Clone
src/entity-loaders/WorldEntityLoader.cpp
#include "WorldEntityLoader.h" #include <vector> #include <entity-loaders/PlayerEntityLoader.h> #include <entity-loaders/InterestPointsEntityLoader.h> #include <components/PhysicsComponent.h> extern "C" { #include <lua-5.1/src/lua.h> #include <lua-5.1/src/lualib.h> #include <lua-5.1/src/lauxlib.h> } #include <l...
SundeepK/Clone
src/opengl/TextureLoader.cpp
#include <opengl/TextureLoader.h> #include <iostream> TextureLoader::TextureLoader() { } TextureLoader::~TextureLoader() { } GLuint TextureLoader::loadAsOpenglTexture(GLuint& gluint, sf::Image& image) { glGenTextures(1, &gluint); glBindTexture(GL_TEXTURE_2D,gluint); gluBuild2DMipmaps(GL_TEXTURE_2D, GL_RGBA, ima...
SundeepK/Clone
src/levels/Level1.cpp
extern "C" { #include <lua-5.1/src/lua.h> #include <lua-5.1/src/lualib.h> #include <lua-5.1/src/lauxlib.h> } #include <luabind/luabind.hpp> #include <levels/Level1.h> #include <lua-exports/ExportBox2d.h> #include <lua-exports/B2WorldProxy.h> #include <utilities/Bitwise.h> #include <SFML/System.hpp> #include <compon...
SundeepK/Clone
luabindings/luabind/detail/conversion_storage.hpp
<filename>luabindings/luabind/detail/conversion_storage.hpp // Copyright <NAME> 2008. Use, modification and distribution is // subject to the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #ifndef LUABIND_CONVERSION_STORAGE_080930_HPP...
SundeepK/Clone
src/systems/BladeShooterSystem.cpp
#include <systems/BladeShooterSystem.h> #include <components/BladeComponent.h> #include <vector> #include <components/PhysicsComponent.h> #include <components/BladeShooterComponent.h> #include <game-objects/GameObjectTag.h> #include <components/Texcoords.h> #include <components/SplitDirectionComponent.h> #include <comp...
SundeepK/Clone
src/UUIDGenerator.cpp
#include <UUIDGenerator.h> UUIDGenerator::UUIDGenerator() { } UUIDGenerator::~UUIDGenerator() { } std::string UUIDGenerator::createUuid() { boost::uuids::uuid uuid = boost::uuids::random_generator()(); return boost::uuids::to_string(uuid); }
SundeepK/Clone
luabindings/src/exception_handler.cpp
<reponame>SundeepK/Clone // Copyright <NAME> 2005. Use, modification and distribution is // subject to the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #define LUABIND_BUILDING #include <luabind/config.hpp> #include <luabind/exc...
SundeepK/Clone
src/game-objects/BladeShooter.cpp
#include <game-objects/BladeShooter.h> #include <SFML/System.hpp> #include <components/BladeShooterComponent.h> #include <components/PhysicsComponent.h> #include <game-objects/GameObjectTag.h> #include <components/Direction.h> #include <map> class BladeShooter::BladeShooterImpl{ public: BladeShooterImpl(){} ~BladeS...
SundeepK/Clone
src/levels/TmxBox2dLevelLoader.cpp
<reponame>SundeepK/Clone #include "TmxBox2dLevelLoader.h" extern "C" { #include <lua-5.1/src/lua.h> #include <lua-5.1/src/lualib.h> #include <lua-5.1/src/lauxlib.h> } #include <luabind/luabind.hpp> #include <luabind/object.hpp> #include <components/PhysicsComponent.h> #include <levels/Level1.h> #include <game-obje...
SundeepK/Clone
src/systems/PlayerDeathSystem.cpp
#include <systems/PlayerDeathSystem.h> #include <components/PlayerTagComponent.h> #include <components/PlayerDeadComponent.h> #include <components/PhysicsComponent.h> #include <tmx/tmx2box2d.h> #include <iostream> #include <anax/World.hpp> #include <game-objects/GameObjectTag.h> #include <utilities/CollisionUtils.h> c...
SundeepK/Clone
src/entity-loaders/PlayerEntityLoader.cpp
<filename>src/entity-loaders/PlayerEntityLoader.cpp #include <entity-loaders/PlayerEntityLoader.h> #include <components/EndPointCollisionTagComponent.h> #include <lua-exports/ExportBox2d.h> #include <boost/scoped_ptr.hpp> #include <lua-exports/B2WorldProxy.h> #include <components/NinjaSenseComponent.h> #include <game-o...
SundeepK/Clone
luabindings/luabind/version.hpp
<filename>luabindings/luabind/version.hpp // Copyright <NAME> 2009. Use, modification and distribution is // subject to the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #ifndef LUABIND_VERSION_090216_HPP # define LUABIND_VERSION_09...
SundeepK/Clone
src/systems/PhysicsInterpolatorSystem.cpp
#include <systems/PhysicsInterpolatorSystem.h> #include <Box2D/Box2D.h> #include <components/Texcoords.h> #include <components/PhysicsComponent.h> #include <anax/Component.hpp> class PhysicsInterpolatorSystem::PhysicsInterpolatorSystemImpl{ public: std::function<void (b2Body*, float, PhysicsComponent&)> m_resetCompo...
SundeepK/Clone
src/systems/MouseSplitterSystem.cpp
#include <systems/MouseSplitterSystem.h> #include <Box2D/Box2D.h> #include <components/PlayerControls.h> #include <components/PlayerStateComponent.h> #include <components/PhysicsComponent.h> #include <components/PlayerTagComponent.h> #include <tmx/Helpers.h> #include <math.h> class MouseSplitterSystem::MouseSplitterSy...
SundeepK/Clone
src/lua-exports/B2WorldProxy.cpp
<gh_stars>0 #include <lua-exports/B2WorldProxy.h> #include <iostream> #include <UUIDGenerator.h> #include <tmx/MapLoader.h> #include <tmx/tmx2box2d.h> class B2WorldProxy::B2WorldProxyImpl{ public: B2WorldProxyImpl(b2World& box2dWorld) : m_box2dWorld(box2dWorld){ } ~B2WorldProxyImpl(){ } b2Joint* rope; b2Worl...
Arjung27/turtlebot_walker
include/turtlebot_walker/walkerAlgorithm.hpp
/** * MIT License * * Copyright (c) 2019 <NAME> * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without * limitation the rights to use, copy, mo...
Arjung27/turtlebot_walker
src/walkerAlgorithm.cpp
<filename>src/walkerAlgorithm.cpp /** * MIT License * * Copyright (c) 2019 <NAME> * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without * limi...
Banbury/UE4Elias
Plugins/EliasPlugin/Source/EliasPlugin/Private/EliasThemeFactory.cpp
// Fill out your copyright notice in the Description page of Project Settings. #include "EliasPluginPCH.h" #include "EliasTheme.h" #include "EliasThemeFactory.h" #define LOCTEXT_NAMESPACE "EliasTheme" UEliasThemeFactory::UEliasThemeFactory(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer) { b...
Banbury/UE4Elias
Plugins/EliasPlugin/Source/EliasPlugin/Private/EliasTheme.cpp
// Fill out your copyright notice in the Description page of Project Settings. #include "EliasPluginPCH.h" #include "EliasTheme.h" UEliasTheme* UEliasTheme::CreateThemeFromXml(FString path) { if (!path.IsEmpty()) { auto theme = NewObject<UEliasTheme>(); theme->XmlPath = path; theme->LoadXml(); return theme;...
Banbury/UE4Elias
Plugins/EliasPlugin/Source/EliasPlugin/Private/EliasPlugin.cpp
#include "EliasPluginPCH.h" #include "AssetRegistryModule.h" #include "AssetToolsModule.h" #include "AssetTypeActions_EliasTheme.h" IMPLEMENT_MODULE(FEliasPlugin, EliasPlugin) DEFINE_LOG_CATEGORY(LogElias); FMOD::System* FEliasPlugin::FMSYS; void FEliasPlugin::StartupModule() { UE_LOG(LogElias, Log, TEXT("Elias Pl...
Banbury/UE4Elias
Plugins/EliasPlugin/Source/EliasPlugin/Private/SoundNodeElias.cpp
<reponame>Banbury/UE4Elias // Fill out your copyright notice in the Description page of Project Settings. #include "EliasPluginPCH.h" #include "SoundNodeElias.h" int32 USoundNodeElias::GetMaxChildNodes() const { return 0; } float USoundNodeElias::GetDuration() { return INDEFINITELY_LOOPING_DURATION; } void USound...
Banbury/UE4Elias
Plugins/EliasPlugin/Source/EliasPlugin/Private/AssetTypeActions_EliasTheme.cpp
<filename>Plugins/EliasPlugin/Source/EliasPlugin/Private/AssetTypeActions_EliasTheme.cpp // Fill out your copyright notice in the Description page of Project Settings. #include "EliasPluginPCH.h" #include "EliasTheme.h" #include "AssetTypeActions_EliasTheme.h" UClass* FAssetTypeActions_EliasTheme::GetSupportedClass()...