Raised This Month: $ Target: $400
 0% 

Optimizations questions


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Syturi0
Veteran Member
Join Date: Aug 2014
Location: Your mom house -Portugal
Old 04-18-2016 , 22:20   Optimizations questions
Reply With Quote #1

PHP Code:
return PLUGIN_HANDLED 
Should i always return PLUGIN_HANDLED at the end of code? Does it matter? Does it affect performance?
Example:
PHP Code:
public MenuTest(id)
{
    new 
Menu menu_create(sMenu"MenuTest_Handler")

    
menu_additem(Menu"test 1"""0)
    
menu_additem(Menu"teste 2"""0)

    
menu_setprop(MenuMPROP_EXITMEXIT_NEVER)
    
menu_setprop(MenuMPROP_PERPAGE6)

    
menu_display(idMenu0)
    return 
PLUGING_HANDLED



==========================

Is it better to have all plugins seperated, or have a HUGE with all of them inside a single one?
Does it affect performance?

==========================

When doing loops:
PHP Code:
    new iPlayers[32], iNum
    get_players
(iPlayersiNum"ch")

    for(new 
0iNumi++) 
Should i use "new i" inside "for()", or outside?
Like this:
PHP Code:
    new iPlayers[32], iNumi
    get_players
(iPlayersiNum"ch")

    for(
0iNumi++) 

Last edited by Syturi0; 04-18-2016 at 22:28.
Syturi0 is offline
 


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

Forum Jump


All times are GMT -4. The time now is 18:38.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode