Plugin preturii cu errori

Categoria cu cereri de pluginuri si nu numai.

Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com

Forum rules
Accesează link-ul pentru a putea vedea regulile forumului

Daca doriti sa vi se modifice un plugin, va rugam postati aici .
Post Reply
User avatar
CsN^ ;x
Membru eXtream
Membru eXtream
Posts: 3559
Joined: 02 Apr 2012, 15:58
Detinator Steam: Nu
CS Status: Retras din domeniul Counter-Strike
Reputatie: Fost moderator
Location: Bucuresti
Has thanked: 796 times
Been thanked: 607 times

14 Dec 2013, 10:49

Am si eu un plugin de preturii care imi da niste errori,el a avut 5 casete adica 1,2,3,4,5 eu iam scos 3 din ele si am lasat doar 2 si a mai avut si un mesaj si l-am scos si pe ala.(acum nu stiu daca am scos totu bine ca imi da in logs niste errori la linia 18)
.sma aici | Afiseaza codul
[code]#include <amxmodx>
#include <amxmisc>

new motd_open[33];

public plugin_init() 
{
   register_plugin("Informatii meniu", "1.0", "cyby")
   register_clcmd("say /preturi", "Info_Menu")
   register_clcmd("say_team /preturi", "Info_Menu")
   register_clcmd("say .preturi", "Info_Menu")
   register_clcmd("say_team .preturi", "Info_Menu")
   
}

public client_putinserver(id)
{
   set_task(12.0, "join_message", id)
   motd_open[id] = 0
}

public client_disconnect(id)
{
   motd_open[id] = 0
   remove_task(id)
}

public Info_Menu(id)
{
   new menu_informatii = menu_create("Meniul cu preturii:^n", "Info_backside");
   
   menu_additem(menu_informatii, "\dPreturi VIP", "1", 0);
   menu_additem(menu_informatii, "\dPreturi ADMIN", "2", 0);
   
   menu_setprop(menu_informatii, MPROP_EXIT, MEXIT_ALL);
   menu_display(id, menu_informatii, 0);
}

public Info_backside(id, menu_informatii, item)
{
   if( item == MENU_EXIT )
   {
      menu_destroy(menu_informatii);
      return PLUGIN_HANDLED;
   }
   new data[6], iName[64];
   new access, callback;
   menu_item_getinfo(menu_informatii, item, access, data,5, iName, 63, callback);
   new key = str_to_num(data);
   
   switch(key)
   {
      case 1:
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii VIP.")
         motd_open[id] = 1
         set_task(2.5, "show_info", id)
      }
      case 2: 
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii admin.")
         motd_open[id] = 2
         set_task(2.5, "show_info", id)
      }

   }
   menu_destroy(menu_informatii)
   return PLUGIN_HANDLED;
}

public show_info(id)
{
   if(motd_open[id] == 1)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/vip.html")
   }
   else if(motd_open[id] == 2)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/admin.html")
   }
   
   {
      color_chat(id, ".v[INFO].g Cum ai ajuns gica aici?  Treci la meniul principal.")
      motd_open[id] = 0
      Info_Menu(id)
   }
}

stock color_chat(const id, const input[], any:...)
{
   new count = 1, players[32]
   static msg[191]
   vformat(msg, 190, input, 3)

   replace_all(msg, 190, ".v", "^4")
   replace_all(msg, 190, ".g", "^1")
   replace_all(msg, 190, ".e", "^3")

   if (id) players[0] = id; else get_players(players, count, "ch")
   {
      for (new i = 0; i < count; i++)
      {
         if (is_user_connected(players))
         {
            message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players)
            write_byte(players);
            write_string(msg);
            message_end();
         }
      }
   }
}[/code]

