Question about input limit
#1

So if i am right the limit of dialog_style_input is 128.
Is there another kind of way with a bigger input box which allows more characters?
Or a way to bypass this limit?
Reply
#2

PHP код:
#define DIALOG_INPUT 0
CMD:input(playeridparams[])
{
    new 
input[2000];
    
strcat(input"Put your 128+ characters message here.");
    
ShowPlayerDialog(playeridDIALOG_INPUTDIALOG_STYLE_INPUT"Input"input"Okay""Cancel");
    return 
1;

Not sure if that's what you meant.
Reply
#3

Quote:
Originally Posted by willbedie
Посмотреть сообщение
PHP код:
#define DIALOG_INPUT 0
CMD:input(playeridparams[])
{
    new 
input[2000];
    
strcat(input"Put your 128+ characters message here.");
    
ShowPlayerDialog(playeridDIALOG_INPUTDIALOG_STYLE_INPUT"Input"input"Okay""Cancel");
    return 
1;

Not sure if that's what you meant.
thank you but you misunderstood. When you display DIALOG_INPUT it only allows you to enter 128 characters right? i assume that because that is the limit.
I need to know how i can add more then 128.

I need that because when you create a note in the system i am creating it uses alot more then 128 characters and i want players be able to enter bigger notes.

example:
http://217.62.194.69/sa-mp-535.png
http://217.62.194.69/sa-mp-534.png
Reply
#4

Quote:
Originally Posted by jasperschellekens
Посмотреть сообщение
thank you but you misunderstood. When you display DIALOG_INPUT it only allows you to enter 128 characters right? i assume that because that is the limit.
I need to know how i can add more then 128.

I need that because when you create a note in the system i am creating it uses alot more then 128 characters and i want players be able to enter bigger notes.

example:
http://217.62.194.69/sa-mp-535.png
http://217.62.194.69/sa-mp-534.png
Oh sorry, i thought that you were talking about the text, well i have no idea...
Reply
#5

Unfortunately, you can't bypass this limit. It's like asking if we can bypass the input chattext limit. Sorry for you!
Reply
#6

No you cannot bypass the limit.

What you can do is show multiple input dialogs and strcat your global string untill player decides to finish.

Make secondary button a finish input button or check if player writes a special keyword in input field like "end" or "finish".
Reply
#7

Thank you for the response.
I think bigger input boxes should be included in a next samp update :P

@Gammix i am going to do that thank you for the tip

@Dayrion of course it is like asking if we can bypass the input chattext limit because that is exactly what i did.
Reply
#8

Quote:
Originally Posted by jasperschellekens
Посмотреть сообщение
@Dayrion of course it is like asking if we can bypass the input chattext limit because that is exactly what i did.
I'm wondering how did you do that.
Reply
#9

Quote:
Originally Posted by Dayrion
Посмотреть сообщение
I'm wondering how did you do that.
I wondering How you noticed


OT:
If anyone does want to do the same thing like i, this code will work:

PHP код:
           new tmpinput[128], filepl[64], tmpoldinput[2000], tmpnewinput[2000];
            
format(tmpinputsizeof(tmpinput), "%s"inputtext);
            
format(fileplsizeof(filepl), "Accounts/%s.ini"GetName(playerid));
            
format(tmpoldinputsizeof(tmpoldinput), "%s"INI_Get(filepl,"MDCCreateNoteTemp"));
            
format(tmpnewinputsizeof(tmpnewinput), "%s %s"tmpoldinputtmpinput);
            
INI_Set(filepl,"MDCCreateNoteTemp",tmpnewinput); 
You might have to edit it, but it will give you the feeling of how it works.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)