AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Problem with gunxpmod (https://forums.alliedmods.net/showthread.php?t=278025)

SpoconYYY 01-23-2016 06:07

Problem with gunxpmod
 
Hello,
I would like to change the currency in unlockshop from xp on coins system for codmod.
Is it possible? if so I would be grateful for help

https://forums.alliedmods.net/showth...02294?p=802294

And to create such a thing, or a message from finished, because what I gave it does not work

Code:

register_clcmd("say /reset", "PP_Reset");
register_clcmd("say /ppsklep", "Sklep_PP");

pp_gracza[33];

public PP_Reset(id) { new menu = menu_create("\wZa reset otrzymasz \r2 PP^n\yCzy Resetowac?", "PP_Reset_Select"); menu_additem(menu, "\rTak", "1", 0); menu_additem(menu, "\yNie", "2", 0);  menu_setprop(menu, MPROP_EXIT, MEXIT_ALL);  menu_display(id, menu, 0); }

public PP_Reset_Select(id, menu, item) { new data[6], iName[64]; new zaccess, callback; menu_item_getinfo(menu, item, zaccess, data,5, iName, 64, callback); new key = str_to_num(data) new nick[32]; get_user_name(id,nick,31);  switch(key) { case 1: { if(poziom_gracza[id] == POTRZEBNY_POZIOM) { pp_gracza[id] += 2;  // dwa to ilość punktów powrotu jaką otrzyma gracz po resecie poziom_gracza[id] = 0; // zerujemy poziom gracza exp_gracza[id] = 0; // resetujemy exp gracza client_print(0, print_chat, "Gracz %s zzerowal swoj poziom w zamian otrzymal 2 punkty powrotu!", nick) } else // Gdy nie posiadamy potrzebnego poziomu { client_print(id, print_chat, "Nie posiadasz xx poziomu") } } case 2: { menu_destroy(menu) } } menu_destroy(menu); return PLUGIN_HANDLED; }

public Sklep_PP(id) { new tytul[25], aaa[65]; new MyMenuFun=menu_makecallback("CallbackMenu"); format(tytul, 24, "\rPosiadasz: %i Punktow Powrotu\w^nWybierz Opcje", pp_gracza[id]);  formatex(aaa, 64, "\yXXXX \r[Koszt: X PP]"); new menu = menu_create(tytul, "wymien_powrot2");  menu_additem(menu, aaa, "1");  menu_display(id, menu); } public wymien_powrot2(id, menu, item) { if(!is_user_alive(id) || !is_user_connected(id))  return PLUGIN_CONTINUE; if(item == MENU_EXIT) {  menu_destroy(menu);  return PLUGIN_CONTINUE; }  switch(item) {  case 0:  {    if(pp_gracza[id] >= ILOSC)    {        powrot_gracza[id]-=ILOSC;        // Tutaj umiesc funkcje po kupnie        client_print(id, print_chat, "Kupiles ...")    }    else    {        client_print(id, print_chat, "Nie posiadasz wystarczajacej ilosci PP")    }  } } return PLUGIN_HANDLED; }


SpoconYYY 01-26-2016 09:10

Re: Problem with gunxpmod
 
Refresh...

SpoconYYY 01-29-2016 16:34

Re: Problem with gunxpmod
 
Refresh...

SpoconYYY 01-31-2016 05:48

Re: Problem with gunxpmod
 
Refresh...

Spirit_12 01-31-2016 06:04

Re: Problem with gunxpmod
 
Quote:

Do not "bump" your threads. Bumping is posting simply to make the thread higher in the forum sort order.
To answer your question. Yes, It is possible to use any currency, as long as plugins have API. Otherwise, it will take core plugin edits.


All times are GMT -4. The time now is 09:20.

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