Reclama SERVARE @ Since 2014
Doriți să reacționați la acest mesaj? Creați un cont în câteva clickuri sau conectați-vă pentru a continua.



 
Acasa4SampUltimele imaginiCăutareÎnregistrareConectare
*-*Nu uita !: Fara off - topic / Fara dublu post /Posteaza in sectiunea corecta !*-*
$_$ Pentru a avea acces la toate functiile va rugam sa te Inregistrezi / Loghezi ! &_&
:~: :~: :~: Nu copia continutul forumului ! :~: :~: :~:
Bun venit pe 4Samp ! Distractie placuta ^_^

 

 [Plugin]MapAndreeas V1.0

In jos 
AutorMesaj
icesamp
Administratori
Administratori
icesamp


Bara Warn : [Plugin]MapAndreeas V1.0 111010
Mesaje Mesaje : 57
Experienta Experienta : 221
Data de inscriere Data de inscriere : 17/08/2010
Varsta Varsta : 38
Localizare Localizare : Bucuresti
Joburi/Distractii Joburi/Distractii : SAMP
Stare de spirit Stare de spirit : Be Happy

[Plugin]MapAndreeas V1.0 Empty
MesajSubiect: [Plugin]MapAndreeas V1.0   [Plugin]MapAndreeas V1.0 EmptyJoi Sept 09, 2010 4:39 am

This plugin is designed to read provided data regarding the San Andreas map and provide that information to SA-MP pawn scripts.

This version contains a height map of the San Andreas geometry and provides a function to obtain the highest ground position from a provided 2D point. It is expected that future versions could include other types of maps, such as water maps and road maps.

[Plugin]MapAndreeas V1.0 SAfull


Important: This plugin uses approximately 70MB of RAM. If you are using shared hosting or a VPS, please confirm with your host that this is okay. A version that uses less RAM is planned although it won't have the same level of accuracy.

Possible uses:

This plugin potentially has many uses although here are some obvious examples:

Teleporting:
When the server wants to teleport a player or vehicle to another player, right now the scripts will usually pick a point on the same Z position as the other player. It is only luck most of the time that prevents you from being teleported in to a building or wall, or even below the ground. Using the data made available by this plugin, the server could search around player to find a suitable ground position for teleporting.

Anti-cheat:
Using this plugin you can tell the difference between someone still on top of a building and someone still floating in the air.

Dynamic object placement:
You can potentially use this plugin to determine the ground position around a player for placing objects.

Pawn Natives:

Citat :
native MapAndreas_Init(mode); // Used to initalise the data files in to memory - should be called at least once before any other function.
native MapAndreas_FindZ_For2DCoord(Float:X, Float:Y, &Float:Z); // return highest Z point (ground level) for the provided X,Y co-ordinate.

Limitations of MapAndreas_FindZ_For2DCoord()

- San Andreas is a 3D world, although the output provided by this plugin only represents a single dimension. It will only return the highest Z co-ord for the X,Y position you provide. As an example, someone could be standing underneath a bridge and you won't be able to find the ground level which they are standing on. That means it's valid for a player to be beneath the highest ground level. Although using a height map has some serious drawbacks compared to 3D data, it is extremely fast and you can call this function almost as often as you like.
- The Z return value is accurate to 1.0 square world unit (1m²) for the entire San Andreas landmass (6km²).
- The Z return value is accurate to within a few centimeters from the actual ground surface position.
- There is no data about heights below sea level (0.0Z). The function will always return 0.0 for those areas.
- There are parts of San Andreas below sea level that do not contain water. ie the quarry in LV and the underground airport terminal in LS.
- The SA map has small holes in some places. They are fairly rare, although these holes are often not big enough to fall through. The function will return 0.0 for these co-ords. You can potentially check neighbouring co-ordinates if you want to check if the 0.0 return value is a hole.
- This works only in interior 0 (main SA world) and cannot handle areas with custom objects.

Installation:

- Extract the contents of the zip in to your SA-MP server folder/directory.
- Windows Server: edit server.cfg and add the line: plugins MapAndreas
- Linux Server: edit server.cfg and add the line: plugins MapAndreas.so
- To test everything is working, you can load the mapandreas_test filterscript and use the /glvl command.

Downloads:

MapAndreas plugin v1.0 beta (28.2MB)
MapAndreas plugin v1.0 beta source code

Revision history:

v1.0 beta
---------
Initial test version.

Included files:

plugins/MapAndreas.dll - The Windows dll plugin.
plugins/MapAndreas.so - The linux shared object plugin.
scriptfiles/SAfull.hmap - The San Andreas heightmap data.
scriptfiles/SAfull.jpg - A graphical representation of the heightmap data.
pawno/include/mapandreas.inc - The pawn include for the MapAndreas plugin natives.
filterscripts/mapandreas_test.amx - A filterscript with a test command /glvl
filterscripts/mapandreas_test.pwn - Pawn script source for the above filterscript.
Sus In jos
 
[Plugin]MapAndreeas V1.0
Sus 
Pagina 1 din 1
 Subiecte similare
-
» [Plugin]HPK
» [Plugin]PTB
» [Plugin]JoinIP

Permisiunile acestui forum:Nu puteti raspunde la subiectele acestui forum
Reclama SERVARE @ Since 2014 :: Tutoriale Jocuri :: San Andreeas - MultiPlayer-
Mergi direct la: