Szerző Téma: CreateDynamic3DTextLabel  (Megtekintve 2698 alkalommal)

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Dátum: 2013. Október 30. - 15:21:54 »
0 Show voters
Csáó.
Az miért van, hogy a CreateDynamic3DTextLabel funkció nem jó?
Pontosabban a funkció jó, csak a játékban nem jeleníti meg.
Üdv,
Live

CreateDynamic3DTextLabel
« Válasz #1 Dátum: 2013. Október 30. - 17:16:46 »
0 Show voters
Nekem is volt ilyen, nem foglalkoztam vele, használtam a sima Create3DText-et. Amikor új modot kezdtem írni, már mûködött... Lehet frissíteni kellene a streamer pluginodat vagy ellenõrizni, hogy pluginoknál bent van-e a server.cfg-ben/header file a modoban. Tehát
 #include 

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #2 Dátum: 2013. Október 30. - 18:12:20 »
0 Show voters
A legfrissebb van és a server.cfg-ben is benne van a plugins streamer, és a módban is a #include

CreateDynamic3DTextLabel
« Válasz #3 Dátum: 2013. Október 31. - 08:43:16 »
0 Show voters

Próbáld meg a OnPlayerSpawn alá berakni nekem mûködött
 
[/quote]
Asd, gondolkozz már el rajta, hogy mit mondassz!  :facepalm:
Minden spawnnál hozzon létre egyet?Meg amúgy is, attol h spawnhoz rakja nem fog megjavulni.
BnK, esetleg bemásolhatnád a kòdot,lehet csak te ìrtál el egy paramètert. ;)

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #4 Dátum: 2013. Október 31. - 18:35:49 »
0 Show voters
Az a baj, hogy eddig amiket létrehoztam 3Dtexteket nem hozta létre :d
 

Property[PropertyID][infos] = CreateDynamic3DTextLabel(string, -1, Property[PropertyID][EnterX], Property[PropertyID][EnterY], Property[PropertyID][EnterZ], 20, 0, 0);

Nem elérhető Dfoglalo

  • 4069
  • Globális Moderátor
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #5 Dátum: 2013. Október 31. - 18:43:54 »
0 Show voters

Az a baj, hogy eddig amiket létrehoztam 3Dtexteket nem hozta létre :d
 

Property[PropertyID][infos] = CreateDynamic3DTextLabel(string, -1, Property[PropertyID][EnterX], Property[PropertyID][EnterY], Property[PropertyID][EnterZ], 20, 0, 0);

 

[/quote]
A végén a 20,0,0 mire akar vonatkozni? Mert ott még rengeteg érték lehet.
 
CreateDynamic3DTextLabel(const text[], color, Float:x, Float:y, Float:z, Float:drawdistance, attachedplayer = INVALID_PLAYER_ID, attachedvehicle = INVALID_VEHICLE_ID, testlos = 0, worldid = -1, interiorid = -1, playerid = -1, Float:distance = 100.0);

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #6 Dátum: 2013. Október 31. - 18:56:41 »
0 Show voters
Nem tom xDD
Ha valamit nem használok a végén akkor írjak -1 -et?

Nem elérhető Dfoglalo

  • 4069
  • Globális Moderátor
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #7 Dátum: 2013. Október 31. - 20:12:09 »
0 Show voters
Próbáld meg így.
 
Property[PropertyID][infos] = CreateDynamic3DTextLabel(string, -1, Property[PropertyID][EnterX], Property[PropertyID][EnterY], Property[PropertyID][EnterZ], 10, 5, -1, 50.0); // Így a 10-es VW-ben, és az 5-ös Interiorban lesz látható.

 
Vagy így.
 
Property[PropertyID][infos] = CreateDynamic3DTextLabel(string, -1, Property[PropertyID][EnterX], Property[PropertyID][EnterY], Property[PropertyID][EnterZ], -1, -1, -1, 50.0); // Így elméletileg minden VW-ben és Interiorban látható lesz (vagy csak az alapértelmezettben (?)), 50-es körzetben.

 
A -1 minden esetben a playerid-t jelenti, ez esetben -1-et, azaz minden playerid-t.

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #8 Dátum: 2013. Október 31. - 20:19:31 »
0 Show voters
Még 1 kérdés:
Létrehozom a pickupot:
 

Property[PropertyID][Pickup] = CreateDynamicPickup(1272, 23, Property[PropertyID][EnterX], Property[PropertyID][EnterY], Property[PropertyID][EnterZ], -1, -1, -1);

 
...és akkor ez miért nem jó (nem érzékeli, hogy benne van a pickupban):
 