Si doresc sa imi colorati altfel meniu ala adica sa nu se vada transparent preturii... sa se vada ca la 0.Exist
logs | Afiseaza codul
[code]L 12/14/2013 - 10:38:17: Function is not present (function "join_message") (plugin "preturi.amxx")
L 12/14/2013 - 10:38:17: [AMXX] Run time error 10 (plugin "preturi.amxx") (native "set_task") - debug not enabled!
L 12/14/2013 - 10:38:17: [AMXX] To enable debug mode, add "debug" after the plugin name in plugins.ini (without quotes).
L 12/14/2013 - 10:39:21: Start of error session.
L 12/14/2013 - 10:39:21: Info (map "c21_kitty") (file "addons/amxmodx/logs/error_20131214.log")
L 12/14/2013 - 10:39:21: Function is not present (function "join_message") (plugin "preturi.amxx")
L 12/14/2013 - 10:39:21: [AMXX] Displaying debug trace (plugin "preturi.amxx")
L 12/14/2013 - 10:39:21: [AMXX] Run time error 10: native error (native "set_task")
L 12/14/2013 - 10:39:21: [AMXX]    [0] preturi.sma::client_putinserver (line 18)
[/code]
Si daca puteti cand apasa pe 1-2 sa se deschida motd-ul si sa se inchida meniul,ca acuma se deschide motd-ul daca apasa pe 1 si trebuie sa apas 0 ca sa se inchida.
Addons HNS level,gravity,xp DOWNLOAD ( e țeapă)
https://5filme.com/ - un simplu site de filme pentru timpul liber
Rapidserver
User avatar
CsN^ ;x
Membru eXtream
Membru eXtream
Posts: 3559
Joined: 02 Apr 2012, 15:58
Detinator Steam: Nu
CS Status: Retras din domeniul Counter-Strike
Reputatie: Fost moderator
Location: Bucuresti
Has thanked: 796 times
Been thanked: 607 times

14 Dec 2013, 13:42

Cineva,ma chiar grabesc cu acest plugin,stiu ca am facut dublu post dar...
Macar spuneti ce am sters gresit sau ce ar mai trebui sters din plugin sa nu mai dea errori .
Addons HNS level,gravity,xp DOWNLOAD ( e țeapă)
https://5filme.com/ - un simplu site de filme pentru timpul liber
User avatar
GhosT ***
Membru, skill +2
Membru, skill +2
Posts: 604
Joined: 04 Dec 2013, 21:52
Detinator Steam: Da
CS Status: Morphin . [ Retras ]
SteamID: Mutulica1428
Reputatie: Fost Moderator ajutator
Location: Dumesti.
Has thanked: 40 times
Been thanked: 99 times
Contact:

14 Dec 2013, 13:53

CsN^ ;x wrote:Cineva,ma chiar grabesc cu acest plugin,stiu ca am facut dublu post dar...
Macar spuneti ce am sters gresit sau ce ar mai trebui sters din plugin sa nu mai dea errori .

Code: Select all

"L 12/14/2013 - 10:38:17: [AMXX] Run time error 10 (plugin "preturi.amxx") (native "set_task") - debug not enabled!"
Incearca sa bagi debug la preturi.amxx

Code: Select all

preturi.amxx debug
User avatar
CsN^ ;x
Membru eXtream
Membru eXtream
Posts: 3559
Joined: 02 Apr 2012, 15:58
Detinator Steam: Nu
CS Status: Retras din domeniul Counter-Strike
Reputatie: Fost moderator
Location: Bucuresti
Has thanked: 796 times
Been thanked: 607 times

14 Dec 2013, 13:55

Uite man ,e pus debug

Code: Select all

L 12/14/2013 - 10:39:21: [AMXX] Run time error 10: native error (native "set_task")
L 12/14/2013 - 10:39:21: [AMXX]    [0] preturi.sma::client_putinserver (line 18)
Addons HNS level,gravity,xp DOWNLOAD ( e țeapă)
https://5filme.com/ - un simplu site de filme pentru timpul liber
User avatar
-Turbo-
Membru, skill +4
Membru, skill +4
Posts: 1658
Joined: 11 Nov 2012, 01:28
Detinator Steam: Da
CS Status: Bored !
Detinator server CS: Da
SteamID: kingforbidden
Reputatie: Utilizator neserios ( tepar )
Restrictie moderator
Ban scos ( achitat )
Nume anterior: Turbo19973
Location: Botosani
Has thanked: 47 times
Been thanked: 210 times
Contact:

14 Dec 2013, 13:56

:) | Afiseaza codul
#include <amxmodx>
#include <amxmisc>

new motd_open[33];

public plugin_init() 
{
   register_plugin("Informatii meniu", "1.0", "cyby")
   register_clcmd("say /preturi", "Info_Menu")
   register_clcmd("say_team /preturi", "Info_Menu")
   register_clcmd("say .preturi", "Info_Menu")
   register_clcmd("say_team .preturi", "Info_Menu")
   
}

public client_putinserver(id)
{
   motd_open[id] = 0
}

public client_disconnect(id)
{
   motd_open[id] = 0
}

public Info_Menu(id)
{
   new menu_informatii = menu_create("Meniul cu preturii:^n", "Info_backside");
   
   menu_additem(menu_informatii, "\dPreturi VIP", "1", 0);
   menu_additem(menu_informatii, "\dPreturi ADMIN", "2", 0);
   
   menu_setprop(menu_informatii, MPROP_EXIT, MEXIT_ALL);
   menu_display(id, menu_informatii, 0);
}

public Info_backside(id, menu_informatii, item)
{
   if( item == MENU_EXIT )
   {
      menu_destroy(menu_informatii);
      return PLUGIN_HANDLED;
   }
   new data[6], iName[64];
   new access, callback;
   menu_item_getinfo(menu_informatii, item, access, data,5, iName, 63, callback);
   new key = str_to_num(data);
   
   switch(key)
   {
      case 1:
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii VIP.")
         motd_open[id] = 1
         set_task(2.5, "show_info", id)
      }
      case 2: 
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii admin.")
         motd_open[id] = 2
         set_task(2.5, "show_info", id)
      }

   }
   menu_destroy(menu_informatii)
   return PLUGIN_HANDLED;
}

public show_info(id)
{
   if(motd_open[id] == 1)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/vip.html")
   }
   else if(motd_open[id] == 2)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/admin.html")
   }
   
   {
      color_chat(id, ".v[INFO].g Cum ai ajuns gica aici?  Treci la meniul principal.")
      motd_open[id] = 0
      Info_Menu(id)
   }
}

stock color_chat(const id, const input[], any:...)
{
   new count = 1, players[32]
   static msg[191]
   vformat(msg, 190, input, 3)

   replace_all(msg, 190, ".v", "^4")
   replace_all(msg, 190, ".g", "^1")
   replace_all(msg, 190, ".e", "^3")

   if (id) players[0] = id; else get_players(players, count, "ch")
   {
      for (new i = 0; i < count; i++)
      {
         if (is_user_connected(players))
         {
            message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players)
            write_byte(players);
            write_string(msg);
            message_end();
         }
      }
   }
}
User avatar
CsN^ ;x
Membru eXtream
Membru eXtream
Posts: 3559
Joined: 02 Apr 2012, 15:58
Detinator Steam: Nu
CS Status: Retras din domeniul Counter-Strike
Reputatie: Fost moderator
Location: Bucuresti
Has thanked: 796 times
Been thanked: 607 times

14 Dec 2013, 14:33

Mersi turbo dar il poti colora cum este colorat la numaru 0.Exist ,0.=rosu si scrisu e alb,eu cum am acuma 1-2 e transparent .
Daca poti si cand intri intr-un motd sa disapra dupa meniu daca poti daca nu,se poate spune ca e rezolvat ca errori nu mai da.
Addons HNS level,gravity,xp DOWNLOAD ( e țeapă)
https://5filme.com/ - un simplu site de filme pentru timpul liber
User avatar
aNNNdReY
Membru, skill +1
Membru, skill +1
Posts: 410
Joined: 07 Sep 2012, 23:45
Detinator Steam: Da
SteamID: ravyvevo
Has thanked: 65 times
Been thanked: 18 times

14 Dec 2013, 14:40

Vezi | Afiseaza codul
#include <amxmodx>
#include <amxmisc>

new motd_open[33];

public plugin_init() 
{
   register_plugin("Informatii meniu", "1.0", "cyby")
   register_clcmd("say /preturi", "Info_Menu")
   register_clcmd("say_team /preturi", "Info_Menu")
   register_clcmd("say .preturi", "Info_Menu")
   register_clcmd("say_team .preturi", "Info_Menu")
   
}

public client_putinserver(id)
{
   motd_open[id] = 0
}

public client_disconnect(id)
{
   motd_open[id] = 0
}

