Jump to content
  • 0

CreateHouse


wNekiRo

Question

15 answers to this question

Recommended Posts

  • 0
15 minutes ago, Exodus_xD said:

Am si eu o problema la comanda createhouse...

Sper ca ma poate ajuta cnv.

image.thumb.png.351ef06d8956c301555fd643bb97dade.png

Arata toata linia ca nu se vede 

 Încearcă să fii un om de valoare și nu neapărat un om de succes.

 

Link to comment
Share on other sites

  • 0
Chiar acum, KB.HERO a spus:

Arata toata linia ca nu se vede 

CMD:createhouse( playerid, params[ ] ) {
    if( PlayerInfo[ playerid ][ pAdmin ] < 6 )
        return SendClientMessage( playerid, -1, "Nu esti un administrator level 6+." );
    new type[ 15 ], house, inttype, level, price, Float: x, Float: y, Float: z; GetPlayerPos( playerid, x, y, z ); gString[ 0 ] = (EOS);
    if( sscanf( params, "s[15]dd", type, level, price ) )
    return SendClientMessage( playerid, -1, "{dd0808}Syntax:{ffffff} /createhouse [big | medium | small] [level] [price]" );
    if( strmatch( type, "big" ) ) house = random( 3 );
    else if( strmatch( type, "medium" ) ) house = random( 3 ) + 3;
    else if( strmatch( type, "small" ) ) house = random( 3 ) + 6;
    else return SendClientMessage( playerid, -1, "{dd0808}Syntax:{ffffff} /createhouse [big | medium | small] [level] [price]" );
    if( house >= 0 && house <= 2 ) inttype = 2;
    else if( house >= 3 && house <= 5 ) inttype = 1;
    else if( house >= 6 && house <= 8 ) inttype = 0;
    SCM( playerid, -1, "Processing..." );
    mysql_format( SQL, gString, sizeof gString, "INSERT INTO `houses` (`Entrancex` , `Entrancey` , `Entrancez` , `Exitx` , `Exity` , `Exitz` , `Interior`, `Level` , `Value`) VALUES ('%f', '%f', '%f', '%f', '%f', '%f', '%d', '%d', '%d') ", x, y, z, houseInterior[ house ][ 0 ], houseInterior[ house ][ 1 ], houseInterior[ house ][ 2 ], houseInteriorID[ house ], level, price );
    mysql_tquery( SQL, gString, "insertServerHouse", "dddddffffff", playerid, houseInteriorID[ house ], inttype, level, price, x, y, z, houseInterior[ house ][ 0 ], houseInterior[ house ][ 1 ], houseInterior[ house ][ 2 ] );
    return true; }

Link to comment
Share on other sites

  • 0

 Inlocuieste cu si vezi daca iti merge , daca nu revin-o cu un reply.

    mysql_format( SQL, gString, sizeof(gString), "INSERT INTO `houses` (`Entrancex` , `Entrancey` , `Entrancez` , `Exitx` , `Exity` , `Exitz` , `Interior`, `Level` , `Value`) VALUES ('%f', '%f', '%f', '%f', '%f', '%f', '%d', '%d', '%d') ", x, y, z, houseInterior[ house ][ 0 ], houseInterior[ house ][ 1 ], houseInterior[ house ][ 2 ], houseInteriorID[ house ], level, price );

 

 

vldgIri.png

YouTube : Click Redirect Channel

Discord : Arabu#9330

Canal Discord : Click To Join

Facebook : Click Facebook

Instagram : Click Instagram

Skype : Mita.Official

Respectă și vei fi respectat !

Link to comment
Share on other sites

  • 0
Chiar acum, Marlboro a spus:

 Inlocuieste cu si vezi daca iti merge , daca nu revin-o cu un reply.


    mysql_format( SQL, gString, sizeof(gString), "INSERT INTO `houses` (`Entrancex` , `Entrancey` , `Entrancez` , `Exitx` , `Exity` , `Exitz` , `Interior`, `Level` , `Value`) VALUES ('%f', '%f', '%f', '%f', '%f', '%f', '%d', '%d', '%d') ", x, y, z, houseInterior[ house ][ 0 ], houseInterior[ house ][ 1 ], houseInterior[ house ][ 2 ], houseInteriorID[ house ], level, price );

 

image.thumb.png.e8ba02bc50e42429267297ab3f051a17.png

Link to comment
Share on other sites

  • 0
Chiar acum, Marlboro a spus:

Incearca asa 


