-
Notifications
You must be signed in to change notification settings - Fork 0
Asset specification
arf20 edited this page Dec 10, 2022
·
1 revision
ww1game searches for an asset directory, and tries to load all the game stored in different files, making the game content separate from the game engine, allowing flexibility to add DLCs or make a whole new game with the same engine
assets/
- missing_texture.png #* something to render in case a texture is missing so you know its missing, 32x32
- missing_sound.ogg #* something to play in case a sound is missing so you know its missing, 440Hz 1s
- textures/ #* textures
- bullet.png #* bullet texture
- terrain/ #* terrain variants
- summer/ # variant (naming convention is lowercase and '_' separated)
- a_dirt.png # texture (first character is the texture id, make sure they are all unique like this) 32x32
- b_uphill.png
- c_downhill.png
- t_trench #* id 't' is special for marking a trench
- factions/ #* factions
- german_empire/ # faction (naming convention is lowercase and '_' separated)
- flag.png #* faction flag
- rifleman/ # character (lowercase)
- properties.cfg #* character properties, described below
- idle.png #* idle texture
- walk/ #* walking animation, contains N.png N starting at 0
- 0.png # animation frame texture
- 1.png
- 2.png
- 3.png
- fire/ #* firing animation
- 0.png
- 1.png
- 2.png
- death/ #* death animation
- 0.png
- 1.png
- backgrounds/ #* backgrounds folder
- cambrei.png # background
- campaigns/ #* campaigns
- western_front/ # campaign (naming convention is lowercase and '_' separated, displays "Western Front") contains filenames N.map N starting at 0
- 0.map # map (according to the format specification below, includes a title like "Cambrei")
- 1.map
- fonts/ #* font directory
- default.ttf #* default font
- sounds/ #* sound files
- missing_sound.ogg #* missing sound sound
- music/ #* music tracks
- menu.ogg #* track for the menu
- factions/
- british_empire/ # music for specific faction
- victory.ogg #* to be played on victory
- 0.ogg # X.ogg is to be played randomly during gameplay
- sfx/ #* sound effects
- factions/ #*
- british_empire/ # per faction (must exist in assets/factions/)
- rifleman/ # per character
- fire.ogg #* weapon fire sound
*Fixed, N = a number starting at 0, X = a string
Cambrei # map title
summer # terrain variation
cambrei # background name
german_empire # friendly faction
british_empire # enemy faction
cbbbe # map matrix
cdaaafe cbbe
cdaaaaafe cdaafe
bbbbdaaaaaaafbbbbghibbbbbghibbbbbbbbbbbbbghibbbdaaaafbbbb
aaaaaaaaaaaaaaaaaajaaaaaaajaaaaaaaaaaaaaaajaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
Then the map is described by a matrix of characters which correspond with the first letter of the terrain texture filename. On map load, a path through the map is found, in which soldiers travel by their bottom center point.
Maybe a bit too simplistic, might use a proper format later like idk YAML or whatever
6 # fire frame, at what frame the weapon is fired in the animation
10 # rounds per minute
66 # round damage
300 # muzzle velocity (pix/s)
0.1 # bullet spread (angular standard deviation)
60 # march speed (pix/s)
20 # range (in tiles)
100 # health
When installed, will probably be at /usr/local/ww1game/ or something, and the assets at /usr/local/ww1game/assets or idk
assets/ # asset directory path
200 # gravity (reserved for future use)
7 # animation framerate