public Info_Menu(id)
{
   new menu_informatii = menu_create("Meniul cu preturii:^n", "Info_backside");
   
   menu_additem(menu_informatii, "\dPreturi VIP", "1", 0);
   menu_additem(menu_informatii, "\dPreturi ADMIN", "2", 0);
   
   menu_setprop(menu_informatii, MPROP_EXIT, MEXIT_ALL);
   menu_setprop ( menu, MPROP_NUMBER_COLOR,"\r");

   menu_display(id, menu_informatii, 0);
}

public Info_backside(id, menu_informatii, item)
{
   if( item == MENU_EXIT )
   {
      menu_destroy(menu_informatii);
      return PLUGIN_HANDLED;
   }
   new data[6], iName[64];
   new access, callback;
   menu_item_getinfo(menu_informatii, item, access, data,5, iName, 63, callback);
   new key = str_to_num(data);
   
   switch(key)
   {
      case 1:
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii VIP.")
         motd_open[id] = 1
         set_task(2.5, "show_info", id)
      }
      case 2: 
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii admin.")
         motd_open[id] = 2
         set_task(2.5, "show_info", id)
      }

   }
   menu_destroy(menu_informatii)
   return PLUGIN_HANDLED;
}

public show_info(id)
{
   if(motd_open[id] == 1)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/vip.html")
   }
   else if(motd_open[id] == 2)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/admin.html")
   }
   
   {
      color_chat(id, ".v[INFO].g Cum ai ajuns gica aici?  Treci la meniul principal.")
      motd_open[id] = 0
      Info_Menu(id)
   }
}

stock color_chat(const id, const input[], any:...)
{
   new count = 1, players[32]
   static msg[191]
   vformat(msg, 190, input, 3)

   replace_all(msg, 190, ".v", "^4")
   replace_all(msg, 190, ".g", "^1")
   replace_all(msg, 190, ".e", "^3")

   if (id) players[0] = id; else get_players(players, count, "ch")
   {
      for (new i = 0; i < count; i++)
      {
         if (is_user_connected(players))
         {
            message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players)
            write_byte(players);
            write_string(msg);
            message_end();
         }
      }
   }
}
User avatar
CsN^ ;x
Membru eXtream
Membru eXtream
Posts: 3559
Joined: 02 Apr 2012, 15:58
Detinator Steam: Nu
CS Status: Retras din domeniul Counter-Strike
Reputatie: Fost moderator
Location: Bucuresti
Has thanked: 796 times
Been thanked: 607 times

14 Dec 2013, 14:46

aNNNdReY wrote:
Vezi | Afiseaza codul
#include <amxmodx>
#include <amxmisc>

new motd_open[33];

public plugin_init() 
{
   register_plugin("Informatii meniu", "1.0", "cyby")
   register_clcmd("say /preturi", "Info_Menu")
   register_clcmd("say_team /preturi", "Info_Menu")
   register_clcmd("say .preturi", "Info_Menu")
   register_clcmd("say_team .preturi", "Info_Menu")
   
}

public client_putinserver(id)
{
   motd_open[id] = 0
}

public client_disconnect(id)
{
   motd_open[id] = 0
}

public Info_Menu(id)
{
   new menu_informatii = menu_create("Meniul cu preturii:^n", "Info_backside");
   
   menu_additem(menu_informatii, "\dPreturi VIP", "1", 0);
   menu_additem(menu_informatii, "\dPreturi ADMIN", "2", 0);
   
   menu_setprop(menu_informatii, MPROP_EXIT, MEXIT_ALL);
   menu_setprop ( menu, MPROP_NUMBER_COLOR,"\r");

   menu_display(id, menu_informatii, 0);
}

public Info_backside(id, menu_informatii, item)
{
   if( item == MENU_EXIT )
   {
      menu_destroy(menu_informatii);
      return PLUGIN_HANDLED;
   }
   new data[6], iName[64];
   new access, callback;
   menu_item_getinfo(menu_informatii, item, access, data,5, iName, 63, callback);
   new key = str_to_num(data);
   
   switch(key)
   {
      case 1:
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii VIP.")
         motd_open[id] = 1
         set_task(2.5, "show_info", id)
      }
      case 2: 
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii admin.")
         motd_open[id] = 2
         set_task(2.5, "show_info", id)
      }

   }
   menu_destroy(menu_informatii)
   return PLUGIN_HANDLED;
}