mysql_format(gString, sizeof(gString), "INSERT INTO `houses` (`Entrancex` , `Entrancey` , `Entrancez` , `Exitx` , `Exity` , `Exitz` , `Interior`, `Level` , `Value`) VALUES ('%f', '%f', '%f', '%f', '%f', '%f', '%d', '%d', '%d') ", x, y, z, houseInterior[ house ][ 0 ], houseInterior[ house ][ 1 ], houseInterior[ house ][ 2 ], houseInteriorID[ house ], level, price );

 

image.thumb.png.243363b648e48037f5ad60552f020b43.png

Link to comment
Share on other sites

  • 0
1 oră în urmă, Exodus_xD a spus:

Nu ma poate ajuta nimeni? ...

mysql_format(SQL,gString, sizeof(gString), "INSERT INTO `houses` (`Entrancex` , `Entrancey` , `Entrancez` , `Exitx` , `Exity` , `Exitz` , `Interior`, `Level` , `Value`) VALUES ('%f', '%f', '%f', '%f', '%f', '%f', '%d', '%d', '%d') ", x, y, z, houseInterior[ house ][ 0 ], houseInterior[ house ][ 1 ], houseInterior[ house ][ 2 ], houseInteriorID[ house ], level, price );//Nu ai pus handle. Din cate stiu eu pe burned se numeste SQL
Link to comment
Share on other sites

  • 0
Chiar acum, valivaly96 a spus:

mysql_format(SQL,gString, sizeof(gString), "INSERT INTO `houses` (`Entrancex` , `Entrancey` , `Entrancez` , `Exitx` , `Exity` , `Exitz` , `Interior`, `Level` , `Value`) VALUES ('%f', '%f', '%f', '%f', '%f', '%f', '%d', '%d', '%d') ", x, y, z, houseInterior[ house ][ 0 ], houseInterior[ house ][ 1 ], houseInterior[ house ][ 2 ], houseInteriorID[ house ], level, price );//Nu ai pus handle. Din cate stiu eu pe burned se numeste SQL

nu stiu de la ce e pornit gmu' asta,l-am cumparat de la @DrooM. cu 10 euro.

Link to comment
Share on other sites

  • 0
#define houseInterior

Si cu asta ti-am spus toata problema

Nu poti defini asa un Array 2D (din ce vad eu) si stiu sigur ca ai copiat-o de undeva doar ca ai ratat parti importante. Sau daca as l-ai cumparat, atunci imi pare rau dar ti-a dat putin de munca

Si din pacate nu ma pot gandi cum ar putea fi scris acel array

enum e_houseInterior{
	Float:x,
	Float:y,
	Float:z
};
houseInterior[MAX_HOUSES][e_houseInterior];

Ceva de genu din ce vad eu in codul tau

Edit: Daca ma gandesc mai bine, acel enum poate sa fie array la randu lui care contine coordonatele interioarelor. Habar nu am

Edit2: Acel houseInterior poate arata in asa multe moduri, ce ti-am dat poate sa fie deasemenea gresit

Edited by Banditul
Link to comment
Share on other sites

  • 0
Chiar acum, Banditul a spus:

#define houseInterior

Si cu asta ti-am spus toata problema

Nu poti defini asa un Array 2D (din ce vad eu) si stiu sigur ca ai copiat-o de undeva doar ca ai ratat parti importante. Sau daca as l-ai cumparat, atunci imi pare rau dar ti-a dat putin de munca

Si din pacate nu ma pot gandi cum ar putea fi scris acel array


enum e_houseInterior{
	Float:x,
	Float:y,
	Float:z
};
houseInterior[MAX_HOUSES][e_houseInterior];

Ceva de genu din ce vad eu in codul tau

Edit: Daca ma gandesc mai bine, acel enum poate sa fie array la randu lui care contine coordonatele interioarelor. Habar nu am

Edit2: Acel houseInterior poate arata in asa multe moduri, ce ti-am dat poate sa fie deasemenea gresit

man...ma bucur intr-un fel ca incerci sa ma ajuti dar singura mea problema e ca sunt incepator,intelegi? mai fac eu una alta nu-s chiar prost... dar totusi nu stiu multe,intelegi?

Link to comment
Share on other sites

  • 0

C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40815) : error 010: invalid function or declaration
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40821) : warning 219: local variable "x" shadows a variable at a preceding level
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40821) : warning 219: local variable "y" shadows a variable at a preceding level
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40821) : warning 219: local variable "z" shadows a variable at a preceding level
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40821) : error 035: argument type mismatch (argument 2)
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40832) : error 076: syntax error in the expression, or invalid function call
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40832) : error 017: undefined symbol "houseInterior"
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40832) : error 029: invalid expression, assumed zero
C:\Users\Cht\Desktop\GM 10 EURO\gamemodes\RPG.pwn(40832) : fatal error 107: too many error messages on one line
 

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • 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.