SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Filterscripts > Includes

Reply
 
Thread Tools Display Modes
Old 22/09/2017, 04:06 AM   #361
Gammix
High-roller
 
Gammix's Avatar
 
Join Date: Jan 2015
Location: Ottawa, Canada
Posts: 1,683
Reputation: 662
Default Re: Dialogs include - Adding new styles to SAMP GUI

Quote:
Originally Posted by Fungi View Post
sorry for double posting
a simple fix for the list-item returning 0 bug

replacing all

with
Thanks for reporting, and as your fixes says that was the issue.
__________________
Gammix is online now   Reply With Quote
Old 25/10/2017, 06:47 AM   #362
Gammix
High-roller
 
Gammix's Avatar
 
Join Date: Jan 2015
Location: Ottawa, Canada
Posts: 1,683
Reputation: 662
Default Re: Dialogs include - Adding new styles to SAMP GUI

Quote:
Originally Posted by PatrickGTR View Post
A string size issue somewhere that doesn't even reach the MAX_DIALOG_LIST_ITEMS, it happens when you combine labels+preview models.

Code: https://paste.ofcode.org/CpPy2yhmMy3r6XQdUmHUMS

Screenshot:

What is "%m" ?
PHP Code:
"%s%i\t%s~g~(%m)\n" 
You should declare string size like this instead:
PHP Code:
new string[sizeof (mInfo) * /*max length of the item name string*/ 3/*for specifiers in format*/]; 
Maybe that might fix it but as i said in my space right now! lol
__________________
Gammix is online now   Reply With Quote
Old 25/10/2017, 09:52 AM   #363
GamezCEO
Big Clucker
 
Join Date: Oct 2017
Posts: 65
Reputation: 32
Default Re: Dialogs include - Adding new styles to SAMP GUI

Very useful include! Rep+
GamezCEO is offline   Reply With Quote
Old 25/10/2017, 10:12 AM   #364
Eoussama
High-roller
 
Eoussama's Avatar
 
Join Date: Jul 2016
Location: Kingdom of Morocco // Tangier
Posts: 1,072
Reputation: 149
Default Re: Dialogs include - Adding new styles to SAMP GUI

Quote:
Originally Posted by Gammix View Post
What is "%m" ?
PHP Code:
"%s%i\t%s~g~(%m)\n" 
Not very sure, but I guess that's a custom specifier, refer to this post for further information. http://forum.sa-mp.com/showthread.php?t=313488
__________________
Eoussama is online now   Reply With Quote
Old 12/11/2017, 04:50 PM   #365
grymtn
Big Clucker
 
Join Date: Jun 2013
Posts: 171
Reputation: 11
Default Re: Dialogs include - Adding new styles to SAMP GUI

hey all. Im trying to use this for my vehicle menus but they just look bad because i cant change the preview rotation and zoom. I know i saw the function in first post but where and how do i actually use this?
Code:
Dialog_SetListitemPreviewRot(playerid, 0, 5.0, 5.0, 2.0, 10.0, cola1, colb1);
grymtn is offline   Reply With Quote
Old 12/11/2017, 05:39 PM   #366
Gammix
High-roller
 
Gammix's Avatar
 
Join Date: Jan 2015
Location: Ottawa, Canada
Posts: 1,683
Reputation: 662
Default Re: Dialogs include - Adding new styles to SAMP GUI

Quote:
Originally Posted by grymtn View Post
hey all. Im trying to use this for my vehicle menus but they just look bad because i cant change the preview rotation and zoom. I know i saw the function in first post but where and how do i actually use this?
Code:
Dialog_SetListitemPreviewRot(playerid, 0, 5.0, 5.0, 2.0, 10.0, cola1, colb1);
Before showing your dialog, use this.
Also you know, you have to set rotation of other listitems too. Use a for loop with limit of number of listitems (array size) and use this function in it.
__________________
Gammix is online now   Reply With Quote
Old 12/11/2017, 06:05 PM   #367
grymtn
Big Clucker
 
Join Date: Jun 2013
Posts: 171
Reputation: 11
Default Re: Dialogs include - Adding new styles to SAMP GUI

at mos i have 3 items because i can own at most 3 items so i use it like this:
Code:
        Dialog_SetListitemPreviewRot(playerid, 0, 45.0, 5.0, 2.0, 10.0, cola1, colb1);
	Dialog_SetListitemPreviewRot(playerid, 1, 45.0, 5.0, 2.0, 1.0, cola2, colb2);
	Dialog_SetListitemPreviewRot(playerid, 2, 45.0, 5.0, 2.0, 1.0, cola3, colb3);
        ShowPlayerDialog(playerid, 6969, DIALOG_STYLE_PREVMODEL, "Vehicle's list", string, "Spawn", "Close");
All vehicle model ids are taken from database, they work fine in the string with dialog.like vehicle model ids cola's and colb's are taken in same query with model ids but still i see them on front with random colors. Not even a slight bit of rotation happens..
grymtn is offline   Reply With Quote
Old 12/11/2017, 09:05 PM   #368
Gammix
High-roller
 
Gammix's Avatar
 
Join Date: Jan 2015
Location: Ottawa, Canada
Posts: 1,683
Reputation: 662
Default Re: Dialogs include - Adding new styles to SAMP GUI

Quote:
Originally Posted by grymtn View Post
at mos i have 3 items because i can own at most 3 items so i use it like this:
Code:
        Dialog_SetListitemPreviewRot(playerid, 0, 45.0, 5.0, 2.0, 10.0, cola1, colb1);
	Dialog_SetListitemPreviewRot(playerid, 1, 45.0, 5.0, 2.0, 1.0, cola2, colb2);
	Dialog_SetListitemPreviewRot(playerid, 2, 45.0, 5.0, 2.0, 1.0, cola3, colb3);
        ShowPlayerDialog(playerid, 6969, DIALOG_STYLE_PREVMODEL, "Vehicle's list", string, "Spawn", "Close");
All vehicle model ids are taken from database, they work fine in the string with dialog.like vehicle model ids cola's and colb's are taken in same query with model ids but still i see them on front with random colors. Not even a slight bit of rotation happens..
Yea i forgot to adjust rotation on smaller version of dialog(the small sized dialog). Its a simple quickfix, I'll do it when i am free.
__________________
Gammix is online now   Reply With Quote
Old 12/11/2017, 09:54 PM   #369
grymtn
Big Clucker
 
Join Date: Jun 2013
Posts: 171
Reputation: 11
Default Re: Dialogs include - Adding new styles to SAMP GUI

Oh so thats a known bug haha. Good to know im not doing anything wrong. Thank you for your answer i will be waiting for it Keep up the good work.(Really amazing work!)
grymtn is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[FilterScript] Items spawner dialogs (zcmd & dialogs include) Q_Lite Filterscripts 17 16/10/2016 12:09 PM
[FilterScript] [FS]Fighting Styles,5 most usable styles Like in SP By Don_(GH) HAYTXA Filterscripts 10 28/03/2013 07:39 AM
Making an OnFilterScriptInit in an include without adding anything in the .pwn exepct the #include r3k1lLz_ Help Archive 6 06/01/2011 07:49 AM
[FilterScript] [FS]Trans World Airlines v0.2 [TWA] - Bug Fixed - Adding Dialogs Soon. Toni Filterscripts 16 13/06/2010 03:57 PM
[FilterScript] [FS] Fighting Styles (0.3a) - |Save styles in Dini| MoBiL[e] Filterscripts 23 24/04/2010 12:12 PM


All times are GMT. The time now is 12:22 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.