public show_info(id)
{
   if(motd_open[id] == 1)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/vip.html")
   }
   else if(motd_open[id] == 2)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/admin.html")
   }
   
   {
      color_chat(id, ".v[INFO].g Cum ai ajuns gica aici?  Treci la meniul principal.")
      motd_open[id] = 0
      Info_Menu(id)
   }
}

stock color_chat(const id, const input[], any:...)
{
   new count = 1, players[32]
   static msg[191]
   vformat(msg, 190, input, 3)

   replace_all(msg, 190, ".v", "^4")
   replace_all(msg, 190, ".g", "^1")
   replace_all(msg, 190, ".e", "^3")

   if (id) players[0] = id; else get_players(players, count, "ch")
   {
      for (new i = 0; i < count; i++)
      {
         if (is_user_connected(players))
         {
            message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players)
            write_byte(players);
            write_string(msg);
            message_end();
         }
      }
   }
}

Imi da errori la compilare
Image
Addons HNS level,gravity,xp DOWNLOAD ( e țeapă)
https://5filme.com/ - un simplu site de filme pentru timpul liber
User avatar
aNNNdReY
Membru, skill +1
Membru, skill +1
Posts: 410
Joined: 07 Sep 2012, 23:45
Detinator Steam: Da
SteamID: ravyvevo
Has thanked: 65 times
Been thanked: 18 times

14 Dec 2013, 15:14

TESTAT | Afiseaza codul
#include <amxmodx>
#include <amxmisc>

new motd_open[33];

public plugin_init() 
{
   register_plugin("Informatii meniu", "1.0", "cyby")
   register_clcmd("say /preturi", "Info_Menu")
   register_clcmd("say_team /preturi", "Info_Menu")
   register_clcmd("say .preturi", "Info_Menu")
   register_clcmd("say_team .preturi", "Info_Menu")
   
}

public client_putinserver(id)
{
   motd_open[id] = 0
}

public client_disconnect(id)
{
   motd_open[id] = 0
}

public Info_Menu(id)
{
   new menu_informatii = menu_create("Meniul cu preturii:^n", "Info_backside");
   
   menu_additem(menu_informatii, "\dPreturi VIP", "1", 0);
   menu_additem(menu_informatii, "\dPreturi ADMIN", "2", 0);
   
   menu_setprop(menu_informatii, MPROP_EXIT, MEXIT_ALL);
   menu_setprop(menu_informatii, MPROP_NUMBER_COLOR,"\r");

   menu_display(id, menu_informatii, 0);
}

public Info_backside(id, menu_informatii, item)
{
   if( item == MENU_EXIT )
   {
      menu_destroy(menu_informatii);
      return PLUGIN_HANDLED;
   }
   new data[6], iName[64];
   new access, callback;
   menu_item_getinfo(menu_informatii, item, access, data,5, iName, 63, callback);
   new key = str_to_num(data);
   
   switch(key)
   {
      case 1:
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii VIP.")
         motd_open[id] = 1
         set_task(2.5, "show_info", id)
      }
      case 2: 
      {
         color_chat(id, ".v[INFO].g In.e 2.g secunde se deschide pagina cu informatii despre preturii admin.")
         motd_open[id] = 2
         set_task(2.5, "show_info", id)
      }

   }
   menu_destroy(menu_informatii)
   return PLUGIN_HANDLED;
}

public show_info(id)
{
   if(motd_open[id] == 1)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/vip.html")
   }
   else if(motd_open[id] == 2)
   {
      show_motd(id,"http://www.legendcs.com/download/motduri/admin.html")
   }
   
   {
      color_chat(id, ".v[INFO].g Cum ai ajuns gica aici?  Treci la meniul principal.")
      motd_open[id] = 0
      Info_Menu(id)
   }
}

stock color_chat(const id, const input[], any:...)
{
   new count = 1, players[32]
   static msg[191]
   vformat(msg, 190, input, 3)

   replace_all(msg, 190, ".v", "^4")
   replace_all(msg, 190, ".g", "^1")
   replace_all(msg, 190, ".e", "^3")

   if (id) players[0] = id; else get_players(players, count, "ch")
   {
      for (new i = 0; i < count; i++)
      {
         if (is_user_connected(players))
         {
            message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players)
            write_byte(players);
            write_string(msg);
            message_end();
         }
      }
   }
}
Post Reply

Return to “Cereri”

  • Information