You are not logged in.
Another annoying bug in CLEO4 (probably in CLEO3 too).
There is set of bytes in script below which could be used to store data.
31@ contains proper move between 0@ from current thread and script content, label @AdditionalVariables in memory.
It works perfectly, reading/writing 4-byte data to this array using standard GTA SA opcodes.
0@(31@,1i) = 0x90807060 // It is GTA SA standard opcode, it doesn`t crash, works
And value appears on memory adress of @AdditionalVariables.
But trying to WRITE (not read) in CLEO to this array ends with a crash:
0AD2: 0@(31@,1i) = player $PLAYER_CHAR targeted_actor //IF and SET // It crashes, CLEO writing function is buggy and works for 0@ to 33@ in thread only, i think
or
0A8E: 0@(31@,1i) = 3 + 2 // int
There were only 2 examples, writing function in CLEO4 is broken. I hope it will get fixed.
{$CLEO} 0662: NOP "Crash when opcode created using CLEO is trying to write into an array which points to somewhere else than 0 - 33 local var" 0662: NOP "Array index is good, problem is CLEO writing function" 0662: NOP "It is out of thread 224 bytes and in CLEO it crashes :(" 0AB1: call_scm_func @getAdditionall_4byte_VariablesLabelIndex 1 label @AddtionalVariables store_index_to 31@ :CLEO_SDK wait 0 if 0AB0: key_pressed 48 else_jump @CLEO_SDK 0AC6: 1@ = label @AddtionalVariables offset // 0@(31@,1i) = 0x90807060 // It is GTA SA standard opcode, it doesn`t crash, works 0AD2: 0@(31@,1i) = player $PLAYER_CHAR targeted_actor //IF and SET // It crashes, CLEO writing function is buggy and works for 0@ to 33@ in thread only, i think // 0AD2: 2@ = player $PLAYER_CHAR targeted_actor //IF and SET // It works, but it is not an array out of thread. 0AD1: show_formatted_text_highpriority "Crashed, no 0AD1 executed. value: %X close memory offset of value: %X" time 2000 0@(31@,1i) 1@ wait 250 jump @CLEO_SDK :AddtionalVariables hex 0 00 00 00 00 // space 00 00 00 00 // 0@ 00 00 00 00 // 1@ end :getAdditionall_4byte_VariablesLabelIndex { Description: Reads given number of chars from memory and returns into variable. Type: SET Parameters: Passed: 0@ - label Result: 4@ - index, movement Example: 0AB1: call_scm_func @getAdditionall_4byte_VariablesLabelIndex 1 label @AddtionalVariables store_index_to 31@ :AddtionalVariables hex 00 00 00 00 // space 00 00 00 00 // 0@ 00 00 00 00 // 1@ end Usage in code: 0@(31@,1i); 1@(31@,1i) and so on } 0A9F: 2@ = current_thread_pointer 2@ += 60 0AC6: 3@ = label 0@ offset 0A8F: 4@ = 3@ - 2@ // int 4@ /= 4 4@ += 1 0AB2: ret 1 4@
Offline
I Found a bug....
{$CLEO} thread 'CLEO_T' :T11 wait 0 0A99: chdir "CLEO" wait 5000 0A99: chdir 0 wait 5000 0390: load_txd_dictionary 'LD_BEAT' 0A93: end_custom_thread
If I use the CHDIR to change the directory for another (In the example the CLEO Directory), and use chdir 0 to change to original directory, it doesn't work.
For test it, I try to load a txd dictionary, well, the game crashes.
I also use this to test:
:T11 wait 0 0A99: chdir "CLEO" wait 5000 0A99: chdir 0 wait 5000 0A9A: 1@ = openfile "see.ini" mode "wt+" // IF and SET 0A93: end_custom_thread
Well, the file see.ini was created in cleo directory =/
Offline
Could someone please direct me to a download for cleo 4 that doesn't have the W.S. Reputation virus?
Offline
@Link2012
0A99 opcode works only for CLEO file opcodes like 0A9A=3,%3d% = openfile %1s% mode %2d% ; IF and SET
it works probably for INI opcodes.
It is not for GTA SA standard texture opcodes.
0390: load_txd_dictionary 'LD_BEAT'
Texture dictionary LD_BEAT.txd must exist in models\txd
Last edited by fastman92 (20-05-2011 12:12)
Offline
Well, this is examples.
I Found the poblem using chdir to folder "GTA San Andreas/Player".
And use a texture existing in folder models/txd.
The game crashes, but if I create a folder GTA San Andreas/Player/Models/Txd and put the texture to load in these folder the game don't crashes.
Oh, Sorry the bad english.
Last edited by Link2012 (20-05-2011 23:21)
Offline
@Link2012
0A99 opcode works only for CLEO file opcodes like 0A9A=3,%3d% = openfile %1s% mode %2d% ; IF and SET
it works probably for INI opcodes.
It is not for GTA SA standard texture opcodes.0390: load_txd_dictionary 'LD_BEAT'Texture dictionary LD_BEAT.txd must exist in models\txd
chdir calls a San Andreas function (see CLEO 2 Source) which is used to switch between the user files and installation directories.
Offline
Looks like the CLEO 4.1.1.30f corrupts car_generators which generate newly added vehicles. For me, it keeps crashing at 0x0047BA64 (mov [eax+CParkedGenerator.field_D], cl at 0A17 opcode handler) with added some vehicles and incerased limit using SALA. With 4.1.1.30 it works fine.
Also, some other people reports this bug aswell.
Offline
Question: Is CLEO still being worked on or should we lose faith? There's been no updates in months and the bug reports are only stacking up. I've tried to keep a posotive look towards the future of CLEO 4 but at the moment a future for it appears inexistant.
Offline
Question: Is CLEO still being worked on or should we lose faith? There's been no updates in months and the bug reports are only stacking up. I've tried to keep a posotive look towards the future of CLEO 4 but at the moment a future for it appears inexistant.
Would be intressting to know.
I have antoher "bug".
If you play a mp3, and instantly minimize the game (go not to menue before), the mp3 keeps playing. Is it possible to freeze the mp3, like the rest of game?
Offline
Heh, if I knew for sure that there will be no updates, I might make CLEO 4 bugfixes in a separate ASI. I think I know how to fix that one, for starters.
Offline
hi,
im new
i have big problem please help
I run the game
The sound of vehicles and guns are off after 2 or more minutes
But when I get to ride vehicles. I changed the camera view to the left and right. Fx sound is heard.
Worked well in the cleo 3
But the bug was found in cleo v4.1.1.30f
please help me
Sorry for bad English writing
Offline
Heh, if I knew for sure that there will be no updates, I might make CLEO 4 bugfixes in a separate ASI. I think I know how to fix that one, for starters.
Well, I think there will be no problem in making and releasing a third-party plugin fixing bugs for the specific CLEO 4 version. If a new version of CLEO 4 will fix them, a user can just remove the plugin.
Offline
It'd be a bit of a waste of time for me to make it only for CLEO 4 to be updated a month later. I already have a lot of my own things to finish and little time to work on them. It'd make a lot more sense to just wait for a CLEO 4 update, if one is due. Let me know if you need any help, though.
Offline
I am sorry that has left here so much questions without answers. And you won't receive any answers to them, don't even hope!:-) But some thoughts on some of them...
1. What's about updates and the future of CLEO 4. Actually i just can't see any possibilities of this kind of stuff applying to scripting in GTA. Though generally I have certain notions of "a following step". Unfortunately, they are too cardinal, also demand the big investment of human abilities. To be put in modding of the game of 2005 is ungrateful employment. Is better I will direct my creative on something more worthy...
I don't have so many free time on my hobbies as well. The work, the study... Also, being in a miserable human body, I am compelled to sleep sometimes. GTA modding with all this stuff becomes secondary.
Though, if you have any concrete little proposals - offer, I'll consider.
2. About sound issues with CLEO 4. It's because of unfully support of currently using sound system software with hardware acceleration. You can partially solve this problem by disabling through 'dxdiag'.
3. About incompatibility of CLEO's with other low-level injecting soft for GTA. Well, they all are potentially incompatible, I can't do anything with it.
Last edited by Alien (18-09-2011 10:54)
Offline
Time to go open source?
Although I'd personally gain more from the Sanny Builder source
Offline
Offline
Deji, are you really interested in developing CLEO further?
Offline
Time to go open source?
Actually, I've already thought about it. But the code needs a little comb for this. Very tight time now...
Although I'd personally gain more from the Sanny Builder source
Question to Seemann.
Deji, are you really interested in developing CLEO further?
For this purpose was instroduced the plugin system (CLEO API). I certainly understand, that thing called so is somewhat laughable. Also need to refine.
Offline
@Alien - I asked Deji because if he does it would probably be better to give him the CLEO 4 sources to continue developing this project and/or fix bugs. Depends on you of course.
The Sanny Builder sources are unavailable even for me right now. They are located on another computer I have no access to at the moment. More than that, these sources are ugly and require a lot of additional components to be installed in order to compile them.
Offline
I'd be willing to take it on, just focusing on fixing what current bugs I could. I'm not as free with time as I used to be and am not sure what to expect within the source outside of what I've seen from my decompilation of the CLEO ASI, so I can't promise to fix everything or build on it. Still got a lot to do with Vigilante Justice, after all.
The sounds playing while minimised would be easy enough to fix, at least.
By the way, Alien, what was the purpose of diverting SA file functions to CLEO ones? Fix for the game file function and CLEO file handle incompatibility? It may have caused me some previous problems in a project of mine.
Last edited by Deji (15-10-2011 01:02)
Offline
OK, i am now on refactoring of CLEO 4 code. After this the library will go to open source. It would be nice if an interested group of GTA fans will have an ability to modify the code and to help improve library further. Seemann, what do you think?
By the way, Alien, what was the purpose of diverting SA file functions to CLEO ones? Fix for the game file function and CLEO file handle incompatibility? It may have caused me some previous problems in a project of mine.
it was made for compatibilty with Ryosoke scripts. He liked to use opcode "openfile" instead of "call_function #fopen#". I do not think that it can cause incompatibility with other scripts - i've replaced all CRT file functions from game instance.
PS: the code will be rewritten for GCC and will not support any other compilers. It will use GNU extensions of C++ language like
__attribute__(thiscall)
Also the library will pass to the new standard of C++ (C++11).
Last edited by Alien (19-10-2011 08:19)
Offline
It would be great. I thought I had
nothing to expect. It will be really
cool to see a correction in the
codes of operations, as well as
new opcodes.
Offline
OK, i am now on refactoring of CLEO 4 code. After this the library will go to open source. It would be nice if an interested group of GTA fans will have an ability to modify the code and to help improve library further. Seemann, what do you think?
передача кода другому человеку, который заинтересован в развитии проекта, - хороший шаг. так CLEO 3 превратилась в CLEO 4 но я не уверен, что стоит выкладывать исходники в открытый доступ. все равно не так мало людей будет что-то дорабатывать в библиотеке. скорее всего, все ограничится снятием копирайтов и желтой надписи в меню) я бы на твоем месте передал исходники лично Deji, поскольку он, во-первых, разбирается в устройстве CLEO, во-вторых, знает слабые места (баги), в-третьих, он разбирается в программировании и реально может что-то сделать. а если он посчитает нужным привлечь в проект еще людей, это будет зависеть от него.
Offline
все равно не так мало людей будет что-то дорабатывать в библиотеке. скорее всего, все ограничится снятием копирайтов и желтой надписи в меню
Про мало людей согласен. Я думаю, скриптерам в любом случае будет полезно иметь под рукой исходный код - он может заменить недостаток документированности. На самом деле, мне кажется, что здесь более вероятен другой вариант развития событий - CLEO (да и весь III-series моддинг) окажутся никому не нужными и все о них забудут (если еще не забыли).
скорее всего, все ограничится снятием копирайтов и желтой надписи в меню
ИМХО ну и пусть. Хотя я сомневаюсь в возможности такого. Для модификации кода будет существовать достаточно высокий входной порог на "качество программиста". Короче говоря, Cleo Hacker из Нижнего Тагила на это явно не способен. Ну а люди других качеств на такие подлые вещи вряд ли пойдут.
я бы на твоем месте передал исходники лично Deji, поскольку он, во-первых, разбирается в устройстве CLEO, во-вторых, знает слабые места (баги), в-третьих, он разбирается в программировании и реально может что-то сделать. а если он посчитает нужным привлечь в проект еще людей, это будет зависеть от него.
Ну что ж, если открыть исходники CLEO и дать права на модификацию, то Deji в принципе получит все те же возможности наравне с другими...
Offline
Okay, so I really wanted to get ELM for my GTA SA. However, no matter how many times I installed it with CLEO, and comes up with SA-MP crashed as soon as I try to join a server. I have tried to run my SA-MP without the ELM mod, but just CLEO 4, and it still crashes. Therefore, it's a problem with CLEO 4, rather than ELM. Can anyway shred some light ont his please and help me out? I really want ELM. Thanks in advance.
Offline