Comments (8)
Ah, ok. Please keep me updated about your work, I'm interested to see how it works.
from planck.js.
Awesome! :) I'm glad it worked for you. I will add it to a new demo list in near future.
from planck.js.
Cool! Does it require specifying static types for methods' arguments and return?
from planck.js.
They are already defined into the externs :
sometimes I had to create some new "typedef" that conform to yours :
https://github.com/NicolasVereenoghe/git.vega.pixi4/blob/master/haxe/lib/planck%2Cjs/0%2C1%2C34/src/planck/World.hx#L10-L29
... or sometimes they are just externs of yours :
https://github.com/NicolasVereenoghe/git.vega.pixi4/blob/master/haxe/lib/planck%2Cjs/0%2C1%2C34/src/planck/collision/Distance.hx#L14-L43
For now I've just checked the instances are created (World, Body .... Transform ...) and filled correctly. I followed the provided index.js file and tryed to deal with code that is exposed (not all protected members, not the Solver class, I believe the latter can remain hidden for now)
More testing is needed, I work for a client and I will test it this week ....
from planck.js.
That's interesting and very helpful! Do you know how does it compare to TypeScript types? Because someone asked me about it before.
from planck.js.
Sorry, I dont have expertise with TypeScript
from planck.js.
Hello,
My work is still in progress, and for now the planckjs seems to run properly with the Haxe externs.
I cannot show a demo because it's for a client. It's a mini game where you need to complete a level by adding blocks, so that a ball can travel to a goal.
From my first post, I had to adjust the externs to be compliant with your code, I updated them into my framework repository (see previous links). I copy my "commit comments" here :
. optional Body::createFixture parameters
. optional parameters for Fixture constructor
. added FixtureDef::shape field
. adjusted signature for World::on and World::off events registration functions
. added constants for world events labels (WORLD_REMOVE_BODY,WORLD_REMOVE_JOINT,WORLD_REMOVE_FIXTURE,WORLD_CONTACT_BEGIN,WORLD_CONTACT_END,WORLD_CONTACT_PRE,WORLD_CONTACT_POST)
. warning : you have to explicitly set a body as dynamic, even if its fixtures have a non 0 density
I continue the testings :)
from planck.js.
Hello, here a game demo extracted from my work for my client. I think I can share this :
https://github.com/NicolasVereenoghe/vega.labo.pampamplanck
The game is redeveloped from former Flash Box2D sources. Mechanics are very simple. It conforms to the original game. No issues for now, just some adjustments to adapt to the last Box2D API.
from planck.js.
Related Issues (20)
- Memory leak in planck? HOT 2
- When will version 1 be released? HOT 5
- Feature Request: Implementation of b2Draw, SetDebugDraw and DebugDraw HOT 7
- Changing a circle collider's friction doesn't make it roll slower HOT 1
- Feature Request: Add the ESM button to jsDelivr
- How to change a collider's center? HOT 5
- Why does displacement cause multiple begin and end contact events? HOT 6
- Typo in the Wiki HOT 4
- setActive(true) throwing error in v1 beta 8
- ERROR changing a collider's mass cancels its linearVelocity HOT 5
- planck's npm package is quite large HOT 8
- World step error HOT 12
- possible testOverlap bug HOT 2
- Undefined Reading "x" error HOT 5
- Raycasts phasing through walls HOT 6
- clarification on the determinism limitation from docs HOT 1
- pointers on how to network planck HOT 8
- inconsistent Vec2 construction throughout examples
- DistanceJoint `getReactionForce` function not working HOT 4
- Script tag: Uncaught TypeError: t is null HOT 2
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 planck.js.