Visualizzazione dei risultati da 1 a 3 su 3
  1. #1
    Utente di HTML.it
    Registrato dal
    Jul 2007
    Messaggi
    7

    [Java] Inserire istruzione da un file txt ad uno .propierties

    Premetto che sono un niubbaccio che sta cercando di imparare e sono al primo giorno.
    Ho imparato a inserire istruzioni con sql e cose varie pero' ora mi trovo innanzi ad un dilemma.

    Ho questa serie di istruzioni riportate su txt


    Index: java/config/options.properties
    ================================================== =================
    --- java/config/options.properties (revision 901)
    +++ java/config/options.properties (working copy)
    @@ -181,7 +181,41 @@
    # Log GM actions
    GMAudit = False

    +# ------------------------
    +# Npc Buffer Configuration
    +# ------------------------
    +AllowNpcBuffer = True

    +# Min and max level to get buffs
    +MinLevelToGetBuffs = 1
    +MaxLevelToGetBuffs = 80
    +
    +# Set the price per buff
    +ProphetBuffPrice = 10000
    +SongPrice = 10000
    +DancePrice = 10000
    +OrcBuffPrice = 10000
    +ClanBuffPrice = 10000
    +
    +# The npc buffer can restore CP/HP/MP
    +# for each CP/HP/MP point
    +# Exemple if char hp is 100 to restore all hp will cost PricePerHpPoint x 100 (if set to 1)
    +PricePerCpPoint = 8
    +PricePerMpPoint = 8
    +PricePerHpPoint = 8
    +
    +# Exchange sp for sp scrolls from npc buffer, here is the multiplier.
    +SpMultiplier = 1
    +
    +# Price for all buffs per class
    +FullProphetBuffsPrice = 200000
    +FullDancesPrice = 100000
    +FullSongsDancePrice = 100000
    +FullShamanBuffPrice = 50000
    +FullWarcryerBuffPrice = 50000
    +FullOverlordBuffPrice = 50000
    +FullClanBuffsPrice = 150000
    +
    # ================================================== ===============
    # Community board configuration
    # ================================================== ===============


    e devo inserirle in file .properties..... non so cosa fare...

  2. #2
    Utente di HTML.it L'avatar di andbin
    Registrato dal
    Jan 2006
    residenza
    Italy
    Messaggi
    18,284
    Il formato di un file di properties è spiegato qui
    Andrea, andbin.devSenior Java developerSCJP 5 (91%) • SCWCD 5 (94%)
    java.util.function Interfaces Cheat SheetJava Versions Cheat Sheet

  3. #3
    Utente di HTML.it
    Registrato dal
    Jul 2007
    Messaggi
    7
    basta quindi che tolgo i "+" e faccio copia incolla?

    se invece dovessi inserire istruzioni nella stessa maniera ma in un file .java?

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.