Added 2 new web demos.
34
web/docs_hoster_simple/BrowsableFolderServeWebPage.gd
Normal file
@ -0,0 +1,34 @@
|
||||
extends BrowsableFolderServeWebPage
|
||||
|
||||
var markdown_renderer : MarkdownRenderer = null
|
||||
|
||||
func serve_md(request: WebServerRequest) -> void:
|
||||
var path : String = request.get_path_full()
|
||||
|
||||
var fabs : String = get_file_cache().wwwroot_get_file_abspath(path)
|
||||
|
||||
if fabs == "":
|
||||
request.send_error(HTTPServerEnums.HTTP_STATUS_CODE_404_NOT_FOUND)
|
||||
return
|
||||
|
||||
var f : File = File.new()
|
||||
if f.open(fabs, File.READ) != OK:
|
||||
request.send_error(HTTPServerEnums.HTTP_STATUS_CODE_404_NOT_FOUND)
|
||||
return
|
||||
|
||||
request.body += markdown_renderer.render(f.get_as_text())
|
||||
|
||||
f.close()
|
||||
|
||||
request.compile_and_send_body()
|
||||
|
||||
func _handle_request_main(request: WebServerRequest) -> void:
|
||||
|
||||
if request.get_path_full().ends_with(".md"):
|
||||
serve_md(request)
|
||||
return
|
||||
|
||||
._handle_request_main(request)
|
||||
|
||||
func _ready() -> void:
|
||||
markdown_renderer = MarkdownRenderer.new()
|
31
web/docs_hoster_simple/Main.tscn
Normal file
@ -0,0 +1,31 @@
|
||||
[gd_scene load_steps=2 format=3]
|
||||
|
||||
[ext_resource path="res://BrowsableFolderServeWebPage.gd" type="Script" id=1]
|
||||
|
||||
[node name="Main" type="Node"]
|
||||
|
||||
[node name="PanelContainer" type="PanelContainer" parent="."]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
|
||||
[node name="CC" type="CenterContainer" parent="PanelContainer"]
|
||||
margin_left = 7.0
|
||||
margin_top = 7.0
|
||||
margin_right = 1017.0
|
||||
margin_bottom = 593.0
|
||||
|
||||
[node name="LinkButton" type="LinkButton" parent="PanelContainer/CC"]
|
||||
margin_left = 437.0
|
||||
margin_top = 286.0
|
||||
margin_right = 573.0
|
||||
margin_bottom = 300.0
|
||||
text = "http://127.0.0.1:8080"
|
||||
uri = "http://127.0.0.1:8080"
|
||||
|
||||
[node name="WebServerSimple" type="WebServerSimple" parent="."]
|
||||
start_on_ready = true
|
||||
|
||||
[node name="BrowsableFolderServeWebPage" type="BrowsableFolderServeWebPage" parent="WebServerSimple"]
|
||||
uri_segment = "/"
|
||||
serve_folder = "res://www/"
|
||||
script = ExtResource( 1 )
|
7
web/docs_hoster_simple/default_env.tres
Normal file
@ -0,0 +1,7 @@
|
||||
[gd_resource type="Environment3D" load_steps=2 format=3]
|
||||
|
||||
[sub_resource type="ProceduralSky" id=1]
|
||||
|
||||
[resource]
|
||||
background_mode = 2
|
||||
background_sky = SubResource( 1 )
|
BIN
web/docs_hoster_simple/icon.png
Normal file
After Width: | Height: | Size: 3.2 KiB |
35
web/docs_hoster_simple/icon.png.import
Normal file
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://icon.png"
|
||||
dest_files=[ "res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
25
web/docs_hoster_simple/project.pandemonium
Normal file
@ -0,0 +1,25 @@
|
||||
; Engine configuration file.
|
||||
; It's best edited using the editor UI and not directly,
|
||||
; since the parameters that go here are not all obvious.
|
||||
;
|
||||
; Format:
|
||||
; [section] ; section goes between []
|
||||
; param=value ; assign values to parameters
|
||||
|
||||
config_version=4
|
||||
|
||||
[application]
|
||||
|
||||
config/name="Pandemonium Docs Hoster Simple"
|
||||
run/main_scene="res://Main.tscn"
|
||||
config/icon="res://icon.png"
|
||||
|
||||
[physics]
|
||||
|
||||
common/enable_pause_aware_picking=true
|
||||
|
||||
[rendering]
|
||||
|
||||
vram_compression/import_etc=true
|
||||
vram_compression/import_etc2=false
|
||||
environment/default_environment="res://default_env.tres"
|
19
web/docs_hoster_simple/www/.editorconfig
Normal file
@ -0,0 +1,19 @@
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
# YAML requires indentation with spaces instead of tabs.
|
||||
[*.{js,yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
# Makefile requires tab indentation.
|
||||
[Makefile]
|
||||
indent_style = tab
|
||||
indent_size = 4
|
0
web/docs_hoster_simple/www/.gdignore
Normal file
5
web/docs_hoster_simple/www/.gitattributes
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
# Properly detect languages on GitHub
|
||||
*.rst linguist-detectable=true
|
||||
|
||||
# Normalize EOL for all files that Git considers text files
|
||||
* text=auto eol=lf
|
44
web/docs_hoster_simple/www/.gitignore
vendored
Normal file
@ -0,0 +1,44 @@
|
||||
_build/
|
||||
env/
|
||||
__pycache__
|
||||
*.pyc
|
||||
*~
|
||||
.directory
|
||||
.vs/
|
||||
.vscode/
|
||||
*.mo
|
||||
|
||||
out/
|
||||
|
||||
# Vim temp files
|
||||
*.swo
|
||||
*.swp
|
||||
|
||||
# Geany/geany-plugins files
|
||||
*.geany
|
||||
.geanyprj
|
||||
|
||||
# Finder (macOS) makes these automatically.
|
||||
.DS_Store
|
||||
__MACOSX
|
||||
|
||||
# Windows image file caches
|
||||
[Tt]humbs.db
|
||||
[Tt]humbs.db:encryptable
|
||||
ehthumbs.db
|
||||
ehthumbs_vista.db
|
||||
|
||||
# Windows shortcuts
|
||||
*.lnk
|
||||
|
||||
# Windows folder config file
|
||||
[Dd]esktop.ini
|
||||
|
||||
# Windows Recycle Bin used on file shares
|
||||
$RECYCLE.BIN/
|
||||
logo.h
|
||||
*.autosave
|
||||
|
||||
# Output of list-unused-images.sh tool
|
||||
tmp-unused-images
|
||||
tmp-unused-images-history
|
111
web/docs_hoster_simple/www/04_modules/01_thread_pool.md
Normal file
@ -0,0 +1,111 @@
|
||||
# Thread pool module
|
||||
|
||||
Todo: was merged into core.
|
||||
|
||||
A c++ Pandemonium engine module, that will help you with threading.
|
||||
|
||||
It can also work if threads are not available (like on the javascript backend), in this case it runs jobs on the
|
||||
main thread. Jobs themselves can also distribute their work onto multiple frames, and you can set how much time
|
||||
is allocated per frame.
|
||||
|
||||
You can access it's setting from the `Project->Project Settings...` menu, in the `ThreadPool` category.
|
||||
|
||||
# ThreadPoolJob
|
||||
|
||||
Contains a job that can run on different threads.
|
||||
|
||||
A job is only considered finished, if you set the 'complete' property to 'true'. If multiple threads are available,
|
||||
the system will not check for this though, because there is no need.
|
||||
|
||||
If you want to support environments that doesn't have threading, you can use:
|
||||
|
||||
```
|
||||
bool should_do(const bool just_check = false);
|
||||
bool should_return();
|
||||
```
|
||||
|
||||
For example:
|
||||
|
||||
```
|
||||
func _execute():
|
||||
# On the first run this will return true, on subsequent runs it will return false
|
||||
if should_do():
|
||||
thing1()
|
||||
|
||||
# if you ran out the allocated timeframe in a frame, this will return true
|
||||
if should_return():
|
||||
return
|
||||
|
||||
if should_do():
|
||||
thing2()
|
||||
|
||||
if should_return():
|
||||
return
|
||||
|
||||
thing3()
|
||||
|
||||
complete = true
|
||||
|
||||
```
|
||||
|
||||
`should_do`'s optional parameter will let you just query the system, whether you finished a step, without
|
||||
incrementing internal couters. This is useful for example to distribute algorithms onto multiple frames.
|
||||
|
||||
For example:
|
||||
|
||||
```
|
||||
func _execute():
|
||||
if should_do(true):
|
||||
while current <= elements.size():
|
||||
#do heavy calculations
|
||||
|
||||
current += 1
|
||||
|
||||
if should_return():
|
||||
return
|
||||
|
||||
#The heavy calculation finished, increment counters
|
||||
should_do()
|
||||
|
||||
if should_return():
|
||||
return
|
||||
|
||||
if should_do():
|
||||
thing2()
|
||||
|
||||
if should_return():
|
||||
return
|
||||
|
||||
thing3()
|
||||
|
||||
complete = true
|
||||
|
||||
```
|
||||
|
||||
This class will need little tweaks, hopefully I can get to is soon.
|
||||
|
||||
# ThreadPoolExecuteJob
|
||||
|
||||
This will let you run a method uin an another thread, without creating your own jobs.
|
||||
|
||||
Use it through the ThreadPool Singleton. Like:
|
||||
|
||||
```
|
||||
ThreadPool.create_execute_job(self, "method", arg1, arg2, ...)
|
||||
|
||||
#or
|
||||
ThreadPool.create_execute_job_simple(self, "method")
|
||||
```
|
||||
|
||||
This class will need little tweaks, hopefully I can get to is soon.
|
||||
|
||||
# ThreadPool singleton
|
||||
|
||||
The ThreadPool singleton handles jobs.
|
||||
|
||||
If you have a job, submit it using `add_job`:
|
||||
|
||||
```
|
||||
MyJob job = MyJob.new()
|
||||
ThreadPool.add_job(job)
|
||||
```
|
72
web/docs_hoster_simple/www/04_modules/02_texture_packer.md
Normal file
@ -0,0 +1,72 @@
|
||||
# Texture Packer for the Pandemonium Engine
|
||||
|
||||
This is a texture packer engine module, for the Pandemonium Engine.
|
||||
|
||||
It can create texture atlases for you even in the running game.
|
||||
|
||||
It uses the legacy version of [rectpack2D](https://github.com/TeamHypersomnia/rectpack2D/tree/legacy)
|
||||
|
||||
It should work on all platforms.
|
||||
|
||||
# Features and Usage
|
||||
|
||||
## TexturePacker
|
||||
|
||||
This is the class that can merge textures. Add every texture you want into it using it's API (add_texture()), and then call merge().
|
||||
|
||||
add_texture() will return an AtlasTexture, this is the texture you want to use in your classes. It is immediately usable, it will just contain the original texture. Calling merge() will change it, to point to the new (merged) texture.
|
||||
|
||||
Supports filters, custom background color, margins.
|
||||
|
||||
### The keep_original_atlases option:
|
||||
|
||||
If you set this to true, and then add AtlasTextures, TexturePacker will change these ones (the ones you actually added)
|
||||
after the bake.
|
||||
|
||||
You can use this to bake gui textures together, without changing the resources everywhere at runtime.
|
||||
Think of rpgs, when you have a huge number of potential icons that the player can put on his or her actionbars.
|
||||
You can take look at Tales of Maj'Eyal or pretty much every actually complex MMORPGs as an example.
|
||||
|
||||
Note: Doing something like this in only recommended, if you can't pre-make the atlases (or it's really unfeasible), you are better off
|
||||
making the atlases yourself during development.
|
||||
|
||||
## TextureMerger
|
||||
|
||||
A Node that can bake textures for you. It uses TexturePacker internally.
|
||||
|
||||
It has an exposed Array, so you can assign textures to it in the editor.
|
||||
|
||||
## PackerImageResource
|
||||
|
||||
This is a simple Texture, which just contains an imported Image. It has no logic for drawing.
|
||||
|
||||
Useful for textures you only need for baking, as this class will not register it's data into the RenderingServer.
|
||||
|
||||
The module also contains an editor plugin which can import textures as `PackerImageResource` Resource.
|
||||
|
||||
To access it, click on a texture, switch to the import tab, and in the "Import As" Dropdown, select "Packer Image Recource".
|
||||
|
||||
## TextureLayerMerger
|
||||
|
||||
This class can merge together textures as layers. Useful for example to merge together (and color) skin, and clothes for a character.
|
||||
|
||||
It can handle both AtlasTextures and normal Textures.
|
||||
|
||||
Add the layers from bottom to top with the add_texture() method, when you added everything call merge().
|
||||
|
||||
You can set the resulting image's size with the `width`, and `height` properties. If you leave them at 0, they will
|
||||
change to the first added texture's size.
|
||||
|
||||
add_texture looks like this:
|
||||
|
||||
```
|
||||
void add_texture(Ref<Texture> p_texture, Color p_color = Color(1, 1, 1, 1), Vector2 p_position = Vector2(), Rect2 p_rect = Rect2());
|
||||
```
|
||||
|
||||
The color parameter will color the given texture on merge().
|
||||
With the position parameter you can offset your texture (in the resulted texture), and with the rect parameter, you can crop it.
|
||||
|
||||
There are setters to manipulate the added data later.
|
||||
|
||||
After the merge, you can either use `get_result_as_texture()` (it creates an ImageTexture on the fly), or the `data` property to
|
||||
grab the resulting Image.
|
25
web/docs_hoster_simple/www/04_modules/03_mesh_utils.md
Normal file
@ -0,0 +1,25 @@
|
||||
# Mesh Utils Module
|
||||
|
||||
This is a c++ engine module for the Pandemonium engine, containing my mesh merging utilities.
|
||||
|
||||
# Optional Dependencies
|
||||
|
||||
[Mesh Data Resource](https://github.com/Relintai/mesh_data_resource): Support for merged meshes, even in gles2.
|
||||
Adds MeshMerger a few helper methods.
|
||||
|
||||
# MeshUtils Singleton
|
||||
|
||||
Contains generic algorithms that manipulate meshes.
|
||||
|
||||
# Mesh Merger
|
||||
|
||||
Works similarly to SurfaceTool, but it has more utility functions.
|
||||
|
||||
# Fast Quadratic Mesh Simplifier
|
||||
|
||||
A port of https://github.com/Whinarn/UnityMeshSimplifier .
|
||||
For future reference it's based on e8ff4e8862735197c3308cfe926eeba68e0d2edb.
|
||||
Porting is mostly done, but it does needs some debugging (it has a crash if smart linking is enabled).
|
||||
|
||||
I might just return to using the original FQMS. As if meshes are merged together using `MeshUtils.merge_mesh_array`, or
|
||||
`bake_mesh_array_uv` the original algorithm will work fine. Still on the fence about it.
|
@ -0,0 +1,36 @@
|
||||
# Mesh data resource Module
|
||||
|
||||
A c++ Pandemonium engine module, that adds a resource, which contains raw mesh data for merging and collider information.
|
||||
|
||||
The module also comes with importers (gltf, and collada for now), you can import 3d models as MeshDataResources with these.
|
||||
|
||||
## Optional Dependencies
|
||||
|
||||
`https://github.com/Relintai/props`: If present, you also get a prop importer for MeshDataInstances.
|
||||
`https://github.com/Relintai/mesh_utils`: If present, you get mesh simplification/optimization options at import.
|
||||
|
||||
## MeshDataResource
|
||||
|
||||
The resource that holds mesh and collider data.
|
||||
|
||||
## MeshDataResourceCollection
|
||||
|
||||
Holds a list of MeshDataResources.
|
||||
|
||||
## MeshDataInstance
|
||||
|
||||
You can easily put MeshDataResources into the scene with these. They are equivalent to MeshInstances, except they work
|
||||
with MeshDataResources.
|
||||
|
||||
## Importers
|
||||
|
||||
In order to import a 3d model as a MeshDataResource, select the model, go to the import tab, and switch the import type to `<type> MDR`. Like:
|
||||
|
||||
![Import Tab](screenshots/import.png)
|
||||
|
||||
If you set the import type to single, the importers will convert the first model that they encounter into a MeshDataResource, then save that,
|
||||
if you set it to multiple, you get a MeshDataResourceCollection as the main resource, and also all encountered models as files separately.
|
||||
|
||||
Since MeshDataResource can hold collider information, these importers can create this for you. There are quite a few options for it:
|
||||
|
||||
![Colliders](screenshots/import_2.png)
|
61
web/docs_hoster_simple/www/04_modules/05_props.md
Normal file
@ -0,0 +1,61 @@
|
||||
# Props Module
|
||||
|
||||
This is a c++ engine module for the Pandemonium Engine.
|
||||
|
||||
It gives you props, and editor utilities to convert scenes to props.
|
||||
|
||||
# Optional Dependencies
|
||||
|
||||
[Mesh Data Resource](https://github.com/Relintai/mesh_data_resource): Support for merged meshes, even in gles2.\
|
||||
[Texture Packer](https://github.com/Relintai/texture_packer): Prop Instance will use this to merge textures.
|
||||
|
||||
# PropData
|
||||
|
||||
Props are basically 3D scenes in a simple format, so other things can easily process them without instancing.
|
||||
|
||||
For example if you create a building from MeshDataInstances, and then convert that scene to a prop, Voxelman
|
||||
can spawn it, merge it's meshes, and create lods without any scene instancing.
|
||||
|
||||
PropData is the main class you'll use, it's main purpose it to store a list of PropDataEntries.
|
||||
|
||||
# PropDataEntries
|
||||
|
||||
These are the classes that actually store data.
|
||||
|
||||
They contain 4 methods for scene->prop conversion, namely:
|
||||
|
||||
```
|
||||
//Whether or not this PropDataEntry can process the given Node.
|
||||
virtual bool _processor_handles(Node *node);
|
||||
|
||||
//Save the given Node into the given prop_data any way you like, at transform.
|
||||
virtual void _processor_process(Ref<PropData> prop_data, Node *node, const Transform &transform);
|
||||
|
||||
//Turn PropDataEntry back into a Node
|
||||
virtual Node *_processor_get_node_for(const Transform &transform);
|
||||
|
||||
//Whether the system should skip evaluating the children of a processes Node or not. See PropDataScene, or PropDataProp.
|
||||
virtual bool _processor_evaluate_children();
|
||||
```
|
||||
|
||||
# PropInstances
|
||||
|
||||
PropInstances are not yet finished.
|
||||
|
||||
They will be able to merge meshes, texture etc from a Prop, and also generate lods for it.
|
||||
|
||||
Essentially they will be a more advanced MeshInstance.
|
||||
|
||||
Voxelman implements all of this, just haven't finished porting it yet.
|
||||
|
||||
# PropUtils Singleton
|
||||
|
||||
The PropUtils singleton helps with scene->prop conversion.
|
||||
|
||||
You can register new PropDataEntries as processors, should you need to.
|
||||
|
||||
# Scene conversion
|
||||
|
||||
You can either click the new "To Prop" button on the menubar of the 3D scene for a quick conversion,
|
||||
or look into Project->Tools.
|
||||
|
61
web/docs_hoster_simple/www/04_modules/06_props_2d.md
Normal file
@ -0,0 +1,61 @@
|
||||
# Prop2Ds Module
|
||||
|
||||
This is a c++ engine module for the Pandemonium Engine.
|
||||
|
||||
It gives you props, and editor utilities to convert scenes to props.
|
||||
|
||||
# Optional Dependencies
|
||||
|
||||
[Mesh Data Resource](https://github.com/Relintai/mesh_data_resource): Support for merged meshes, even in gles2.\
|
||||
[Texture Packer](https://github.com/Relintai/texture_packer): Prop2D Instance will use this to merge textures.
|
||||
|
||||
# Prop2DData
|
||||
|
||||
Prop2Ds are basically 3D scenes in a simple format, so other things can easily process them without instancing.
|
||||
|
||||
For example if you create a building from MeshDataInstances, and then convert that scene to a prop, Voxelman
|
||||
can spawn it, merge it's meshes, and create lods without any scene instancing.
|
||||
|
||||
Prop2DData is the main class you'll use, it's main purpose it to store a list of Prop2DDataEntries.
|
||||
|
||||
# Prop2DDataEntries
|
||||
|
||||
These are the classes that actually store data.
|
||||
|
||||
They contain 4 methods for scene->prop conversion, namely:
|
||||
|
||||
```
|
||||
//Whether or not this Prop2DDataEntry can process the given Node.
|
||||
virtual bool _processor_handles(Node *node);
|
||||
|
||||
//Save the given Node into the given prop_data any way you like, at transform.
|
||||
virtual void _processor_process(Ref<Prop2DData> prop_data, Node *node, const Transform &transform);
|
||||
|
||||
//Turn Prop2DDataEntry back into a Node
|
||||
virtual Node *_processor_get_node_for(const Transform &transform);
|
||||
|
||||
//Whether the system should skip evaluating the children of a processes Node or not. See Prop2DDataScene, or Prop2DDataProp2D.
|
||||
virtual bool _processor_evaluate_children();
|
||||
```
|
||||
|
||||
# Prop2DInstances
|
||||
|
||||
Prop2DInstances are not yet finished.
|
||||
|
||||
They will be able to merge meshes, texture etc from a Prop2D, and also generate lods for it.
|
||||
|
||||
Essentially they will be a more advanced MeshInstance.
|
||||
|
||||
Voxelman implements all of this, just haven't finished porting it yet.
|
||||
|
||||
# Prop2DUtils Singleton
|
||||
|
||||
The Prop2DUtils singleton helps with scene->prop conversion.
|
||||
|
||||
You can register new Prop2DDataEntries as processors, should you need to.
|
||||
|
||||
# Scene conversion
|
||||
|
||||
You can either click the new "To Prop2D" button on the menubar of the 3D scene for a quick conversion,
|
||||
or look into Project->Tools.
|
||||
|
173
web/docs_hoster_simple/www/04_modules/07_terraman.md
Normal file
@ -0,0 +1,173 @@
|
||||
# Terraman
|
||||
|
||||
A terrain engine for pandemonium, focusing more on editor integration, gameplay-related features, and extendability (even from gdscript), without sacrificing too much speed.
|
||||
|
||||
It is a spinoff of [Voxelman](https://github.com/Relintai/voxelman). I started working on it when I realized that not only a full 3d voxel engine is too hard for me to use properly for an rpg (just think about how hard it is to do smooth zone - zone and dungeon transitions with the proper fidelity for an rpg), it's also unnecessary.
|
||||
|
||||
I could have technically implemented all of this into voxelman, as having only have one row of chunks, and then setting chunk height to 1, and creating a mesher that reads isolevel values as a normal height map will achieve the same effect. However as voxelman has lots of features with noises, lights and vertices, adding this on top of that module would have ended up being messy just for this reason alone (and also let's not forget the 3d apis).
|
||||
|
||||
So I ended up creating this. Everything works the same as in voxelman, but the apis have been simplified to make UX a bit better.
|
||||
|
||||
This is an engine module! Which means that you will need to compile it into Pandemonium! [See the compiling section here.](#compiling)
|
||||
|
||||
You can grab pre-built binaries (even editor + export templates) from the [Broken Seals](https://github.com/Relintai/broken_seals/releases) repo.
|
||||
|
||||
## Optional Dependencies
|
||||
|
||||
`https://github.com/Relintai/texture_packer`: You get access to [TerraLibraryMerger](#voxellibrarymerger) and [TerraLibraryMergerPCM](#voxellibrarymergerpcm). \
|
||||
`https://github.com/Relintai/mesh_data_resource`: You get access to a bunch of properties, and methods that can manipulate meshes.\
|
||||
`https://github.com/Relintai/props`: You get access to a bunch of properties, and methods that can manipulate, and use props.\
|
||||
`https://github.com/Relintai/mesh_utils`: Lets you use lod levels higher than 4 by default.
|
||||
|
||||
## Usage
|
||||
|
||||
First create a scene, and add a TerraWorldBlocky node into it. Create a TerraLibrary, and assign it to the Library property.
|
||||
Also, add a TerraSurface into your library.
|
||||
|
||||
Tick the editable property, deselect, then select the world again, and click the insert button at the top toolbar, or press B to insert a
|
||||
voxel at the inspector's camera's location.
|
||||
|
||||
Select the add button, and now you can just add voxels with the mouse, by clicking on the newly added voxel.
|
||||
|
||||
## TerraLibrary
|
||||
|
||||
This class stores the materials, and the TerraSurfaces.
|
||||
|
||||
Lod levels will automatically try to use materials of their own index.\
|
||||
For example lod level 1 will try to use material index 1, lod level 2 will try to use material index 2, etc.\
|
||||
If a material index is not available, they'll use the highest that is.\
|
||||
For example lod level 5 will try to get material index 5, but if you only have 3 materials it will use the 3rd.
|
||||
|
||||
### TerraLibrarySimple
|
||||
|
||||
The simplest library, just assign a material with a texture, and using the atlas_rows and atlas_culomns properties to tell the system
|
||||
how the UVs should be divided.
|
||||
|
||||
This is the basic Minecraft-style lib rary. Use this if you just have one texture atlas.
|
||||
|
||||
### TerraLibraryMerger
|
||||
|
||||
You will only have this if your pandemonium also contains https://github.com/Relintai/texture_packer
|
||||
|
||||
You can assign any texture to your surfaces with this, and it will merge them together.
|
||||
|
||||
### TerraLibraryMergerPCM
|
||||
|
||||
(PCM = Per Chunk Material)
|
||||
|
||||
You will only have this if your pandemonium also contains https://github.com/Relintai/texture_packer
|
||||
|
||||
You can assign any texture to your surfaces with this, and it will merge them together, but it will do it for every required chunk/voxel combination.
|
||||
|
||||
For example if you have a chunk with voxel Grass, and voxel Stone used in it, this library will create a material with a merged texture for Stone and Grass.
|
||||
If you have an anouther chunk which only has Grass and Stone in it, this material will be reused.
|
||||
And if you have a third chunk which only has a Grass voxel used in it, it will get a new merged material and texture only containing Grass voxel.
|
||||
|
||||
## Worlds
|
||||
|
||||
The 2 base classes. These won't do meshing on their own:
|
||||
|
||||
TerraWorld: Basic world, does not do anything until you implemnent the required virtual methods!\
|
||||
TerraWorldDefault: This adds threading, and LoD storage support to TerraWorld. Will not create meshes for you!
|
||||
|
||||
### TerraWorldBlocky
|
||||
|
||||
It generated UV mapped standard simple terrain meshes.
|
||||
The default algorithm can also generate normal lods.
|
||||
|
||||
### Level generation
|
||||
|
||||
Assign a TerraManLevelGenerator to the `World`'s `Level Generator` property.
|
||||
|
||||
You can write your own algorithm by implementing the ``` void _generate_chunk(chunk: TerraChunk) virtual ``` method.
|
||||
|
||||
`TerraManLevelGeneratorFlat` is also available, it will generate a floor for you, if you use it.
|
||||
|
||||
## TerraJobs
|
||||
|
||||
Producing just a terrain mesh for a chunk is not that hard by itself. However when you start adding layers/features
|
||||
like lod generation, collision meshes (especially since manipulating the physics server is not threadsafe),
|
||||
vertex lights, props, snapping props, props with vertex lights, etc
|
||||
chunk mesh generation can quickly become a serious mess.
|
||||
|
||||
TerraJobs are meant to solve the issue with less complexity.
|
||||
|
||||
They also provide a way to easily modularize mesh and lod generation.
|
||||
|
||||
### TerraJob
|
||||
|
||||
Base class for jobs.
|
||||
|
||||
This is inherited from `ThreadPoolJob`.
|
||||
|
||||
A job has a reference to it's owner chunk.
|
||||
|
||||
If you implement your own jobs, when your job finishes call `next_job()`.
|
||||
|
||||
### TerraLightJob
|
||||
|
||||
This is the job that will generate vertex light based ao, random ao, and will bake your `TerraLight`s.
|
||||
|
||||
### TerraTerrainJob
|
||||
|
||||
This will generate your terrain collider and mesh (with lods) for you, using the meshers that you add into it.
|
||||
|
||||
Your lod setup is easily customizable with [TerraMesherJobSteps](https://github.com/Relintai/terraman/blob/master/world/jobs/voxel_mesher_job_step.h). The setup happens in your selected world's `_create_chunk` method.
|
||||
|
||||
### TerraPropJob
|
||||
|
||||
This will generate your prop meshes (with lods).
|
||||
|
||||
Also supports [TerraMesherJobSteps](https://github.com/Relintai/terraman/blob/master/world/jobs/voxel_mesher_job_step.h).
|
||||
|
||||
### Internal workings
|
||||
|
||||
#### TerraWorld
|
||||
|
||||
Whenever you want to spawn a chunk your World will create it using the ``` TerraChunk _create_chunk(x: int, y: int, z: int, chunk: TerraChunk) virtual ``` method.
|
||||
|
||||
Since properly initializing a chunk usually takes quite a few steps that you probably don't want to repeat everywhere the `chunk`
|
||||
parameter was added. This means you can just call the super `_create_chunk` methods, and you won't need to worry about your chunk
|
||||
getting overridden. Like:
|
||||
|
||||
Note that `_create_chunk` is also responsible for initializing chunks if you have them stored inside a scene.
|
||||
This is done by `setup_chunk(shunk)` in `TerraWorld`.
|
||||
|
||||
```
|
||||
func _create_chunk(x : int, y : int, z : int, chunk : TerraChunk) -> TerraChunk:
|
||||
if !chunk:
|
||||
chunk = MyChunk.new()
|
||||
|
||||
# We need to check whether or not we need to initialize jobs
|
||||
if chunk.job_get_count() == 0:
|
||||
# Setup a blocky (minecratf like) mesher job
|
||||
var tj : TerraTerrainJob = TerraTerrainJob.new()
|
||||
|
||||
var s : TerraMesherJobStep = TerraMesherJobStep.new()
|
||||
s.job_type = TerraMesherJobStep.TYPE_NORMAL
|
||||
tj.add_jobs_step(s)
|
||||
|
||||
tj.add_mesher(TerraMesherBlocky.new())
|
||||
tj.add_liquid_mesher(TerraMesherLiquidBlocky.new())
|
||||
|
||||
chunk.job_add(tj);
|
||||
|
||||
#setup your chunk here
|
||||
|
||||
return ._create_chunk(x, y, z, chunk)
|
||||
```
|
||||
|
||||
You can look at the world implementations for more examples: [TerraWorldBlocky](https://github.com/Relintai/terraman/blob/master/world/blocky/voxel_world_blocky.cpp).
|
||||
|
||||
#### TerraChunk
|
||||
|
||||
Stores terrain data, prop data. And mesh data (TerraChunkDefault), and the mesh generation jobs.
|
||||
|
||||
When it starts building meshes it will start submitting jobs to thread_pool (if present) one by one.
|
||||
|
||||
#### TerraMesher
|
||||
|
||||
If you want to implement your own meshing algorithm you can do so by overriding ``` void _add_chunk(chunk: TerraChunk) virtual ```.
|
||||
|
||||
TerraMesher works similarly to SurfaceTool, so first you need to set colors, uvs, etc and then call add_vertex.
|
||||
They won't get reset, so for example if you want all your vertices to have a certain color, you can get away with setting it only once.
|
171
web/docs_hoster_simple/www/04_modules/08_terraman_2d.md
Normal file
@ -0,0 +1,171 @@
|
||||
# Terraman
|
||||
|
||||
A terrain engine for pandemonium, focusing more on editor integration, gameplay-related features, and extendability (even from gdscript), without sacrificing too much speed.
|
||||
|
||||
It is a spinoff of [Voxelman](https://github.com/Relintai/voxelman). I started working on it when I realized that not only a full 3d voxel engine is too hard for me to use properly for an rpg (just think about how hard it is to do smooth zone - zone and dungeon transitions with the proper fidelity for an rpg), it's also unnecessary.
|
||||
|
||||
I could have technically implemented all of this into voxelman, as having only have one row of chunks, and then setting chunk height to 1, and creating a mesher that reads isolevel values as a normal height map will achieve the same effect. However as voxelman has lots of features with noises, lights and vertices, adding this on top of that module would have ended up being messy just for this reason alone (and also let's not forget the 3d apis).
|
||||
|
||||
So I ended up creating this. Everything works the same as in voxelman, but the apis have been simplified to make UX a bit better.
|
||||
|
||||
## Optional Dependencies
|
||||
|
||||
`https://github.com/Relintai/thread_pool`: Threaded chunk generation. Without this terraman is single threaded! \
|
||||
`https://github.com/Relintai/texture_packer`: You get access to [TerraLibraryMerger](#voxellibrarymerger) and [TerraLibraryMergerPCM](#voxellibrarymergerpcm). \
|
||||
`https://github.com/Relintai/mesh_data_resource`: You get access to a bunch of properties, and methods that can manipulate meshes.\
|
||||
`https://github.com/Relintai/props`: You get access to a bunch of properties, and methods that can manipulate, and use props.\
|
||||
`https://github.com/Relintai/mesh_utils`: Lets you use lod levels higher than 4 by default.
|
||||
|
||||
## Usage
|
||||
|
||||
First create a scene, and add a TerraWorldBlocky node into it. Create a TerraLibrary, and assign it to the Library property.
|
||||
Also, add a TerraSurface into your library.
|
||||
|
||||
Tick the editable property, deselect, then select the world again, and click the insert button at the top toolbar, or press B to insert a
|
||||
voxel at the inspector's camera's location.
|
||||
|
||||
Select the add button, and now you can just add voxels with the mouse, by clicking on the newly added voxel.
|
||||
|
||||
## TerraLibrary
|
||||
|
||||
This class stores the materials, and the TerraSurfaces.
|
||||
|
||||
Lod levels will automatically try to use materials of their own index.\
|
||||
For example lod level 1 will try to use material index 1, lod level 2 will try to use material index 2, etc.\
|
||||
If a material index is not available, they'll use the highest that is.\
|
||||
For example lod level 5 will try to get material index 5, but if you only have 3 materials it will use the 3rd.
|
||||
|
||||
### TerraLibrarySimple
|
||||
|
||||
The simplest library, just assign a material with a texture, and using the atlas_rows and atlas_culomns properties to tell the system
|
||||
how the UVs should be divided.
|
||||
|
||||
This is the basic Minecraft-style lib rary. Use this if you just have one texture atlas.
|
||||
|
||||
### TerraLibraryMerger
|
||||
|
||||
You will only have this if your pandemonium also contains https://github.com/Relintai/texture_packer
|
||||
|
||||
You can assign any texture to your surfaces with this, and it will merge them together.
|
||||
|
||||
### TerraLibraryMergerPCM
|
||||
|
||||
(PCM = Per Chunk Material)
|
||||
|
||||
You will only have this if your pandemonium also contains https://github.com/Relintai/texture_packer
|
||||
|
||||
You can assign any texture to your surfaces with this, and it will merge them together, but it will do it for every required chunk/voxel combination.
|
||||
|
||||
For example if you have a chunk with voxel Grass, and voxel Stone used in it, this library will create a material with a merged texture for Stone and Grass.
|
||||
If you have an anouther chunk which only has Grass and Stone in it, this material will be reused.
|
||||
And if you have a third chunk which only has a Grass voxel used in it, it will get a new merged material and texture only containing Grass voxel.
|
||||
|
||||
## Worlds
|
||||
|
||||
The 2 base classes. These won't do meshing on their own:
|
||||
|
||||
TerraWorld: Basic world, does not do anything until you implemnent the required virtual methods!\
|
||||
TerraWorldDefault: This adds threading, and LoD storage support to TerraWorld. Will not create meshes for you!
|
||||
|
||||
### TerraWorldBlocky
|
||||
|
||||
It generated UV mapped standard simple terrain meshes.
|
||||
The default algorithm can also generate normal lods.
|
||||
|
||||
### Level generation
|
||||
|
||||
Assign a TerraManLevelGenerator to the `World`'s `Level Generator` property.
|
||||
|
||||
You can write your own algorithm by implementing the ``` void _generate_chunk(chunk: TerraChunk) virtual ``` method.
|
||||
|
||||
`TerraManLevelGeneratorFlat` is also available, it will generate a floor for you, if you use it.
|
||||
|
||||
## TerraJobs
|
||||
|
||||
Producing just a terrain mesh for a chunk is not that hard by itself. However when you start adding layers/features
|
||||
like lod generation, collision meshes (especially since manipulating the physics server is not threadsafe),
|
||||
vertex lights, props, snapping props, props with vertex lights, etc
|
||||
chunk mesh generation can quickly become a serious mess.
|
||||
|
||||
TerraJobs are meant to solve the issue with less complexity.
|
||||
|
||||
They also provide a way to easily modularize mesh and lod generation.
|
||||
|
||||
### TerraJob
|
||||
|
||||
Base class for jobs.
|
||||
|
||||
If the [thread pool](https://github.com/Relintai/thread_pool) module is present, this is inherited from `ThreadPoolJob`,
|
||||
else it implements the same api as `ThreadPoolJob`, but it's not going to use threading.
|
||||
|
||||
A job has a reference to it's owner chunk.
|
||||
|
||||
If you implement your own jobs, when your job finishes call `next_job()`.
|
||||
|
||||
### TerraLightJob
|
||||
|
||||
This is the job that will generate vertex light based ao, random ao, and will bake your `TerraLight`s.
|
||||
|
||||
### TerraTerrain2DJob
|
||||
|
||||
This will generate your terrain collider and mesh (with lods) for you, using the meshers that you add into it.
|
||||
|
||||
Your lod setup is easily customizable with [TerraMesherJobSteps](https://github.com/Relintai/terraman/blob/master/world/jobs/voxel_mesher_job_step.h). The setup happens in your selected world's `_create_chunk` method.
|
||||
|
||||
### TerraProp2DJob
|
||||
|
||||
This will generate your prop meshes (with lods).
|
||||
|
||||
Also supports [TerraMesherJobSteps](https://github.com/Relintai/terraman/blob/master/world/jobs/voxel_mesher_job_step.h).
|
||||
|
||||
### Internal workings
|
||||
|
||||
#### TerraWorld
|
||||
|
||||
Whenever you want to spawn a chunk your World will create it using the ``` TerraChunk _create_chunk(x: int, y: int, z: int, chunk: TerraChunk) virtual ``` method.
|
||||
|
||||
Since properly initializing a chunk usually takes quite a few steps that you probably don't want to repeat everywhere the `chunk`
|
||||
parameter was added. This means you can just call the super `_create_chunk` methods, and you won't need to worry about your chunk
|
||||
getting overridden. Like:
|
||||
|
||||
Note that `_create_chunk` is also responsible for initializing chunks if you have them stored inside a scene.
|
||||
This is done by `setup_chunk(shunk)` in `TerraWorld`.
|
||||
|
||||
```
|
||||
func _create_chunk(x : int, y : int, z : int, chunk : TerraChunk) -> TerraChunk:
|
||||
if !chunk:
|
||||
chunk = MyChunk.new()
|
||||
|
||||
# We need to check whether or not we need to initialize jobs
|
||||
if chunk.job_get_count() == 0:
|
||||
# Setup a blocky (minecratf like) mesher job
|
||||
var tj : TerraTerrain2DJob = TerraTerrain2DJob.new()
|
||||
|
||||
var s : TerraMesherJobStep = TerraMesherJobStep.new()
|
||||
s.job_type = TerraMesherJobStep.TYPE_NORMAL
|
||||
tj.add_jobs_step(s)
|
||||
|
||||
tj.add_mesher(TerraMesherBlocky.new())
|
||||
tj.add_liquid_mesher(TerraMesherLiquidBlocky.new())
|
||||
|
||||
chunk.job_add(tj);
|
||||
|
||||
#setup your chunk here
|
||||
|
||||
return ._create_chunk(x, y, z, chunk)
|
||||
```
|
||||
|
||||
You can look at the world implementations for more examples: [TerraWorldBlocky](https://github.com/Relintai/terraman/blob/master/world/blocky/voxel_world_blocky.cpp).
|
||||
|
||||
#### TerraChunk
|
||||
|
||||
Stores terrain data, prop data. And mesh data (TerraChunkDefault), and the mesh generation jobs.
|
||||
|
||||
When it starts building meshes it will start submitting jobs to thread_pool one by one.
|
||||
|
||||
#### TerraMesher
|
||||
|
||||
If you want to implement your own meshing algorithm you can do so by overriding ``` void _add_chunk(chunk: TerraChunk) virtual ```.
|
||||
|
||||
TerraMesher works similarly to SurfaceTool, so first you need to set colors, uvs, etc and then call add_vertex.
|
||||
They won't get reset, so for example if you want all your vertices to have a certain color, you can get away with setting it only once.
|
177
web/docs_hoster_simple/www/04_modules/09_voxelman.md
Normal file
@ -0,0 +1,177 @@
|
||||
# Voxelman
|
||||
|
||||
A voxel engine for pandemonium, focusing more on editor integration, gameplay-related features, and extendability (even from gdscript), without sacrificing too much speed.
|
||||
|
||||
This is an engine module! Which means that you will need to compile it into Pandemonium! [See the compiling section here.](#compiling)
|
||||
|
||||
You can find a demonstration project (with pre-built binaries) here: https://github.com/Relintai/the_tower
|
||||
|
||||
## Optional Dependencies
|
||||
|
||||
`https://github.com/Relintai/texture_packer`: You get access to [VoxelLibraryMerger](#voxellibrarymerger) and [VoxelLibraryMergerPCM](#voxellibrarymergerpcm). \
|
||||
`https://github.com/Relintai/mesh_data_resource`: You get access to a bunch of properties, and methods that can manipulate meshes.\
|
||||
`https://github.com/Relintai/props`: You get access to a bunch of properties, and methods that can manipulate, and use props.\
|
||||
`https://github.com/Relintai/mesh_utils`: Lets you use lod levels higher than 4 by default.
|
||||
|
||||
## Usage
|
||||
|
||||
First create a scene, and add a VoxelWorldBlocky / VoxelWorldMarchingCubes node into it. Create a VoxelLibrary, and assign it to the Library property.
|
||||
Also, add a VoxelSurface into your library.
|
||||
|
||||
Tick the editable property, deselect, then select the world again, and click the insert button at the top toolbar, or press B to insert a
|
||||
voxel at the inspector's camera's location.
|
||||
|
||||
Select the add button, and now you can just add voxels with the mouse, by clicking on the newly added voxel.
|
||||
|
||||
## VoxelLibrary
|
||||
|
||||
This class stores the materials, and the VoxelSurfaces.
|
||||
|
||||
Lod levels will automatically try to use materials of their own index.\
|
||||
For example lod level 1 will try to use material index 1, lod level 2 will try to use material index 2, etc.\
|
||||
If a material index is not available, they'll use the highest that is.\
|
||||
For example lod level 5 will try to get material index 5, but if you only have 3 materials it will use the 3rd.
|
||||
|
||||
### VoxelLibrarySimple
|
||||
|
||||
The simplest library, just assign a material with a texture, and using the atlas_rows and atlas_culomns properties to tell the system
|
||||
how the UVs should be divided.
|
||||
|
||||
This is the basic Minecraft-style lib rary. Use this if you just have one texture atlas.
|
||||
|
||||
### VoxelLibraryMerger
|
||||
|
||||
You will only have this if your pandemonium also contains https://github.com/Relintai/texture_packer
|
||||
|
||||
You can assign any texture to your surfaces with this, and it will merge them together.
|
||||
|
||||
### VoxelLibraryMergerPCM
|
||||
|
||||
(PCM = Per Chunk Material)
|
||||
|
||||
You will only have this if your pandemonium also contains https://github.com/Relintai/texture_packer
|
||||
|
||||
You can assign any texture to your surfaces with this, and it will merge them together, but it will do it for every required chunk/voxel combination.
|
||||
|
||||
For example if you have a chunk with voxel Grass, and voxel Stone used in it, this library will create a material with a merged texture for Stone and Grass.
|
||||
If you have an anouther chunk which only has Grass and Stone in it, this material will be reused.
|
||||
And if you have a third chunk which only has a Grass voxel used in it, it will get a new merged material and texture only containing Grass voxel.
|
||||
|
||||
## Worlds
|
||||
|
||||
The 2 base classes. These won't do meshing on their own:
|
||||
|
||||
VoxelWorld: Basic world, does not do anything until you implemnent the required virtual methods!\
|
||||
VoxelWorldDefault: This adds threading, and LoD storage support to VoxelWorld. Will not create meshes for you!
|
||||
|
||||
### VoxelWorldBlocky
|
||||
|
||||
The most basic world. It is the Minecraft-style world.
|
||||
|
||||
### VoxelWorldMarchingCubes
|
||||
|
||||
A marching cubes based Voxel World. Actually it uses a modified version of the Transvoxel tables, because it is UV mapped.
|
||||
|
||||
### VoxelWorldCubic
|
||||
|
||||
This is my own meshing algorithm, it's basically a Minecraft style mesher that can take isolevel into account.
|
||||
|
||||
It's kind of a pain to use, it might get removed.
|
||||
|
||||
### Level generation
|
||||
|
||||
Assign a VoxelManLevelGenerator to the `World`'s `Level Generator` property.
|
||||
|
||||
You can write your own algorithm by implementing the ``` void _generate_chunk(chunk: VoxelChunk) virtual ``` method.
|
||||
|
||||
`VoxelManLevelGeneratorFlat` is also available, it will generate a floor for you, if you use it.
|
||||
|
||||
## VoxelJobs
|
||||
|
||||
Producing just a terrain mesh for a chunk is not that hard by itself. However when you start adding layers/features
|
||||
like lod generation, collision meshes (especially since manipulating the physics server is not threadsafe),
|
||||
vertex lights, props, snapping props, props with vertex lights, etc
|
||||
chunk mesh generation can quickly become a serious mess.
|
||||
|
||||
VoxelJobs are meant to solve the issue with less complexity.
|
||||
|
||||
They also provide a way to easily modularize mesh and lod generation.
|
||||
|
||||
### VoxelJob
|
||||
|
||||
Base class for jobs.
|
||||
|
||||
If the [thread pool](https://github.com/Relintai/thread_pool) module is present, this is inherited from `ThreadPoolJob`,
|
||||
else it implements the same api as `ThreadPoolJob`, but it's not going to use threading.
|
||||
|
||||
A job has a reference to it's owner chunk.
|
||||
|
||||
If you implement your own jobs, when your job finishes call `next_job()`.
|
||||
|
||||
### VoxelLightJob
|
||||
|
||||
This is the job that will generate vertex light based ao, random ao, and will bake your `VoxelLight`s.
|
||||
|
||||
### VoxelTerrainJob
|
||||
|
||||
This will generate your terrain collider and mesh (with lods) for you, using the meshers that you add into it.
|
||||
|
||||
Your lod setup is easily customizable with [VoxelMesherJobSteps](https://github.com/Relintai/voxelman/blob/master/world/jobs/voxel_mesher_job_step.h). The setup happens in your selected world's `_create_chunk` method.
|
||||
|
||||
### VoxelPropJob
|
||||
|
||||
This will generate your prop meshes (with lods).
|
||||
|
||||
Also supports [VoxelMesherJobSteps](https://github.com/Relintai/voxelman/blob/master/world/jobs/voxel_mesher_job_step.h).
|
||||
|
||||
### Internal workings
|
||||
|
||||
#### VoxelWorld
|
||||
|
||||
Whenever you want to spawn a chunk your World will create it using the ``` VoxelChunk _create_chunk(x: int, y: int, z: int, chunk: VoxelChunk) virtual ``` method.
|
||||
|
||||
Since properly initializing a chunk usually takes quite a few steps that you probably don't want to repeat everywhere the `chunk`
|
||||
parameter was added. This means you can just call the super `_create_chunk` methods, and you won't need to worry about your chunk
|
||||
getting overridden. Like:
|
||||
|
||||
Note that `_create_chunk` is also responsible for initializing chunks if you have them stored inside a scene.
|
||||
This is done by `setup_chunk(shunk)` in `VoxelWorld`.
|
||||
|
||||
```
|
||||
func _create_chunk(x : int, y : int, z : int, chunk : VoxelChunk) -> VoxelChunk:
|
||||
if !chunk:
|
||||
chunk = MyChunk.new()
|
||||
|
||||
# We need to check whether or not we need to initialize jobs
|
||||
if chunk.job_get_count() == 0:
|
||||
# Setup a blocky (minecratf like) mesher job
|
||||
var tj : VoxelTerrainJob = VoxelTerrainJob.new()
|
||||
|
||||
var s : VoxelMesherJobStep = VoxelMesherJobStep.new()
|
||||
s.job_type = VoxelMesherJobStep.TYPE_NORMAL
|
||||
tj.add_jobs_step(s)
|
||||
|
||||
tj.add_mesher(VoxelMesherBlocky.new())
|
||||
tj.add_liquid_mesher(VoxelMesherLiquidBlocky.new())
|
||||
|
||||
chunk.job_add(tj);
|
||||
|
||||
#setup your chunk here
|
||||
|
||||
return ._create_chunk(x, y, z, chunk)
|
||||
```
|
||||
|
||||
You can look at the world implementations for more examples: [VoxelWorldBlocky](https://github.com/Relintai/voxelman/blob/master/world/blocky/voxel_world_blocky.cpp), [VoxelWorldMarchingCubes](https://github.com/Relintai/voxelman/blob/master/world/marching_cubes/voxel_world_marching_cubes.cpp).
|
||||
|
||||
#### VoxelChunk
|
||||
|
||||
Stores terrain data, prop data. And mesh data (VoxelChunkDefault), and the mesh generation jobs.
|
||||
|
||||
When it starts building meshes it will start submitting jobs to thread_pool one by one.
|
||||
|
||||
#### VoxelMesher
|
||||
|
||||
If you want to implement your own meshing algorithm you can do so by overriding ``` void _add_chunk(chunk: VoxelChunk) virtual ```.
|
||||
|
||||
VoxelMesher works similarly to SurfaceTool, so first you need to set colors, uvs, etc and then call add_vertex.
|
||||
They won't get reset, so for example if you want all your vertices to have a certain color, you can get away with setting it only once.
|
555
web/docs_hoster_simple/www/04_modules/10_entity_spell_system.md
Normal file
@ -0,0 +1,555 @@
|
||||
# Entity Spell System
|
||||
|
||||
An entity and spell system for the PANDEMONIUM Engine, that is usable for both 2d, and 3d games. The main purpose of this
|
||||
module is to handle spells, auras, and most entity-related things like spawning, items, inventory, containers,
|
||||
vendors, interaction, targeting, equipment (+ visuals), loot, crafting, talents, pets, npcs, etc ...
|
||||
|
||||
The module supports networking. It is designed to be authoritative, so players shouldn't be able to cheat by design.
|
||||
|
||||
## Project setup tl;dr
|
||||
|
||||
### First
|
||||
|
||||
You need to create an `ESSResourceDB` resource somewhere in you project. (Or alloocate it dynamically.)
|
||||
|
||||
Now you can either:
|
||||
|
||||
-Go to `ProjectSettings->Ess->Data`, and set the `ess_resource_db_path` property also make sure that `automatic_load` is on.
|
||||
|
||||
-Or you can load it yourself and set it into the `ESS` singleton either using the `resource_db` property.
|
||||
|
||||
### Second
|
||||
|
||||
You need to add an `ESSEntitySpawner` somewhere into your SceneTree. I recommend that you create an autoload for it.
|
||||
This is where you have to implement your spawning logic.
|
||||
|
||||
### What the module doesn't cover
|
||||
|
||||
Movement, and controls.
|
||||
|
||||
Unfortunately, there isn't a one-stop-shop solution for movement, especially if we throw networking into the mix,
|
||||
and the same is true for targeting. This means that this module cannot really do much in this regard, but it will
|
||||
give you as much help to set everything up as possible.
|
||||
|
||||
## Optional Dependencies
|
||||
|
||||
Mesh Data Resource
|
||||
|
||||
https://github.com/Relintai/mesh_data_resource.git
|
||||
|
||||
Adds mesh (MeshDataResource) support to ModelVisuals.
|
||||
|
||||
## Pre-built binaries
|
||||
|
||||
You can grab a pre-built editor binary from the [Broken Seals](https://github.com/Relintai/broken_seals/releases)
|
||||
repo, should you want to. It contains all my modules.
|
||||
|
||||
## Overview
|
||||
|
||||
The module provides a huge number of script callbacks, usually as virtual methods they usually start with an underscore.
|
||||
|
||||
Do not call methods with underscores, all of them has a normal counterpart, always call that.
|
||||
|
||||
For example entity has `crafts(int id)` and `_crafts(int id)` (virtual). Always use `crafts(int id)`, it will
|
||||
call `_crafts(int id)`.
|
||||
|
||||
For networked classes, every variable is broken up into clientside, and serverside. This makes it easier to
|
||||
develop games that can also run locally, with less overhead and simpler logic.
|
||||
E.g. this makes it easy to use the visibility system even when you play locally on the server, because you just use the clientside variables,
|
||||
and your logic will work the same way.
|
||||
|
||||
## Settings
|
||||
|
||||
Entity and spell system comes with quite a few settings, you can find these under `ProjectSettings->Ess`.
|
||||
|
||||
## Singletons
|
||||
|
||||
The module contains 2 singletons. `ESS`, and `ProfileManager`. Both are accessible from scripts.
|
||||
|
||||
### The ESS singleton
|
||||
|
||||
Contains the active `ESSResourceDB` instance, and for convenience a reference to the active `ESSEntitySpawner`
|
||||
instance. Also loads/handles/processes all of the entity and spell system related ProjectSettings, so if you need
|
||||
any ESS related value from ProjectSettings, don't query it directly, get it from this singleton.
|
||||
|
||||
Customizable enums values are preprocessed, and you usually have multiple ways of getting them.
|
||||
|
||||
### The ProfileManager singleton
|
||||
|
||||
Contains methods to easily load/save/handle `PlayerProfile`s.
|
||||
|
||||
#### PlayerProfile
|
||||
|
||||
Contains player-related data, most notably `ClassProfile`s.
|
||||
|
||||
#### ClassProfile
|
||||
|
||||
Contains class-related data, most notably `ActionBarProfile`s, and `InputProfiles`.
|
||||
|
||||
#### ActionBarProfile
|
||||
|
||||
Contains the data for a set of actionbars.
|
||||
|
||||
#### InputProfileswd
|
||||
|
||||
Contains the keybind data for a class.
|
||||
|
||||
## Enums
|
||||
|
||||
ESS needs lots of enums to work, and to reduce complexity with includes they ended up in a few separate classes.
|
||||
|
||||
I'm still in the process of converting these to be customizable (`ESS` singleton / ProjectSettings).
|
||||
|
||||
(Only the ones that worth it will be converted.)
|
||||
|
||||
### EntityEnums
|
||||
|
||||
Contains Entity-related enums, like AIStates, skeleton attach points, entity flags, immunity flags,
|
||||
state flags.
|
||||
|
||||
### ItemEnums
|
||||
|
||||
Contains item-related enums, like rarity, armor type, item types.
|
||||
|
||||
### SpellEnums
|
||||
|
||||
Contains spell-related enums, like aura types, damage types, spell categories, spell types, trigger types,
|
||||
and quite a few notification constants.
|
||||
|
||||
### Customizable enums
|
||||
|
||||
Open `ProjectSettings`, and then go to `ESS/Enums`.
|
||||
|
||||
All of the string properties are customizable enums. These require a comma-separated list.
|
||||
They are essentially a pandemonium comma separated property hint enum string.
|
||||
|
||||
They all have defaults.
|
||||
|
||||
Fer example:
|
||||
|
||||
If you want you game to work with the following stats: Agility,Intellect,Crit,Weapon Damage,Stamina
|
||||
and you want Agility,Intellect,Stamina as you main stats.
|
||||
|
||||
Firstly you want to put you main stats at the beginning, because the system will take the first `main_stat_count`
|
||||
stats as main stats.
|
||||
|
||||
And then just enter `Agility,Intellect,Stamina,Crit,Weapon Damage` into the `stats` setting, and then
|
||||
set `main_stat_count` to 3.
|
||||
|
||||
When these values are expected to be used as properties, the `ESS` singleton will create snake_cased versions automatically.
|
||||
`String stat_get_property_name(id: int) const` inside the ESS singleton for example.
|
||||
|
||||
So in the example case `ESS.stat_get_property_name(4)` would return `weapon_damage`.
|
||||
|
||||
## ESSResourceDB
|
||||
|
||||
This is a class that maps ids to resources for quick lookups.
|
||||
This is necessary in order to support networking, because you don't want to send resource paths over the network
|
||||
every time somebody casts a spell for example.
|
||||
|
||||
### ESSResourceDBStatic
|
||||
|
||||
Simple static resource db. Just drag and drop all your data that you use into it with the inspector.
|
||||
|
||||
Stores the data as vectors.
|
||||
|
||||
Supports id remapping, which means that it can assign new ids to all added resources, so they don't clash.
|
||||
The added resource's index will be set as it's id.
|
||||
|
||||
This is useful for modding support, as you can just collect every mod's resource dbs, and add them to a static db,
|
||||
and with this option enabled the ids will not clash.
|
||||
|
||||
You can see an example of this [here](https://github.com/Relintai/broken_seals/blob/master/game/scripts/game_modules/DataManager.gd).
|
||||
|
||||
### ESSResourceDBMap
|
||||
|
||||
Stores everything as a vector, and a map.
|
||||
|
||||
#### ESSResourceDBFolders
|
||||
|
||||
Inherited from `ESSResourceDBMap`.
|
||||
|
||||
It will load everything from the folders that you set up into it's `folders` property.
|
||||
|
||||
## Entity
|
||||
|
||||
This is the main class that can be used for players/mobs/npcs and also other things like chests.
|
||||
|
||||
I ended up merging subclass functionality into it, because
|
||||
that way it gains a lot more utility, by sacrificing only a small amount of memory.
|
||||
For example this way it is easy to make chests attack the player, or make spell that animate objects.
|
||||
|
||||
## Entity Body
|
||||
|
||||
Originally entities used to be inherited from `Spatial` or `Node2D`, so they could contain/drive their own models,
|
||||
but eventually on order to support both 2d, and 3d, bodies were separated from them. This unfortunately
|
||||
complicates the setup a bit, but the upsides overweight the downsides, as this way you don't need to create different
|
||||
entities for every model/body you have.
|
||||
|
||||
Bodies are stored at `EntityData->EntitySpeciesData->ModelDatas (SpeciesModelData)->Body`
|
||||
|
||||
When an `Entity` gets initialized, it will instance it's body automatically, but if you want to do it yourself,
|
||||
you can call `void instance_body(entity_data: EntityData, model_index: int)` on an `Entity`.
|
||||
|
||||
The `model_index` property tell the `Entity` which one it should use.
|
||||
|
||||
Instancing bodies does not happen immediately, but you will probably want to set an `Entity`'s position right where
|
||||
you create it, a few helpers were added:\
|
||||
|
||||
`void set_transform_2d(transform: Transform2D, only_stored: bool = false)`\
|
||||
`void set_transform_3d(transform: Transform, only_stored: bool = false)`
|
||||
|
||||
Your body implementation then can get this from an entity an set itself to the right place.
|
||||
|
||||
### CharacterSkeletons
|
||||
|
||||
CharacterSkeletons handle the looks of your characters.
|
||||
|
||||
They come in two variants, one for 2d, one for 3d.
|
||||
|
||||
They have quite a few helper methods.
|
||||
|
||||
They can store ModelVisuals, and ModelVisualEntries.
|
||||
|
||||
They support attach points. For example a character's hand.
|
||||
It adds properties based on the selected entity_type.
|
||||
These are based on the values from `ProjectSettings->ESS->Enums->skeletons_bone_attachment_points`.
|
||||
|
||||
If you want to merge meshes this is where you can implement it.
|
||||
|
||||
#### CharacterSkeleton3D
|
||||
|
||||
The 3d variant.
|
||||
|
||||
[Complex 3d skeleton scene](https://github.com/Relintai/broken_seals/blob/master/game/models/entities/human/models/armature_huf.tscn) \
|
||||
[Complex 3d skeleton script](https://github.com/Relintai/broken_seals/blob/master/game/player/CharacterSkeletonGD.gd)
|
||||
|
||||
#### CharacterSkeleton2D
|
||||
|
||||
The 2d variant.
|
||||
|
||||
[Simple 2d roguelike skeleton script](https://github.com/Relintai/broken_seals_roguelike/blob/master/game/characters/SimpleCharacter.gd) \
|
||||
[Simple 2d roguelike skeleton scene](https://github.com/Relintai/broken_seals_roguelike/blob/master/game/characters/SimpleCharacter.tscn)
|
||||
|
||||
#### ModelVisual
|
||||
|
||||
A collection ModelVisualEntries.
|
||||
|
||||
You will need to use this to define a look. For example if you have an item that will change your character's clothes,
|
||||
you will use this.
|
||||
|
||||
##### ModelVisualEntry
|
||||
|
||||
Contains meshes, textures, texture tints, mesh transforms.
|
||||
|
||||
It has 2 modes, `Bone` and `Attachment`.
|
||||
|
||||
In the bone mode, you need to select an entity type, and then a concrete bone. This is the "merge this into the final character mesh" mode.
|
||||
|
||||
In the attachment mode, you need to select a common attach point (`ProjectSettings->Ess->enums->skeletons_bone_attachment_points`),
|
||||
and the containing mesh will be put on to that point by the CharacterSkeleton. This is how you can implement weapons for example.
|
||||
|
||||
### EntitySpeciesData
|
||||
|
||||
Contains data related to a species, like `SpeciesModelData`s, and species specific spells, and auras.
|
||||
|
||||
#### SpeciesModelData
|
||||
|
||||
Contains a scene of a species's body and it's customizations.
|
||||
|
||||
The `customizable_slots_string` and `customizable_colors_string` should be filled with a comma separated string,
|
||||
they will add properties. Currently you need to click on something else, and back on the resource for these to show up,
|
||||
after a change to the strings.
|
||||
|
||||
The body can be any scene, Entity will instance it, and set it to it's body property.
|
||||
|
||||
The body should handle movement based on the player's input, it should handle sending position information through the network,
|
||||
if you want networking, it might (`CharacterSkeleton`s can also do it) also drive your animations/animation players if you have it.
|
||||
|
||||
Bodies does not need to handle the graphics themselves (`ModelVisualEntries` for example) (you can implement your logic here
|
||||
if you want to), but the `CharacterSkeleton` classes exist for that purpose.
|
||||
|
||||
[Complex 3d body script](https://github.com/Relintai/broken_seals/blob/master/game/player/Body.gd) \
|
||||
[Complex 3d body scene](https://github.com/Relintai/broken_seals/blob/master/game/models/entities/human/models/HumanFemale.tscn)
|
||||
|
||||
[Simple 2d roguelike body script](https://github.com/Relintai/broken_seals_roguelike/blob/master/game/player/Body.gd) \
|
||||
[Simple 2d roguelike body scene](https://github.com/Relintai/broken_seals_roguelike/blob/master/game/player/Body.gd)
|
||||
|
||||
#### SpeciesInstance
|
||||
|
||||
This class will store character model customization data. E.g. which hairstyle you want for an `Entity`.
|
||||
|
||||
Not yet finished!
|
||||
|
||||
### Spawning
|
||||
|
||||
Since spawning (= creating) entities is entirely dependent on the type of game you are making, ESS cannot do
|
||||
everything for you. It will set up stats, equipment etc, but there is no way to set up positions for example.
|
||||
|
||||
You can implement your spawning logic by inheriting from `ESSEntitySpawner`, and implementing `_request_entity_spawn`.
|
||||
|
||||
You should only have one spawner at any given time. It will register itself into the ESS singleton automatically.
|
||||
|
||||
Since it is inherited from Node, I recommend that you create an autoload for it.
|
||||
|
||||
The ESS singleton also contains convenience methods to request spawning an Entity.
|
||||
|
||||
[Sample 3d spawner implementation](https://github.com/Relintai/broken_seals/blob/master/game/player/bs_entity_spawner.gd) \
|
||||
[Sample 2d spawner implementation](https://github.com/Relintai/broken_seals_roguelike/blob/master/game/player/bs_entity_spawner.gd)
|
||||
|
||||
#### EntityCreateInfo
|
||||
|
||||
Entity spawning usually requires a lot of complexity and hassle, this helper class aims to make it painless.
|
||||
|
||||
All methods that deal with spawning will take this as a parameter.
|
||||
|
||||
### EntityData
|
||||
|
||||
Since setting up Entities as scenes is usually quite the hassle, `EntityData` had to be created.
|
||||
|
||||
It stores everything an entity needs.
|
||||
|
||||
In order to spawn an entity you need it.
|
||||
|
||||
#### EntityClassData
|
||||
|
||||
`EntityClassData` holds class-related information, like specs (`CharacterSpec`), spells, start spells, start auras,
|
||||
alternative ais, `EntityResource`s (mana for example).
|
||||
|
||||
#### CharacterSpec
|
||||
|
||||
`CharacterSpec` holds spec-related information, most notably talents.
|
||||
|
||||
#### EntityResource
|
||||
|
||||
EntityResources are things like mana, health, or speed. These add greater flexibility over stats.
|
||||
|
||||
The resource system is quite flexible, if you add a resource serverside, it will be automatically
|
||||
added clientside. (You have to add `EntityResource`s to the active `ESSResourceDB`!)
|
||||
|
||||
By default all entities have the build in speed and health resources, as a set index
|
||||
(`EntityEnums::ENTITY_RESOURCE_INDEX_HEALTH` and `EntityEnums::ENTITY_RESOURCE_INDEX_SPEED`).
|
||||
|
||||
There is also the `EntityEnums::ENTITY_RESOURCE_INDEX_RESOURCES_BEGIN` constant, so you have
|
||||
the current offset where the custom resources start.
|
||||
|
||||
Entity allocates these in it's `_initialize()` virtual method, if you want to customize them.
|
||||
|
||||
Note that `EntityClassData` contains an array, so you can add more resources easily to classes,
|
||||
these will be automatically added when the system initializes an `Entity`.
|
||||
|
||||
##### EntityResourceHealth
|
||||
|
||||
The standard health resource implementation.
|
||||
|
||||
##### EntityResourceSpeed
|
||||
|
||||
The standard speed resource implementation.
|
||||
|
||||
#### EntityResourceCostData
|
||||
|
||||
This is the class that lets you implement resource costs. For example mana cost for a spell.
|
||||
|
||||
##### EntityResourceCostDataResource
|
||||
|
||||
The standard resource cost implementation.
|
||||
|
||||
##### EntityResourceCostDataHealth
|
||||
|
||||
The standard health resource cost implementation.
|
||||
|
||||
It has a resource property, so you can just assign any resource to this.
|
||||
|
||||
### Interactions
|
||||
|
||||
If you want your player to interact with it's target. For example a vendor, or loot.
|
||||
|
||||
First make sure that you can interact, by checking `Entity.cans_interact()` or `Entity.canc_interact()`.
|
||||
If this returns true, you can call `Entity.crequest_interact()`. This will call `Entity.sinteract()` serverside.
|
||||
|
||||
Interactions are handled by `EntityData` by default. It has the same methods. If `EntityData` is not set, the `Entity`
|
||||
will try to call the same overridable on itself.
|
||||
|
||||
You can see an example implementation [here](https://github.com/Relintai/broken_seals/blob/master/game/scripts/entities/EntityDataGD.gd).
|
||||
|
||||
### AI
|
||||
|
||||
You can implement ai by extending `EntityAI`, and then assigning it to an `EntityData`.
|
||||
|
||||
When an `Entity` gets spawned it will create a copy for itself, so you can safely use class variables.
|
||||
|
||||
#### AIFormation
|
||||
|
||||
Not yet finished, it was meant as a way to calculate offset pet positions, (If an `Entity` has let's say
|
||||
4 pets you don't just want them all to stay on top of their controller).
|
||||
|
||||
If this functionality ends up in `EntityAI`, after pets are finished, this will be removed.
|
||||
|
||||
### Pets
|
||||
|
||||
Unfortunately pet support is not yet finished.
|
||||
|
||||
It is mostly done though, so you will see pet-related methods scattered around.
|
||||
|
||||
### Bags
|
||||
|
||||
Stores items. See `Bag`. It has quite a few virtual methods, you should be able to implement most inventory types
|
||||
should you want to.
|
||||
|
||||
Entity will send these over the network.
|
||||
|
||||
Also Entities have a target bag property. For example this makes vendors easily implementable.
|
||||
|
||||
### VRPCs
|
||||
|
||||
Entities has a networked visibility system. The method itself is called `vrpc`, it works the same way as normal rpcs.
|
||||
If you want to send data to every client that sees the current entity, use this.
|
||||
|
||||
## Spells, Auras, Talents
|
||||
|
||||
Spell is the class you need to create both spells, and aura.\
|
||||
It stores the data, and also it has the ability to be scripted.\
|
||||
Talents are actually just spells used as Auras. Right now the system just applies them as a permanent aura.\
|
||||
You don't need to worry about applying auras, cast them as spells instead. It they are set to permanent, or they have a duration set they will be applied as an aura automatically.
|
||||
|
||||
Talent ranks are implemented by deapplying the earlier rank first, then applying the new rank.
|
||||
|
||||
### How to
|
||||
|
||||
Request casting a spell clientside: `void spell_crequest_cast(spell_id: int)` \
|
||||
Request to learn a spell clientside: `void spell_learn_requestc(id: int)`
|
||||
|
||||
Request talent learning clientside: \
|
||||
`void character_talent_crequest_learn(spec_index: int, character_talent_row: int, character_talent_culomn: int)` or \
|
||||
`void class_talent_crequest_learn(spec_index: int, class_talent_row: int, class_talent_culomn: int)`
|
||||
|
||||
#### Cast a spell
|
||||
|
||||
Note that you should only do this serverside.
|
||||
|
||||
```
|
||||
# Or get it from the active ESSResourceDB, etc
|
||||
export(Spell) var spell : Spell
|
||||
|
||||
func scast_spell() -> void:
|
||||
var sci : SpellCastInfo = SpellCastInfo.new()
|
||||
|
||||
sci.caster = info.caster
|
||||
sci.target = info.target
|
||||
sci.has_cast_time = spell.cast_enabled
|
||||
sci.cast_time = spell.cast_cast_time
|
||||
sci.spell_scale = info.spell_scale
|
||||
sci.set_spell(spell)
|
||||
|
||||
spell.cast_starts(sci)
|
||||
|
||||
```
|
||||
|
||||
#### Apply an aura
|
||||
|
||||
Normally you shouldn't do this, this is for more advanced uses. Cast the aura as a spell instead.
|
||||
|
||||
Note that you should only apply auras serverside, they will be sent to clients automatically.
|
||||
|
||||
```
|
||||
# Or get it from the active ESSResourceDB, etc
|
||||
export(Spell) var aura : Spell
|
||||
|
||||
func sapply_aura() -> void:
|
||||
var ainfo : AuraApplyInfo = AuraApplyInfo.new()
|
||||
|
||||
ainfo.caster = info.caster
|
||||
ainfo.target = info.caster
|
||||
ainfo.spell_scale = 1
|
||||
ainfo.aura = aura
|
||||
|
||||
aura.sapply(ainfo)
|
||||
|
||||
```
|
||||
|
||||
#### UI
|
||||
|
||||
[Complete UI Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player)
|
||||
|
||||
[Player UI Core Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/player_ui)
|
||||
|
||||
[Aura Frame Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/auraframe) \
|
||||
[Castbar Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/castbar) \
|
||||
[Unitframe Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/unitframes)
|
||||
|
||||
[Actionbar Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/actionbars)
|
||||
|
||||
[Character Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/character) \
|
||||
[Inventory Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/bags) \
|
||||
[Crafting Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/crafting) \
|
||||
[Loot Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/loot_window) \
|
||||
[Talent Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/talents) \
|
||||
[Spellbook Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/spellbook) \
|
||||
[Vendor Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/vendor_window) \
|
||||
[Trainer Window Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/trainer)
|
||||
|
||||
[3D Nameplate Implementation](https://github.com/Relintai/broken_seals/tree/master/game/ui/world/nameplates) \
|
||||
[2D Nameplate Implementation](https://github.com/Relintai/broken_seals_roguelike/tree/master/game/ui/nameplates)
|
||||
|
||||
### Infos / Pipelines
|
||||
|
||||
#### SpellCastInfo
|
||||
|
||||
Stores information about the state of a spell's cast.
|
||||
|
||||
#### AuraApplyInfo
|
||||
|
||||
Helps to apply auras
|
||||
|
||||
#### SpellDamageInfo, SpellHealInfo
|
||||
|
||||
These are used in the damage and heal calculation. For example these can be used to implement immunities, or absorb effects
|
||||
by modifying their damage values in aura callbacks.
|
||||
|
||||
### Projectiles
|
||||
|
||||
Spells support projectiles, they are created/set up inside `void handle_projectile(info: SpellCastInfo)`.
|
||||
|
||||
The default implementation will instance `Spell`'s projectile scene (if set), and then it will try to call a
|
||||
`void setup_projectile(info: SpellCastInfo)` on it if exists.
|
||||
|
||||
You can override this behaviour by implementing your own `_void handle_projectile(info: SpellCastInfo)` on `Spell`
|
||||
|
||||
Note that the module already adds `SpellFollowProjectile3D`, but this has not been finished yet.
|
||||
|
||||
## Items
|
||||
|
||||
Items are implemented using 2 classes, `ItemTemplate`, and `ItemInstance`.
|
||||
|
||||
`ItemTemplate` contains all information for a potential item. You can generate `Iteminstance`s with this,
|
||||
using it's `ItemInstance create_item_instance()` method. You can also implement your custom item creation logic
|
||||
using the `void _create_item_instance()` virtual.
|
||||
|
||||
`ItemInstance` is the actual item.
|
||||
|
||||
### Loot
|
||||
|
||||
Looting can be implemented using `Entity`'s target bag functionality.
|
||||
|
||||
You can see an example implementation [here](https://github.com/Relintai/broken_seals/blob/master/game/scripts/entities/EntityDataGD.gd). \
|
||||
And an example ui implementation [here](https://github.com/Relintai/broken_seals/tree/master/game/ui/player/loot_window).
|
||||
|
||||
## XP
|
||||
|
||||
You can set all the xp values for your levels in `ProjectSettings->Ess->xp`.
|
||||
|
||||
Now you can start distributing xp, for whatever you'd like to Entities, using `Entity.xp_adds(value : int)`
|
||||
|
||||
## Examples
|
||||
|
||||
Eventually I'll create a separate repository with a few examples/demos, but for now you can check the game
|
||||
I've been working on for examples.
|
||||
|
||||
3d:
|
||||
https://github.com/Relintai/broken_seals.git
|
||||
|
||||
2d turn based:
|
||||
https://github.com/Relintai/broken_seals_roguelike
|
||||
|
||||
2d:
|
||||
https://github.com/Relintai/broken_seals_2d.git
|
@ -0,0 +1,7 @@
|
||||
# Skeleton Editor
|
||||
|
||||
This is a c++ engine module for the Pandemonium engine that contains a modularized version of TokageItLab's pr's 3.2 version from the pandemonium engine repository, until it gets merged.
|
||||
|
||||
The original pr is here: https://github.com/Relintai/pandemonium_engine/pull/45699
|
||||
Tht 3.x version (linked in the pr itself) is here (This is the base for this module): https://github.com/TokageItLab/pandemonium/tree/pose-edit-mode
|
||||
|
45
web/docs_hoster_simple/www/04_modules/12_ui_extensions.md
Normal file
@ -0,0 +1,45 @@
|
||||
# UI Extensions
|
||||
|
||||
This is a c++ engine module for the Pandemonium engine, containing smaller utilities.
|
||||
|
||||
# TouchButton
|
||||
|
||||
A `Control` based button, that handles multitouch properly.
|
||||
|
||||
# BSInputEventKey
|
||||
|
||||
An `inputEventKey` implementation, that matches actions exactly.
|
||||
|
||||
For example with the default pandemonium implementation if you have an action that gets triggered
|
||||
with the key `E` then `Ctrl-E` will also trigger it.
|
||||
|
||||
This has the side effect, that if you bind an action to `E`, and an another one to `Ctrl-E`,
|
||||
then hitting `Ctrl-E` will trigger both.
|
||||
|
||||
This implementation changes that behaviour.
|
||||
|
||||
However, you do need to replace normal input events at startup like this:
|
||||
|
||||
```
|
||||
func _ready():
|
||||
var actions : Array = InputMap.get_actions()
|
||||
|
||||
for action in actions:
|
||||
var acts : Array = InputMap.get_action_list(action)
|
||||
|
||||
for i in range(len(acts)):
|
||||
var a = acts[i]
|
||||
if a is InputEventKey:
|
||||
var nie : BSInputEventKey = BSInputEventKey.new()
|
||||
nie.from_input_event_key(a as InputEventKey)
|
||||
acts[i] = nie
|
||||
|
||||
InputMap.action_erase_event(action, a)
|
||||
InputMap.action_add_event(action, nie)
|
||||
|
||||
```
|
||||
|
||||
I recommend putting this code into a singleton.
|
||||
|
||||
|
||||
|
294
web/docs_hoster_simple/www/04_modules/csg/01_csg_tools.md
Normal file
@ -0,0 +1,294 @@
|
||||
|
||||
|
||||
Prototyping levels with CSG
|
||||
===========================
|
||||
|
||||
CSG stands for **Constructive Solid Geometry**, and is a tool to combine basic
|
||||
shapes or custom meshes to create more complex shapes. In 3D modelling software,
|
||||
CSG is mostly known as "Boolean Operators".
|
||||
|
||||
Level prototyping is one of the main uses of CSG in Pandemonium. This technique allows
|
||||
users to create simple versions of most common shapes by combining primitives.
|
||||
Interior environments can be created by using inverted primitives.
|
||||
|
||||
Note:
|
||||
The CSG nodes in Pandemonium are mainly intended for prototyping. There is
|
||||
no built-in support for UV mapping or editing 3D polygons (though
|
||||
extruded 2D polygons can be used with the CSGPolygon node).
|
||||
|
||||
If you're looking for an easy to use level design tool for a project,
|
||||
you may want to use `Qodot ( https://github.com/Shfty/qodot-plugin )`
|
||||
instead. It lets you design levels using
|
||||
`TrenchBroom ( https://kristianduske.com/trenchbroom/ )` and import
|
||||
them in Pandemonium.
|
||||
|
||||
![](img/csg.gif)
|
||||
|
||||
Introduction to CSG nodes
|
||||
-------------------------
|
||||
|
||||
Like other features of Pandemonium, CSG is supported in the form of nodes. These are
|
||||
the CSG nodes:
|
||||
|
||||
- `CSGBox`
|
||||
- `CSGCylinder` (also supports cone)
|
||||
- `CSGSphere`
|
||||
- `CSGTorus`
|
||||
- `CSGPolygon`
|
||||
- `CSGMesh`
|
||||
- `CSGCombiner`
|
||||
|
||||
![](img/csg_nodes.png)
|
||||
|
||||
![](img/csg_mesh.png)
|
||||
|
||||
CSG tools features
|
||||
~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Every CSG node supports 3 kinds of boolean operations:
|
||||
|
||||
- **Union:** Geometry of both primitives is merged, intersecting geometry
|
||||
is removed.
|
||||
- **Intersection:** Only intersecting geometry remains, the rest is removed.
|
||||
- **Subtraction:** The second shape is subtracted from the first, leaving a dent
|
||||
with its shape.
|
||||
|
||||
![](img/csg_operation_menu.png)
|
||||
|
||||
![](img/csg_operation.png)
|
||||
|
||||
CSGPolygon
|
||||
~~~~~~~~~~
|
||||
|
||||
The `CSGPolygon` node extrude along a Polygon drawn in
|
||||
2D (in X, Y coordinates) in the following ways:
|
||||
|
||||
- **Depth:** Extruded back a given amount.
|
||||
- **Spin:** Extruded while spinning around its origin.
|
||||
- **Path:** Extruded along a Path node. This operation is commonly called
|
||||
lofting.
|
||||
|
||||
![](img/csg_poly_mode.png)
|
||||
|
||||
![](img/csg_poly.png)
|
||||
|
||||
Note:
|
||||
The **Path** mode must be provided with a `Path`
|
||||
node to work. In the Path node, draw the path and the polygon in
|
||||
CSGPolygon will extrude along the given path.
|
||||
|
||||
|
||||
Custom meshes
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
Any mesh can be used for `CSGMesh`; the mesh can be
|
||||
modelled in other software and imported into Pandemonium. Multiple materials are
|
||||
supported. There are some restrictions for geometry:
|
||||
|
||||
- it must be closed,
|
||||
- it must not self-intersect,
|
||||
- it must not contain internal faces,
|
||||
- every edge must connect to only two other faces.
|
||||
|
||||
![](img/csg_custom_mesh.png)
|
||||
|
||||
CSGCombiner
|
||||
~~~~~~~~~~~
|
||||
|
||||
The `CSGCombiner` node is an empty shape used for
|
||||
organization. It will only combine children nodes.
|
||||
|
||||
Processing order
|
||||
~~~~~~~~~~~~~~~~
|
||||
|
||||
Every CSG node will first process its children nodes and their operations:
|
||||
union, intersection or subtraction, in tree order, and apply them to itself one
|
||||
after the other.
|
||||
|
||||
Note:
|
||||
In the interest of performance, make sure CSG geometry remains
|
||||
relatively simple, as complex meshes can take a while to process.
|
||||
If adding objects together (such as table and room objects), create
|
||||
them as separate CSG trees. Forcing too many objects in a single tree
|
||||
will eventually start affecting performance.
|
||||
Only use binary operations where you actually need them.
|
||||
|
||||
Prototyping a level
|
||||
-------------------
|
||||
|
||||
We will prototype a room to practice the use of CSG tools.
|
||||
|
||||
Tip:
|
||||
Working in **Orthogonal** projection gives a better view when combining
|
||||
the CSG shapes.
|
||||
|
||||
Our level will contain these objects:
|
||||
|
||||
- a room,
|
||||
- a bed,
|
||||
- a lamp,
|
||||
- a desk,
|
||||
- a bookshelf.
|
||||
|
||||
Create a scene with a Spatial node as root node.
|
||||
|
||||
Tip:
|
||||
The default lighting of the environment doesn't provide clear shading
|
||||
at some angles. Change the display mode using **Display Overdraw** in
|
||||
the 3D viewport menu, or add a DirectionalLight node to help you see
|
||||
clearly.
|
||||
|
||||
![](img/csg_overdraw.png)
|
||||
|
||||
Create a CSGBox and name it `room`, enable **Invert Faces** and change the
|
||||
dimensions of your room.
|
||||
|
||||
![](img/csg_room.png)
|
||||
|
||||
![](img/csg_room_invert.png)
|
||||
|
||||
Next, create a CSGCombiner and name it `desk`.
|
||||
|
||||
A desk has one surface and 4 legs:
|
||||
|
||||
- Create 1 CSGBox children node in **Union** mode for the surface
|
||||
and adjust the dimensions.
|
||||
- Create 4 CSGBox children nodes in **Union** mode for the legs
|
||||
and adjust the dimensions.
|
||||
|
||||
Adjust their placement to resemble a desk.
|
||||
|
||||
![](img/csg_desk.png)
|
||||
|
||||
Note:
|
||||
CSG nodes inside a CSGCombiner will only process their operation
|
||||
within the combiner. Therefore, CSGCombiners are used to organize
|
||||
CSG nodes.
|
||||
|
||||
Create a CSGCombiner and name it `bed`.
|
||||
|
||||
Our bed consists of 3 parts: the bed, the mattress and a pillow. Create a CSGBox
|
||||
and adjust its dimension for the bed. Create another CSGBox and adjust its
|
||||
dimension for the mattress.
|
||||
|
||||
![](img/csg_bed_mat.png)
|
||||
|
||||
We will create another CSGCombiner named `pillow` as the child of `bed`.
|
||||
The scene tree should look like this:
|
||||
|
||||
![](img/csg_bed_tree.png)
|
||||
|
||||
We will combine 3 CSGSphere nodes in **Union** mode to form a pillow. Scale the
|
||||
Y axis of the spheres and enable **Smooth Faces**.
|
||||
|
||||
![](img/csg_pillow_smooth.png)
|
||||
|
||||
Select the `pillow` node and switch the mode to **Subtraction**; the combined
|
||||
spheres will cut a hole into the mattress.
|
||||
|
||||
![](img/csg_pillow_hole.png)
|
||||
|
||||
Try to re-parent the `pillow` node to the root `Spatial` node; the hole will
|
||||
disappear.
|
||||
|
||||
Note:
|
||||
This is to illustrate the effect of CSG processing order.
|
||||
Since the root node is not a CSG node, the CSGCombiner nodes are
|
||||
the end of the operations; this shows the use of CSGCombiner to
|
||||
organize the CSG scene.
|
||||
|
||||
Undo the re-parent after observing the effect. The bed you've built should look
|
||||
like this:
|
||||
|
||||
![](img/csg_bed.png)
|
||||
|
||||
Create a CSGCombiner and name it `lamp`.
|
||||
|
||||
A lamp consists of 3 parts: the stand, the pole and the lampshade.
|
||||
Create a CSGCylinder, enable the **Cone** option and make it the stand. Create
|
||||
another CSGCylinder and adjust the dimensions to use it as a pole.
|
||||
|
||||
![](img/csg_lamp_pole_stand.png)
|
||||
|
||||
We will use a CSGPolygon for the lampshade. Use the **Spin** mode for the
|
||||
CSGPolygon and draw a `trapezoid ( https://en.wikipedia.org/wiki/Trapezoid )`
|
||||
while in **Front View** (numeric keypad 1); this shape will extrude around the
|
||||
origin and form the lampshade.
|
||||
|
||||
![](img/csg_lamp_spin.png)
|
||||
|
||||
![](img/csg_lamp_polygon.png)
|
||||
|
||||
![](img/csg_lamp_extrude.png)
|
||||
|
||||
Adjust the placement of the 3 parts to make it look like a lamp.
|
||||
|
||||
![](img/csg_lamp.png)
|
||||
|
||||
Create a CSGCombiner and name it `bookshelf`.
|
||||
|
||||
We will use 3 CSGBox nodes for the bookshelf. Create a CSGBox and adjust its
|
||||
dimensions; this will be the size of the bookshelf.
|
||||
|
||||
![](img/csg_shelf_big.png)
|
||||
|
||||
Duplicate the CSGBox and shorten the dimensions of each axis and change the mode
|
||||
to **Subtraction**.
|
||||
|
||||
![](img/csg_shelf_subtract.png)
|
||||
|
||||
![](img/csg_shelf_subtract_menu.png)
|
||||
|
||||
You've almost built a shelf. Create one more CSGBox for dividing the shelf into
|
||||
two levels.
|
||||
|
||||
![](img/csg_shelf.png)
|
||||
|
||||
Position your furniture in your room as you like and your scene should look
|
||||
this:
|
||||
|
||||
![](img/csg_room_result.png)
|
||||
|
||||
You've successfully prototyped a room level with the CSG tools in Pandemonium.
|
||||
CSG tools can be used for designing all kinds of levels, such as a maze
|
||||
or a city; explore its limitations when designing your game.
|
||||
|
||||
Using prototype textures
|
||||
------------------------
|
||||
|
||||
Pandemonium's `doc_spatial_material` supports *triplanar mapping*, which can be
|
||||
used to automatically apply a texture to arbitrary objects without distortion.
|
||||
This is handy when using CSG as Pandemonium doesn't support editing UV maps on CSG
|
||||
nodes yet. Triplanar mapping is relatively slow, which usually restricts its
|
||||
usage to organic surfaces like terrain. Still, when prototyping, it can be used
|
||||
to quickly apply textures to CSG-based levels.
|
||||
|
||||
Note:
|
||||
If you need some textures for prototyping, Kenney made a
|
||||
`set of CC0-licensed prototype textures ( https://kenney.nl/assets/prototype-textures )`.
|
||||
|
||||
There are two ways to apply a material to a CSG node:
|
||||
|
||||
- Applying it to a CSGCombiner node as a material override
|
||||
(**Geometry > Material Override** in the Inspector). This will affect its
|
||||
children automatically, but will make it impossible to change the material in
|
||||
individual children.
|
||||
- Applying a material to individual nodes (**Material** in the Inspector). This
|
||||
way, each CSG node can have its own appearance. Subtractive CSG nodes will
|
||||
apply their material to the nodes they're "digging" into.
|
||||
|
||||
To apply triplanar mapping to a CSG node, select it, go to the Inspector, click
|
||||
the **[empty]** text next to **Material Override** (or **Material** for
|
||||
individual CSG nodes). Choose **New SpatialMaterial**. Click the newly created
|
||||
material's icon to edit it. Unfold the **Albedo** section and load a texture
|
||||
into the **Texture** property. Now, unfold the **Uv1** section and check
|
||||
**Triplanar**. You can change the texture offset and scale on each axis by
|
||||
playing with the **Scale** and **Offset** properties just above. Higher values
|
||||
in the **Scale** property will cause the texture to repeat more often.
|
||||
|
||||
Tip:
|
||||
You can copy a SpatialMaterial to reuse it across CSG nodes. To do so,
|
||||
click the dropdown arrow next to a material property in the Inspector
|
||||
and choose **Copy**. To paste it, select the node you'd like to apply
|
||||
the material onto, click the dropdown arrow next to its material
|
||||
property then choose **Paste**.
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg.gif
Normal file
After Width: | Height: | Size: 1.6 MiB |
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_bed.png
Normal file
After Width: | Height: | Size: 23 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_bed.png-ced6d692c9ea0db986fd1f9a48f9cf40.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_bed.png"
|
||||
dest_files=[ "res://.import/csg_bed.png-ced6d692c9ea0db986fd1f9a48f9cf40.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_bed_mat.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_bed_mat.png-1436b5c392294975394443ffc5a59dea.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_bed_mat.png"
|
||||
dest_files=[ "res://.import/csg_bed_mat.png-1436b5c392294975394443ffc5a59dea.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_bed_tree.png
Normal file
After Width: | Height: | Size: 5.0 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_bed_tree.png-26e07c9fd0ebb0d471c8b6a28436ffb1.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_bed_tree.png"
|
||||
dest_files=[ "res://.import/csg_bed_tree.png-26e07c9fd0ebb0d471c8b6a28436ffb1.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 104 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_custom_mesh.png-77ed05e79769775e1161afa6c166f4de.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_custom_mesh.png"
|
||||
dest_files=[ "res://.import/csg_custom_mesh.png-77ed05e79769775e1161afa6c166f4de.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_desk.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_desk.png-cd3be285b3e8ee409fd3f2925a7fef50.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_desk.png"
|
||||
dest_files=[ "res://.import/csg_desk.png-cd3be285b3e8ee409fd3f2925a7fef50.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_lamp.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_lamp.png-7035a0dc7e4d78eae54e351fae89ccf9.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_lamp.png"
|
||||
dest_files=[ "res://.import/csg_lamp.png-7035a0dc7e4d78eae54e351fae89ccf9.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 2.2 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_lamp_extrude.png-c9c981a49c26714206b85f483b1cc14e.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_lamp_extrude.png"
|
||||
dest_files=[ "res://.import/csg_lamp_extrude.png-c9c981a49c26714206b85f483b1cc14e.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 6.3 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_lamp_pole_stand.png-165ba5670c613e8ac9c730c5f14a6251.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_lamp_pole_stand.png"
|
||||
dest_files=[ "res://.import/csg_lamp_pole_stand.png-165ba5670c613e8ac9c730c5f14a6251.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 7.6 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_lamp_polygon.png-888050ee105f15687b1345758b7b2d65.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_lamp_polygon.png"
|
||||
dest_files=[ "res://.import/csg_lamp_polygon.png-888050ee105f15687b1345758b7b2d65.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_lamp_spin.png
Normal file
After Width: | Height: | Size: 11 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_lamp_spin.png-8792aa7764222a6347597dbac889b8a7.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_lamp_spin.png"
|
||||
dest_files=[ "res://.import/csg_lamp_spin.png-8792aa7764222a6347597dbac889b8a7.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_mesh.png
Normal file
After Width: | Height: | Size: 66 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_mesh.png-f707844c8261ac6129fbd74bb1727fdc.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_mesh.png"
|
||||
dest_files=[ "res://.import/csg_mesh.png-f707844c8261ac6129fbd74bb1727fdc.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_nodes.png
Normal file
After Width: | Height: | Size: 9.0 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_nodes.png-105a887703d5bfdb7f846b12f9dae21b.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_nodes.png"
|
||||
dest_files=[ "res://.import/csg_nodes.png-105a887703d5bfdb7f846b12f9dae21b.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_operation.png
Normal file
After Width: | Height: | Size: 56 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_operation.png-f494327a5035029a5af9c14f54c6a728.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_operation.png"
|
||||
dest_files=[ "res://.import/csg_operation.png-f494327a5035029a5af9c14f54c6a728.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 12 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_operation_menu.png-385acb6101ef608bde05b935dc64b090.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_operation_menu.png"
|
||||
dest_files=[ "res://.import/csg_operation_menu.png-385acb6101ef608bde05b935dc64b090.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_overdraw.png
Normal file
After Width: | Height: | Size: 23 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_overdraw.png-4dbc7c8508fb4928a45fb0291d88a508.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_overdraw.png"
|
||||
dest_files=[ "res://.import/csg_overdraw.png-4dbc7c8508fb4928a45fb0291d88a508.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 6.8 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_pillow_hole.png-66ad203818ae302486d567fcb3b1bc84.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_pillow_hole.png"
|
||||
dest_files=[ "res://.import/csg_pillow_hole.png-66ad203818ae302486d567fcb3b1bc84.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 8.4 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_pillow_smooth.png-dc9ae66bd02d8edbd620df227663e659.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_pillow_smooth.png"
|
||||
dest_files=[ "res://.import/csg_pillow_smooth.png-dc9ae66bd02d8edbd620df227663e659.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_poly.png
Normal file
After Width: | Height: | Size: 85 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_poly.png-c52d982c9fcfcdac8e2dd160168991a2.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_poly.png"
|
||||
dest_files=[ "res://.import/csg_poly.png-c52d982c9fcfcdac8e2dd160168991a2.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_poly_mode.png
Normal file
After Width: | Height: | Size: 15 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_poly_mode.png-16e777fa3e6512f43ae468c471966926.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_poly_mode.png"
|
||||
dest_files=[ "res://.import/csg_poly_mode.png-16e777fa3e6512f43ae468c471966926.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_room.png
Normal file
After Width: | Height: | Size: 46 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_room.png-1f11bb7d1d96e67c13a7e17750483647.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_room.png"
|
||||
dest_files=[ "res://.import/csg_room.png-1f11bb7d1d96e67c13a7e17750483647.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 8.7 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_room_invert.png-6d346777dc19f88722d3cf1a387c8268.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_room_invert.png"
|
||||
dest_files=[ "res://.import/csg_room_invert.png-6d346777dc19f88722d3cf1a387c8268.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 24 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_room_result.png-6bb30c43a135c212095a75cb092e0ac6.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_room_result.png"
|
||||
dest_files=[ "res://.import/csg_room_result.png-6bb30c43a135c212095a75cb092e0ac6.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_shelf.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_shelf.png-6505db2fabc475bd46ca90da069dc644.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_shelf.png"
|
||||
dest_files=[ "res://.import/csg_shelf.png-6505db2fabc475bd46ca90da069dc644.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
BIN
web/docs_hoster_simple/www/04_modules/csg/img/csg_shelf_big.png
Normal file
After Width: | Height: | Size: 19 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_shelf_big.png-c7fc6c40bc39fe7cf3c725280f8f043d.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_shelf_big.png"
|
||||
dest_files=[ "res://.import/csg_shelf_big.png-c7fc6c40bc39fe7cf3c725280f8f043d.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 1.5 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_shelf_subtract.png-799cc33bc5faecf536b589f0981a716d.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_shelf_subtract.png"
|
||||
dest_files=[ "res://.import/csg_shelf_subtract.png-799cc33bc5faecf536b589f0981a716d.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
After Width: | Height: | Size: 13 KiB |
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/csg_shelf_subtract_menu.png-2be20309e366b3a6387576e1a9193b77.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://www/04_modules/csg/img/csg_shelf_subtract_menu.png"
|
||||
dest_files=[ "res://.import/csg_shelf_subtract_menu.png-2be20309e366b3a6387576e1a9193b77.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
@ -0,0 +1,82 @@
|
||||
|
||||
# Introduction to editor development
|
||||
|
||||
On this page, you will learn:
|
||||
|
||||
- The **design decisions** behind the Pandemonium editor.
|
||||
- How to work efficiently on the Pandemonium editor's C++ code.
|
||||
|
||||
This guide is aimed at current or future engine contributors.
|
||||
To create editor plugins in GDScript, see `doc_making_plugins` instead.
|
||||
|
||||
See also:
|
||||
|
||||
If you are new to Pandemonium, we recommended you to read
|
||||
`doc_pandemonium_design_philosophy` before continuing. Since the Pandemonium editor
|
||||
is a Pandemonium project written in C++, much of the engine's philosophy applies
|
||||
to the editor.
|
||||
|
||||
## Technical choices
|
||||
|
||||
The Pandemonium editor is drawn using Pandemonium's renderer and
|
||||
`UI system ( toc-gui-basics )`. It does *not* rely on a toolkit
|
||||
such as GTK or Qt. This is similar in spirit to software like Blender.
|
||||
While using toolkits makes it easier to achieve a "native" appearance, they are
|
||||
also quite heavy and their licensing is not compatible with Pandemonium's.
|
||||
|
||||
The editor is fully written in C++. It can't contain any GDScript or C# code.
|
||||
|
||||
## Directory structure
|
||||
|
||||
The editor's code is fully self-contained in the
|
||||
`editor/ ( https://github.com/Relintai/pandemonium_engine/tree/master/editor )` folder
|
||||
of the Pandemonium source repository.
|
||||
|
||||
Some editor functionality is also implemented via
|
||||
`modules ( doc_custom_modules_in_c++ )`. Some of these are only enabled in
|
||||
editor builds to decrease the binary size of export templates. See the
|
||||
`modules/ ( https://github.com/Relintai/pandemonium_engine/tree/master/modules )` folder
|
||||
in the Pandemonium source repository.
|
||||
|
||||
Some important files in the editor are:
|
||||
|
||||
- `editor/editor_node.cpp ( https://github.com/Relintai/pandemonium_engine/blob/3.x/editor/editor_node.cpp )`:
|
||||
Main editor initialization file. Effectively the "main scene" of the editor.
|
||||
- `editor/project_manager.cpp ( https://github.com/Relintai/pandemonium_engine/blob/3.x/editor/project_manager.cpp )`:
|
||||
Main project manager initialization file. Effectively the "main scene" of the project manager.
|
||||
- `editor/plugins/canvas_item_editor_plugin.cpp ( https://github.com/Relintai/pandemonium_engine/blob/3.x/editor/plugins/canvas_item_editor_plugin.cpp )`:
|
||||
The 2D editor viewport and related functionality (toolbar at the top, editing modes, overlaid helpers/panels, …).
|
||||
- `editor/plugins/spatial_editor_plugin.cpp ( https://github.com/Relintai/pandemonium_engine/blob/3.x/editor/plugins/spatial_editor_plugin.cpp )`:
|
||||
The 3D editor viewport and related functionality (toolbar at the top, editing modes, overlaid panels, …).
|
||||
- `editor/spatial_editor_gizmos.cpp ( https://github.com/Relintai/pandemonium_engine/blob/3.x/editor/spatial_editor_gizmos.cpp )`:
|
||||
Where the 3D editor gizmos are defined and drawn.
|
||||
This file doesn't have a 2D counterpart as 2D gizmos are drawn by the nodes themselves.
|
||||
|
||||
## Editor dependencies in `scene/` files
|
||||
|
||||
When working on an editor feature, you may have to modify files in
|
||||
Pandemonium's GUI nodes, which you can find in the `scene/` folder.
|
||||
|
||||
One rule to keep in mind is that you must **not** introduce new dependencies to
|
||||
`editor/` includes in other folders such as `scene/`. This applies even if
|
||||
you use `#ifdef TOOLS_ENABLED`.
|
||||
|
||||
To make the codebase easier to follow and more self-contained, the allowed
|
||||
dependency order is:
|
||||
|
||||
- `editor/` -> `scene/` -> `servers/` -> `core/`
|
||||
|
||||
This means that files in `editor/` can depend on includes from `scene/`,
|
||||
`servers/`, and `core/`. But, for example, while `scene/` can depend on includes
|
||||
from `servers/` and `core/`, it cannot depend on includes from `editor/`.
|
||||
|
||||
Currently, there are some dependencies to `editor/` includes in `scene/`
|
||||
files, but
|
||||
`they are in the process of being removed ( https://github.com/Relintai/pandemonium_engine/issues/29730 )`.
|
||||
|
||||
## Development tips
|
||||
|
||||
To iterate quickly on the editor, we recommend to set up a test project and
|
||||
`open it from the command line ( doc_command_line_tutorial )` after compiling
|
||||
the editor. This way, you don't have to go through the project manager every
|
||||
time you start Pandemonium.
|
@ -0,0 +1,98 @@
|
||||
|
||||
|
||||
# Editor icons
|
||||
|
||||
When a new class is created and exposed to scripting, the editor's interface
|
||||
will display it with a default icon representing the base class it inherits
|
||||
from. In most cases, it's still recommended to create icons for new classes to
|
||||
improve the user experience.
|
||||
|
||||
### Creating icons
|
||||
|
||||
To create new icons, you first need a vector graphics editor installed.
|
||||
For instance, you can use the open source `Inkscape ( https://inkscape.org/ )` editor.
|
||||
|
||||
Clone the `pandemonium` repository containing all the editor icons:
|
||||
|
||||
```
|
||||
git clone https://github.com/Relintai/pandemonium_engine.git
|
||||
```
|
||||
|
||||
The icons must be created in a vector graphics editor in SVG format. There are
|
||||
two main requirements to follow:
|
||||
|
||||
- Icons must be 16×16. In Inkscape, you can configure the document size in
|
||||
**File > Document Properties**.
|
||||
- Lines should be snapped to pixels whenever possible to remain crisp at lower DPI.
|
||||
You can create a 16×16 grid in Inkscape to make this easier.
|
||||
|
||||
Once you're satisfied with the icon's design, save the icon in the cloned
|
||||
repository's `editor/icons` folder. The icon name should match the intended
|
||||
name in a case-sensitive manner. For example, to create an icon for
|
||||
CPUParticles2D, name the file `CPUParticles2D.svg`.
|
||||
|
||||
### Color conversion for light editor themes
|
||||
|
||||
If the user has configured their editor to use a light theme, Pandemonium will
|
||||
convert the icon's colors based on a
|
||||
`set of predefined color mappings ( https://github.com/Relintai/pandemonium_engine/blob/b9f2e57d6240346f1833fd0390de195c956299e7/editor/editor_themes.cpp#L122-L184 )`.
|
||||
This is to ensure the icon always displays with a sufficient contrast rate.
|
||||
Try to restrict your icon's color palette to colors found in the list above.
|
||||
Otherwise, your icon may become difficult to read on a light background.
|
||||
|
||||
### Icon optimization
|
||||
|
||||
Because the editor renders SVGs once at load time, they need to be small
|
||||
in size so they can be efficiently parsed. Editor icons must be first
|
||||
optimized before being added to the engine, to do so:
|
||||
|
||||
1. Install `svgcleaner ( https://github.com/RazrFalcon/svgcleaner )`
|
||||
by downloading a binary from its
|
||||
`Releases tab ( https://github.com/RazrFalcon/svgcleaner/releases/latest )`
|
||||
and placing it into a location in your `PATH` environment variable.
|
||||
|
||||
2. Run the command below, replacing `svg_source.svg` with the path to your
|
||||
SVG file (which can be a relative or absolute path):
|
||||
|
||||
```
|
||||
svgcleaner --multipass svg_source.svg svg_optimized.svg
|
||||
```
|
||||
|
||||
The `--multipass` switch improves compression, so make sure to include it.
|
||||
The optimized icon will be saved to `svg_optimized.svg`. You can also change
|
||||
the destination parameter to any relative or absolute path you'd like.
|
||||
|
||||
Note:
|
||||
|
||||
|
||||
While this optimization step won't impact the icon's quality noticeably, it
|
||||
will still remove editor-only information such as guides. Therefore, it's
|
||||
recommended to keep the source SVG around if you need to make further
|
||||
changes.
|
||||
|
||||
### Integrating and sharing the icons
|
||||
|
||||
If you're contributing to the engine itself, you should make a pull request to
|
||||
add optimized icons to `editor/icons` in the main repository. Recompile the
|
||||
engine to make it pick up new icons for classes.
|
||||
|
||||
It's also possible to create custom icons within a module. If you're creating
|
||||
your own module and don't plan to integrate it with Pandemonium, you don't need to
|
||||
make a separate pull request for your icons to be available within the editor
|
||||
as they can be self-contained.
|
||||
|
||||
For specific instructions on how to create module icons, refer to
|
||||
`Creating custom module icons( doc_custom_module_icons )`.
|
||||
|
||||
### Troubleshooting
|
||||
|
||||
If icons don't appear in the editor, make sure that:
|
||||
|
||||
1. Each icon's filename matches the naming requirement as described previously.
|
||||
|
||||
2. `modules/svg` is enabled (it should be enabled by default). Without it,
|
||||
icons won't appear in the editor at all.
|
||||
|
||||
### References
|
||||
|
||||
- `editor/icons ( https://github.com/Relintai/pandemonium_engine/tree/master/editor/icons )`
|
@ -0,0 +1,92 @@
|
||||
|
||||
|
||||
# Editor style guide
|
||||
|
||||
## Introduction
|
||||
|
||||
Thanks for your interest in contributing to the Pandemonium editor!
|
||||
|
||||
This page describes the grammar and writing style used throughout the Pandemonium
|
||||
editor. Following this style guide will help your contribution get merged faster
|
||||
since there will be fewer review steps required.
|
||||
|
||||
## Writing style
|
||||
|
||||
- **Write messages (errors, warnings, ...) as full sentences.** They should start
|
||||
with an uppercase letter and end with a period.
|
||||
- **Try to keep sentences short.** This makes it more likely that their translations
|
||||
will be short as well, which is a good thing to avoid UI bugs.
|
||||
- **Use contractions.** For example, use "isn't" instead of "is not". An exception
|
||||
to this rule can be made when you specifically want to emphasize one of the
|
||||
contraction's words.
|
||||
- **Use double quotes in messages** (`""`) instead of single quotes (`''`).
|
||||
Double quotes should be used to quote user input, file paths and possibly
|
||||
other things depending on the context.
|
||||
|
||||
See also:
|
||||
|
||||
|
||||
Try to follow the `doc_docs_writing_guidelines` in addition to the
|
||||
guidelines outlined above.
|
||||
|
||||
## Button and menu texts
|
||||
|
||||
Capitalize text in buttons and menu actions:
|
||||
|
||||
- **Good:** *Open Editor Data Folder*
|
||||
- **Bad:** *Open editor data folder*
|
||||
|
||||
If a menu action opens a modal dialog, suffix it with an ellipsis (`...`).
|
||||
|
||||
- **Good:** *Editor Settings...*
|
||||
- **Bad:** *Editor Settings*
|
||||
|
||||
## Inspector sections
|
||||
|
||||
In general, don't create sections that contain less than 3 items. Sections that
|
||||
contain few items make it difficult to navigate the inspector, while missing the
|
||||
benefits of using sections such as folding.
|
||||
|
||||
There are some valid exceptions for this, such as material features in
|
||||
`SpatialMaterial`.
|
||||
|
||||
This advice also applies to the Project Settings and Editor Settings.
|
||||
|
||||
## Inspector performance hints
|
||||
|
||||
Enum properties that noticeably impact performance should have a performance
|
||||
hint associated. The hint should refer to the *absolute* performance impact,
|
||||
rather than being relative to the other options provided in the enum. Here are
|
||||
some examples taken from the Pandemonium editor:
|
||||
|
||||
- **Screen-space antialiasing:** *Disabled (Fastest), FXAA (Fast)*
|
||||
- **MSAA quality:** *Disabled (Fastest), 2x (Fast), 4x (Average), 8x (Slow), 16x
|
||||
(Slower)*
|
||||
- **DirectionalLight mode:** *Orthogonal (Fast), PSSM 2 Splits
|
||||
(Average), PSSM 4 Splits (Slow)*
|
||||
|
||||
For consistency, try to stick to the terms below (from fastest to slowest):
|
||||
|
||||
- *Fastest, Faster, Fast, Average, Slow, Slower, Slowest*
|
||||
|
||||
Their usage doesn't have to be contiguous. For example, you can use only "Fast"
|
||||
and "Slow" from the list above.
|
||||
|
||||
If you're adding a new enum, its values should be ordered from the fastest
|
||||
option to the slowest option.
|
||||
|
||||
## Tooltips
|
||||
|
||||
Consider adding tooltips whenever the action performed by a button or menu
|
||||
action isn't obvious. You can also provide additional context or highlight
|
||||
caveats in the tooltip.
|
||||
|
||||
You can do this by calling `set_tooltip(TTR("Text here."))` on the
|
||||
Control-based node in question. If the tooltip is particularly long (more than
|
||||
~80 characters), wrap it over several lines by adding line breaks using `\n`.
|
||||
|
||||
Tooltips should follow the writing style described above. In addition to this,
|
||||
use indicative mood instead of imperative mood:
|
||||
|
||||
- **Good:** *Computes global illumination for the selected GIProbe.*
|
||||
- **Bad:** *Compute global illumination for the selected GIProbe.*
|
@ -0,0 +1,423 @@
|
||||
|
||||
|
||||
# TSCN file format
|
||||
|
||||
The TSCN (text scene) file format represents a single scene tree inside
|
||||
Pandemonium. Unlike binary SCN files, TSCN files have the advantage of being mostly
|
||||
human-readable and easy for version control systems to manage.
|
||||
|
||||
The ESCN (exported scene) file format is identical to the TSCN file format, but
|
||||
is used to indicate to Pandemonium that the file has been exported from another
|
||||
program and should not be edited by the user from within Pandemonium.
|
||||
Unlike SCN and TSCN files, during import, ESCN files are compiled to binary
|
||||
SCN files stored inside the `.import/` folder.
|
||||
This reduces the data size and speeds up loading, as binary formats are faster
|
||||
to load compared to text-based formats.
|
||||
|
||||
For those looking for a complete description, the parsing is handled in the file
|
||||
`resource_format_text.cpp ( https://github.com/Relintai/pandemonium_engine/blob/master/scene/resources/resource_format_text.cpp )`
|
||||
in the `ResourceFormatLoaderText` class.
|
||||
|
||||
## File structure
|
||||
|
||||
There are five main sections inside the TSCN file:
|
||||
|
||||
0. File Descriptor
|
||||
1. External resources
|
||||
2. Internal resources
|
||||
3. Nodes
|
||||
4. Connections
|
||||
|
||||
The file descriptor looks like `[gd_scene load_steps=3 format=2]` and should
|
||||
be the first entry in the file. The `load_steps` parameter is equal to the
|
||||
total amount of resources (internal and external) plus one (for the file itself).
|
||||
If the file has no resources, `load_steps` is omitted. The engine will
|
||||
still load the file correctly if `load_steps` is incorrect, but this will affect
|
||||
loading bars and any other piece of code relying on that value.
|
||||
|
||||
These sections should appear in order, but it can be hard to distinguish them.
|
||||
The only difference between them is the first element in the heading for all of
|
||||
the items in the section. For example, the heading of all external resources
|
||||
should start with `[ext_resource .....]`.
|
||||
|
||||
A TSCN file may contain single-line comments starting with a semicolon (`;`).
|
||||
However, comments will be discarded when saving the file using the Pandemonium editor.
|
||||
|
||||
### Entries inside the file
|
||||
|
||||
A heading looks like
|
||||
`[<resource_type> key=value key=value key=value ...]`
|
||||
where resource_type is one of:
|
||||
|
||||
- `ext_resource`
|
||||
- `sub_resource`
|
||||
- `node`
|
||||
- `connection`
|
||||
|
||||
Below every heading comes zero or more `key = value` pairs. The
|
||||
values can be complex datatypes such as Arrays, Transforms, Colors, and
|
||||
so on. For example, a spatial node looks like:
|
||||
|
||||
```
|
||||
[node name="Cube" type="Spatial" parent="."]
|
||||
transform=Transform( 1.0, 0.0, 0.0 ,0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0 )
|
||||
```
|
||||
|
||||
## The scene tree
|
||||
|
||||
The scene tree is made up of… nodes! The heading of each node consists of
|
||||
its name, parent and (most of the time) a type. For example
|
||||
`[node type="Camera" name="PlayerCamera" parent="Player/Head"]`
|
||||
|
||||
Other valid keywords include:
|
||||
|
||||
- `instance`
|
||||
- `instance_placeholder`
|
||||
- `owner`
|
||||
- `index` (sets the order of appearance in the tree. If absent, inherited nodes will take precedence over plain ones)
|
||||
- `groups`
|
||||
|
||||
The first node in the file, which is also the scene root, must not have a
|
||||
`parent=Path/To/Node` entry in its heading. All scene files should have
|
||||
exactly *one* scene root. If it doesn't, Pandemonium will fail to import the file.
|
||||
The parent path of other nodes should be absolute, but shouldn't contain
|
||||
the scene root's name. If the node is a direct child of the scene root,
|
||||
the path should be `"."`. Here is an example scene tree
|
||||
(but without any node content):
|
||||
|
||||
```
|
||||
[node name="Player" type="Spatial"] ; The scene root
|
||||
[node name="Arm" parent="." type="Spatial"] ; Parented to the scene root
|
||||
[node name="Hand" parent="Arm" type="Spatial"]
|
||||
[node name="Finger" parent="Arm/Hand" type="Spatial"]
|
||||
```
|
||||
|
||||
Similar to the internal resource, the document for each node is currently
|
||||
incomplete. Fortunately, it is easy to find out because you can simply
|
||||
save a file with that node in it. Some example nodes are:
|
||||
|
||||
```
|
||||
[node type="CollisionShape" name="SphereCollision" parent="SpherePhysics"]
|
||||
|
||||
shape = SubResource(8)
|
||||
transform = Transform( 1.0 , 0.0 , -0.0 , 0.0 , -4.371138828673793e-08 , 1.0 , -0.0 , -1.0 , -4.371138828673793e-08 ,0.0 ,0.0 ,-0.0 )
|
||||
|
||||
|
||||
[node type="MeshInstance" name="Sphere" parent="SpherePhysics"]
|
||||
|
||||
mesh = SubResource(9)
|
||||
transform = Transform( 1.0 , 0.0 , -0.0 , 0.0 , 1.0 , -0.0 , -0.0 , -0.0 , 1.0 ,0.0 ,0.0 ,-0.0 )
|
||||
|
||||
|
||||
[node type="OmniLight" name="Lamp" parent="."]
|
||||
|
||||
light_energy = 1.0
|
||||
light_specular = 1.0
|
||||
transform = Transform( -0.29086464643478394 , -0.7711008191108704 , 0.5663931369781494 , -0.05518905818462372 , 0.6045246720314026 , 0.7946722507476807 , -0.9551711678504944 , 0.199883371591568 , -0.21839118003845215 ,4.076245307922363 ,7.3235554695129395 ,-1.0054539442062378 )
|
||||
omni_range = 30
|
||||
shadow_enabled = true
|
||||
light_negative = false
|
||||
light_color = Color( 1.0, 1.0, 1.0, 1.0 )
|
||||
|
||||
|
||||
[node type="Camera" name="Camera" parent="."]
|
||||
|
||||
projection = 0
|
||||
near = 0.10000000149011612
|
||||
fov = 50
|
||||
transform = Transform( 0.6859206557273865 , -0.32401350140571594 , 0.6515582203865051 , 0.0 , 0.8953956365585327 , 0.44527143239974976 , -0.7276763319969177 , -0.3054208755493164 , 0.6141703724861145 ,14.430776596069336 ,10.093015670776367 ,13.058500289916992 )
|
||||
far = 100.0
|
||||
```
|
||||
|
||||
### NodePath
|
||||
|
||||
A tree structure is not enough to represent the whole scene. Pandemonium uses a
|
||||
`NodePath(Path/To/Node)` structure to refer to another node or attribute of
|
||||
the node anywhere in the scene tree. For instance, MeshInstance uses
|
||||
`NodePath()` to point to its skeleton. Likewise, Animation tracks use
|
||||
`NodePath()` to point to node properties to animate.
|
||||
|
||||
```
|
||||
[node name="mesh" type="MeshInstance" parent="Armature001"]
|
||||
|
||||
mesh = SubResource(1)
|
||||
skeleton = NodePath("..:")
|
||||
```
|
||||
|
||||
```
|
||||
[sub_resource id=3 type="Animation"]
|
||||
|
||||
...
|
||||
tracks/0/type = "transform
|
||||
tracks/0/path = NodePath("Cube:")
|
||||
...
|
||||
```
|
||||
|
||||
### Skeleton
|
||||
|
||||
The Skeleton node inherits the Spatial node, but also may have a list of bones
|
||||
described in key-value pairs in the format `bones/Id/Attribute=Value`. The
|
||||
bone attributes consist of:
|
||||
|
||||
- `name`
|
||||
- `parent`
|
||||
- `rest`
|
||||
- `pose`
|
||||
- `enabled`
|
||||
- `bound_children`
|
||||
|
||||
1. `name` must be the first attribute of each bone.
|
||||
2. `parent` is the index of parent bone in the bone list, with parent index,
|
||||
the bone list is built to a bone tree.
|
||||
3. `rest` is the transform matrix of bone in its "resting" position.
|
||||
4. `pose` is the pose matrix; use `rest` as the basis.
|
||||
5. `bound_children` is a list of `NodePath()` which point to
|
||||
BoneAttachments belonging to this bone.
|
||||
|
||||
Here's an example of a skeleton node with two bones:
|
||||
|
||||
```
|
||||
[node name="Skeleton" type="Skeleton" parent="Armature001" index="0"]
|
||||
|
||||
bones/0/name = "Bone.001"
|
||||
bones/0/parent = -1
|
||||
bones/0/rest = Transform( 1, 0, 0, 0, 0, -1, 0, 1, 0, 0.038694, 0.252999, 0.0877164 )
|
||||
bones/0/pose = Transform( 1.0, 0.0, -0.0, 0.0, 1.0, -0.0, -0.0, -0.0, 1.0, 0.0, 0.0, -0.0 )
|
||||
bones/0/enabled = true
|
||||
bones/0/bound_children = [ ]
|
||||
bones/1/name = "Bone.002"
|
||||
bones/1/parent = 0
|
||||
bones/1/rest = Transform( 0.0349042, 0.99939, 0.000512929, -0.721447, 0.0248417, 0.692024, 0.691589, -0.0245245, 0.721874, 0, 5.96046e-08, -1.22688 )
|
||||
bones/1/pose = Transform( 1.0, 0.0, -0.0, 0.0, 1.0, -0.0, -0.0, -0.0, 1.0, 0.0, 0.0, -0.0 )
|
||||
bones/1/enabled = true
|
||||
bones/1/bound_children = [ ]
|
||||
```
|
||||
|
||||
### BoneAttachment
|
||||
|
||||
BoneAttachment node is an intermediate node to describe some node being parented
|
||||
to a single bone in a Skeleton node. The BoneAttachment has a
|
||||
`bone_name=NameOfBone` attribute, and the corresponding bone being the parent has the
|
||||
BoneAttachment node in its `bound_children` list.
|
||||
|
||||
An example of one MeshInstance parented to a bone in Skeleton:
|
||||
|
||||
```
|
||||
[node name="Armature" type="Skeleton" parent="."]
|
||||
|
||||
transform = Transform(1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, -0.0219986, 0.0125825, 0.0343127)
|
||||
bones/0/name = "Bone"
|
||||
bones/0/parent = -1
|
||||
bones/0/rest = Transform(1.0, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0)
|
||||
bones/0/pose = Transform(1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0)
|
||||
bones/0/enabled = true
|
||||
bones/0/bound_children = [NodePath("BoneAttachment:")]
|
||||
|
||||
[node name="BoneAttachment" type="BoneAttachment" parent="Armature"]
|
||||
|
||||
bone_name = "Bone"
|
||||
|
||||
[node name="Cylinder" type="MeshInstance" parent="Armature/BoneAttachment"]
|
||||
|
||||
mesh = SubResource(1)
|
||||
transform = Transform(1.0, 0.0, 0.0, 0.0, 1.86265e-09, 1.0, 0.0, -1.0, 0.0, 0.0219986, -0.0343127, 2.25595)
|
||||
```
|
||||
|
||||
### AnimationPlayer
|
||||
|
||||
AnimationPlayer works as an animation library. It stores animations listed in
|
||||
the format `anim/Name=SubResource(ResourceId)`; each line refers to an
|
||||
Animation resource. All the animation resources use the root node of
|
||||
AnimationPlayer. The root node is stored as
|
||||
`root_node=NodePath(Path/To/Node)`.
|
||||
|
||||
```
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="." index="1"]
|
||||
|
||||
root_node = NodePath("..")
|
||||
autoplay = ""
|
||||
playback_process_mode = 1
|
||||
playback_default_blend_time = 0.0
|
||||
playback_speed = 1.0
|
||||
anims/default = SubResource( 2 )
|
||||
blend_times = [ ]
|
||||
```
|
||||
|
||||
## Resources
|
||||
|
||||
Resources are components that make up the nodes. For example, a MeshInstance
|
||||
node will have an accompanying ArrayMesh resource. The ArrayMesh resource
|
||||
may be either internal or external to the TSCN file.
|
||||
|
||||
References to the resources are handled by `id` numbers in the resource's
|
||||
heading. External resources and internal resources are referred to with
|
||||
`ExtResource(id)` and `SubResource(id)`, respectively. Because there
|
||||
have different methods to refer to internal and external resources, you can have
|
||||
the same ID for both an internal and external resource.
|
||||
|
||||
For example, to refer to the resource `[ext_resource id=3 type="PackedScene"
|
||||
path=....]`, you would use `ExtResource(3)`.
|
||||
|
||||
### External resources
|
||||
|
||||
External resources are links to resources not contained within the TSCN file
|
||||
itself. An external resource consists of a path, a type and an ID.
|
||||
|
||||
Pandemonium always generates absolute paths relative to the resource directory and
|
||||
thus prefixed with `res://`, but paths relative to the TSCN file's location
|
||||
are also valid.
|
||||
|
||||
Some example external resources are:
|
||||
|
||||
```
|
||||
[ext_resource path="res://characters/player.dae" type="PackedScene" id=1]
|
||||
[ext_resource path="metal.tres" type="Material" id=2]
|
||||
```
|
||||
|
||||
Like TSCN files, a TRES file may contain single-line comments starting with a
|
||||
semicolon (`;`). However, comments will be discarded when saving the resource
|
||||
using the Pandemonium editor.
|
||||
|
||||
### Internal resources
|
||||
|
||||
A TSCN file can contain meshes, materials and other data. These are contained in
|
||||
the *internal resources* section of the file. The heading for an internal
|
||||
resource looks similar to those of external resources, except that it doesn't
|
||||
have a path. Internal resources also have `key=value` pairs under each
|
||||
heading. For example, a capsule collision shape looks like:
|
||||
|
||||
```
|
||||
[sub_resource type="CapsuleShape" id=2]
|
||||
|
||||
radius = 0.5
|
||||
height = 3.0
|
||||
```
|
||||
|
||||
Some internal resources contain links to other internal resources (such as a
|
||||
mesh having a material). In this case, the referring resource must appear
|
||||
*before* the reference to it. This means that order matters in the file's
|
||||
internal resources section.
|
||||
|
||||
Unfortunately, documentation on the formats for these subresources isn't
|
||||
complete. Some examples can be found by inspecting saved resource files, but
|
||||
others can only be found by looking through Pandemonium's source.
|
||||
|
||||
### ArrayMesh
|
||||
|
||||
ArrayMesh consists of several surfaces, each in the format `surface\Index={}`.
|
||||
Each surface is a set of vertices and a material.
|
||||
|
||||
TSCN files support two surface formats:
|
||||
|
||||
1. For the old format, each surface has three essential keys:
|
||||
|
||||
- `primitive`
|
||||
- `arrays`
|
||||
- `morph_arrays`
|
||||
|
||||
i. `primitive` is an enumerate variable, `primitive=4` which is
|
||||
`PRIMITIVE_TRIANGLES` is frequently used.
|
||||
|
||||
ii. `arrays` is a two-dimensional array, it contains:
|
||||
|
||||
1. Vertex positions array
|
||||
2. Normals array
|
||||
3. Tangents array
|
||||
4. Vertex colors array
|
||||
5. UV array 1
|
||||
6. UV array 2
|
||||
7. Bone indexes array
|
||||
8. Bone weights array
|
||||
9. Vertex indexes array
|
||||
|
||||
iii. `morph_arrays` is an array of morphs. Each morph is exactly an
|
||||
`arrays` without the vertex indexes array.
|
||||
|
||||
An example of ArrayMesh:
|
||||
|
||||
```
|
||||
[sub_resource id=1 type="ArrayMesh"]
|
||||
|
||||
surfaces/0 = {
|
||||
"primitive":4,
|
||||
"arrays":[
|
||||
Vector3Array(0.0, 1.0, -1.0, 0.866025, -1.0, -0.5, 0.0, -1.0, -1.0, 0.866025, 1.0, -0.5, 0.866025, -1.0, 0.5, 0.866025, 1.0, 0.5, -8.74228e-08, -1.0, 1.0, -8.74228e-08, 1.0, 1.0, -0.866025, -1.0, 0.5, -0.866025, 1.0, 0.5, -0.866025, -1.0, -0.5, -0.866025, 1.0, -0.5),
|
||||
Vector3Array(0.0, 0.609973, -0.792383, 0.686239, -0.609973, -0.396191, 0.0, -0.609973, -0.792383, 0.686239, 0.609973, -0.396191, 0.686239, -0.609973, 0.396191, 0.686239, 0.609973, 0.396191, 0.0, -0.609973, 0.792383, 0.0, 0.609973, 0.792383, -0.686239, -0.609973, 0.396191, -0.686239, 0.609973, 0.396191, -0.686239, -0.609973, -0.396191, -0.686239, 0.609973, -0.396191),
|
||||
null, ; No Tangents,
|
||||
null, ; no Vertex Colors,
|
||||
null, ; No UV1,
|
||||
null, ; No UV2,
|
||||
null, ; No Bones,
|
||||
null, ; No Weights,
|
||||
IntArray(0, 2, 1, 3, 1, 4, 5, 4, 6, 7, 6, 8, 0, 5, 9, 9, 8, 10, 11, 10, 2, 1, 10, 8, 0, 1, 3, 3, 4, 5, 5, 6, 7, 7, 8, 9, 5, 0, 3, 0, 9, 11, 9, 5, 7, 9, 10, 11, 11, 2, 0, 10, 1, 2, 1, 6, 4, 6, 1, 8)
|
||||
],
|
||||
"morph_arrays":[]
|
||||
}
|
||||
```
|
||||
|
||||
### Animation
|
||||
|
||||
An animation resource consists of tracks. Besides, it has `length`, `loop`
|
||||
and `step` applied to all the tracks.
|
||||
|
||||
1. `length` and `step` are both durations in seconds.
|
||||
|
||||
Each track is described by a list of key-value pairs in the format
|
||||
`tracks/Id/Attribute`. Each track includes:
|
||||
|
||||
- `type`
|
||||
- `path`
|
||||
- `interp`
|
||||
- `keys`
|
||||
- `loop_wrap`
|
||||
- `imported`
|
||||
- `enabled`
|
||||
|
||||
1. The `type` must be the first attribute of each track.
|
||||
The value of `type` can be:
|
||||
|
||||
- `transform`
|
||||
- `value`
|
||||
- `method`
|
||||
|
||||
2. The `path` has the format `NodePath(Path/To/Node:attribute)`.
|
||||
It's the path to the animated node or attribute, relative to the root node
|
||||
defined in the AnimationPlayer.
|
||||
|
||||
3. The `interp` is the method to interpolate frames from the keyframes.
|
||||
It is an enum variable with one of the following values:
|
||||
|
||||
- `0` (constant)
|
||||
- `1` (linear)
|
||||
- `2` (cubic)
|
||||
|
||||
4. The `keys` correspond to the keyframes. It appears as a `PoolRealArray()`,
|
||||
but may have a different structure for tracks with different types.
|
||||
|
||||
- A Transform track uses every 12 real numbers in the `keys` to describe
|
||||
a keyframe. The first number is the timestamp. The second number is the
|
||||
transition followed by a 3-number translation vector, followed by a
|
||||
4-number rotation quaternion (X, Y, Z, W) and finally a 3-number
|
||||
scale vector. The default transition in a Transform track is 1.0.
|
||||
|
||||
```
|
||||
[sub_resource type="Animation" id=2]
|
||||
|
||||
length = 4.95833
|
||||
loop = false
|
||||
step = 0.1
|
||||
tracks/0/type = "transform"
|
||||
tracks/0/path = NodePath("Armature001")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/imported = true
|
||||
tracks/0/enabled = true
|
||||
tracks/0/keys = PoolRealArray( 0, 1, -0.0358698, -0.829927, 0.444204, 0, 0, 0, 1, 0.815074, 0.815074, 0.815074, 4.95833, 1, -0.0358698, -0.829927, 0.444204, 0, 0, 0, 1, 0.815074, 0.815074, 0.815074 )
|
||||
tracks/1/type = "transform"
|
||||
tracks/1/path = NodePath("Armature001/Skeleton:Bone.001")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/imported = true
|
||||
tracks/1/enabled = false
|
||||
tracks/1/keys = PoolRealArray( 0, 1, 0, 5.96046e-08, 0, 0, 0, 0, 1, 1, 1, 1, 4.95833, 1, 0, 5.96046e-08, 0, 0, 0, 0, 1, 1, 1, 1 )
|
||||
```
|
53
web/docs_hoster_simple/www/AUTHORS.md
Normal file
@ -0,0 +1,53 @@
|
||||
# Godot Engine documentation authors
|
||||
|
||||
Godot Engine is developed by a community of voluntary contributors who
|
||||
contribute on all areas, including writing and maintaining the documentation.
|
||||
|
||||
It is impossible to list them all; nevertheless, this file aims at listing
|
||||
the writers who contributed significant patches to this CC-BY licensed
|
||||
documentation on the `godot-docs` repository.
|
||||
|
||||
GitHub usernames are indicated in parentheses, or as sole entry when no other
|
||||
name is available.
|
||||
|
||||
## Main contributors
|
||||
|
||||
(in alphabetical order, with over 10 commits excluding merges)
|
||||
|
||||
Aaron Franke (aaronfranke)
|
||||
Andrew Conrad (her001)
|
||||
Andrii Doroshenko (Xrayez)
|
||||
Arman (puchik)
|
||||
Bastiaan Olij (BastiaanOlij)
|
||||
bitbutter
|
||||
Camille Mohr-Daurat (pouleyKetchoupp)
|
||||
Chris Bradfield (cbscribe)
|
||||
Clay John (clayjohn)
|
||||
corrigentia
|
||||
Fabio Alessandrelli (Faless)
|
||||
FeralBytes
|
||||
Frido (mega-bit)
|
||||
George Marques (vnen)
|
||||
Gerrit Großkopf (Grosskopf)
|
||||
Griatch
|
||||
Haoyu Qiu (timothyqiu)
|
||||
Hugo Locurcio (Calinou)
|
||||
Ignacio Roldán Etcheverry (neikeq)
|
||||
Jérôme Gully (Nutriz)
|
||||
Juan Linietsky (reduz)
|
||||
Julian Murgia (StraToN)
|
||||
Kelly Thomas (KellyThomas)
|
||||
Leon Krause (leonkrause)
|
||||
Matthew (skyace65)
|
||||
Max Hilbrunner (mhilbrunner)
|
||||
Michael Alexsander (YeldhamDev)
|
||||
Nathan Lovato (NathanLovato)
|
||||
Paul Joannon (paulloz)
|
||||
Poommetee Ketson (Naryosha)
|
||||
Rémi Verschelde (akien-mga)
|
||||
Tomasz Chabora (KoBeWi)
|
||||
TwistedTwigleg
|
||||
Will Nations (willnationsdev)
|
||||
Yuri Roubinsky (Chaosus)
|
||||
Yuri Sizov (pycbouh)
|
||||
ZX-WT
|
319
web/docs_hoster_simple/www/LICENSE.txt
Normal file
@ -0,0 +1,319 @@
|
||||
Creative Commons Legal Code
|
||||
|
||||
Attribution 3.0 Unported
|
||||
|
||||
CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE
|
||||
LEGAL SERVICES. DISTRIBUTION OF THIS LICENSE DOES NOT CREATE AN
|
||||
ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS
|
||||
INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES
|
||||
REGARDING THE INFORMATION PROVIDED, AND DISCLAIMS LIABILITY FOR
|
||||
DAMAGES RESULTING FROM ITS USE.
|
||||
|
||||
License
|
||||
|
||||
THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS CREATIVE
|
||||
COMMONS PUBLIC LICENSE ("CCPL" OR "LICENSE"). THE WORK IS PROTECTED BY
|
||||
COPYRIGHT AND/OR OTHER APPLICABLE LAW. ANY USE OF THE WORK OTHER THAN AS
|
||||
AUTHORIZED UNDER THIS LICENSE OR COPYRIGHT LAW IS PROHIBITED.
|
||||
|
||||
BY EXERCISING ANY RIGHTS TO THE WORK PROVIDED HERE, YOU ACCEPT AND AGREE
|
||||
TO BE BOUND BY THE TERMS OF THIS LICENSE. TO THE EXTENT THIS LICENSE MAY
|
||||
BE CONSIDERED TO BE A CONTRACT, THE LICENSOR GRANTS YOU THE RIGHTS
|
||||
CONTAINED HERE IN CONSIDERATION OF YOUR ACCEPTANCE OF SUCH TERMS AND
|
||||
CONDITIONS.
|
||||
|
||||
1. Definitions
|
||||
|
||||
a. "Adaptation" means a work based upon the Work, or upon the Work and
|
||||
other pre-existing works, such as a translation, adaptation,
|
||||
derivative work, arrangement of music or other alterations of a
|
||||
literary or artistic work, or phonogram or performance and includes
|
||||
cinematographic adaptations or any other form in which the Work may be
|
||||
recast, transformed, or adapted including in any form recognizably
|
||||
derived from the original, except that a work that constitutes a
|
||||
Collection will not be considered an Adaptation for the purpose of
|
||||
this License. For the avoidance of doubt, where the Work is a musical
|
||||
work, performance or phonogram, the synchronization of the Work in
|
||||
timed-relation with a moving image ("synching") will be considered an
|
||||
Adaptation for the purpose of this License.
|
||||
b. "Collection" means a collection of literary or artistic works, such as
|
||||
encyclopedias and anthologies, or performances, phonograms or
|
||||
broadcasts, or other works or subject matter other than works listed
|
||||
in Section 1(f) below, which, by reason of the selection and
|
||||
arrangement of their contents, constitute intellectual creations, in
|
||||
which the Work is included in its entirety in unmodified form along
|
||||
with one or more other contributions, each constituting separate and
|
||||
independent works in themselves, which together are assembled into a
|
||||
collective whole. A work that constitutes a Collection will not be
|
||||
considered an Adaptation (as defined above) for the purposes of this
|
||||
License.
|
||||
c. "Distribute" means to make available to the public the original and
|
||||
copies of the Work or Adaptation, as appropriate, through sale or
|
||||
other transfer of ownership.
|
||||
d. "Licensor" means the individual, individuals, entity or entities that
|
||||
offer(s) the Work under the terms of this License.
|
||||
e. "Original Author" means, in the case of a literary or artistic work,
|
||||
the individual, individuals, entity or entities who created the Work
|
||||
or if no individual or entity can be identified, the publisher; and in
|
||||
addition (i) in the case of a performance the actors, singers,
|
||||
musicians, dancers, and other persons who act, sing, deliver, declaim,
|
||||
play in, interpret or otherwise perform literary or artistic works or
|
||||
expressions of folklore; (ii) in the case of a phonogram the producer
|
||||
being the person or legal entity who first fixes the sounds of a
|
||||
performance or other sounds; and, (iii) in the case of broadcasts, the
|
||||
organization that transmits the broadcast.
|
||||
f. "Work" means the literary and/or artistic work offered under the terms
|
||||
of this License including without limitation any production in the
|
||||
literary, scientific and artistic domain, whatever may be the mode or
|
||||
form of its expression including digital form, such as a book,
|
||||
pamphlet and other writing; a lecture, address, sermon or other work
|
||||
of the same nature; a dramatic or dramatico-musical work; a
|
||||
choreographic work or entertainment in dumb show; a musical
|
||||
composition with or without words; a cinematographic work to which are
|
||||
assimilated works expressed by a process analogous to cinematography;
|
||||
a work of drawing, painting, architecture, sculpture, engraving or
|
||||
lithography; a photographic work to which are assimilated works
|
||||
expressed by a process analogous to photography; a work of applied
|
||||
art; an illustration, map, plan, sketch or three-dimensional work
|
||||
relative to geography, topography, architecture or science; a
|
||||
performance; a broadcast; a phonogram; a compilation of data to the
|
||||
extent it is protected as a copyrightable work; or a work performed by
|
||||
a variety or circus performer to the extent it is not otherwise
|
||||
considered a literary or artistic work.
|
||||
g. "You" means an individual or entity exercising rights under this
|
||||
License who has not previously violated the terms of this License with
|
||||
respect to the Work, or who has received express permission from the
|
||||
Licensor to exercise rights under this License despite a previous
|
||||
violation.
|
||||
h. "Publicly Perform" means to perform public recitations of the Work and
|
||||
to communicate to the public those public recitations, by any means or
|
||||
process, including by wire or wireless means or public digital
|
||||
performances; to make available to the public Works in such a way that
|
||||
members of the public may access these Works from a place and at a
|
||||
place individually chosen by them; to perform the Work to the public
|
||||
by any means or process and the communication to the public of the
|
||||
performances of the Work, including by public digital performance; to
|
||||
broadcast and rebroadcast the Work by any means including signs,
|
||||
sounds or images.
|
||||
i. "Reproduce" means to make copies of the Work by any means including
|
||||
without limitation by sound or visual recordings and the right of
|
||||
fixation and reproducing fixations of the Work, including storage of a
|
||||
protected performance or phonogram in digital form or other electronic
|
||||
medium.
|
||||
|
||||
2. Fair Dealing Rights. Nothing in this License is intended to reduce,
|
||||
limit, or restrict any uses free from copyright or rights arising from
|
||||
limitations or exceptions that are provided for in connection with the
|
||||
copyright protection under copyright law or other applicable laws.
|
||||
|
||||
3. License Grant. Subject to the terms and conditions of this License,
|
||||
Licensor hereby grants You a worldwide, royalty-free, non-exclusive,
|
||||
perpetual (for the duration of the applicable copyright) license to
|
||||
exercise the rights in the Work as stated below:
|
||||
|
||||
a. to Reproduce the Work, to incorporate the Work into one or more
|
||||
Collections, and to Reproduce the Work as incorporated in the
|
||||
Collections;
|
||||
b. to create and Reproduce Adaptations provided that any such Adaptation,
|
||||
including any translation in any medium, takes reasonable steps to
|
||||
clearly label, demarcate or otherwise identify that changes were made
|
||||
to the original Work. For example, a translation could be marked "The
|
||||
original work was translated from English to Spanish," or a
|
||||
modification could indicate "The original work has been modified.";
|
||||
c. to Distribute and Publicly Perform the Work including as incorporated
|
||||
in Collections; and,
|
||||
d. to Distribute and Publicly Perform Adaptations.
|
||||
e. For the avoidance of doubt:
|
||||
|
||||
i. Non-waivable Compulsory License Schemes. In those jurisdictions in
|
||||
which the right to collect royalties through any statutory or
|
||||
compulsory licensing scheme cannot be waived, the Licensor
|
||||
reserves the exclusive right to collect such royalties for any
|
||||
exercise by You of the rights granted under this License;
|
||||
ii. Waivable Compulsory License Schemes. In those jurisdictions in
|
||||
which the right to collect royalties through any statutory or
|
||||
compulsory licensing scheme can be waived, the Licensor waives the
|
||||
exclusive right to collect such royalties for any exercise by You
|
||||
of the rights granted under this License; and,
|
||||
iii. Voluntary License Schemes. The Licensor waives the right to
|
||||
collect royalties, whether individually or, in the event that the
|
||||
Licensor is a member of a collecting society that administers
|
||||
voluntary licensing schemes, via that society, from any exercise
|
||||
by You of the rights granted under this License.
|
||||
|
||||
The above rights may be exercised in all media and formats whether now
|
||||
known or hereafter devised. The above rights include the right to make
|
||||
such modifications as are technically necessary to exercise the rights in
|
||||
other media and formats. Subject to Section 8(f), all rights not expressly
|
||||
granted by Licensor are hereby reserved.
|
||||
|
||||
4. Restrictions. The license granted in Section 3 above is expressly made
|
||||
subject to and limited by the following restrictions:
|
||||
|
||||
a. You may Distribute or Publicly Perform the Work only under the terms
|
||||
of this License. You must include a copy of, or the Uniform Resource
|
||||
Identifier (URI) for, this License with every copy of the Work You
|
||||
Distribute or Publicly Perform. You may not offer or impose any terms
|
||||
on the Work that restrict the terms of this License or the ability of
|
||||
the recipient of the Work to exercise the rights granted to that
|
||||
recipient under the terms of the License. You may not sublicense the
|
||||
Work. You must keep intact all notices that refer to this License and
|
||||
to the disclaimer of warranties with every copy of the Work You
|
||||
Distribute or Publicly Perform. When You Distribute or Publicly
|
||||
Perform the Work, You may not impose any effective technological
|
||||
measures on the Work that restrict the ability of a recipient of the
|
||||
Work from You to exercise the rights granted to that recipient under
|
||||
the terms of the License. This Section 4(a) applies to the Work as
|
||||
incorporated in a Collection, but this does not require the Collection
|
||||
apart from the Work itself to be made subject to the terms of this
|
||||
License. If You create a Collection, upon notice from any Licensor You
|
||||
must, to the extent practicable, remove from the Collection any credit
|
||||
as required by Section 4(b), as requested. If You create an
|
||||
Adaptation, upon notice from any Licensor You must, to the extent
|
||||
practicable, remove from the Adaptation any credit as required by
|
||||
Section 4(b), as requested.
|
||||
b. If You Distribute, or Publicly Perform the Work or any Adaptations or
|
||||
Collections, You must, unless a request has been made pursuant to
|
||||
Section 4(a), keep intact all copyright notices for the Work and
|
||||
provide, reasonable to the medium or means You are utilizing: (i) the
|
||||
name of the Original Author (or pseudonym, if applicable) if supplied,
|
||||
and/or if the Original Author and/or Licensor designate another party
|
||||
or parties (e.g., a sponsor institute, publishing entity, journal) for
|
||||
attribution ("Attribution Parties") in Licensor's copyright notice,
|
||||
terms of service or by other reasonable means, the name of such party
|
||||
or parties; (ii) the title of the Work if supplied; (iii) to the
|
||||
extent reasonably practicable, the URI, if any, that Licensor
|
||||
specifies to be associated with the Work, unless such URI does not
|
||||
refer to the copyright notice or licensing information for the Work;
|
||||
and (iv) , consistent with Section 3(b), in the case of an Adaptation,
|
||||
a credit identifying the use of the Work in the Adaptation (e.g.,
|
||||
"French translation of the Work by Original Author," or "Screenplay
|
||||
based on original Work by Original Author"). The credit required by
|
||||
this Section 4 (b) may be implemented in any reasonable manner;
|
||||
provided, however, that in the case of a Adaptation or Collection, at
|
||||
a minimum such credit will appear, if a credit for all contributing
|
||||
authors of the Adaptation or Collection appears, then as part of these
|
||||
credits and in a manner at least as prominent as the credits for the
|
||||
other contributing authors. For the avoidance of doubt, You may only
|
||||
use the credit required by this Section for the purpose of attribution
|
||||
in the manner set out above and, by exercising Your rights under this
|
||||
License, You may not implicitly or explicitly assert or imply any
|
||||
connection with, sponsorship or endorsement by the Original Author,
|
||||
Licensor and/or Attribution Parties, as appropriate, of You or Your
|
||||
use of the Work, without the separate, express prior written
|
||||
permission of the Original Author, Licensor and/or Attribution
|
||||
Parties.
|
||||
c. Except as otherwise agreed in writing by the Licensor or as may be
|
||||
otherwise permitted by applicable law, if You Reproduce, Distribute or
|
||||
Publicly Perform the Work either by itself or as part of any
|
||||
Adaptations or Collections, You must not distort, mutilate, modify or
|
||||
take other derogatory action in relation to the Work which would be
|
||||
prejudicial to the Original Author's honor or reputation. Licensor
|
||||
agrees that in those jurisdictions (e.g. Japan), in which any exercise
|
||||
of the right granted in Section 3(b) of this License (the right to
|
||||
make Adaptations) would be deemed to be a distortion, mutilation,
|
||||
modification or other derogatory action prejudicial to the Original
|
||||
Author's honor and reputation, the Licensor will waive or not assert,
|
||||
as appropriate, this Section, to the fullest extent permitted by the
|
||||
applicable national law, to enable You to reasonably exercise Your
|
||||
right under Section 3(b) of this License (right to make Adaptations)
|
||||
but not otherwise.
|
||||
|
||||
5. Representations, Warranties and Disclaimer
|
||||
|
||||
UNLESS OTHERWISE MUTUALLY AGREED TO BY THE PARTIES IN WRITING, LICENSOR
|
||||
OFFERS THE WORK AS-IS AND MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY
|
||||
KIND CONCERNING THE WORK, EXPRESS, IMPLIED, STATUTORY OR OTHERWISE,
|
||||
INCLUDING, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTIBILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE, NONINFRINGEMENT, OR THE ABSENCE OF
|
||||
LATENT OR OTHER DEFECTS, ACCURACY, OR THE PRESENCE OF ABSENCE OF ERRORS,
|
||||
WHETHER OR NOT DISCOVERABLE. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION
|
||||
OF IMPLIED WARRANTIES, SO SUCH EXCLUSION MAY NOT APPLY TO YOU.
|
||||
|
||||
6. Limitation on Liability. EXCEPT TO THE EXTENT REQUIRED BY APPLICABLE
|
||||
LAW, IN NO EVENT WILL LICENSOR BE LIABLE TO YOU ON ANY LEGAL THEORY FOR
|
||||
ANY SPECIAL, INCIDENTAL, CONSEQUENTIAL, PUNITIVE OR EXEMPLARY DAMAGES
|
||||
ARISING OUT OF THIS LICENSE OR THE USE OF THE WORK, EVEN IF LICENSOR HAS
|
||||
BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
|
||||
|
||||
7. Termination
|
||||
|
||||
a. This License and the rights granted hereunder will terminate
|
||||
automatically upon any breach by You of the terms of this License.
|
||||
Individuals or entities who have received Adaptations or Collections
|
||||
from You under this License, however, will not have their licenses
|
||||
terminated provided such individuals or entities remain in full
|
||||
compliance with those licenses. Sections 1, 2, 5, 6, 7, and 8 will
|
||||
survive any termination of this License.
|
||||
b. Subject to the above terms and conditions, the license granted here is
|
||||
perpetual (for the duration of the applicable copyright in the Work).
|
||||
Notwithstanding the above, Licensor reserves the right to release the
|
||||
Work under different license terms or to stop distributing the Work at
|
||||
any time; provided, however that any such election will not serve to
|
||||
withdraw this License (or any other license that has been, or is
|
||||
required to be, granted under the terms of this License), and this
|
||||
License will continue in full force and effect unless terminated as
|
||||
stated above.
|
||||
|
||||
8. Miscellaneous
|
||||
|
||||
a. Each time You Distribute or Publicly Perform the Work or a Collection,
|
||||
the Licensor offers to the recipient a license to the Work on the same
|
||||
terms and conditions as the license granted to You under this License.
|
||||
b. Each time You Distribute or Publicly Perform an Adaptation, Licensor
|
||||
offers to the recipient a license to the original Work on the same
|
||||
terms and conditions as the license granted to You under this License.
|
||||
c. If any provision of this License is invalid or unenforceable under
|
||||
applicable law, it shall not affect the validity or enforceability of
|
||||
the remainder of the terms of this License, and without further action
|
||||
by the parties to this agreement, such provision shall be reformed to
|
||||
the minimum extent necessary to make such provision valid and
|
||||
enforceable.
|
||||
d. No term or provision of this License shall be deemed waived and no
|
||||
breach consented to unless such waiver or consent shall be in writing
|
||||
and signed by the party to be charged with such waiver or consent.
|
||||
e. This License constitutes the entire agreement between the parties with
|
||||
respect to the Work licensed here. There are no understandings,
|
||||
agreements or representations with respect to the Work not specified
|
||||
here. Licensor shall not be bound by any additional provisions that
|
||||
may appear in any communication from You. This License may not be
|
||||
modified without the mutual written agreement of the Licensor and You.
|
||||
f. The rights granted under, and the subject matter referenced, in this
|
||||
License were drafted utilizing the terminology of the Berne Convention
|
||||
for the Protection of Literary and Artistic Works (as amended on
|
||||
September 28, 1979), the Rome Convention of 1961, the WIPO Copyright
|
||||
Treaty of 1996, the WIPO Performances and Phonograms Treaty of 1996
|
||||
and the Universal Copyright Convention (as revised on July 24, 1971).
|
||||
These rights and subject matter take effect in the relevant
|
||||
jurisdiction in which the License terms are sought to be enforced
|
||||
according to the corresponding provisions of the implementation of
|
||||
those treaty provisions in the applicable national law. If the
|
||||
standard suite of rights granted under applicable copyright law
|
||||
includes additional rights not granted under this License, such
|
||||
additional rights are deemed to be included in the License; this
|
||||
License is not intended to restrict the license of any rights under
|
||||
applicable law.
|
||||
|
||||
|
||||
Creative Commons Notice
|
||||
|
||||
Creative Commons is not a party to this License, and makes no warranty
|
||||
whatsoever in connection with the Work. Creative Commons will not be
|
||||
liable to You or any party on any legal theory for any damages
|
||||
whatsoever, including without limitation any general, special,
|
||||
incidental or consequential damages arising in connection to this
|
||||
license. Notwithstanding the foregoing two (2) sentences, if Creative
|
||||
Commons has expressly identified itself as the Licensor hereunder, it
|
||||
shall have all rights and obligations of Licensor.
|
||||
|
||||
Except for the limited purpose of indicating to the public that the
|
||||
Work is licensed under the CCPL, Creative Commons does not authorize
|
||||
the use by either party of the trademark "Creative Commons" or any
|
||||
related trademark or logo of Creative Commons without the prior
|
||||
written consent of Creative Commons. Any permitted use will be in
|
||||
compliance with Creative Commons' then-current trademark usage
|
||||
guidelines, as may be published on its website or otherwise made
|
||||
available upon request from time to time. For the avoidance of doubt,
|
||||
this trademark restriction does not form part of this License.
|
||||
|
||||
Creative Commons may be contacted at https://creativecommons.org/.
|
139
web/docs_hoster_simple/www/README.md
Normal file
@ -0,0 +1,139 @@
|
||||
# Pandemonium Engine documentation
|
||||
|
||||
This repository contains the source files of [Pandemonium Engine](https://pandemoniumengine.org)'s documentation, in reStructuredText markup language (reST).
|
||||
|
||||
They are meant to be parsed with the [Sphinx](https://www.sphinx-doc.org/) documentation builder to build the HTML documentation on [Pandemonium's website](https://docs.pandemoniumengine.org).
|
||||
|
||||
## Download for offline use
|
||||
|
||||
You can [download an HTML copy](https://nightly.link/pandemoniumengine/pandemonium-docs/workflows/build_offline_docs/master/pandemonium-docs-html-stable.zip)
|
||||
for offline reading (updated every Monday). Extract the ZIP archive then open
|
||||
the top-level `index.html` in a web browser.
|
||||
|
||||
## Theming
|
||||
|
||||
The Pandemonium documentation uses the default `sphinx_rtd_theme` with many
|
||||
[customizations](_static/) applied on top. It will automatically switch between
|
||||
the light and dark theme depending on your browser/OS' theming preference.
|
||||
|
||||
If you use Firefox and wish to use the dark theme regardless of your OS
|
||||
configuration, you can install the
|
||||
[Dark Website Forcer](https://addons.mozilla.org/en-US/firefox/addon/dark-mode-website-switcher/)
|
||||
add-on.
|
||||
|
||||
## Contributing changes
|
||||
|
||||
**Pull Requests should use the `master` branch by default. Only make Pull Requests against other branches (e.g. `2.1` or `3.0`) if your changes only apply to that specific version of Pandemonium.**
|
||||
|
||||
Though arguably less convenient to edit than a wiki, this Git repository is meant to receive pull requests to always improve the documentation, add new pages, etc. Having direct access to the source files in a revision control system is a big plus to ensure the quality of our documentation.
|
||||
|
||||
### Editing existing pages
|
||||
|
||||
To edit an existing page, locate its .rst source file and open it in your favorite text editor. You can then commit the changes, push them to your fork and make a pull request.
|
||||
**Note that the pages in `classes/` should not be edited here, they are automatically generated from Pandemonium's [XML class references](https://github.com/Relintai/pandemonium_engine/tree/master/doc/classes).**
|
||||
See [Contribute to the Class Reference](https://docs.pandemoniumengine.org/en/latest/community/contributing/updating_the_class_reference.html) for details.
|
||||
|
||||
### Adding new pages
|
||||
|
||||
To add a new page, create a .rst file with a meaningful name in the section you want to add a file to, e.g. `tutorials/3d/light_baking.rst`. Write its content like you would do for any other file, and make sure to define a reference name for Sphinx at the beginning of the file (check other files for the syntax), based on the file name with a "doc_" prefix (e.g. `.. _doc_light_baking:`).
|
||||
|
||||
You should then add your page to the relevant "toctree" (table of contents, e.g. `tutorials/3d/index.rst`). By convention, the files used to define the various levels of toctree are prefixed with an underscore, so in the above example the file should be referenced in `tutorials/3d/_3d_graphics.rst`. Add your new filename to the list on a new line, using a relative path and no extension, e.g. here `light_baking`.
|
||||
|
||||
### Sphinx and reStructuredText syntax
|
||||
|
||||
Check Sphinx's [reST Primer](https://www.sphinx-doc.org/en/stable/rest.html) and the [official reference](http://docutils.sourceforge.net/rst.html) for details on the syntax.
|
||||
|
||||
Sphinx uses specific reST comments to do specific operations, like defining the table of contents (`:toctree:`) or cross-referencing pages. Check the [official Sphinx documentation](https://www.sphinx-doc.org/en/stable/index.html) for more details, or see how things are done in existing pages and adapt it to your needs.
|
||||
|
||||
### Adding images and attachments
|
||||
|
||||
To add images, please put them in an `img/` folder next to the .rst file with a meaningful name and include them in your page with:
|
||||
```rst
|
||||
![](img/image_name.png)
|
||||
```
|
||||
|
||||
Similarly, you can include attachments (like assets as support material for a tutorial) by placing them into a `files/` folder next to the .rst file, and using this inline markup:
|
||||
```rst
|
||||
:download:`myfilename.zip ( files/myfilename.zip )`
|
||||
```
|
||||
|
||||
## Building with Sphinx
|
||||
|
||||
To build the HTML website (or any other format supported by Sphinx, like PDF, EPUB or LaTeX), you need to install [Sphinx](https://www.sphinx-doc.org/) >= 1.3 as well as (for the HTML) the [readthedocs.org theme](https://github.com/snide/sphinx_rtd_theme).
|
||||
You also need to install the Sphinx extensions defined in `requirements.txt`.
|
||||
|
||||
Those tools are best installed using [pip](https://pip.pypa.io), Python's module installer. The Python 3 version might be provided (on Linux distros) as `pip3` or `python3-pip`. You can then run:
|
||||
|
||||
```sh
|
||||
pip install -r requirements.txt
|
||||
```
|
||||
|
||||
You can then build the HTML documentation from the root folder of this repository with:
|
||||
|
||||
```sh
|
||||
make html
|
||||
```
|
||||
|
||||
or:
|
||||
|
||||
```sh
|
||||
make SPHINXBUILD=~/.local/bin/sphinx-build html
|
||||
```
|
||||
|
||||
Building the documentation requires at least 8 GB of RAM to be done without swapping. If you have at least 16 GB of RAM, you can speed up compilation by using:
|
||||
|
||||
```bash
|
||||
# On Linux/macOS
|
||||
make html SPHINXOPTS=-j2
|
||||
|
||||
# On Windows
|
||||
set SPHINXOPTS=-j2 && make html
|
||||
```
|
||||
|
||||
The compilation might take some time as the `classes/` folder contains many files to parse.
|
||||
|
||||
In case of a `MemoryError` or `EOFError`, you can remove the `classes/` folder and run `make` again. This will drop the class references from the final HTML documentation but will keep the rest intact. Make sure to avoid using `git add .` in this case when working on a pull request, or the whole `classes/` folder will be removed when you make a commit. See [#3157](https://github.com/Relintai/pandemonium_engine-docs/issues/3157) for more details.
|
||||
|
||||
You can then test the changes live by opening `build/html/index.html` in your favorite browser.
|
||||
|
||||
### Building with Sphinx on Windows
|
||||
|
||||
On Windows, you need to:
|
||||
* Download the Python installer [here](https://www.python.org/downloads/).
|
||||
* Install Python. Don't forget to check the "Add Python to PATH" box.
|
||||
* Use the above `pip` commands.
|
||||
|
||||
Building is still done at the root folder of this repository using the provided `make.bat`:
|
||||
```sh
|
||||
make.bat html
|
||||
```
|
||||
|
||||
Alternatively, you can build with this command instead:
|
||||
```sh
|
||||
sphinx-build -b html ./ _build
|
||||
```
|
||||
|
||||
Note that during the first build, various installation prompts may appear and ask to install LaTeX plugins.
|
||||
Make sure you don't miss them, especially if they open behind other windows, else the build may appear to hang until you confirm these prompts.
|
||||
|
||||
You could also install a normal `make` toolchain (for example via MinGW) and build the docs using the normal `make html`.
|
||||
|
||||
### Building with Sphinx and virtualenv
|
||||
|
||||
If you want your Sphinx installation scoped to the project, you can install it using virtualenv.
|
||||
Execute this from the root folder of this repository:
|
||||
|
||||
```sh
|
||||
virtualenv --system-site-packages env/
|
||||
. env/bin/activate
|
||||
pip install -r requirements.txt
|
||||
```
|
||||
|
||||
Then do `make html` like above.
|
||||
|
||||
## License
|
||||
|
||||
At the exception of the `classes/` folder, all the content of this repository is licensed under the Creative Commons Attribution 3.0 Unported license ([CC BY 3.0](https://creativecommons.org/licenses/by/3.0/)) and is to be attributed to "Péter Magyar and the Pandemonium community, and Juan Linietsky, Ariel Manzur and the Godot community".
|
||||
See [LICENSE.txt](/LICENSE.txt) for details.
|
||||
|
||||
The files in the `classes/` folder are derived from [Pandemonium's main source repository](https://github.com/Relintai/pandemonium_engine) and are distributed under the MIT license, with the same authors as above.
|
141
web/docs_hoster_simple/www/index.md
Normal file
@ -0,0 +1,141 @@
|
||||
Pandemonium Docs – *3.5* branch
|
||||
=========================
|
||||
|
||||
.. only:: not i18n
|
||||
|
||||
Note:
|
||||
Pandemonium's documentation is available in various languages and versions.
|
||||
Expand the "Read the Docs" panel at the bottom of the sidebar to see
|
||||
the list.
|
||||
|
||||
Tip:
|
||||
This is the documentation for the 3.5 branch.
|
||||
Looking for the documentation of the current **development** branch?
|
||||
`Have a look here ( https://docs.pandemoniumengine.org/en/latest )`.
|
||||
You can also browse the documentation for the current stable
|
||||
`3.4 ( https://docs.pandemoniumengine.org/en/3.4 )` branch.
|
||||
|
||||
.. only:: i18n
|
||||
|
||||
Note:
|
||||
This documentation is translated from the `original English one
|
||||
( https://docs.pandemoniumengine.org/en/latest )` by community members
|
||||
on `Weblate ( https://hosted.weblate.org/projects/pandemonium-engine/pandemonium-docs )`.
|
||||
|
||||
Depending on the translation effort's completion level, you may
|
||||
find paragraphs or whole pages which are still in English. You can
|
||||
help the community by providing new translations or reviewing existing
|
||||
ones on Weblate.
|
||||
|
||||
For the time being, localized translations are only available for
|
||||
the "latest" (development) branch, but should be suitable to learn
|
||||
how to use stable Pandemonium releases nevertheless.
|
||||
|
||||
Welcome to the official documentation of `Pandemonium Engine ( https://pandemoniumengine.org )`,
|
||||
the free and open source community-driven 2D and 3D game engine! If you are new
|
||||
to this documentation, we recommend that you read the
|
||||
`introduction page ( doc_about_intro )` to get an overview of what this
|
||||
documentation has to offer.
|
||||
|
||||
The table of contents below and in the sidebar should let you easily access the
|
||||
documentation for your topic of interest. You can also use the search function
|
||||
in the top left corner.
|
||||
|
||||
You can also `download an HTML copy ( https://nightly.link/pandemoniumengine/pandemonium-docs/workflows/build_offline_docs/master/pandemonium-docs-html-stable.zip )`
|
||||
for offline reading (updated every Monday). Extract the ZIP archive then open
|
||||
the top-level `index.html` in a web browser.
|
||||
|
||||
Note:
|
||||
Pandemonium Engine is an open source project developed by a community of
|
||||
volunteers. The documentation team can always use your
|
||||
feedback and help to improve the tutorials and class reference. If
|
||||
you don't understand something, or cannot find what you
|
||||
are looking for in the docs, help us make the documentation better
|
||||
by letting us know!
|
||||
|
||||
Submit an issue or pull request on the `GitHub repository
|
||||
( https://github.com/Relintai/pandemonium_engine-docs/issues )`,
|
||||
help us `translate the documentation
|
||||
( https://hosted.weblate.org/engage/pandemonium-engine/ )` into your
|
||||
language, or talk to us on the
|
||||
`#documentation` channel on the `Pandemonium Contributors Chat
|
||||
( https://chat.pandemoniumengine.org/ )`!
|
||||
|
||||
.. centered:: |weblate_widget|
|
||||
|
||||
The main documentation for the site is organized into the following sections:
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
:caption: General
|
||||
:name: sec-general
|
||||
|
||||
about/index
|
||||
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
:caption: Getting started
|
||||
:name: sec-learn
|
||||
|
||||
getting_started/introduction/index
|
||||
getting_started/step_by_step/index
|
||||
getting_started/first_2d_game/index
|
||||
getting_started/first_3d_game/index
|
||||
|
||||
|
||||
.. The sections below are sorted alphabetically. Please keep them that way.
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
:caption: Tutorials
|
||||
:name: sec-tutorials
|
||||
|
||||
tutorials/2d/index
|
||||
tutorials/3d/index
|
||||
tutorials/animation/index
|
||||
tutorials/assets_pipeline/index
|
||||
tutorials/audio/index
|
||||
tutorials/best_practices/index
|
||||
tutorials/editor/index
|
||||
tutorials/export/index
|
||||
tutorials/i18n/index
|
||||
tutorials/inputs/index
|
||||
tutorials/io/index
|
||||
tutorials/math/index
|
||||
tutorials/navigation/index
|
||||
tutorials/networking/index
|
||||
tutorials/performance/index
|
||||
tutorials/physics/index
|
||||
tutorials/platform/index
|
||||
tutorials/plugins/index
|
||||
tutorials/rendering/index
|
||||
tutorials/scripting/index
|
||||
tutorials/shaders/index
|
||||
tutorials/ui/index
|
||||
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
:caption: Development
|
||||
:name: sec-devel
|
||||
|
||||
development/compiling/index
|
||||
development/cpp/index
|
||||
development/editor/index
|
||||
development/file_formats/index
|
||||
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
:caption: Community
|
||||
:name: sec-community
|
||||
|
||||
community/contributing/index
|
||||
community/tutorials
|
||||
|
||||
.. Indices and tables
|
||||
.. ------------------
|
||||
..
|
||||
.. * `genindex`
|
||||
.. * `modindex`
|
||||
.. * `search`
|
3
web/docs_hoster_webroot/.gitignore
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
|
||||
www/
|
||||
.import/
|
34
web/docs_hoster_webroot/BrowsableFolderServeWebPage.gd
Normal file
@ -0,0 +1,34 @@
|
||||
extends BrowsableFolderServeWebPage
|
||||
|
||||
var markdown_renderer : MarkdownRenderer = null
|
||||
|
||||
func serve_md(request: WebServerRequest) -> void:
|
||||
var path : String = request.get_path_full()
|
||||
|
||||
var fabs : String = get_file_cache().wwwroot_get_file_abspath(path)
|
||||
|
||||
if fabs == "":
|
||||
request.send_error(HTTPServerEnums.HTTP_STATUS_CODE_404_NOT_FOUND)
|
||||
return
|
||||
|
||||
var f : File = File.new()
|
||||
if f.open(fabs, File.READ) != OK:
|
||||
request.send_error(HTTPServerEnums.HTTP_STATUS_CODE_404_NOT_FOUND)
|
||||
return
|
||||
|
||||
request.body += markdown_renderer.render(f.get_as_text())
|
||||
|
||||
f.close()
|
||||
|
||||
request.compile_and_send_body()
|
||||
|
||||
func _handle_request_main(request: WebServerRequest) -> void:
|
||||
|
||||
if request.get_path_full().ends_with(".md"):
|
||||
serve_md(request)
|
||||
return
|
||||
|
||||
._handle_request_main(request)
|
||||
|
||||
func _ready() -> void:
|
||||
markdown_renderer = MarkdownRenderer.new()
|
34
web/docs_hoster_webroot/Main.tscn
Normal file
@ -0,0 +1,34 @@
|
||||
[gd_scene load_steps=2 format=3]
|
||||
|
||||
[ext_resource path="res://WebRoot.gd" type="Script" id=1]
|
||||
|
||||
[node name="Main" type="Node"]
|
||||
|
||||
[node name="PanelContainer" type="PanelContainer" parent="."]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
|
||||
[node name="CC" type="CenterContainer" parent="PanelContainer"]
|
||||
margin_left = 7.0
|
||||
margin_top = 7.0
|
||||
margin_right = 1017.0
|
||||
margin_bottom = 593.0
|
||||
|
||||
[node name="LinkButton" type="LinkButton" parent="PanelContainer/CC"]
|
||||
margin_left = 437.0
|
||||
margin_top = 286.0
|
||||
margin_right = 573.0
|
||||
margin_bottom = 300.0
|
||||
text = "http://127.0.0.1:8080"
|
||||
uri = "http://127.0.0.1:8080"
|
||||
|
||||
[node name="WebServerSimple" type="WebServerSimple" parent="."]
|
||||
start_on_ready = true
|
||||
|
||||
[node name="WebRoot" type="WebRoot" parent="WebServerSimple"]
|
||||
www_root_path = "res://www/"
|
||||
script = ExtResource( 1 )
|
||||
|
||||
[node name="BrowsableFolderServeWebPage" type="BrowsableFolderServeWebPage" parent="WebServerSimple/WebRoot"]
|
||||
uri_segment = "/"
|
||||
serve_folder = "res://www/"
|
34
web/docs_hoster_webroot/WebRoot.gd
Normal file
@ -0,0 +1,34 @@
|
||||
extends WebRoot
|
||||
|
||||
var markdown_renderer : MarkdownRenderer = null
|
||||
|
||||
func serve_md(request: WebServerRequest) -> void:
|
||||
var path : String = request.get_path_full()
|
||||
|
||||
var fabs : String = www_root_file_cache.wwwroot_get_file_abspath(path)
|
||||
|
||||
if fabs == "":
|
||||
request.send_error(HTTPServerEnums.HTTP_STATUS_CODE_404_NOT_FOUND)
|
||||
return
|
||||
|
||||
var f : File = File.new()
|
||||
if f.open(fabs, File.READ) != OK:
|
||||
request.send_error(HTTPServerEnums.HTTP_STATUS_CODE_404_NOT_FOUND)
|
||||
return
|
||||
|
||||
request.body += markdown_renderer.render(f.get_as_text())
|
||||
|
||||
f.close()
|
||||
|
||||
request.compile_and_send_body()
|
||||
|
||||
func _handle_request_main(request: WebServerRequest) -> void:
|
||||
|
||||
if request.get_path_full().ends_with(".md"):
|
||||
serve_md(request)
|
||||
return
|
||||
|
||||
._handle_request_main(request)
|
||||
|
||||
func _ready() -> void:
|
||||
markdown_renderer = MarkdownRenderer.new()
|
7
web/docs_hoster_webroot/default_env.tres
Normal file
@ -0,0 +1,7 @@
|
||||
[gd_resource type="Environment3D" load_steps=2 format=3]
|
||||
|
||||
[sub_resource type="ProceduralSky" id=1]
|
||||
|
||||
[resource]
|
||||
background_mode = 2
|
||||
background_sky = SubResource( 1 )
|
BIN
web/docs_hoster_webroot/icon.png
Normal file
After Width: | Height: | Size: 3.2 KiB |
35
web/docs_hoster_webroot/icon.png.import
Normal file
@ -0,0 +1,35 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="StreamTexture"
|
||||
path="res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://icon.png"
|
||||
dest_files=[ "res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex" ]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_mode=0
|
||||
compress/bptc_ldr=0
|
||||
compress/normal_map=0
|
||||
flags/repeat=0
|
||||
flags/filter=true
|
||||
flags/mipmaps=false
|
||||
flags/anisotropic=false
|
||||
flags/srgb=2
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/HDR_as_SRGB=false
|
||||
process/invert_color=false
|
||||
process/normal_map_invert_y=false
|
||||
stream=false
|
||||
size_limit=0
|
||||
detect_3d=true
|
||||
svg/scale=1.0
|
25
web/docs_hoster_webroot/project.pandemonium
Normal file
@ -0,0 +1,25 @@
|
||||
; Engine configuration file.
|
||||
; It's best edited using the editor UI and not directly,
|
||||
; since the parameters that go here are not all obvious.
|
||||
;
|
||||
; Format:
|
||||
; [section] ; section goes between []
|
||||
; param=value ; assign values to parameters
|
||||
|
||||
config_version=4
|
||||
|
||||
[application]
|
||||
|
||||
config/name="Pandemonium Docs Hoster WebRoot"
|
||||
run/main_scene="res://Main.tscn"
|
||||
config/icon="res://icon.png"
|
||||
|
||||
[physics]
|
||||
|
||||
common/enable_pause_aware_picking=true
|
||||
|
||||
[rendering]
|
||||
|
||||
vram_compression/import_etc=true
|
||||
vram_compression/import_etc2=false
|
||||
environment/default_environment="res://default_env.tres"
|