npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@yantra-core/yantra

v1.0.0

Published

Yantra.gg Serverless Physics SDK for Real-time Multiplayer Game Development

Downloads

47

Readme

@yantra-core/yantra

@yantra-core/yantra is the core SDK for interfacing with the Yantra Serverless Physics.

With this SDK, you can create, manage, and interact with dynamic physics environments in the cloud. Below is a guide on how to use it.

yantra works in tandem with mantra. You can develop your games locally using mantra and then run yantra deploy in the game's directory to deploy to cloud.

Installation

Install the SDK CLI (Command Line Tool) with npm:

npm install -g @yantra-core/cli

Now you can run the yantra command on your system.


  __     __         _                _____ _      _____ 
  \ \   / /        | |              / ____| |    |_   _|
   \ \_/ /_ _ _ __ | |_ _ __ __ _  | |    | |      | |  
    \   / _` | '_ \| __| '__/ _` | | |    | |      | |  
     | | (_| | | | | |_| | | (_| | | |____| |____ _| |_ 
     |_|\__,_|_| |_|\__|_|  \__,_|  \_____|______|_____|
                                                        
 
Usage:  [options] [command]

Yantra Serverless Physics Platform CLI

Options:
  -V, --version   output the version number
  -h, --help      display help for command

Commands:
  init            Initialize a new world in the current directory
  clone           Clone a world from the Yantra library
  deploy          Deploy your physics world
  list            List your worlds
  info            Checks current directory for a Yantra world and displays information about it
  rm              Remove a world
  whoami          Display the current user
  login           Login to Yantra using OTP or create an account if it does not exist
  logout          Logs CLI client out of Yantra
  recover         Recover your account names by email address
  help [command]  display help for command

Features

  • Create Client: Generate a new instance of YantraClient
  • World Management: Connect to, or disconnect from, specific worlds.
  • Entity Management: Create and update entities in the physics world.
  • Physics Interactions: Apply forces, set velocities, and modify other physics-related attributes of entities.
  • Event Handling: React to various events and server messages.
  • World Deployment: Deploy physics world to cloud
  • Auto-scaling: Automatically scale resources for a given world in a specific region.

CLI Quick Start

Login / Register Account

Login with existing account name or register new account by email address

yantra login

Initialize and a new World

Installs base template for World development and deployment

mkdir my-world
cd my-world
yantra init

Clone existing Yantra World

Installs a pre-made World into current directory. Type yantra clone to view available Worlds

yantra clone pong
cd pong
npm start

Deploy World from localhost to cloud

Deploys local world to Yantra Cloud. Provides a default game client link via ayyo.gg

yantra clone snake
cd snake
yantra deploy

Running in Yantra's Environment:

When you upload your code to Yantra, it's executed in our optimized low-latency environment. Here's what you should know:

  • High Performance: Yantra's backend is fine-tuned to ensure your game logic runs smoothly.
  • Consistent Framerate: We prioritize a consistent, high framerate, ensuring your gameplay is fluid and responsive.
  • Direct Execution: Your uploaded code runs directly, 1:1, with no modifications or external dependencies. The performance you see locally will mirror what you get in our cloud environment.

Support

For issues, bugs, or feedback, please open an issue on our GitHub repository or visit us in our Discord