@infernus/colandreas
TypeScript icon, indicating that this package has built-in type declarations

0.0.6 • Public • Published

@infernus/colandreas

npm npm npm bundle size

A wrapper of the popular SA-MP ColAndreas plugin for samp-node.

Getting started

pnpm add @infernus/core @infernus/colandreas

Example

import { GameMode, PlayerEvent } from "@infernus/core";
import { init, isPlayerInWater } from "@infernus/colandreas";

GameMode.onInit(({ next }) => {
  init();
  return next();
});

PlayerEvent.onCommandText("water", ({ player, next }) => {
  const info = isPlayerInWater(player);
  if (info)
    player.sendClientMessage(
      "#f00",
      `you are in water, ${JSON.stringify(info)}`
    );
  else {
    player.sendClientMessage("#0f0", "you are not in water");
  }
  return next();
});

Package Sidebar

Install

npm i @infernus/colandreas

Weekly Downloads

0

Version

0.0.6

License

MIT

Unpacked Size

28.4 kB

Total Files

6

Last publish

Collaborators

  • dockfries