Jump to content
  • 0
Sign in to follow this  
Ghost.

Problema CreateDynamic3DTextLabel

Question

Hey Salut all, am si eu o problema la functia "CreateDynamic3DTextLabel" - La Load -ul de la Case & Biz (Nu vrea sa apara primul 3d text label la care ma apropi, si daca de exemplu daca mai e un label langa el, ala apare..

function LoadProps()
{
    new Field[24], Field2[24], X, Rows, Fields, String[1024], ExpiredCount; cache_get_data(Rows, Fields, SQL);
    new lvlstring[123];
    //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    for(new i = 0; i < Rows; i++)
    {
        X = CACHE(i, "ID", SQL);
        //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
        CONTENT(i, "PropName", Field, SQL);
		format(PropInfo[X][PropName], 24, "%s", Field);
        //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		CONTENT(i, "PropOwner", Field2, SQL);
		format(PropInfo[X][PropOwner], 24, "%s", Field2);
        //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		PropInfo[X][PropX] = FLOAT(i, "PosX", SQL);
        PropInfo[X][PropY] = FLOAT(i, "PosY", SQL);
        PropInfo[X][PropZ] = FLOAT(i, "PosZ", SQL);
        //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
        PropInfo[X][InteriorX] = FLOAT(i, "IntX", SQL);
        PropInfo[X][InteriorY] = FLOAT(i, "IntY", SQL);
		PropInfo[X][InteriorZ] = FLOAT(i, "IntZ", SQL);
		//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		PropInfo[X][IntID] = CACHE(i, "Interior", SQL);
		PropInfo[X][p_Level] = CACHE(i, "Level", SQL);
		//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		PropInfo[X][Cost] = CACHE(i, "PropCost", SQL);
		PropInfo[X][CostM] = CACHE(i, "PropCostM", SQL);
		//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		PropInfo[X][PTime] = CACHE(i, "PropTime", SQL);
		//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		PropInfo[X][Earning] = CACHE(i, "PropEarning", SQL);
		PropInfo[X][EarningM] = CACHE(i, "PropEarningM", SQL);
        //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
        if(PropInfo[X][p_Level] == 1) lvlstring = "{FF9900}Standard";
		if(PropInfo[X][p_Level] == 2) lvlstring = "{FF0000}Premium";
		//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
        if(strcmp(PropInfo[X][PropOwner], "Nobody", true) == 0)
        {
            PropInfo[X][PropMapIcon] = CreateDynamicMapIcon(PropInfo[X][PropX], PropInfo[X][PropY], PropInfo[X][PropZ], 52, 52);
			format(String, sizeof(String), "{9C9621}\"%s\"\n{9C9621}Property is For Sale\n{2982FF}Cost: {00FF22}%d coins and $%d\n{2982FF}Win: {00FF22}%d coins and $%d\n{DE00BD}/business", PropInfo[X][PropName], PropInfo[X][Cost], PropInfo[X][CostM], PropInfo[X][Earning], PropInfo[X][EarningM]);
		}
		else
		{
		    PropInfo[X][PropMapIcon] = CreateDynamicMapIcon(PropInfo[X][PropX], PropInfo[X][PropY], PropInfo[X][PropZ], 36, 36);
			format(String, sizeof(String), "{9C9621}\"%s\"\n{2982FF}Business Owner: {00FF22}%s\n{2982FF}Business Level: %s\n\n{2982FF}Cost: {00FF22}%d coins and $%d\n{2982FF}Win: {00FF22}%d coins and $%d\n{DE00BD}/business", PropInfo[X][PropName], PropInfo[X][PropOwner], lvlstring, PropInfo[X][Cost], PropInfo[X][CostM], PropInfo[X][Earning], PropInfo[X][EarningM]);
		}
		Prop3D[X] = CreateDynamic3DTextLabel(String, ~1, PropInfo[X][PropX], PropInfo[X][PropY], PropInfo[X][PropZ], 30.0);
        PropPickUP[X] = CreateDynamicPickup(1274, 1, PropInfo[X][PropX], PropInfo[X][PropY], PropInfo[X][PropZ]);
        //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		if(strcmp(PropInfo[X][PropOwner], "Nobody", true) != 0 && PropInfo[X][PTime] < gettime())
        {
		     format(PropInfo[X][PropName], 24, "ForSale"), 	format(PropInfo[X][PropOwner], 24, "Nobody");
	         //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
	         DestroyDynamicMapIcon(PropInfo[X][PropMapIcon]);
	         //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
		     PropInfo[X][PropMapIcon] = CreateDynamicMapIcon(PropInfo[X][PropX], PropInfo[X][PropY], PropInfo[X][PropZ], 52, 52);
	         //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
		     format(String, sizeof(String), "{9C9621}\"%s\"\n{9C9621}Business is For Sale\n{2982FF}Cost: {00FF22}%d Coins and $%d\n{2982FF}Win: {00FF22}%d Coins and $%d\n{DE00BD}/business", PropInfo[X][PropName], PropInfo[X][Cost], PropInfo[X][CostM], PropInfo[X][Earning], PropInfo[X][EarningM]);
	         //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
	         UpdateDynamic3DTextLabelText(Prop3D[X], ~1, String);
	         //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
	         format(eQuery, 512, "UPDATE `Properties` SET `PropOwner` = 'Nobody', `PropName` = 'ForSale', `PropTime` = '0' WHERE `ID` = '%d'", X);
		     mysql_tquery(SQL, eQuery, "", "");
		     //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
		     format(eQuery, sizeof(eQuery), "UPDATE `Accounts` SET `Property` = '0' WHERE `Property` = %d", X);
		     mysql_tquery(SQL, eQuery, "", "");
		     //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
		     PropInfo[X][PTime] = 0, ExpiredCount++;
        }
	}
	printf("Loaded %d Properties and %d reseted!", Rows, ExpiredCount);
	return true;
}

 Aic de exemplu, nu apare deloc: image.thumb.png.40332d92d486066e9467b4cb915e701c.png

Edited by Ghost.

Share this post


Link to post
Share on other sites

11 answers to this question

Recommended Posts

  • 0
  • 0
  • 0

Nop, nu i asta problema, am incercat deja alea, inainte sa fac post-ul aceasta.

Edited by Ghost.

Share this post


Link to post
Share on other sites
  • 0
  • 0
  • 0

image.thumb.png.b89a94f4a9fca61a5cc611bd355b04fa.png

E un bug, daca ma apropri de primul 3dtext . ala nu imi apare, doar ala care e langa el...
Adica plm, oare ar cauza ceva din gm ? Ce pareri aveti ?

Edited by Ghost.

Share this post


Link to post
Share on other sites
  • 0
  • 0

La Create3DTextLabel e limita... [700 3d text max] -> eu am vr-o 1500 la house

Edited by Ghost.

Share this post


Link to post
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.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...

Important Information

This site uses cookies. By continuing browsing, you agree to the use of this information. For more details, see Terms of Use and Privacy Policy.