Rename buildings to building_factory, randomize unit place position
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
#include "../game_state.h"
|
||||
#include "../input.h"
|
||||
#include "../buildings.h"
|
||||
#include "../building_factory.h"
|
||||
#include "../pathfinding.h"
|
||||
|
||||
#include <rlImGui.h>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
#include "../input.h"
|
||||
#include "../map_init.h"
|
||||
#include "../ui_widgets.h"
|
||||
#include "../buildings.h"
|
||||
#include "../building_factory.h"
|
||||
#include "../utils.h"
|
||||
#include "../entity_factory.h"
|
||||
|
||||
@@ -189,7 +189,8 @@ void drawGameUI(Game *game, f32 dt) {
|
||||
(building.pos.x + building.size.x * 0.5f) * 16.0f,
|
||||
(building.pos.y + building.size.y + 0.5f) * 16.0f
|
||||
};
|
||||
//placePos = GetWorldToScreen2D(placePos, game->camera);
|
||||
placePos.x += GetRandomValue(-16, 16);
|
||||
placePos.y += GetRandomValue(-4, 4);
|
||||
PlayerResources playerRes = game->playerResources[game->player];
|
||||
switch (building.type) {
|
||||
case BUILDING_KEEP: {
|
||||
|
||||
Reference in New Issue
Block a user