nasser / ajeeb Goto Github PK
View Code? Open in Web Editor NEWPatterns for Playful Systems
Home Page: http://ajeeb.games/
Patterns for Playful Systems
Home Page: http://ajeeb.games/
A collection of math functions for e.g. clamp, random choice, etc. that are generally useful and annoying to re-implement for each project.
tick
is by definition in the inner loop of any coroutine system and needs to be as fast as possible. The current implementation based on arrays is needlessly wasteful and can be improved. The new implementation should:
tick
An implementation based on a linked list will probably work best.
Similar to remove
and removeAll
but also call return
on the couroutine(s) in being cancelled.
When restarting a game it is useful to be able to get rid of any background coroutines while preserving the "main" coroutine. It's important to do this in a way that does not enshrine the "main" coroutine in any way.
One possible approach is to take advantage of the ordered nature of schedules. If coroutine B is farther in the schedule than coroutine A then B guaranteed to have started later than A. If we want to get rid of any coroutines started after a coroutine, we could expose a removeAllAfter(i)
method, where i
is the offset into the schedule after which to remove coroutines.
SCHED.add(function* () { // "main" coroutine
const depthAtStart = SCHED.size // or similar
while(true) {
// ... coroutine body
// when resetting
SCHED.removeAllAfter(depthAtStart)
}
})
removeAllAfter
should call return()
on the relevant coroutines and allow them to be cleaned up in later tick
s.
السلام عليكم
Tauri = تاري
Electron = الكترون
الكترون يستخدم الكثير من موارد الجهاز وغير متوفر على الاجهزه المحمولة
تاري اخف بكثير ويدعم webassembly ودعم الاجهزه المحمولة قادم
وشكرا.
https://tauri.studio/en/ : موقع تاري الرسمي
A collection of easing functions would make sense as a top-level Ajeeb library. Useful on every project, annoying to re-implement each time.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.