Comments (2)
godot-nim
by itself is just a Nim library. It doesn't do anything out of the ordinary when you use it.
godot-nim-stub
provides an example (a rather basic one) of how to build your Nim project in a way that Godot expects it. You can modify it to your needs, name libraries differently or even have multiple libraries in your own project. That project was meant to provide a basic template that you can expand as needed.
As about the specific questions here:
-
You cannot package a native dynamic library into another file. OS APIs expect it to be a separate file. The only exception is iOS where dynamic libraries are not allowed and so GDNative libraries are linked statically. The last time I checked GDNative didn't support static linking for other platforms, but things may have changed since then.
-
I haven't looked into exporting Nim projects for HTML5. You should look into how it's done for C and replicate the same steps for Nim. Nim supports overriding the commands used for compiling C files, which may come in handy here.
-
For exporting to multiple platforms I'd recommend making a task like
nake package html5
that does the necessary preparations, compiles the library for Godot, and then invokes Godot to export the project.
from godot-nim.
To be clear on one of the questions: you can copy the nim-lang library from 1 exported project over to another and it will carry over logic (most notably window settings if set via nim). It might be interesting if 2 games were developed similarly enough that swapping files like that would produce a playable (though odd) result. Though I suspect the more common issue will be people updating/replacing .pck files and not also the libraries, and thus not actually fixing code errors.
So It'd be more clear if it were nim_gamelogic_OSbits.libext
(or something like that) as default instead. Though sure, I do see how I could do that myself in nakefile.nim
in your stub project (which yes, I have used obviously). EDIT: Actually the gdnlib file needs to be edited as well
The other stuff I don't know where I'd even start (a while ago I wanted to test Bunnymark and couldn't get C++ bindings installed), I'm not far enough for it to really matter that much (well, I've now done 1 project that I tried to export to HTML5) but it'd be nice to have actual info/directions.
from godot-nim.
Related Issues (20)
- Nim constructor not found for class BulletPhysicsDirectSpaceState HOT 1
- Issue with connecting signal BodyEntered (area) HOT 1
- Generate .dll for other platforms (like Linux) HOT 4
- New native extension system for 4.0 HOT 1
- Basis getEuler behavior
- Add proc directionTo for vector2 and vector3
- GDExtentions Support HOT 1
- Nake Build Error HOT 14
- Nake build failed if GODOT_BIN path contains space character
- How to deal with exceptions? (and other beginner notes) HOT 7
- Documentation search doesn't do anything
- Is this abandoned? What's happening HOT 4
- nake build error:: type expected but got symbol 'Array' of kind 'enumField' HOT 2
- godot-nim crashing godot (windows 10) [Solved?]
- I can't find the answers
- Error: type expected, but got symbol 'Array' of kind 'enumField' HOT 1
- is this abandoned? HOT 7
- Output is flooding with `A foreign thread is created` when i use NavigationAgent
- Cant compile to wasm
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from godot-nim.