aboutsummaryrefslogtreecommitdiff
path: root/src/skyparams.h
Commit message (Collapse)AuthorAge
* Color gradient for default and 'regular' type sky (#9502)TheTermos2020-05-09
| | | | | | | | | * add regular sky gradient * add regular sky gradient * Update sky.cpp * change default day sky colors
* Sky API: Rename *_tint to fog_*_tint for consistencySmallJoker2020-05-05
|
* Fix star visilibity and documentation (since 946c03c6)Jordan Snelling2020-03-08
| | | | | | | Fix memory leak (unused allocation) Fix star rendering Rename sky color struct Fix stars on android Remove extraneous .data() from android star draw
* Fix code style to make clang-format happysfan52020-03-05
|
* set_sky improvements, set_sun, set_moon and set_starsJordach2020-03-05
span> #include "clientobject.h" #include "debug.h" #include "porting.h" /* ClientActiveObject */ ClientActiveObject::ClientActiveObject(u16 id, Client *client, ClientEnvironment *env): ActiveObject(id), m_client(client), m_env(env) { } ClientActiveObject::~ClientActiveObject() { removeFromScene(true); } ClientActiveObject* ClientActiveObject::create(ActiveObjectType type, Client *client, ClientEnvironment *env) { // Find factory function UNORDERED_MAP<u16, Factory>::iterator n = m_types.find(type); if(n == m_types.end()) { // If factory is not found, just return. warningstream << "ClientActiveObject: No factory for type=" << (int)type << std::endl; return NULL; } Factory f = n->second; ClientActiveObject *object = (*f)(client, env); return object; } void ClientActiveObject::registerType(u16 type, Factory f) { UNORDERED_MAP<u16, Factory>::iterator n = m_types.find(type); if(n != m_types.end()) return; m_types[type] = f; }