World of Metin

[TUTORIAL]Cum sa creezi un HQ

View previous topic View next topic Go down

[TUTORIAL]Cum sa creezi un HQ

Post by A.Levine on Fri Sep 14, 2012 10:14 am

In acest tutorial va voi arata cum sa creezi un HQ pentru samp.

Prima data, intri in GM si cauti liniile:
Cod:
if(house == 241)//City Hall
{
SetPlayerInterior(i,0);
SetPlayerPos(i,1481.0566,-1770.9563,18.7958);
PlayerInfo[i][pInt] = 0;
PlayerInfo[i][pLocal] = 255;
}Dublezii liniile si in loc de "//City Hall" pui ce vrei tu, iar la SetPlayerPos pui asa:
Cod:
SetPlayerPos(i,x,y,z);
Apoi, sa creeam i-ul pe care se va intra.Cauti linia:
Cod:
AddStaticPickup(1239, 2, 1481.0566,-1770.9563,18.7958); //City Hallo dublezi, si in loc de "//City Hall" (fara ghilimele) pui ce vrei tu si vei avea asta:
Cod:
AddStaticPickup(1239, 2, x,y,z); //orice aici
Apoi, cauti liniile:
Cod:
if (PlayerToPoint(3.0, playerid,1481.0566,-1770.9563,18.7958))
{
SetPlayerInterior(playerid,id-ul interiorului (oricare vrei tu) );
SetPlayerPos(playerid,387.7978,173.8582,1008.3828);
GameTextForPlayer(playerid, "~w~Welcome to the City Hall", 5000, 1);
PlayerInfo[playerid][pInt] = id-ul interiorului(oricare vrei tu);
PlayerInfo[playerid][pLocal] = 241;
}
Le dublezi si in loc de
Cod:
if (PlayerToPoint(3.0, playerid,1481.0566,-1770.9563,18.7958)) pui coordonatele tale.

Apoi, la setplayerinterior pui id-ul interiorului tau (este aici) ori in joc scri /interior si /save pentru a afla coordonatele si interiorul.Apoi modifici playerinfo[playerid][pInt] = 3; cu interior id-ului si in loc de welcome to city hall pui orice.

Acum, sa facem si gametext-ul.Cauti liniile:
Cod:
else if (PlayerToPoint(3, i,1481.0566,-1770.9563,18.7958))
{
GameTextForPlayer(i, "~y~Welcome to the ~r~City Hall~n~~w~Type /enter to go in", 5000, 5);
}Le dublezi si in loc de PlayerToPoint pui asa PlayerToPoint(3, i, coordonatele tale)) si restul.

Acum, sa facem comanda de iesit.Cauti comanda "/exit" cu ghilimele, dai mai jos si gasesti asta:
Cod:
else if (PlayerToPoint(3.0, playerid,387.7978,173.8582,1008.3828))
{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,1481.0566,-1770.9563,18.7958);
PlayerInfo[playerid][pInt] = 0;
PlayerInfo[playerid][pLocal] = 255;
}
In loc de:
Cod:
else if (PlayerToPoint(3.0, playerid,387.7978,173.8582,1008.3828))pui asa
Cod:
else if (PlayerToPoint(3.0, playerid,coordonatele din interior))si in loc de:
Cod:
SetPlayerPos(playerid,1481.0566,-1770.9563,18.7958);pui:
Cod:
SetPlayerPos(playerid,coordonatele de afara);
Asta a fost, sper ca ati inteles, postati aici probleme/erori. Smile

A.Levine
Administrator
Administrator

Posts : 931
Reputation : 0
Join date : 19/10/2010
Age : 18
Location : Hunedoara

View user profile http://world-of-metin.big-forum.net

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum