Jump to content
  • 0

Problema comanda Bullhorn


Adrian FW

Question

 

Am creat comanda Bullhorn , sa imi ataseze de masina niste coarne . Dar nu apar . 

YCMD:bullhorn(playerid, params[], help) {
    if(!IsPlayerInAnyVehicle(playerid)) return SCM(playerid, COLOR_GREY, "Nu esti in vehiculul tau.");
    if(PersonalCar(playerid) == -1) return SCM(playerid, COLOR_LGREEN, "Eroare: Nu esti in unul dintre vehiculele tale personale!");
    if(GetPlayerState(playerid) != 2) return SCM(playerid, COLOR_LGREEN, "* Trebuie sa fii la volan pentru a putea folosi aceasta comanda!");
    if(PlayerInfo[playerid][pVip] == 1) return 1;
    if(!IsPlayerInAnyVehicle(playerid)) return 1;
    if(InRaceArena[playerid] == 1 && PlayerInfo[playerid][pAdmin] < 1) return SCM(playerid, COLOR_LGREEN, "Nu ai voie sa folosesti aceasta comanda atata timp cat esti in arena de curse!");
    new vehicleid = GetPlayerVehicleID(playerid);
    new object1 = CreateObject(19314, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0);
    new object2 = CreateObject(19314, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0);
    AttachObjectToVehicle(object1, vehicleid, 206.44, 1767.66, 17.38,0.000000,0.000000,0.000000);
    AttachObjectToVehicle(object2, vehicleid, 206.44, 1767.66, 17.38,0.000000,0.000000,0.000000);
    SCM(playerid, COLOR_YELLOW, "Comanda executata cu succes.");
    return 1;
}

Link to comment
Share on other sites

7 answers to this question

Recommended Posts

  • 0

salut, 

AttachObjectToVehicle(object1, vehicleid, 206.44, 1767.66, 17.38,0.000000,0.000000,0.000000);

coordonatele tale sunt mult prea mari nu stiu de unde ai luat tu aceste valori 206.44, 1767.66, 17.38,

intra in map editor creaza o masina la coordonatele 0 0 0 x y si z si acolo creezi obiectele atasate pe masina si acelea sunt coordonatele de care ai nevoie

 

Mutat la categoria corespunzatoare data viitoare ai grija unde postezi

 

    __  ____      __           
   /  |/  (_)____/ /____  _____
  / /|_/ / / ___/ __/ _ \/ ___/
 / /  / / (__  ) /_/  __/ /    
/_/  /_/_/____/\__/\___/_/     
SERVICII SCRIPTING DE CALITATE
Pagina     Scripting     pawn
Link to comment
Share on other sites

  • 0
1 minute ago, Mister said:


    salut

AttachObjectToVehicle(object1, vehicleid, 206.44, 1767.66, 17.38,0.000000,0.000000,0.000000);

coordonatele tale sunt mult prea mari nu stiu de unde ai luat tu aceste valori 206.44, 1767.66, 17.38,

intra in map editor creaza o masina la coordonatele 0 0 0 x y si z si acolo creezi obiectele atasate pe masina si acelea sunt coordonatele de care ai nevoie

Coordonatele le*am luat cu map editor

 

Link to comment
Share on other sites

  • 0
3 minutes ago, Adrian FW said:

Coordonatele le*am luat cu map editor

 

iar eu iti spun ca nu sunt bune,206.44, 1767.66, 17.38

206 inseamna ca e la 206 distanta x fata de vehicul, 1767 inseamna ca este la 1767 de metri distanta fata de vehicul si z la fel deci faci cum ti  am spus eu va merge, refa coorodnatele in map editor cu o masina la coordonatele 0 0 0 si obiectele atasate le pui pe ea si de acolo iei coordonatele

 

    __  ____      __           
   /  |/  (_)____/ /____  _____
  / /|_/ / / ___/ __/ _ \/ ___/
 / /  / / (__  ) /_/  __/ /    
/_/  /_/_/____/\__/\___/_/     
SERVICII SCRIPTING DE CALITATE
Pagina     Scripting     pawn
Link to comment
Share on other sites

  • 0
9 minutes ago, Mister said:

iar eu iti spun ca nu sunt bune,206.44, 1767.66, 17.38

206 inseamna ca e la 206 distanta x fata de vehicul, 1767 inseamna ca este la 1767 de metri distanta fata de vehicul si z la fel deci fa cum ti  am spus eu refa coorodnatele in map editor cu o masina la coordonatele 0 0 0 si obiectele atasate le pui pe ea si de acolo iei coordonatele

https://imgur.com/a/K1jvXU9 - La fel

Link to comment
Share on other sites

  • 0
2 minutes ago, Adrian FW said:

nu ai facut nimic, in dreapta acolo scrie 0 0 0 la coordonatele x y z? nu, scrie -77 2067 si  16.9

 

    __  ____      __           
   /  |/  (_)____/ /____  _____
  / /|_/ / / ___/ __/ _ \/ ___/
 / /  / / (__  ) /_/  __/ /    
/_/  /_/_/____/\__/\___/_/     
SERVICII SCRIPTING DE CALITATE
Pagina     Scripting     pawn
Link to comment
Share on other sites

  • 0
Acum 1 oră, Adrian FW a spus:

Nush frate , nu ma prea pricep . Mersi oricum 

Trebuiesc niste coordonate offset.practic indepartezi obiectele de masina cu cat ai tu pus pe x,y,z.

Iti dau ca exemplu yrmatoarele comezi pt a aseza pe masina textul vip in functie de masina. coordonatele difera de la masina la masina deoarece au forme diferite

CMD:xpos(playerid, params[]) {
	if(sscanf(params, "f", VipPos[0])) return 1;
	DestroyDynamicObject(VipText);
	VipText = CreateDynamicObject(1463, -2597.0762, -2638.4270, -5.3536, -87.6999, 90.4001, -87.1805);
	AttachDynamicObjectToVehicle(VipText, GetPlayerVehicleID(playerid), VipPos[0], VipPos[1], VipPos[2], 0.0, 0.0, 0.0);
	return 1;
}

CMD:ypos(playerid, params[]) {
	if(sscanf(params, "f", VipPos[1])) return 1;
	DestroyDynamicObject(VipText);
	VipText = CreateDynamicObject(1463, -2597.0762, -2638.4270, -5.3536, -87.6999, 90.4001, -87.1805);
	AttachDynamicObjectToVehicle(VipText, GetPlayerVehicleID(playerid), VipPos[0], VipPos[1], VipPos[2], 0.0, 0.0, 0.0);
	return 1;
}

CMD:zpos(playerid, params[]) {
	if(sscanf(params, "f", VipPos[2])) return 1;
	DestroyDynamicObject(VipText);
	VipText = CreateDynamicObject(1463, -2597.0762, -2638.4270, -5.3536, -87.6999, 90.4001, -87.1805);
	AttachDynamicObjectToVehicle(VipText, GetPlayerVehicleID(playerid), VipPos[0], VipPos[1], VipPos[2], 0.0, 0.0, 0.0);
	return 1;
}

 

Edited by valivaly96
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.