summaryrefslogtreecommitdiff
path: root/assets.h
blob: 419795bce0ec830490a7c8cfafb6d6acba783c4f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/*
 * Tux-Town is a chill life-simulation game. 
 * Copyright (C) 2025  orangerot <me@orangerot.dev>
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <https://www.gnu.org/licenses/>.
 */

#include <raylib.h>

#ifndef ASSETS_H
#define ASSETS_H

#define ASSET_PATH "assets/kenney_nature-kit/Models/OBJ format/"
#define ASSETS(ASSET) \
  ASSET(ground_riverOpen) \
  ASSET(ground_riverCornerSmall) \
  ASSET(ground_riverSideOpen) \
  ASSET(ground_riverSide) \
  ASSET(ground_riverCross) \
  ASSET(ground_riverSplit) \
  ASSET(ground_riverStraight) \
  ASSET(ground_riverCorner) \
  ASSET(ground_riverBend) \
  ASSET(ground_riverEndClosed) \
  ASSET(ground_riverTile) \
  ASSET(ground_grass) \
  ASSET(cliff_top_rock) \
  ASSET(tree_oak) \
  ASSET(tent_detailedOpen)

#define AS_ENUM(name) name,
enum Asset {
  ASSETS(AS_ENUM)
  ASSET_LEN
};

Model assets[ASSET_LEN];

#define AS_ARRAY(name) assets[name] = LoadModel(ASSET_PATH #name ".obj");
void LoadModels() {
  ASSETS(AS_ARRAY)
}

#endif /* ASSETS_H */