Help Where Can I Set Private Server Buff?

smoochy boys on tour

redmc

LOMCN Rookie
Aug 6, 2021
20
1
5
I recently noticed that in our private server, there is a default server buff, Skill, which is 3x skill EXP gained. Where can I modify the server buffs, Server.exe UI or within files?
 

Moderat

Loyal Member
Loyal Member
Oct 14, 2018
98
8
20
[@Main]
#SAY
Welcome.

<Buff Exp 1hr/@exp10>

<Buff Drop 1hr/@drop10>

[@exp10]

#IF
#ACT
GIVEBUFF Exp 3600 20
LocalMessage "Exp Buffed To 20%" System
<Close/@exit>

[@drop10]

#IF
#ACT
GIVEBUFF Drop 3600 5
LocalMessage "Drop Buffed To 5%" System
<Close/@exit>
Post automatically merged:

I think it will be more convenient through the nps than to search in the server.exe
 
Upvote 0

redmc

LOMCN Rookie
Aug 6, 2021
20
1
5
[@Main]
#SAY
Welcome.

<Buff Exp 1hr/@exp10>

<Buff Drop 1hr/@drop10>

[@exp10]

#IF
#ACT
GIVEBUFF Exp 3600 20
LocalMessage "Exp Buffed To 20%" System
<Close/@exit>

[@drop10]

#IF
#ACT
GIVEBUFF Drop 3600 5
LocalMessage "Drop Buffed To 5%" System
<Close/@exit>
Post automatically merged:

I think it will be more convenient through the nps than to search in the server.exe
I am new to Crystal Mir2 modification or C#. Would you mind explain how the script, or command, is explicitly applied? Thanks.
 
Upvote 0

Moderat

Loyal Member
Loyal Member
Oct 14, 2018
98
8
20
1637937019980.png
Post automatically merged:

select the npc item in the menu and click on it
press the ADD button then write as in the picture the coordinates and locations of the NPS
open the script and paste that text
Post automatically merged:

if you have any questions find me discord
 
Upvote 0

redmc

LOMCN Rookie
Aug 6, 2021
20
1
5
I digged in the file system and have understood a little bit of syntax. The thing is that I want a SKILL EXP BUFF, and I am not sure how to reference it.
 
Upvote 0

Far

tsniffer
Staff member
Developer
May 19, 2003
20,172
30
2,767
540
Theres no way to add buffs to the player which uses stats (like skill) via an npc. NPC "ADDBUFF" command can only add the buff itself and no added stats.

If you want to add the skill buff this is only possible via an equippable item. Where you'd just tick the "Skill" option under the special item modes.

The method Moderat explains is from older files which will no longer work with the latest source (due to a much improved buff system).

If you want to give all players a permanent skill boost i'd probably recommend creating a new buff type in code give applies under the rules you want.

If you look in the BuffInfo.cs class you can find all existing buffs and add a new one with the rules you want. Then all you need to do is apply it when you want. For example if its an infinite buff for everyone under level 50, just look at the ProcessBuffs method and follow how all the existing infinite buffs work, or you could apply it via an item etc.
 
Upvote 0