public OnPlayerPickUpPickup(playerid, pickupid) {
new id = Which_Property(playerid);
if(pickupid == Property[id][Pickup]) {
if(strcmp(Property[id][Owner], GetName(playerid), false)) {
    new string[500];
    if(Property[id][Price] == 0) {
       format(string, sizeof(string), \"{FF4646}Tulajdonos: {DDDDDD}%s\\nID: %i\", Property[id][Owner], id);
              ShowPlayerDialog(playerid, DIALOG_HOUSE_MENU, DIALOG_STYLE_LIST, \"{FFCC22}Ingatlan információk\", string, \"Bemegy\", \"Mégsem\");
    } else {
       format(string, sizeof(string), \"{FF4646}Tulajdonos: {DDDDDD}-\\nÁr: {33AA33}${DDDDDD}%i\", Property[id][Price]);
              ShowPlayerDialog(playerid, DIALOG_HOUSE_MENU, DIALOG_STYLE_LIST, \"{FFCC22}Ingatlan információk\", string, \"Megvesz\", \"Mégsem\");
    }
}
}
return 1;
}

 
EDIT:
Az elõzõre amit mutattál, hogy próbáljam, azokra Tag Mismatchot ír.
« Utoljára szerkesztve: 2013. Október 31. - 20:22:07 írta BnK' »

Nem elérhető Dfoglalo

  • 4069
  • Globális Moderátor
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #9 Dátum: 2013. Október 31. - 20:25:30 »
0 Show voters
A tag akármi szar errorra: a Property[PropertyID][Pickup]-ot amikor létrehozod, írj elé Text3D:-t, pl.
 
new Text3D:Property[1000][1000]

 
A pickuposhoz pedig nyomass be jó pár printf függvényt, hogy lásd, meddig jut el - majd közöld a kedves fórumozókkal az eredményt.

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #10 Dátum: 2013. Október 31. - 20:29:02 »
0 Show voters
Text3D-nél nekem enumban van így:
 

enum house {
ID,
Owner[MAX_PLAYER_NAME],
Interior,
Price,
VirtualWorld,
Float:EnterX,
Float:EnterY,
Float:EnterZ,
Pickup,
MapIcon,
Text3D:Infos,
Float:ExitX,
Float:ExitY,
Float:ExitZ,
Door,
InteriorStyle
}

Nem elérhető Dfoglalo

  • 4069
  • Globális Moderátor
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #11 Dátum: 2013. Október 31. - 20:32:00 »
0 Show voters
Az nem akadály, akkor oda beírod. Csak nem kell a new. Ott van egy hasonló benne:
 

Text3D-nél nekem enumban van így:
 

enum house {
Text3D:Infos
}

 

[/quote]
Meg a floatok is ilyen típusúak:
 

Text3D-nél nekem enumban van így:
 

enum house {
Float:EnterX,
Float:EnterY,
Float:EnterZ,
Float:ExitX,
Float:ExitY,
Float:ExitZ
}

 

[/quote]
Tehát akkor ezt is így kell:
 

Text3D-nél nekem enumban van így:
 

enum house {
ID,
Owner[MAX_PLAYER_NAME],
Interior,
Price,
VirtualWorld,
Float:EnterX,
Float:EnterY,
Float:EnterZ,
Pickup,
MapIcon,
Text3D:Infos,
Float:ExitX,
Float:ExitY,
Float:ExitZ,
Door,
InteriorStyle,
       Text3D:Property[1000][1000] // Az 1000 csak példa, nem tudom nálad hogy-smint van megadva
}

 

[/quote]

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #12 Dátum: 2013. Október 31. - 20:36:37 »
0 Show voters
Pickupos dolog:
 

public OnPlayerPickUpPickup(playerid, pickupid) {
print(\"1\");
new id = Which_Property(playerid);
print(\"2\");
if(pickupid == Property[id][Pickup]) {
print(\"3\");
if(strcmp(Property[id][Owner], GetName(playerid), false)) {
print(\"4\");
    new string[500];
    print(\"5\");
    if(Property[id][Price] == 0) {
    print(\"6\");
       format(string, sizeof(string), \"{FF4646}Tulajdonos: {DDDDDD}%s\\nID: %i\", Property[id][Owner], id);
               print(\"7\");
         ShowPlayerDialog(playerid, DIALOG_HOUSE_MENU, DIALOG_STYLE_LIST, \"{FFCC22}Ingatlan információk\", string, \"Bemegy\", \"Mégsem\");
                   print(\"8\");
   } else {
      print(\"9\");
       format(string, sizeof(string), \"{FF4646}Tulajdonos: {DDDDDD}-\\nÁr: {33AA33}${DDDDDD}%i\", Property[id][Price]);
                   print(\"10\");
         ShowPlayerDialog(playerid, DIALOG_HOUSE_MENU, DIALOG_STYLE_LIST, \"{FFCC22}Ingatlan információk\", string, \"Megvesz\", \"Mégsem\");
                       print(\"11\");
   }
   print(\"12\");
}
print(\"13\");
}
print(\"14\");
return 1;
}

 
2-ig jutott el :D
A 3DText még mindig nem jó  :D
Te nem tudom, hogy gondoltad a 3DTextes cuccot.
Nekem ez így van:
 

enum house {
ID,
Owner[MAX_PLAYER_NAME],
Interior,
Price,
VirtualWorld,
Float:EnterX,
Float:EnterY,
Float:EnterZ,
Pickup,
MapIcon,
Text3D:Infos,
Float:ExitX,
Float:ExitY,
Float:ExitZ,
Door,
InteriorStyle
}
new
Property[MAX_HOUSES][house];

 
A Property a házakra utal.
« Utoljára szerkesztve: 2013. Október 31. - 20:45:45 írta BnK' »

Nem elérhető jana4

  • 5929
  • Ex Staff
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #13 Dátum: 2013. Október 31. - 20:45:04 »
0 Show voters
Live, vezesd végig a paramétereket 3D Text-nél, lehet ott gabalyodik össze. (Tapasztalat.)

A pickupos dolog pedig:


Használd ezt az eljárást az alap helyett: OnPlayerPickUpDynamicPickup(playerid, pickupid)

Nem elérhető Live

  • 507
    • Profil megtekintése
CreateDynamic3DTextLabel
« Válasz #14 Dátum: 2013. Október 31. - 20:47:41 »
0 Show voters
A helyzet nem változott egyiknél sem.

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal