[Tutorial] Adding Custom MTA Mappings to SAMP [Beginners]
#1

Alright, Before you post "There are alot of tutorials like that", All I've seen are Horrible ones and definetly not explained well, and I've seen alot of People lately, asking how to add em, and how to Convert em.

Step 1: Getting the .map file.
  • After you're done with mapping your custom map, you will need the .map file to be able to convert it.
  • You will need to goto Your MTA folder > mods > deathmatch, there you will be able to find the .map file you mapped.
Step 2: Converting.
  • Alright, so after getting into your folder where the .map file is located, right click on it, and Open it using Notepad.
  • After you do, you will need to copy EVERYTHING inside the notepad, Then when you copy it, goto www.convertFFS.com
  • When you get on convertFFS, you'll see a HUGE text saying: PASTE HERE, paste what you copied from the notepad there, and then click the convert tab under it.

    Screen:

Step 3: Getting the Converted code.
  • After you've pressed on the Convert button, you'll get something like this:
  • Click on "Select all of the output", and copy the code.
Step 4: Pasting it in your script.
  • After copying the code, open your .pwn script and paste your custom map code you just copied under OnGameModeInit, If you wanna use it in a Filterscript, then put it under OnFilterScriptInit.
-If Gamemode:

PHP код:
public OnGameModeInit()
{
    
// The CreateObject codes goes here.
    
return 1;

-If Filterscript:

PHP код:
public OnFilterScriptInit()
{
    
// The CreateObject codes goes here.
    
return 1;

  • Compile the script and You're done.

Additional Stuff.

Since SA-MP has limited using CreateObjects, you might wanna use the Streamer Plugin, which is found Here.
  1. After downloading it, Copy the Streamer.inc to your pawno > Includes folder.
  2. Get on your .pwn script and add this the top of your script, right under #include <a_samp>
PHP код:
#include <streamer> 
  1. After including it, copy the streamer.dll (if the host is Windows), or the streamer.so (if the host is Linux), and paste it in the plugins folder, in your server's file.
  2. Finally, open your server.cfg and add this:
If Windows:

Код:
plugins Streamer
If Linux:

Код:
plugins Streamer.so - Don't forget the .so
At Last, you've got Streamer now, and you will be able to use Shitloads of objects.

For the last task, get on your script again and change the codes:

PHP код:
CreateObject(modelidFloat:XFloat:YFloat:ZFloat:rXFloat:rYFloat:rZFloat:DrawDistance
To

PHP код:
CreateDynamicObject(modelidFloat:XFloat:YFloat:ZFloat:rXFloat:rYFloat:rZFloat:DrawDistance
This Tutorial, is based for Beginners, and to lack headaches going on over "Scripting Discussions".

Credits: Incognito For Streamer.
Reply
#2

Good for the beginners .
Reply
#3

Quote:
Originally Posted by Darnell
Посмотреть сообщение
Good for the beginners .
Yep, and i think you've seen the spamming going on the forums for map adding.
Reply
#4

I would give you +1,but they dont let me ^^

good job
Reply
#5

Nice!
Reply
#6

Neat, perferably use pawn tags instead of php tags? It'd be much easier to read since I'm not familiar with the php syntax.
Reply
#7

Quote:
Originally Posted by =WoR=Bruno
Посмотреть сообщение
I would give you +1,but they dont let me ^^

good job
Lol.

Quote:
Originally Posted by Kush
Посмотреть сообщение
Nice!
Yep, Thanks ^^.


Quote:
Originally Posted by Lorenc_
Посмотреть сообщение
Neat, perferably use pawn tags instead of php tags? It'd be much easier to read since I'm not familiar with the php syntax.
I never use [ pawn ] [/ pawn ], Thanks to Kush.
Reply
#8

Nice mate.
Reply
#9

Quote:
Originally Posted by Jafet_Macario
Посмотреть сообщение
Nice mate.
Thank You.
Reply
#10

I've been looking out for this only in my last few posts and didn't saw you had uploaded it as a tut so thanks and NICE work
Reply
#11

THX! DD
Reply
#12

Thanks.... its helping me
Reply
#13

I get this:
Quote:

C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(1) : warning 235: public function lacks forward declaration (symbol "OnFilterScriptInit")
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(3) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(4) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(5) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(6) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(7) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn( : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(9) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(10) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(11) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(12) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(13) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(14) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(15) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(16) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(17) : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(1 : error 017: undefined symbol "CreateObject"
C:\Users\Jeremy\Desktop\World European Trucking Server\filterscripts\maps.pwn(19) : error 017: undefined symbol "CreateObject"

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)