samp.directory
← Scripts et bibliothèques

philip1337/samp-plugin-mapandreas

MapAndreas Plugin

Plugin★ 29mis à jour juin 2023Pas de licenceC++sampctl
Ouvrir sur GitHub

Ce dépôt n’a pas de fichier de licence. Il est public en lecture, mais cela ne donne pas à lui seul le droit de le réutiliser.

Installer avec sampctl

sampctl package install philip1337/samp-plugin-mapandreas

Lance ceci dans le dossier de ton projet. sampctl télécharge le paquet et ce dont il dépend.

L’essayer dans le compilateur Pawn →

Ajoute ses fichiers include, avec les bibliothèques dont il dépend, au compilateur Pawn de ton navigateur, prêts à être inclus dans un script.

Utilisé par 1 paquet

README.md

Map Andreas Plugin

This plugin was initiali made by Kalcor and extended bv Mauzen. It allows you to load different height maps and check the min height for x,y coordinates. You can us it as example for an anti cheat to detect airbreaks easier or to prevent falling through the ground.

Features

  • Load height map
  • You can also implement it in your sampgdk plugins.

Themes about this plugin:

Functions

nativeparamsreturn
MapAndreas_Initmode, const name[]int (0 failed/1 success)
MapAndreas_Unloadconst name[], const message[]int (0 failed/1 success)
MapAndreas_SaveCurrentHMapconst name[]int (0 failed/1 success)
MapAndreas_FindZ_For2DCoordFloat:X, Float:Y, &Float:Zint (0 failed/1 success)
MapAndreas_FindAverageZFloat:X, Float:Y, &Float:Zint (0 failed/1 success)
MapAndreas_SetZ_For2DCoordFloat:X, Float:Y, Float:Zint (0 failed/1 success)

Installation

Simply install to your project:

sampctl package install philip1337/samp-plugin-mapandreas

Include in your code and begin using the library:

#include <mapandreas>

Example

Initialize MapAndreas and get a position.

public OnGameModeInit(playerid, cmdtext[])
{
    MapAndreas_Init(MAP_ANDREAS_MODE_FULL, "scriptfiles/SAFull.hmap");
    new Float:pos;
    if (MapAndreas_FindAverageZ(20.001, 25.006, pos)) {
        // Found position - position saved in 'pos'
    }
    return 0;
}

Build

Requirements

Synchronize dependencies from DEPS File.

gclient.py sync -v -f

You can also download it manually and place it into the external directory.

mkdir build
cd build
cmake ..\samp-log-spdlog
make

heightmapmapandreaspluginsa-mp

Cette page est construite à partir de ce que GitHub publie sur le dépôt. samp.directory n’héberge pas le code. Signaler un problème avec cette fiche

philip1337/samp-plugin-mapandreas : Plugin SA-MP | samp.directory