[Include] YSI 4
#61

Hi.

I was using an old YSI 3 and today decided to update YSI to 4.0 and update compiler to Zeex one.
I'm using only y_iterate, y_inline and y_bit. I've also added -Z arg to compiler, but still have the same problem:
Code:
error 035: argument type mismatch (argument 1)
There is a lot of the same errors and I don't know what's wrong.

Example lines:
Code:
sscanf(GetString("pos", q), "p<,>fff", x, y, z);
// or
sscanf(GetString("pozycja", q), "p<,>fff", StacjaInfo[q][sPosX], StacjaInfo[q][sPosY], StacjaInfo[q][sPosZ]);
// or
strcatex(str, _, C_CZERWONY"Jesteś zbanowany/a."C_SZARY"\n\nData: "C_BEZOWY"%s"C_SZARY"\nGracz: "C_BEZOWY"%s\n"C_SZARY"Host: "C_BEZOWY"%s\n"C_SZARY"Powуd: "C_BEZOWY"%s"C_SZARY"\n", GetString("data"), GetString("gracz"), GetString("host"), GetString("powod"));
As you can see, GetString() is causing it:
Code:
stock GetString(field[], row=0)
{
	new temp[128];
	cache_get_field_content(row, field, temp);
	return temp;
}
This is error to this function:
Code:
error 025: function heading differs from prototype
error 021: symbol already defined: "returnstringarg"
error 090: public functions may not return arrays (symbol "returnstringarg")
What's wrong with this stock? It's not public function and it was ok when using YSI 3.
Why after including YSI 4 I can't return string?

Thanks for help in advance.
Reply
#62

Did you update mysql as well? cache_get_field_content is one of mysql functions, it requires database handle as the first argument.
Reply
#63

I'm using 39-4 version for now. It's to much work to update it to the latest. I don't think that mysql is a problem.
Reply
#64

Oh, my mistake, R39-X does not require connection handle as first argument, your function is fine. You've hit a name collision: https://github.com/Misiur/YSI-Includ...utils.inc#L793 - even if you don't explicitly include y_utils it's used by (probably) y_inline.
Reply
#65

Whaaat... I was searching on ****** for: "returnstringarg" and found nothing intresting (even when using site:github.com).

Thank you. Changed name and compiled fine.
Reply
#66

Quote:
Originally Posted by Misiur
Посмотреть сообщение
There was a bug with AUTO_INCLUDE_GUARD constant just before ****** left, I commited a fix later. If you're using latest YSI-Includes version with my patch, it shouldn't raise this error at all (except in compat mode, so with #pragma compat 1, or -Z+ flag passed to the compiler). If it does, please paste somewhere contents of your YSI_Internal\y_compilerpass.inc
Good joke :P

PHP код:
#include <a_samp>
#include <YSI/y_timers>
public OnFilterScriptInit(){
    return 
1;
}
//YSI/y_timers.inc(1) : fatal error 100: cannot read from file: "..\YSI_Internal\y_compilerpass"
//already here :D 
next joke: 49 includes in 263 files ? XD
Reply
#67

It always works / so it does not see the problem here.

This is not include guard, just pretends that it works like if you do not look at these libraries they report the most problems...

Include is one file no more.

Maybe this is FilterScript created in many files, most are empty as always.
Reply
#68

It's not about the include guard, read the whole page - especially the part about relative path includes.
Reply
#69

Quote:
Originally Posted by AbyssMorgan
Посмотреть сообщение
It always works / so it does not see the problem here.
If it always works, why doesn't it work for you? The fact that it isn't working clearly proves you are wrong. YSI has never ever used /, only \
Reply
#70

Is JIT compatibility being actively worked on? I‘m inclined to give YSI a shot, I could make good use of a bunch of the features it offers, like hooks, timers, colors, etc. Is there any progress?
Reply
#71

Yes: https://github.com/Misiur/YSI-Includ...its/Branch_JIT
Reply
#72

Hi guys! A little update: YSI has been moved from under my username onto the new github umbrella organisation for pawn related projects.

Also, I just published 4.0.2 zip package - get it from https://github.com/pawn-lang/YSI-Inc...ses/tag/v4.0.2
4.0.1 had some serious bugs, sorry for not updating for such a long time.
Reply
#73

Thanks a lot Misiur, has been waiting for the update.
Reply
#74

Your work is much appreciated. I'm getting one warning with YSI 4.0.2 though.

Код:
pawno\include\YSI\..\YSI_Coding\..\YSI_Core\y_utils.inc(430) : warning 201: redefinition of constant/macro (symbol "isnull(%1)")
Reply
#75

That just means one of your other includes also defines `isnull`, and does it differently. Delete one of the definitions.
Reply
#76

hook OnPlayerEditDynamicObject(playerid, objectid, response, Float, Float:y, Float:z, Float:rx, Float:ry, Float:rz)

warning 200: symbol "@yH_OnPlayerEditDynamicObject@0" is truncated to 31 characters

how to fix this?

i'm using the latest ysi
Reply
#77

Hi, I'm having a little problem when I updated YSI from 3.09.0684 to 4.0.2 (the latest on the github). All my commands worked fine, but since the update, the log is filled with this:

Quote:

[12:46:24] =======================================
[12:46:24] | |
[12:46:24] | YSI version 4.00.0001 |
[12:46:24] | By Alex "******" Cole |
[12:46:24] | |
[12:46:24] =======================================
[12:46:24]
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:28] *** YSI Error: Could not add command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.
[12:46:29] *** YSI Error: Could not add alt command to array.

What could be the problem?

Thanks in advance.
Reply
#78

I think I have found a little mistake in y_vehicledata.inc

Model_IsTrain(591) (Article Trailer 3) returns true but Article Trailer 3 is a truck trailer.
Reply
#79

Quote:
Originally Posted by sidney123
Посмотреть сообщение
Hi, I'm having a little problem when I updated YSI from 3.09.0684 to 4.0.2 (the latest on the github). All my commands worked fine, but since the update, the log is filled with this:



What could be the problem?

Thanks in advance.
Try add:

#define MAX_COMMANDS 1024

To the top of your script. Increase the number until the code works - I don't know how many you will need.

Quote:
Originally Posted by 2Col
Посмотреть сообщение
I think I have found a little mistake in y_vehicledata.inc

Model_IsTrain(591) (Article Trailer 3) returns true but Article Trailer 3 is a truck trailer.
Thanks, I'll check on that.
Reply
#80

how ready is YSI5? should i upgrade?
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)