First chose what trigger or what auto reborn system do you want to use.
How to install?
1. Open your SQL manager and go to RanGame1 > Tables > ChaInfo
2. Rightclick dbo.ChaInfo and click Design Table
Go to the bottom of the list that appearst
there at the Column name put "ChaReborn"
datatype : Smallint
allow "NULL"
when you're done save the edits and open the tree of dbo.ChaInfo and find "Trigger"
Rightclick Trigger and click "New Trigger"
Copy and Execute the trigger that you have chosen.
For EP4 "only"
Features:
Normal Class
Req. Lv to Reborn = 300
Max Reborn = 50
Stats per Reborn = 300
Reborn Cost = 50m per reborn
NewClassMan/Woman
Req. Lv to Reborn = 300
Max Reborn = 60
Stats per Reborn = 400
Reborn Cost = 100m per reborn
Class: SM, Fighter will change into NewClassMan when you reach 50rb and 300Lv's and 1b gold
Class Shaman, Archer will change into NewClassWoman when you reach 50rb and 300Lv's and 1b gold
after ChangeInto mix class you will gained 5k Stat points, but your reborn will go back to 0
Code:
CREATE TRIGGER [dbo].[Auto_RB_CHCLASS] ON [dbo].[ChaInfo]
after update
as
BEGIN
Update [ChaInfo] set [ChaInfo].ChaReborn = 1,[ChaInfo].ChaTribe = 1
from Inserted
Where Inserted.ChaTribe = 0
Update [ChaInfo] set [ChaInfo].ChaLevel=1, -- Level that you get after reborn
[ChaInfo].ChaReborn=[ChaInfo].ChaReborn + 1, -- Reborn counter
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 300*[ChaInfo].ChaReborn, -- how many stat points you get per reborn
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 50000000 -- Optional : Reborn cost 50m
From Inserted
Where Inserted.ChaLevel = 300 -- Level to reborn
and [ChaInfo].ChaReborn < 51 -- Max Reborn number
and [ChaInfo].ChaTribe = 1
and [ChaInfo].ChaName=inserted.ChaName
and [ChaInfo].UserNum =inserted.UserNum
and [ChaInfo].ChaMoney >= 50000000 -- Optional : Require 50m gold for reborn
and [ChaInfo].ChaOnline=0
Update [ChaInfo] set [ChaInfo].ChaLevel=1,
[ChaInfo].ChaTribe = 2,
[ChaInfo].ChaClass = 16,
[ChaInfo].ChaReborn=1, -- will go back to 1 reborn after Change to MixClass
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 5000, -- stat points you get when you change into mix class
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaSkills = NULL, -- Optional : Forget all skills after reborn
[ChaInfo].ChaSkillSlot = NULL, -- Optional : Delete shortcut list of skills
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 1000000000 -- Optional : Chang MixClass cost 1b
From inserted
Where Inserted.ChaLevel = 300 -- Level to Change into MixClass
and [ChaInfo].ChaClass = 1
and [ChaInfo].ChaReborn = 51 -- Required RB to Change MixClass
and [ChaInfo].ChaMoney >= 1000000000 -- Optional : Require 1b gold for Change MixClass
and [ChaInfo].ChaName = inserted.ChaName
and [ChaInfo].ChaNum = inserted.ChaNum
Update [ChaInfo] set [ChaInfo].ChaLevel=1,
[ChaInfo].ChaTribe = 2,
[ChaInfo].ChaClass = 16,
[ChaInfo].ChaReborn=1, -- will go back to 1 reborn after Change to MixClass
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 5000, -- stat points you get when you change into mix class
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaSkills = NULL, -- Optional : Forget all skills after reborn
[ChaInfo].ChaSkillSlot = NULL, -- Optional : Delete shortcut list of skills
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 1000000000 -- Optional : Chang MixClass cost 1b
From inserted
Where Inserted.ChaLevel = 300 -- Level to Change into MixClass
and [ChaInfo].ChaClass = 2
and [ChaInfo].ChaReborn = 51 -- Required RB to Change MixClass
and [ChaInfo].ChaMoney >= 1000000000 -- Optional : Require 1b gold for Change MixClass
and [ChaInfo].ChaName = inserted.ChaName
and [ChaInfo].ChaNum = inserted.ChaNum
Update [ChaInfo] set [ChaInfo].ChaLevel=1,
[ChaInfo].ChaTribe = 2,
[ChaInfo].ChaClass = 32,
[ChaInfo].ChaReborn=1, -- will go back to 1 reborn after Change to MixClass
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 5000, -- stat points you get when you change into mix class
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaSkills = NULL, -- Optional : Forget all skills after reborn
[ChaInfo].ChaSkillSlot = NULL, -- Optional : Delete shortcut list of skills
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 1000000000 -- Optional : Chang MixClass cost 1b
From inserted
Where Inserted.ChaLevel = 300 -- Level to Change into MixClass
and [ChaInfo].ChaClass = 4
and [ChaInfo].ChaReborn = 51 -- Required RB to Change MixClass
and [ChaInfo].ChaMoney >= 1000000000 -- Optional : Require 1b gold for Change MixClass
and [ChaInfo].ChaName = inserted.ChaName
and [ChaInfo].ChaNum = inserted.ChaNum
Update [ChaInfo] set [ChaInfo].ChaLevel=1,
[ChaInfo].ChaTribe = 2,
[ChaInfo].ChaClass = 32,
[ChaInfo].ChaReborn=1, -- will go back to 1 reborn after Change to MixClass
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 5000, -- stat points you get when you change into mix class
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaSkills = NULL, -- Optional : Forget all skills after reborn
[ChaInfo].ChaSkillSlot = NULL, -- Optional : Delete shortcut list of skills
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 1000000000 -- Optional : Chang MixClass cost 1b
From inserted
Where Inserted.ChaLevel = 300 -- Level to Change into MixClass
and [ChaInfo].ChaClass = 8
and [ChaInfo].ChaReborn = 51 -- Required RB to Change MixClass
and [ChaInfo].ChaMoney >= 1000000000 -- Optional : Require 1b gold for Change MixClass
and [ChaInfo].ChaName = inserted.ChaName
and [ChaInfo].ChaNum = inserted.ChaNum
Update [ChaInfo] set [ChaInfo].ChaLevel=1, -- Level that you get after reborn
[ChaInfo].ChaReborn=[ChaInfo].ChaReborn + 1, -- Reborn counter
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 400*[ChaInfo].ChaReborn+5000, -- how many stat points you get per reborn (+5000 is reward stat you get from Change Mixclass)
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 100000000 -- Optional : Reborn cost 100m
From Inserted
Where Inserted.ChaLevel = 300 -- Level to reborn
and [ChaInfo].ChaReborn < 61 -- Max Reborn number
and [ChaInfo].ChaTribe = 2
and [ChaInfo].ChaClass = 16
and [ChaInfo].ChaName=inserted.ChaName
and [ChaInfo].UserNum =inserted.UserNum
and [ChaInfo].ChaMoney >= 100000000 -- Optional : Require 100m gold for reborn
and [ChaInfo].ChaOnline=0
Update [ChaInfo] set [ChaInfo].ChaLevel=1, -- Level that you get after reborn
[ChaInfo].ChaReborn=[ChaInfo].ChaReborn + 1, -- Reborn counter
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 400*[ChaInfo].ChaReborn+5000, -- how many stat points you get per reborn (+5000 is reward stat you get from Change Mixclass)
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 100000000 -- Optional : Reborn cost 100m
From Inserted
Where Inserted.ChaLevel = 300 -- Level to reborn
and [ChaInfo].ChaReborn < 61 -- Max Reborn number
and [ChaInfo].ChaTribe = 2
and [ChaInfo].ChaClass = 32
and [ChaInfo].ChaName=inserted.ChaName
and [ChaInfo].UserNum =inserted.UserNum
and [ChaInfo].ChaMoney >= 100000000 -- Optional : Require 100m gold for reborn
and [ChaInfo].ChaOnline=0
End
This trigger can be used also in EP3, or EP4
Features:
Normal Class/MixClass
Req. Lv to Reborn = 300
Max Reborn = 100
Reborn Cost = 50m
Stats per RB = 300
Code:
CREATE TRIGGER [dbo].[Auto_Reborn] ON [dbo].[ChaInfo]
after update
as
BEGIN
Update [ChaInfo] set [ChaInfo].ChaReborn = 1,[ChaInfo].ChaTribe = 1
from Inserted
Where Inserted.ChaTribe = 0
Update [ChaInfo] set [ChaInfo].ChaLevel=1, -- Level that you get after reborn
[ChaInfo].ChaReborn=[ChaInfo].ChaReborn + 1, -- Reborn counter
[ChaInfo].ChaExp=0, -- Set Exp back to 0
[ChaInfo].ChaStRemain = 300*[ChaInfo].ChaReborn, -- how many stat points you get per reborn
[ChaInfo].ChaPower = 0, -- Set the number of Pow you added to 0
[ChaInfo].ChaStrong = 0, -- Set the number of Vit you added to 0
[ChaInfo].ChaStrength = 0, -- Set the number of Stm you added to 0
[ChaInfo].ChaSpirit = 0, -- Set the number of Spirit you added to 0
[ChaInfo].ChaDex = 0, -- Set the number of Dex you added to 0
[ChaInfo].ChaIntel = 0, -- Set the number of Int you added to 0
[ChaInfo].ChaMoney = [ChaInfo].ChaMoney - 50000000 -- Optional : Reborn cost 50m
From Inserted
Where Inserted.ChaLevel = 300 -- Level to reborn
and [ChaInfo].ChaReborn < 101 -- Max Reborn number
and [ChaInfo].ChaName=inserted.ChaName
and [ChaInfo].UserNum =inserted.UserNum
and [ChaInfo].ChaMoney >= 50000000 -- Optional : Require 50m gold for reborn
and [ChaInfo].ChaOnline=0
End
And add -1 to your reborn from your status.php or rank.php
Like this
Code:
$rbrn = $row3["ChaReborn"]-1;
You need to add this to your status or rank bcoz it will apear in your rank, status..
Ex. i got only 1rb if you look at your cp you will see 2rb thats why...
Credits to all Ragezoner
Thanks to all of you i have learned a lot in here ^_^