[DEFNAME virtue_levels]
SACRIFICE_L1 01
SACRIFICE_L2 02
SACRIFICE_L3 04
VALOR_L1 08
VALOR_L2 010
VALOR_L3 020
COMPASSION_L1 040
COMPASSION_L2 080
COMPASSION_L3 0100
HONESTY_L1 0200
HONESTY_L2 0400
HONESTY_L3 0800
HONOR_L1 01000
HONOR_L2 02000
HONOR_L3 04000
HUMILITY_L1 08000
HUMILITY_L2 010000
HUMILITY_L3 020000
SPIRITUALITY_L1 040000
SPIRITUALITY_L2 080000
SPIRITUALITY_L3 0100000
JUSTICE_L1 0200000
JUSTICE_L2 0400000
JUSTICE_L3 0800000

[plevel 1]
virtudes

[function virtudes]
sDIALOG d_virtudes

[DIALOG d_status_virtudes]
220,135
src.closealldialogs
PAGE 0
resizepic 20 20 2520 300 250
gumppic 60 180 032
gumppic 130 180 032

PAGE 1
dtext 130 55 0 the virtues
button 50 75 04ba 04ba 0 2 1
dtext 70 73 0 Sacrifice
button 50 100 04ba 04ba 0 8 1
dtext 70 98 0 Valor
button 50 125 04ba 04ba 0 3 1
dtext 70 123 0 Compassion
button 50 150 04ba 04ba 0 0 0
dtext 70 148 0 Honesty
button 170 75 04ba 04ba 0 4 1
dtext 190 73 0 Honor
button 170 100 04ba 04ba 0 5 1
dtext 190 98 0 Humility
button 170 125 04ba 04ba 0 6 1
dtext 190 123 0 Spirituality
button 170 150 04ba 04ba 0 7 1
dtext 190 148 0 Justice
dtext 70 195 0 Click the blue button
dtext 70 210 0 to check your status.
button 270 30 4016 4015 1 0 2

PAGE 2
for 9
gumppic <EVAL (<LOCAL._FOR>*20)+60> 33 0938
endfor
button 270 30 4016 4015 0 1 1
dtext 130 55 0 Sacrifice
xmfhtmlgumpcolor 50 75 235 200 1052053 0 0 1

IF !(<TAG0.VIRTUDES.SACRIFICE>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
LOCAL.SACTEXT=1052044
button 60 242 04ba 04ba 1 0 10
dtext 80 240 0 Start the path of this virtue.
ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
LOCAL.SACTEXT=1052050
ELIF (<TAG0.VIRTUDES.SACRIFICE>==1)
LOCAL.SACTEXT=1052045
ELIF (<TAG0.VIRTUDES.SACRIFICE> <= 40000)
LOCAL.SACTEXT=1052046
ELIF (<TAG0.VIRTUDES.SACRIFICE> <= 100000)
LOCAL.SACTEXT=1052047
ELIF (<TAG0.VIRTUDES.SACRIFICE> <= 190000)
LOCAL.SACTEXT=1052048
ELIF (<TAG0.VIRTUDES.SACRIFICE> <= 220000)
LOCAL.SACTEXT=1052049
ENDIF

xmfhtmlgumpcolor 50 195 220 40 <dLOCAL.SACTEXT> 0 0 1

PAGE 3
for 9
gumppic <EVAL (<LOCAL._FOR>*20)+60> 33 0938
endfor
button 270 30 4016 4015 0 1 1
dtext 130 55 0 Compassion
xmfhtmlgumpcolor 50 75 235 200 1052054 0 0 1

IF !(<TAG0.VIRTUDES.COMPASSION>) && !(<TAG0.VIRTUDES>&<DEF.COMPASSION_L3>)
LOCAL.COMPTEXT=1052044
button 60 242 04ba 04ba 1 0 11
dtext 80 240 0 Start the path of this virtue.
ELIF (<TAG0.VIRTUDES>&<DEF.COMPASSION_L3>)
LOCAL.COMPTEXT=1052050
ELIF (<TAG0.VIRTUDES.COMPASSION>==1)
LOCAL.COMPTEXT=1052045
ELIF (<TAG0.VIRTUDES.COMPASSION> <= 40000)
LOCAL.COMPTEXT=1052046
ELIF (<TAG0.VIRTUDES.COMPASSION> <= 100000)
LOCAL.COMPTEXT=1052047
ELIF (<TAG0.VIRTUDES.COMPASSION> <= 190000)
LOCAL.COMPTEXT=1052048
ELIF (<TAG0.VIRTUDES.COMPASSION> <= 220000)
LOCAL.COMPTEXT=1052049
ENDIF

xmfhtmlgumpcolor 50 195 220 40 <dLOCAL.COMPTEXT> 0 0 1

PAGE 4
for 9
gumppic <EVAL (<LOCAL._FOR>*20)+60> 33 0938
endfor
button 270 30 4016 4015 0 1 1
dtext 130 55 0 Honor
xmfhtmlgumpcolor 50 75 235 200 1052058 0 0 1

dhtmlgump 50 195 245 200 0 0 You haven't started your path in this virtue.

PAGE 5
for 9
gumppic <EVAL (<LOCAL._FOR>*20)+60> 33 0938
endfor
button 270 30 4016 4015 0 1 1
dtext 130 55 0 Humility
xmfhtmlgumpcolor 50 75 235 200 1052051 0 0 1

dhtmlgump 50 195 245 200 0 0 You haven't started your path in this virtue.

PAGE 6
for 9
gumppic <EVAL (<LOCAL._FOR>*20)+60> 33 0938
endfor
button 270 30 4016 4015 0 1 1
dtext 130 55 0 Spirituality
xmfhtmlgumpcolor 50 75 235 200 1052056 0 0 1

IF !(<TAG0.VIRTUDES.Spirituality>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
LOCAL.SPIRITTEXT=1052044
button 60 242 04ba 04ba 1 0 13
dtext 80 240 0 Start the path of this virtue.
ELIF (<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
LOCAL.SPIRITTEXT=1052050
ELIF (<TAG0.VIRTUDES.Spirituality> == 1)
LOCAL.SPIRITTEXT=1052045
ELIF (<TAG0.VIRTUDES.Spirituality> <= 10000)
LOCAL.SPIRITTEXT=1052046
ELIF (<TAG0.VIRTUDES.Spirituality> <= 50000)
LOCAL.SPIRITTEXT=1052047
ELIF (<TAG0.VIRTUDES.Spirituality> <= 90000)
LOCAL.SPIRITTEXT=1052048
ELIF (<TAG0.VIRTUDES.Spirituality> <= 300000)
LOCAL.SPIRITTEXT=1052049
ENDIF

xmfhtmlgumpcolor 50 195 220 40 <dLOCAL.SPIRITTEXT> 0 0 1

PAGE 7
for 9
gumppic <EVAL (<LOCAL._FOR>*20)+60> 33 0938
endfor
button 270 30 4016 4015 0 1 1
dtext 130 55 0 Justice
xmfhtmlgumpcolor 50 75 235 200 1052059 0 0 1

IF !(<TAG0.VIRTUDES.Justice>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L3>)
LOCAL.JUSTTEXT=1052044
button 60 242 04ba 04ba 1 0 12
dtext 80 240 0 Start the path of this virtue.
ELIF (<TAG0.VIRTUDES>&<DEF.Justice_L3>)
LOCAL.JUSTTEXT=1052050
ELIF (<TAG0.VIRTUDES.Justice>==1)
LOCAL.JUSTTEXT=1052045
ELIF (<TAG0.VIRTUDES.Justice> <= 8600)
LOCAL.JUSTTEXT=1052046
ELIF (<TAG0.VIRTUDES.Justice> <= 20000)
LOCAL.JUSTTEXT=1052047
ELIF (<TAG0.VIRTUDES.Justice> <= 29000)
LOCAL.JUSTTEXT=1052048
ELIF (<TAG0.VIRTUDES.Justice> <= 30000)
LOCAL.JUSTTEXT=1052049
ENDIF

xmfhtmlgumpcolor 50 195 220 40 <dLOCAL.JUSTTEXT> 0 0 1

PAGE 8
for 9
gumppic <EVAL (<LOCAL._FOR>*20)+60> 33 0938
endfor
button 270 30 4016 4015 0 1 1
dtext 130 55 0 Valor
xmfhtmlgumpcolor 50 75 235 200 1054033 0 0 1

IF !(<TAG0.VIRTUDES.Valor>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L3>)
LOCAL.JUSTTEXT=1052044
button 60 242 04ba 04ba 1 0 12
dtext 80 240 0 Start the path of this virtue.
ELIF (<TAG0.VIRTUDES>&<DEF.Valor_L3>)
LOCAL.VALORTEXT=1052050
ELIF (<TAG0.VIRTUDES.Valor>==1)
LOCAL.VALORTEXT=1052045
ELIF (<TAG0.VIRTUDES.Valor> <= 1000)
LOCAL.VALORTEXT=1052046
ELIF (<TAG0.VIRTUDES.Valor> <= 5000)
LOCAL.VALORTEXT=1052047
ELIF (<TAG0.VIRTUDES.Valor> <= 10000)
LOCAL.VALORTEXT=1052048
ELIF (<TAG0.VIRTUDES.Valor> <= 20000)
LOCAL.VALORTEXT=1052049
ENDIF

xmfhtmlgumpcolor 50 195 220 40 <dLOCAL.VALORTEXT> 0 0 1

[DIALOG d_status_virtudes BUTTON]
ON=2
SDIALOG d_VIRTUDES

ON=10
IF (STRCMPI(Shrine of Sacrifice,<REGION.NAME>))
SYSMESSAGE @946,3,1 You're not at Shrine of Sacrifice.
SDIALOG d_status_virtudes
ELSE
TAG.VIRTUDES.SACRIFICE=1
EFFECT 3,i_fx_bless_effect
SDIALOG d_VIRTUDES
ENDIF

ON=11
IF (STRCMPI(Shrine of Compassion,<REGION.NAME>))
SYSMESSAGE @946,3,1 You're not at Shrine of Compassion.
SDIALOG d_status_virtudes
ELSE
TAG.VIRTUDES.COMPASSION=1
EFFECT 3,i_fx_bless_effect
SDIALOG d_VIRTUDES
ENDIF

ON=12
IF (STRCMPI(Shrine of Justice,<REGION.NAME>))
SYSMESSAGE @946,3,1 You're not at Shrine of Justice.
SDIALOG d_status_virtudes
ELSE
EVENTS +E_VIRT_JUSTICE
TAG.VIRTUDES.Justice=1
EFFECT 3,i_fx_bless_effect
SDIALOG d_VIRTUDES
ENDIF

ON=13
IF (STRCMPI(Shrine of Spirituality,<REGION.NAME>))
SYSMESSAGE @946,3,1 You're not at Shrine of Spirituality.
SDIALOG d_status_virtudes
ELSE
TAG.VIRTUDES.Spirituality=1
EFFECT 3,i_fx_bless_effect
SDIALOG d_SPIRIT_ESCOLHA
ENDIF

[DIALOG d_virtudes]
170,120
src.closealldialogs
PAGE 1
gumppic 50 40 068

IF (<TAG0.VIRTUDES.SACRIFICE>) || (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
button 55 135 06e 06e 1 0 1 //Sacrifice
	IF !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1025386
	ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1051009
	ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1051017
	gumppic 55 135 06e 45
	ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1051025
	gumppic 55 135 06e 43
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.VALOR>) || (<TAG0.VIRTUDES>&<DEF.Valor_L3>)
button 142 45 070 070 1 0 2 //Valor
	IF !(<TAG0.VIRTUDES>&<DEF.Valor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1025305
	ELIF (<TAG0.VIRTUDES>&<DEF.Valor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1051012
	ELIF (<TAG0.VIRTUDES>&<DEF.Valor_L1>) && (<TAG0.VIRTUDES>&<DEF.Valor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1051020
	gumppic 142 45 070 39
	ELIF (<TAG0.VIRTUDES>&<DEF.Valor_L1>) && (<TAG0.VIRTUDES>&<DEF.Valor_L2>) && (<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1051028
	gumppic 142 45 070 36
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Compassion>) || (<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
button 231 133 069 069 1 0 3 //Compassion
	IF !(<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1025288
	ELIF (<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1051010
	ELIF (<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && (<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1051018
	gumppic 231 133 069 355
	ELIF (<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && (<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && (<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1051026
	gumppic 231 133 069 354
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Honesty>) || (<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
button 142 220 06A 06A 1 0 4 //Honesty
	IF !(<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1025281
	ELIF (<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1051015
	ELIF (<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && (<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1051023
	gumppic 142 220 06A 300
	ELIF (<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && (<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && (<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1051031
	gumppic 142 220 06A 3
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Honor>) || (<TAG0.VIRTUDES>&<DEF.Honor_L3>)
button 205 70 06B 06B 1 0 5 //Honor
	IF !(<TAG0.VIRTUDES>&<DEF.Honor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1025322
	ELIF (<TAG0.VIRTUDES>&<DEF.Honor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1051013
	ELIF (<TAG0.VIRTUDES>&<DEF.Honor_L1>) && (<TAG0.VIRTUDES>&<DEF.Honor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1051021
	gumppic 205 70 06B 215
	ELIF (<TAG0.VIRTUDES>&<DEF.Honor_L1>) && (<TAG0.VIRTUDES>&<DEF.Honor_L2>) && (<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1051029
	gumppic 205 70 06B 17
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Humility>) || (<TAG0.VIRTUDES>&<DEF.Humility_L3>)
button 80 70 06C 06C 1 0 6 //Humility
	IF !(<TAG0.VIRTUDES>&<DEF.Humility_L1>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L2>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1025328
	ELIF (<TAG0.VIRTUDES>&<DEF.Humility_L1>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L2>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1051008
	ELIF (<TAG0.VIRTUDES>&<DEF.Humility_L1>) && (<TAG0.VIRTUDES>&<DEF.Humility_L2>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1051016
	gumppic 80 70 06C 928
	ELIF (<TAG0.VIRTUDES>&<DEF.Humility_L1>) && (<TAG0.VIRTUDES>&<DEF.Humility_L2>) && (<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1051024
	gumppic 80 70 06C 2305
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Spirituality>) || (<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
button 80 195 06F 06F 1 0 7 //Spirituality
	IF !(<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1025312
	ELIF (<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1051011
	ELIF (<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && (<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1051019
	gumppic 80 195 06F 904
	ELIF (<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && (<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && (<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1051027
	gumppic 80 195 06F 2300
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Justice>) || (<TAG0.VIRTUDES>&<DEF.Justice_L3>)
button 205 195 06D 06D 1 0 8 //Justice
	IF !(<TAG0.VIRTUDES>&<DEF.Justice_L1>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L2>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1025296
	ELIF (<TAG0.VIRTUDES>&<DEF.Justice_L1>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L2>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1051014
	ELIF (<TAG0.VIRTUDES>&<DEF.Justice_L1>) && (<TAG0.VIRTUDES>&<DEF.Justice_L2>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1051022
	gumppic 205 195 06D 478
	ELIF (<TAG0.VIRTUDES>&<DEF.Justice_L1>) && (<TAG0.VIRTUDES>&<DEF.Justice_L2>) && (<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1051030
	gumppic 205 195 06D 172
	ENDIF
ENDIF

button 80 270 07EB 07EC 1 0 101
button 210 270 0817 0818 1 0 102

[DIALOG d_virtudes BUTTON]
ON=1
IF !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
TARGETF SACRIFICE_HABILITY
SYSMESSAGE @04ec,3,1 What would you like to sacrifice?
ENDIF

ON=2
IF (<TAG0.VIRTUDES>&<DEF.VALOR_L3>)
TARGETF F_VALOR_HABILITY
SYSMESSAGE @04ec,,2 1054034
ENDIF

ON=7
IF !(<TAG0.VIRTUDES>&<DEF.SPIRITUALITY_L3>)
DIALOG d_SPIRIT_ESCOLHA
SYSMESSAGE @04ec,3,1 Choose your task.
ENDIF

ON=8
IF (<TAG0.VIRTUDES>&<DEF.JUSTICE_L1>)
TARGETF JUSTICE_HABILITY
SYSMESSAGELOC -1,1049366
ENDIF

ON=101
SDIALOG d_STATUS_VIRTUDES

/////////Virtudes para os outros//////////////////

[DIALOG d_virtudes_para_outros]
170,120
src.closealldialogs
PAGE 1
gumppic 50 40 068

IF (<TAG0.VIRTUDES.SACRIFICE>) || (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1025386
	ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1051009
	ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1051017
	gumppic 55 135 06e 45
	ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>) && (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>) && (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	tooltip 1051025
	gumppic 55 135 06e 43
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.VALOR>) || (<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.Valor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1025305
	ELIF (<TAG0.VIRTUDES>&<DEF.Valor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1051012
	ELIF (<TAG0.VIRTUDES>&<DEF.Valor_L1>) && (<TAG0.VIRTUDES>&<DEF.Valor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1051020
	gumppic 142 45 070 39
	ELIF (<TAG0.VIRTUDES>&<DEF.Valor_L1>) && (<TAG0.VIRTUDES>&<DEF.Valor_L2>) && (<TAG0.VIRTUDES>&<DEF.Valor_L3>)
	tooltip 1051028
	gumppic 142 45 070 36
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Compassion>) || (<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1025288
	ELIF (<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1051010
	ELIF (<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && (<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && !(<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1051018
	gumppic 231 133 069 355
	ELIF (<TAG0.VIRTUDES>&<DEF.Compassion_L1>) && (<TAG0.VIRTUDES>&<DEF.Compassion_L2>) && (<TAG0.VIRTUDES>&<DEF.Compassion_L3>)
	tooltip 1051026
	gumppic 231 133 069 354
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Honesty>) || (<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1025281
	ELIF (<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1051015
	ELIF (<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && (<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1051023
	gumppic 142 220 06A 300
	ELIF (<TAG0.VIRTUDES>&<DEF.Honesty_L1>) && (<TAG0.VIRTUDES>&<DEF.Honesty_L2>) && (<TAG0.VIRTUDES>&<DEF.Honesty_L3>)
	tooltip 1051031
	gumppic 142 220 06A 3
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Honor>) || (<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.Honor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1025322
	ELIF (<TAG0.VIRTUDES>&<DEF.Honor_L1>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1051013
	ELIF (<TAG0.VIRTUDES>&<DEF.Honor_L1>) && (<TAG0.VIRTUDES>&<DEF.Honor_L2>) && !(<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1051021
	gumppic 205 70 06B 215
	ELIF (<TAG0.VIRTUDES>&<DEF.Honor_L1>) && (<TAG0.VIRTUDES>&<DEF.Honor_L2>) && (<TAG0.VIRTUDES>&<DEF.Honor_L3>)
	tooltip 1051029
	gumppic 205 70 06B 17
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Humility>) || (<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.Humility_L1>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L2>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1025328
	ELIF (<TAG0.VIRTUDES>&<DEF.Humility_L1>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L2>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1051008
	ELIF (<TAG0.VIRTUDES>&<DEF.Humility_L1>) && (<TAG0.VIRTUDES>&<DEF.Humility_L2>) && !(<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1051016
	gumppic 80 70 06C 928
	ELIF (<TAG0.VIRTUDES>&<DEF.Humility_L1>) && (<TAG0.VIRTUDES>&<DEF.Humility_L2>) && (<TAG0.VIRTUDES>&<DEF.Humility_L3>)
	tooltip 1051024
	gumppic 80 70 06C 2305
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Spirituality>) || (<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1025312
	ELIF (<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1051011
	ELIF (<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && (<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1051019
	gumppic 80 195 06F 904
	ELIF (<TAG0.VIRTUDES>&<DEF.Spirituality_L1>) && (<TAG0.VIRTUDES>&<DEF.Spirituality_L2>) && (<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
	tooltip 1051027
	gumppic 80 195 06F 2300
	ENDIF
ENDIF

IF (<TAG0.VIRTUDES.Justice>) || (<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	IF !(<TAG0.VIRTUDES>&<DEF.Justice_L1>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L2>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1025296
	ELIF (<TAG0.VIRTUDES>&<DEF.Justice_L1>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L2>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1051014
	ELIF (<TAG0.VIRTUDES>&<DEF.Justice_L1>) && (<TAG0.VIRTUDES>&<DEF.Justice_L2>) && !(<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1051022
	gumppic 205 195 06D 478
	ELIF (<TAG0.VIRTUDES>&<DEF.Justice_L1>) && (<TAG0.VIRTUDES>&<DEF.Justice_L2>) && (<TAG0.VIRTUDES>&<DEF.Justice_L3>)
	tooltip 1051030
	gumppic 205 195 06D 172
	ENDIF
ENDIF

button 80 270 07EB 07EC 1 0 101
button 210 270 0817 0818 1 0 102

//////Habilities//////////

[FUNCTION SACRIFICE_HABILITY]
IF (<ARGO.BASEID> != C_LICHE) && (<ARGO.BASEID> != C_Enslaved_Gargoyle) && (<ARGO.BASEID> != C_Enforcer_Gargoyle) && (<ARGO.BASEID> != C_DAEMON) && (<ARGO.BASEID> != C_H_EVILMAGE) && (<ARGO.BASEID> != C_H_EVILMAGE_F)
SYSMESSAGELOC -1,1052014
ELIF (<FAME> < 4000)
SYSMESSAGELOC -1,1052017
ELIF !(<ARGO.CANSEELOS>)
SYSMESSAGELOC -1,1052011
ELIF (<ARGO.HITS> < <HVAL <ARGO.MAXHITS>-((<ARGO.MAXHITS>*15)/100)>)
SYSMESSAGELOC -1,1052013
ELIF (<FLAGS>&STATF_DEAD)
SYSMESSAGE @946,3,1 You can't sacrifice yourself for this creature while being dead.
ELIF (<FLAGS>&statf_invisible) || (<FLAGS>&statf_hidden)
SYSMESSAGELOC -1,1052015
ELSE
	IF !(<FINDID.i_sacrifiquei>)
	SERV.NEWITEM i_sacrifiquei
	NEW.TIMER=<HVAL 60*60*24>
	NEW.CONT=<UID>
	TAG0.VIRTUDES.SACRIFICE += <FAME>
	FAME=0
	ARGO.EFFECT 3,i_fx_bless_effect,1,20
	ARGO.REMOVE
	SYSMESSAGELOC -1,1052010
		IF (<TAG0.VIRTUDES.SACRIFICE> >= 180000)
		EVENTS +E_SACRIFICE
			IF !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L1>)
			TAG0.VIRTUDES |= <DEF.SACRIFICE_L1>
			TAG.VIRTUDES.SACRIFICE=1
			ELIF !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>)
			TAG0.VIRTUDES |= <DEF.SACRIFICE_L2>
			TAG.VIRTUDES.SACRIFICE=1
			ELIF !(<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
			FINDID.i_sacrifiquei.REMOVE
			TAG0.VIRTUDES |= <DEF.SACRIFICE_L3>
			TAG.VIRTUDES.SACRIFICE
			ENDIF
		SYSMESSAGELOC -1,1052008
		ENDIF
	ELSE
	SYSMESSAGELOC -1,1052016
	ENDIF
ENDIF

[ITEMDEF i_sacrifiquei]
ID=i_memory
TYPE=T_EQ_SCRIPT
NAME=Sacrifiquei

ON=@Timer
CONT.SYSMESSAGE @946,3,1 You can sacrifice your fame once again.
REMOVE
RETURN 1

[EVENTS E_SACRIFICE]
ON=@Death
IF (!(<TAG0.EVENT.ID>) && !(<FINDID.i_pvp_time>))
	IF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L3>)
	LOCAL.RESSES=3
	ELIF (<TAG0.VIRTUDES>&<DEF.SACRIFICE_L2>)
	LOCAL.RESSES=2
	ELSE
		LOCAL.RESSES=1
	ENDIF
	IF (!(<FINDID.i_sacrifice_resses_timer.MORE1> >= <LOCAL.RESSES>))
	TARGETF SACRIFICE_RESS
	SYSMESSAGE @04ec,3,1 If you wish to ressurect target yourself.
	ELSE
	SYSMESSAGELOC 04ec,1052005
	ENDIF
ENDIF

[FUNCTION SACRIFICE_RESS]
IF (<ARGO.UID>==<UID>)
	IF ((!(<UID.<REGION.UID>.ISAMULTI>)) && (<UID.<REGION.UID>.TYPE> != T_SHIP))
	RESURRECT
		IF !(<FINDID.i_sacrifice_resses_timer>)
		SERV.NEWITEM i_sacrifice_resses_timer
		NEW.CONT=<UID>
		ENDIF
		IF !(<FINDID.i_sacrifice_resses_timer.MORE1>)
		FINDID.i_sacrifice_resses_timer.TIMER=<HVAL 60*60*24*6>
		ENDIF
	FINDID.i_sacrifice_resses_timer.MORE1 ++
	ENDIF
ENDIF

[ITEMDEF i_sacrifice_resses_timer]
ID=i_memory
TYPE=T_EQ_SCRIPT
NAME=Sacrifice

ON=@Timer
CONT.SYSMESSAGELOC -1,1052000
REMOVE
RETURN 1

///////////////////////////////

[EVENTS E_VIRT_JUSTICE]
ON=@Kill
IF (<ARGO.ISPLAYER>)
	IF (<ARGO.ISPK>)
	LOCAL.GO=1
	ELIF (<ARGO.GUILD>) && (<GUILD>)
		IF (<ARGO.GUILD.ALIGN> != <GUILD.ALIGN>)
		LOCAL.GO=1
		ENDIF
	ENDIF
	IF (<LOCAL.GO>)
	TAG0.VIRTUDES.JUSTICE += <EVAL ((<ARGO.SKILLTOTAL>*2)-<SKILLTOTAL>)+100>
	SYSMESSAGELOC -1,1049363
		IF (<TAG0.VIRTUDES.JUSTICE> >= 30000)
			IF !(<TAG0.VIRTUDES>&<DEF.JUSTICE_L1>)
			TAG0.VIRTUDES |= <DEF.JUSTICE_L1>
			TAG.VIRTUDES.JUSTICE=1
			ELIF !(<TAG0.VIRTUDES>&<DEF.JUSTICE_L2>)
			TAG0.VIRTUDES |= <DEF.JUSTICE_L2>
			TAG.VIRTUDES.JUSTICE=1
			ELIF !(<TAG0.VIRTUDES>&<DEF.JUSTICE_L3>)
			TAG0.VIRTUDES |= <DEF.JUSTICE_L3>
			TAG.VIRTUDES.JUSTICE
			EVENTS -E_VIRT_JUSTICE
			ENDIF
		SYSMESSAGELOC -1,1049367
		ENDIF
	ENDIF
ENDIF

[FUNCTION JUSTICE_HABILITY]
IF (<ARGO.ISPLAYER>)
	IF (<ARGO.UID> == <UID>)
	SYSMESSAGE @946,3,1 You can't protect yourself.
	ELIF (<FINDID.i_justice_protect_denied>)
	SYSMESSAGELOC -1,1049370
	ELIF ((<ARGO.ISEVENT.e_justice_protected>) || (<ISEVENT.e_justice_protected>))
	SYSMESSAGELOC -1,1049369
	ELSE
	TRYSRC <ARGO.UID> DIALOG d_JUSTICE_PROTECT_ACCEPT
	ARGO.SYSMESSAGELOC -1,1049365
	ENDIF
ELSE
SYSMESSAGE @946,3,1 You can only protect players.
ENDIF

[ITEMDEF i_justice_protect_denied]
ID=i_memory
TYPE=T_EQ_SCRIPT
NAME=Protect Denied

ON=@Timer
REMOVE
RETURN 1

[DIALOG d_JUSTICE_PROTECT_ACCEPT]
200,170
PAGE 0
gumppic 20 20 1140
dhtmlgump 80 65 275 70 0 1 <DEF.BFONT_WHITE><NAME> is offering you his protection. If you accept you can quit at any time by logging out or typing <DEF.BFONT_LCYAN><DEF.U>.cancelprotection<DEF.UE><DEF.BFONT_WHITE>. Do you accept?
button 80 140 025FA 025FB 1 0 1
dtext 115 145 1141 Yes, I do.
button 80 170 025FA 025FB 1 0 2
dtext 115 175 1141 No, I don't.

[DIALOG d_JUSTICE_PROTECT_ACCEPT BUTTON]
ON=2
SYSMESSAGE @946,3,1 <SRC.NAME> denied your offer, you must wait 10 minutes to request another one.
SERV.NEWITEM i_justice_protect_denied
NEW.CONT=<UID>
NEW.TIMER=<EVAL 60*10>

ON=1
IF !(<SRC.ISEVENT.e_justice_protected>)
SYSMESSAGE @946,3,1 <SRC.NAME> accepted your protection offer, now you have a Protection Link.
SRC.SYSMESSAGE @946,3,1 You have accepted the protection of <NAME>.
SRC.EVENTS +e_justice_protected
SRC.TAG.PROTECTOR=<UID>
CTAG.PROTECTED=<SRC>
EVENTS +E_JUSTICE_PROTECTOR
ENDIF

[EVENTS e_justice_protected]
ON=@LogOut
EVENTS -e_justice_protected
REF2=<TAG0.PROTECTOR>
REF2.SYSMESSAGELOC -1,1049371,<NAME>,<REF2.NAME>
REF2.CTAG.PROTECTED=
TAG.PROTECTOR

[EVENTS E_JUSTICE_PROTECTOR]
ON=@LogOut
SERV.ALLCLIENTS CHECK_JUSTPROTECT <UID>
EVENTS -E_JUSTICE_PROTECTOR
CTAG.PROTECTED=

ON=@ReceivePowerScroll
REF1=<CTAG.PROTECTED>
IF (<REF1.DISTANCE> <= 50)
	IF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L3>)
	LOCAL.PORCENTAGEM=100
	ELIF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L2>)
	LOCAL.PORCENTAGEM=80
	ELIF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L1>)
	LOCAL.PORCENTAGEM=60
	ENDIF
FLOAT.DROPCHANCE=<FLOATVAL <dLOCAL.PORCENTAGEM>/100>
	IF (<FLOAT.DROPCHANCE> > <RANDOMDOUBLE>)
	SERV.NEWITEM i_power_scroll
	REF1.BOUNCE <NEW>
	REF1.SYSMESSAGELOC -1,1049368
	ENDIF
ENDIF

ON=@ReceiveTranscendenceScroll
REF1=<CTAG.PROTECTED>
IF (<REF1.DISTANCE> <= 50)
	IF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L3>)
	LOCAL.PORCENTAGEM=100
	ELIF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L2>)
	LOCAL.PORCENTAGEM=80
	ELIF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L1>)
	LOCAL.PORCENTAGEM=60
	ENDIF
FLOAT.DROPCHANCE=<FLOATVAL <dLOCAL.PORCENTAGEM>/100>
	IF (<FLOAT.DROPCHANCE> > <RANDOMDOUBLE>)
	SERV.NEWITEM I_SCROLL_TRANSCENDENCE
	REF1.BOUNCE <NEW>
	REF1.SYSMESSAGELOC -1,1049368
	ENDIF
ENDIF

ON=@ReceiveStatPowerScroll
REF1=<CTAG.PROTECTED>
IF (<REF1.DISTANCE> <= 50)
	IF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L3>)
	LOCAL.PORCENTAGEM=100
	ELIF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L2>)
	LOCAL.PORCENTAGEM=80
	ELIF (<REF1.TAG0.VIRTUDES>&<DEF.JUSTICE_L1>)
	LOCAL.PORCENTAGEM=60
	ENDIF
FLOAT.DROPCHANCE=<FLOATVAL <dLOCAL.PORCENTAGEM>/100>
	IF (<FLOAT.DROPCHANCE> > <RANDOMDOUBLE>)
	SERV.NEWITEM i_stat_power_scroll
	REF1.BOUNCE <NEW>
	REF1.SYSMESSAGELOC -1,1049368
	ENDIF
ENDIF

[FUNCTION CHECK_JUSTPROTECT]
IF (<ISEVENT.e_justice_protected>)
IF (<TAG0.PROTECTOR>==<ARGN1>)
EVENTS -e_justice_protected
REF3=<ARGN1>
REF3.SYSMESSAGELOC -1,1049371,<NAME>,<REF3.NAME>
SYSMESSAGELOC -1,1049371,<NAME>,<REF3.NAME>
TAG.PROTECTOR
ENDIF
ENDIF

[PLEVEL 1]
cancelprotection

[FUNCTION cancelprotection]
IF (<ISEVENT.e_justice_protected>)
EVENTS -e_justice_protected
REF4=<TAG0.PROTECTOR>
REF4.SYSMESSAGELOC -1,1049371,<NAME>,<REF4.NAME>
SYSMESSAGELOC -1,1049371,<NAME>,<REF4.NAME>
REF4.CTAG.PROTECTED
TAG.PROTECTOR
ELSE
SYSMESSAGE @946,3,1 You're not being protected.
ENDIF

///////////////////////////////////////

[DIALOG d_SPIRIT_ESCOLHA]
200,170
src.closealldialogs
PAGE 0
gumppic 20 20 1140
dhtmlgump 80 65 275 70 0 1 <DEF.BFONT_WHITE>You have started your journey on the Spirituality virtue, now you must complete 2 tasks, one for the Virtue of Sacrifice and another for the Virtue of Humility.<DEF.BR>For sacrifice you must kill monsters, but won't receive fame for that.<DEF.BR>For Humility you must deposit 50,000 gold coins in the chest in the Shrine of Spirituality.<DEF.BR>To access this menu again just click on the Spirituality symbol in your Virtues menu.
button 80 140 025FA 025FB 1 0 1
dtext 115 145 1141 Sacrifice
button 80 170 025FA 025FB 1 0 2
dtext 115 175 1141 Humility

[DIALOG d_SPIRIT_ESCOLHA BUTTON]
ON=1
IF !(<TAG0.VIRTUDES>&<DEF.SPIRITUALITY_L3>) && !(<TAG0.SPIRIT.HUMILITY>) && (<TAG0.SPIRIT.ULTIMATAREFA> != 1) && !(<ISEVENT.E_VIRT_SPIRIT_SAC>) && !(<FINDID.i_spirit_timer>)
EVENTS +E_VIRT_SPIRIT_SAC
TAG.SPIRIT.LASTFAME=<FAME>
SYSMESSAGE @04ec,3,1 You've started the Sacrifice task.
ELSE
SYSMESSAGE @946,3,1 You can't do this task.
ENDIF

ON=2
IF !(<TAG0.VIRTUDES>&<DEF.SPIRITUALITY_L3>) && !(<TAG0.SPIRIT.HUMILITY>) && (<TAG0.SPIRIT.ULTIMATAREFA> != 2) && !(<ISEVENT.E_VIRT_SPIRIT_SAC>) && !(<FINDID.i_spirit_timer>)
TAG.SPIRIT.HUMILITY=1
SYSMESSAGE @04ec,3,1 You've started the Humility task.
ELSE
SYSMESSAGE @946,3,1 You can't do this task.
ENDIF

[EVENTS E_VIRT_SPIRIT_SAC]
ON=@FameChange
TAG0.SPIRIT.SACRIFICE += <EVAL <ARGN1>*5>
SYSMESSAGE @04ec,3,1 You have gained on the Sacrifice part of Spirituality.
IF (<TAG0.SPIRIT.SACRIFICE> > 50000)
TAG.SPIRIT.SACRIFICE
EVENTS -E_VIRT_SPIRIT_SAC
TAG.SPIRIT.ULTIMATAREFA=1
TAG.SPIRIT.LASTFAME
TAG0.VIRTUDES.Spirituality += 50000
SERV.NEWITEM i_spirit_timer,1,<UID>
NEW.TIMER=<HVAL 60*60*20>
SYSMESSAGE @04ec,3,1 You have gained on the Spirituality Virtue.
	IF (<TAG0.VIRTUDES.Spirituality> >= 100000)
		IF !(<TAG0.VIRTUDES>&<DEF.Spirituality_L1>)
		TAG0.VIRTUDES |= <DEF.Spirituality_L1>
		TAG.VIRTUDES.Spirituality=1
		ELIF !(<TAG0.VIRTUDES>&<DEF.Spirituality_L2>)
		TAG0.VIRTUDES |= <DEF.Spirituality_L2>
		TAG.VIRTUDES.Spirituality=1
		ELIF !(<TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
		TAG0.VIRTUDES |= <DEF.Spirituality_L3>
		TAG.VIRTUDES.Spirituality
		TAG.SPIRIT.ULTIMATAREFA
		FINDID.i_spirit_timer.REMOVE
		ENDIF
	SYSMESSAGE @04ec,3,1 You have gained a path in the spirituality virtue.
	ENDIF
ENDIF
RETURN 1

[ITEMDEF i_spirit_timer]
ID=i_memory
NAME=spirit timer
TYPE=T_EQ_SCRIPT

ON=@Timer
CONT.SYSMESSAGE @946,3,1 You can do another Spirituality task now.
REMOVE
RETURN 1

[ITEMDEF i_bau_humility]
ID=0e7c
NAME=Humility Chest

ON=@Create
ATTR=ATTR_MOVE_NEVER

ON=@Dropon_Self
IF !(<SRC.TAG0.SPIRIT.HUMILITY>)
SAY @946,3,1 You are not doing the Humility task.
ELIF (<ARGO.BASEID> != i_gold)
SAY @946,3,1 You must put 50,000 gold coins in here.
ELIF (<ARGO.AMOUNT> < 50000)
SAY @946,3,1 You must put 50,000 gold coins in here.
ELSE
ARGO.CONSUME 50000
SAY @946,3,1 Well done <SRC.NAME>, task completed.
SRC.TAG0.VIRTUDES.Spirituality += 50000
SRC.TAG.SPIRIT.HUMILITY
SRC.TAG.SPIRIT.ULTIMATAREFA=2
SERV.NEWITEM i_spirit_timer,1,<SRC>
NEW.TIMER=<HVAL 60*60*20>
SRC.SYSMESSAGE @04ec,3,1 You have gained on the Spirituality Virtue.
	IF (<SRC.TAG0.VIRTUDES.Spirituality> >= 100000)
		IF !(<SRC.TAG0.VIRTUDES>&<DEF.Spirituality_L1>)
		SRC.TAG0.VIRTUDES |= <DEF.Spirituality_L1>
		SRC.TAG.VIRTUDES.Spirituality=1
		ELIF !(<SRC.TAG0.VIRTUDES>&<DEF.Spirituality_L2>)
		SRC.TAG0.VIRTUDES |= <DEF.Spirituality_L2>
		SRC.TAG.VIRTUDES.Spirituality=1
		ELIF !(<SRC.TAG0.VIRTUDES>&<DEF.Spirituality_L3>)
		SRC.TAG0.VIRTUDES |= <DEF.Spirituality_L3>
		SRC.TAG.VIRTUDES.Spirituality
		SRC.TAG.SPIRIT.ULTIMATAREFA
		SRC.FINDID.i_spirit_timer.REMOVE
		ENDIF
	SRC.SYSMESSAGE @04ec,3,1 You conquer a way on the Virtue of Spirituality!
	ENDIF
ENDIF
RETURN 1

////////////////////////////
[FUNCTION F_VALOR_SET_SPAWN_LEVEL]
FOR <ARGN1>
	IF (<MOREX> != 16)
	MOREX ++
	SERV.NEWITEM i_skull_candle
	NEW.TAG.ALWAYSSEND=1
	NEW.COLOR=33
	NEW.TIMER -1
	NEW.ATTR=ATTR_MOVE_NEVER
	TAG0.CANDLES ++
	TRY TAG0.CANDLE.<dTAG0.CANDLES>=<NEW>
	NEW.P=<P>
	NEW.CANDLEP=<TAG0.CANDLES>
	ENDIF
ENDFOR

[FUNCTION F_VALOR_HABILITY]
IF (<ARGO.BASEID> != i_champion_idol)
SYSMESSAGELOC -1,1054035
ELIF (!(<TAG0.VIRTUDES>&<DEF.Valor_L3>))
SYSMESSAGELOC -1,1054036
ELIF (<ARGO.TAG0.VALORTIMES> == 2)
SYSMESSAGELOC -1,1054038
ELIF (<ARGO.TAG0.VALORTIMES> == 0) && (!(<ARGO.TAG0.IDLE>))
ARGO.TIMERD=5
MESSAGE @,,2 1054037
TAG0.IUSEDVALOR ++
ARGO.TIMERF 1,F_VALOR_SET_SPAWN_LEVEL 2
ARGO.TIMERF 1,TIMER=<DEF.CHAMPIONLEVELMINUTE>
ARGO.TAG.VALORTIMES=1
ELIF (<ARGO.TAG0.VALORTIMES> == 1) && (!(<ARGO.TAG0.IDLE>))
MESSAGE @,,2 1054037
TAG0.IUSEDVALOR ++
ARGO.F_VALOR_SET_SPAWN_LEVEL 1
ARGO.TAG.VALORTIMES=2
ENDIF
IF (<TAG0.IUSEDVALOR> == 2)
TAG.IUSEDVALOR=
TAG.VIRTUDES.VALOR=1
TAG0.VIRTUDES &= ~<DEF.VALOR_L1>
TAG0.VIRTUDES &= ~<DEF.VALOR_L2>
TAG0.VIRTUDES &= ~<DEF.VALOR_L3>
	IF (!(<TAG0.VIRTUDES>))
	TAG.VIRTUDES=
	ENDIF
ENDIF

[EOF]