Game crashes with dialogs -
leong124 - 23.06.2011
1. Sometimes your client will crash if you type non-English characters into the dialog(I'm using Big5 coding, which is 16-bit characters)
2. My friend tells me that after typing the password in the dialog when he connect a server, he will crash if he type Chinese in the chat box. The weird thing is, there's no crash if he press "T" to show the chat box before entering his password into the dialog. Both R1 and R3 have this problem.
Re: Game crashes with dialogs -
billy4601 - 02.08.2011
I have the same problem.
I searched some Chinese sa-mp forum, and found this problem not happen on
every player.
Only a few player will get crash when they type non-English characters to the
chat dialog ('T' or 'F6')
According to my test, if player connect a server and show a dialgo immediate
player(not for all) will get this problem.
if they use chat dialog first, then no problem
Re: Game crashes with dialogs -
leong124 - 04.08.2011
I had a chat with Billy, and I'm going to translate what he thinks here:
Quote:
Originally Posted by billy4601
All of you know that there's two main input method in SA-MP. They're chat box and dialog.
However, they share the same program in order to support non-ASCII characters (in this case is Big5 characters).
If an input dialog shows before the chat box, the chat box will be unable to load the program for non-ASCII characters. Therefore the client will crash, due to errors caused by that problem.
|
His dialog is shown in OnPlayerConnect.
Re: Game crashes with dialogs -
Kalcor - 05.08.2011
Is there a crash address?
Also, is it true that the caret in the edit box is not moving with 16bit chars?
Re: Game crashes with dialogs -
billy4601 - 05.08.2011
Quote:
Originally Posted by Kalcor
Is there a crash address?
Also, is it true that the caret in the edit box is not moving with 16bit chars?
|
crash address is mean server IP or players crash location?
What is 'edit box' you mean? is chat box or dialog?
Sorry for my bad English....
Anyway, this bug will make chinese player can't play SA-MP
Because they need to use
Input method to type non-English for chat.
As far as i know, if server show input dialog before the chat box
Some players will crash when they type chinese characters or switch
Input method
If SA-MP developer need more test, my team can help to test.
Re: Game crashes with dialogs -
leong124 - 06.08.2011
For the first problem, the game instantly crashes without any warning and crash report.
I haven't noticed about the caret, but seems that it will occur if you use backspace.
I'll try to reproduce the error.
For the second problem, I don't know so much. I'll help billy to answer you.
Re: Game crashes with dialogs -
billy4601 - 06.08.2011
Quote:
Originally Posted by leong124
For the first problem, the game instantly crashes without any warning and crash report.
I haven't noticed about the caret, but seems that it will occur if you use backspace.
I'll try to reproduce the error.
For the second problem, I don't know so much. I'll help billy to answer you.
|
Thanks for translate, Now i can answer Kalcor's question.
Quote:
Is there a crash address?
|
No, Game just crashes without any warning crash report.
Quote:
is it true that the caret in the edit box is not moving with 16bit chars?
|
Yes, The caret is not moving with 16bit chars. But you can still move between the text.
You can see the caret in front of first character. But in fact i pressed "→(arrow keys)" twice.
and, if i press "Backspace" to del character. i need press twice to del one 16bit character.
press one "Backspace", you will get this
Re: Game crashes with dialogs -
Kalcor - 06.08.2011
Please test this replacement samp.dll
http://www.sa-mp.com/stuff/samp_dll-03cR3-oemchar.zip
Install SA-MP 0.3c R3 client. Download the above zip and unzip samp.dll. Replace the samp.dll in your GTA San Andreas folder with the one from the zip.
Re: Game crashes with dialogs -
leong124 - 06.08.2011
Thanks, I'll try that

BTW, Billy would like to know what is changed in this version.
Re: Game crashes with dialogs -
Kalcor - 06.08.2011
I tested SA-MP with the Chinese language in Windows XP. It was crashing in the Uniscribe dll (usp10.dll). I have added some additional checks to this code and it was no longer crashing.
I'm not sure if this was the source of all crashes. If some people are using different IME systems this could also be the source of crashes.
Re: Game crashes with dialogs -
billy4601 - 06.08.2011
I invited my team to test this new samp.dll. and get some results.
player still crashes when they type chinese characters
Crashes timeline:
Code:
1.Player call Windows Input method
2.Type chinese characters on Input method
3.Press "Enter" for send Input method's Text to SA-MP edit box
4.Game crashes
* some players crashes when switching input method.
More info about the Input method:
Chinese input methods for computers
Pinyin input method (The input method we use is "Microsoft New Phonetic IME")
Re: Game crashes with dialogs -
billy4601 - 06.08.2011
BTW, My teammate will crashes when they Connect to the server in this version.
The crash address:
Code:
SA-MP 0.3c-R3-oemchar
Exception At Address: 0x006F5636
Registers:
EAX: 0x0D4B2FFF EBX: 0x0D49C710 ECX: 0x00823100 EDX: 0xF36D4F60
ESI: 0x000168F0 EDI: 0x00000001 EBP: 0x000168EF ESP: 0x0028FD00
EFLAGS: 0x00210217
Stack:
+0000: 0x00000000 0x00000001 0x00863B10 0x75506C30
+0010: 0xC50CDA14 0x426EE354 0x4208AD29 0x008D48F8
+0020: 0x0000012C 0xFFFFB993 0x44B3F3D7 0x45248429
+0030: 0x411D2805 0x0028FF78 0x00848AAB 0xFFFFFFFF
+0040: 0x006F74C1 0x008724AC 0x00C3802C 0x00C3801C
+0050: 0x00C37FF4 0x00000002 0x00000001 0x00863B10
+0060: 0x00000000 0x000000FF 0x005B931E 0x008E2C90
+0070: 0x41544144 0x50414D5C 0x75615C53 0x7A6F6964
+0080: 0x692E6E6F 0x00006C70 0x50492E64 0x0000004C
+0090: 0x00824200 0x00001800 0x00000000 0x008211B7
+00A0: 0x00001800 0x49742400 0x005B3206 0x00001800
+00B0: 0x0053BCA0 0x00863B10 0x00863A90 0x00863B10
+00C0: 0x0000000A 0x0053E593 0x00863B10 0x00748D00
+00D0: 0x75881245 0x00000000 0x0028FF88 0x7EFDE000
+00E0: 0x01640000 0x0000000A 0x01643DD0 0x00000008
+00F0: 0x00000100 0x00000008 0x00000102 0x44000000
+0100: 0x43C00000 0x00000000 0x00000000 0x00000400
+0110: 0x00000300 0x00000000 0x0028FE54 0x00240182
+0120: 0x00000102 0x0000002E 0x40530001 0x033A6F46
+0130: 0x00000200 0x00000180 0x0000002C 0x0028FE2C
+0140: 0x00825EA4 0x75881245 0x00000000 0x7EFDE000
+0150: 0xFFFFFFFF 0x00821D17 0x00000065 0x00000065
+0160: 0x0028FF88 0x008246F1 0x00400000 0x00000000
+0170: 0x017B2F08 0x0000000A 0x00000094 0x00000006
+0180: 0x00000001 0x00001DB1 0x00000002 0x76726553
+0190: 0x20656369 0x6B636150 0x00003120 0x00000000
+01A0: 0x00000000 0x00000000 0x00000000 0x00000000
+01B0: 0x00000000 0x00000000 0x00000000 0x00000000
+01C0: 0x00000000 0x00000000 0x00000000 0x00000000
+01D0: 0x00000000 0x00000000 0x00000000 0x00000000
+01E0: 0x00000000 0x00000000 0x00000000 0x00000000
+01F0: 0x00000000 0x00000000 0x00000000 0x00000000
+0200: 0x00000000 0x00000000 0x00824588 0x00000000
+0210: 0x00000000 0x7EFDE000 0xC0000005 0x00000000
+0220: 0x017B2F08 0x00000044 0x017F0A68 0x017F3398
+0230: 0x017F36B0 0x00000000 0x00000000 0x00000000
+0240: 0x00000000 0x00000000 0x00000000 0x00000000
+0250: 0x00000000 0x00000000 0x00000000 0xFFFFFFFF
+0260: 0xFFFFFFFF 0xFFFFFFFF 0x00000000 0x00000000
+0270: 0x0028FE78 0x0028F8D4 0x0028FFC4 0x00825EA4
SCM Op: 0x0, lDbg: 0
Game Version: US 1.0
Re: Game crashes with dialogs -
leong124 - 07.08.2011
It still crashes for the first problem.
I can now reproduce that.
When you type the first Chinese character, you will crash if you press backspace.
Re: Game crashes with dialogs -
Kalcor - 07.08.2011
Quote:
Originally Posted by billy4601
BTW, My teammate will crashes when they Connect to the server in this version.
Code:
SA-MP 0.3c-R3-oemchar
Exception At Address: 0x006F5636
..
|
I don't think this is related to the new samp.dll. That crash can happen if there are other gta_sa.exe processes running. You can kill it in the process list or restart the computer.
I think I'll be able to find a fix for these problems. It will take some time though. I'll post a test version here when there is something new to test.
Re: Game crashes with dialogs -
Kalcor - 08.08.2011
I have added experimental IME support to the chat input and dialogs:
http://www.sa-mp.com/stuff/samp_dll-03cR3-ime1.zip
I was only able to test it with IME 3.0 on Windows XP. Please provide feedback on how it works.
Re: Game crashes with dialogs -
leong124 - 08.08.2011
It still crashes when I type a Chinese character and press the backspace key in a input dialog.
The first time to press will hide the input method window, while the game crashes when I press backspace again.
I don't know how the second problem will be, since I only help my friends to report it and I don't have such problems.
Anyway, thanks to add the input method window, which is what all Chinese users want
Edit:
Now when I type the first Chinese character in the dialog, the game instantly crashes without showing the character I typed.
I uses WinXP SP3.
Re: Game crashes with dialogs -
Kalcor - 08.08.2011
Quote:
Originally Posted by leong124
It still crashes when I type a Chinese character and press the backspace key in a input dialog.
The first time to press will hide the input method window, while the game crashes when I press backspace again.
I don't know how the second problem will be, since I only help my friends to report it and I don't have such problems.
Anyway, thanks to add the input method window, which is what all Chinese users want
Edit:
Now when I type the first Chinese character in the dialog, the game instantly crashes without showing the character I typed.
I uses WinXP SP3.
|
This only happens in dialogs and not the chat?
Re: Game crashes with dialogs -
leong124 - 08.08.2011
Yes.
it can now recognise Chinese characters in the chat box, but probably not in dialogs.
Re: Game crashes with dialogs -
billy4601 - 08.08.2011
Quote:
Originally Posted by Kalcor
|
Awesome! It is great job!!
I release this .dll to my server's players. Make more player to test .dll file.
This file
has fix most player's Chinese characters crashes problem.
However,
some players still get crashes when they type Chinese characters to chat box.
I will do more test to find out what happens.
And, My player find some bug about this IME support .dll
Quote:
1. IME support only dispaly four Chinese characters. No more. (On "Microsoft New Phonetic IME")
2.When we choose characters on IME support dialog, no high lighting on the characters we select (On "Microsoft New Phonetic IME")
3.If we press "up" and "down" to choose characters on IME support dialog. The chat box will recovery previous message
4. IME support dialog'sort number do not match with normal IME 'sort numbe
(EX: normal IME 'sort numbe start by "1" not "0")
|
Re: Game crashes with dialogs -
Kalcor - 10.08.2011
Quote:
Originally Posted by billy4601
This file has fix most player's Chinese characters crashes problem.
However, some players still get crashes when they type Chinese characters to chat box.
|
If some players are crashing and others aren't, there must be something different in their Windows settings. Please provide a screenshot of their IME settings in Control Panel.
I have tested:
Microsoft New Phonetic IME 2002a (Windows XP SP3)
Microsoft Pinyin IME 3.0 (Windows XP SP3)
Quote:
Originally Posted by leong124
On Microsoft New Phonetic IME, you can only display 4 characters in the temp word box, while the user actually input more than 4 characters.
|
Yes, some older IMEs have a limit of 4 characters for the reading string, so it is set to 4. I can look at increasing this later.
Quote:
Originally Posted by leong124
IME will show a ordered list of characters for the user to choose. However, some of them starts with 0 while some starts with 1. SA-MP assumes all of them starts with 1.
|
I will have to look in to this a bit more. The index information for the order is coming from Windows, not from SA-MP.
I have a new dll ready for testing.
http://www.sa-mp.com/stuff/samp_dll-03cR3-ime2.zip
The internal SA-MP IME is normally disabled. If you want to use an external IME, you do not have to do anything. If you want to use SA-MP's internal IME handling:
- Open
sa-mp.cfg, found in
My Documents\GTA San Andreas User Files\SAMP in notepad or another editor
- Add line:
ime=1
Changes 0.3cR3-ime1 to 0.3cR3-ime2
Fixed: Pressing Return on a candidate would submit the chat message
Fixed: Pressing arrow keys on candidate may recall previous chat messages
Fixed: Pressing ESC while candidate window open would close the chat window
Fixed: Vertical candidate window was rendering above the chat input, not below
For crashes: Please provide screenshots of Windows IME settings or Exception box information
For problems with the internal IME: Please provide screenshots inside SA-MP