Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Custom Sell Price v. 1.0
- # VX Ace version
- # by mikb89
- # Dettagli:
- # Questo script permette di avere un prezzo di vendita (quindi guadagno per il
- # giocatore) personalizzato per ogni oggetto, arma e armatura del database.
- # Può essere abilitato e disabilitato con uno switch. I prezzi vanno impostati
- # nei notebox.
- # Configurazioni:
- module SELLPRICE
- SALES_SWITCH = 81
- # Switch da mettere ON/OFF per attivare/disattivare lo script
- end
- # Nei rispettivi notebox scrivere ad esempio:
- # <prezzo vendita: 10>
- # Per avere un guadagno di 10 monete alla vendita dell'oggetto/arma
- #Codename: sellprice
- ($imported ||= {})[:mikb89_sellprice] = true
- # License:
- # - You can ask me to include support for other scripts as long as these scripts
- # use the $imported[script] = true;
- # - You can modify and even repost my scripts, after having received a response
- # by me. For reposting it, anyway, you must have done heavy edit or porting,
- # you can't do a post with the script as is;
- # - You can use my scripts for whatever you want, from free to open to
- # commercial games. I'd appreciate by the way if you let me know about what
- # you're doing;
- # - You must credit me, if you use this script or part of it.
- class Scene_Shop < Scene_MenuBase
- alias_method(:sell_price_b4_sellprice, :selling_price) unless method_defined?(:sell_price_b4_sellprice)
- def selling_price
- if $game_switches[SELLPRICE::SALES_SWITCH] && @item.note =~ /<prezzo vendita[:]?[ ]*([0-9]+)>/i
- return $1.to_i
- end
- sell_price_b4_sellprice
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement