New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@infernus/map-loader

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@infernus/map-loader

A tool for obj conversion, parsing, and loading

latest
Source
npmnpm
Version
0.1.1
Version published
Weekly downloads
3
Maintainers
1
Weekly downloads
 
Created
Source

@infernus/map-loader

npm npm npm bundle size

Getting started

A tool for obj conversion, parsing, and loading, which refers to samp-map-parser.

pnpm add @infernus/core @infernus/map-loader

Example

import { GameMode } from "@infernus/core";
import {
  getMapCount,
  getMapInfoFromID,
  loadMap,
  mapConverter,
} from "@infernus/map-loader";
import path from "node:path";

GameMode.onInit(async ({ next }) => {
  const start = Date.now();

  await mapConverter({
    input: path.resolve("./scriptfiles/us_mapas.pwn"),
    output: path.resolve("./scriptfiles/us_mapas.txt"),
    removeOutput: true,
  });

  const end = Date.now();

  console.log((end - start) / 1000 + "s");

  const mapId = await loadMap({
    source: path.resolve("./scriptfiles/us_mapas.txt"),
    onLoaded(objects, removedBuilding) {
      console.log(objects.length, removedBuilding.length);
    },
  });

  console.log(mapId);

  const info = getMapInfoFromID(mapId);

  console.log(info);

  console.log(getMapCount());

  return next();
});

Keywords

samp

FAQs

Package last updated on 19 Dec 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts