PDA

View Full Version : unknown command


shourya
07/07/2015, 02:12 AM
[07:25:17] [debug] #0 0003325c in ?? () from CnR.amx
[07:25:17] [debug] #1 000a6ad4 in public cmd_findhouse () from CnR.amx
[07:25:17] [debug] #2 native CallLocalFunction () [00474110] from samp-server.exe
[07:25:17] [debug] #3 00004360 in public OnPlayerCommandText () from CnR.amx


findhouse command not working

shourya
07/07/2015, 01:52 PM
help me plz

SecretBoss
07/07/2015, 02:19 PM
This is just your server's logs, we can't do anything with it we need the whole script

Bingo
07/07/2015, 02:48 PM
This is just your server's logs, we can't do anything with it we need the whole script

Why'd you need the whole script instead of the callback function?

Post your house loading function.

SecretBoss
07/07/2015, 02:50 PM
Why'd you need the whole script instead of the callback function?

Post your house loading function.

it was just an example

shourya
08/07/2015, 01:04 AM
Why'd you need the whole script instead of the callback function?

Post your house loading function.
hi bingo

public load_houses()
{
new DBResult:qresult, count = 0, value[328];
if(!db_query(DB: HOUSEDB, "SELECT * FROM `house_data`"))
{
print("HOUSE SYSTEM :: No houses were found in \"Houses.db\" :: 0 Loaded");
}
else
{
qresult = db_query(DB: HOUSEDB, "SELECT * FROM `house_data`");
count = db_num_rows(qresult);
for(new i = 0; i < count; i++)
{
if(count <= MAX_SCRIPT_HOUSES)
{

db_get_field_assoc(qresult, "house_id", value, 5);
houseStuff[i][house_id] = strval(value);

db_get_field_assoc(qresult, "house_owner", value, 48);
format(houseStuff[i][house_owner], 48, value);

db_get_field_assoc(qresult, "house_password", value, 48);
format(houseStuff[i][house_password], 48, value);

db_get_field_assoc(qresult, "house_title", value, 48);
format(houseStuff[i][house_title], 48, value);

db_get_field_assoc(qresult, "house_bought", value, 20);
houseStuff[i][house_bought] = strval(value);

db_get_field_assoc(qresult, "house_price", value, 20);
houseStuff[i][house_price] = strval(value);

db_get_field_assoc(qresult, "houseX", value, 20);
houseStuff[i][houseX] = floatstr(value);

db_get_field_assoc(qresult, "houseY", value, 20);
houseStuff[i][houseY] = floatstr(value);

db_get_field_assoc(qresult, "houseZ", value, 20);
houseStuff[i][houseZ] = floatstr(value);

db_get_field_assoc(qresult, "interiorX", value, 20);
houseStuff[i][interiorX] = floatstr(value);

db_get_field_assoc(qresult, "interiorY", value, 20);
houseStuff[i][interiorY] = floatstr(value);

db_get_field_assoc(qresult, "interiorZ", value, 20);
houseStuff[i][interiorZ] = floatstr(value);

db_get_field_assoc(qresult, "interiorAngle", value, 20);
houseStuff[i][interiorA] = floatstr(value);

db_get_field_assoc(qresult, "interiorID", value, 20);
houseStuff[i][interiorID] = strval(value);

db_get_field_assoc(qresult, "lockType", value, 20);
houseStuff[i][houseLock] = strval(value);

db_get_field_assoc(qresult, "houseAlarm", value, 20);
houseStuff[i][houseAlarm] = strval(value);


houseECP[i] = CreateDynamicCP(houseStuff[i][houseX], houseStuff[i][houseY], houseStuff[i][houseZ], 1.5, 0);
houseECP2[i] = CreateDynamicCP(houseStuff[i][interiorX], houseStuff[i][interiorY], houseStuff[i][interiorZ], 1.5, 150 + houseStuff[i][house_id]);


new labelstring[200];
switch(houseStuff[i][house_bought])
{
case 0:
{
houseStuff[i][label] = CreateDynamic3DTextLabel("{58D3F7}[FOR SALE]", COLOR_WHITE, houseStuff[i][houseX], houseStuff[i][houseY], houseStuff[i][houseZ] + 0.2, 25.0, INVALID_PLAYER_ID, INVALID_VEHICLE_ID, 0, 0, -1);
format(labelstring, sizeof(labelstring), "{FFFFFF}/buyhouse {FFDC2E}%i {FFFFFF}\nPrice: {FFDC2E}$%i", houseStuff[i][house_id], houseStuff[i][house_price]);
}
case 1:
{
houseStuff[i][label] = CreateDynamic3DTextLabel("{58D3F7}[ALT TO ENTER]", COLOR_WHITE, houseStuff[i][houseX], houseStuff[i][houseY], houseStuff[i][houseZ] + 0.2, 25.0, INVALID_PLAYER_ID, INVALID_VEHICLE_ID, 0, 0, -1);
format(labelstring, sizeof(labelstring), "{FFFFFF}Owner: {FFDC2E}%s\n{FFFFFF}House ID: {FFDC2E}%i", houseStuff[i][house_owner], houseStuff[i][house_id], houseStuff[i][house_price]);
}
}


houseStuff[i][infoLabel] = CreateDynamic3DTextLabel(labelstring, 0xFF0000FF, houseStuff[i][houseX], houseStuff[i][houseY], houseStuff[i][houseZ], 25.0, INVALID_PLAYER_ID, INVALID_VEHICLE_ID, 0, 0, -1);


xHouses++;


db_next_row(qresult);
}
}

db_free_result(qresult);
}
}

MaxJohnson
08/07/2015, 12:13 PM
show us findhouse command

KingServerIRAN
08/07/2015, 12:14 PM
Please Show the FindHouse Command To Us

You Have Just Posted The Call Back

WaJeeH
08/07/2015, 12:54 PM
Yeah,Add your /findhouse command here...And let us know is it a filter script?If yes then you would haven't added it correctly.First Put the filterscript in "FilterScripts" folder then,Press F2 and Copy the name of the Filterscript then add that name in 'Server.cfg' in front of FilterScripts...I hope it will work..If still it dont,let us know.

SecretBoss
08/07/2015, 01:47 PM
He is using CNRSF's gamemode, and the command looks unfinished you must finish dear shouraya

shourya
08/07/2015, 05:25 PM
all done fixed

MrCallum
08/07/2015, 05:27 PM
Update

shourya
08/07/2015, 05:30 PM
Update
lol what u mean?