Buff System

05/12/2013 00:12 Thelxinoe#1
This is how to make an auto buffing system with ranks.

Begin with
Code:
function get_module_name()
				return "Auto_Buff"
end
Admin

Code:
function player_login_auto_buff()
	local admina = "???" -- Place the name of your first admin/dev's account
	local adminb = "???" -- Place the name of your first admin/dev's account
         add_state(164407,500,8640000) -- Halisha +1000
After that code add GM

Code:
else
		if gv("permission") == 1 then -- GM Buffs
Then for players

Code:
elseif gv("lv") > 19 and gv("lv") < 50 then -- Rank 2 Buffs (Levels 20-49)
				add_state(164407,10,8640000) -- Halisha + 20

			elseif gv("lv") > 49 and gv("lv") < 80 then -- Rank 3 Buffs (Levels 50-79)
				add_state(164407,15,8640000) -- Halisha + 30
				
			elseif gv("lv") > 79 and gv("lv") < 100 then -- Rank 4 Buffs (Levels 80-99)
				add_state(164407,20,8640000) -- Halisha + 40
				
			elseif gv("lv") > 99 and gv("lv") < 120 then -- Rank 5 Buffs (Levels 100-119)
				add_state(164407,25,8640000) -- Halisha + 50
				
			elseif gv("lv") > 119 and gv("lv") < 155 then -- Rank 6 Buffs (Levels 120-154)
				add_state(164407,30,8640000) -- Halisha + 60
				
			elseif gv("lv") > 154 and gv("lv") < 170 then -- Rank 7 Buffs (Levels 155-169)
				add_state(164407,35,8640000) -- Halisha + 70
				
			elseif gv("lv") > 170 then -- Everyone level 170+
				add_state(164407,50,8640000) -- Halisha + 100
				
			end
		end
	end
end
You may add more buffs!!!!

Noticing the haracement and the intimidation done to me by Skype about me using Heaaven's coding lines, I'm sorry to announce that I learnt to do it like that and all resemblance with Heaven's scripts is either coincedence or subconsionce (I have seen his scripts) Noticing that possibiliy and with the request of Heaven I'm adding this:
base By: HeavenOnlyWishes
--
-- Copyright @ 2011. Ningyo Networ
05/12/2013 00:30 Xijezu#2
Quote:
Originally Posted by Thelxinoe View Post
Code:
function player_login_auto_buff()
	local admina = "???" -- Place the name of your first admin/dev's account
	local adminb = "???" -- Place the name of your first admin/dev's account
         add_state(164407,500,8640000) -- Halisha +1000
So... In this case the player will get the buff even if he is not "admina" or "adminb", those variables are just way useless in this example.

Quote:
Originally Posted by Thelxinoe View Post
Code:
else
		if gv("permission") == 1 then -- GM Buffs
then what?

This is more confusing than helpful (well, I do understand it, and for sure you have to add things, but everyone who can "fix" this can write it way easier on his own).
05/12/2013 00:55 Tiestoo#3
Let him stay happy a lil bit for discovering that for him ^_^
05/12/2013 02:51 HeavenOnlyWishes#4
Actually, I let him have the Auto Buff System V2 and V3 scripts that I had originally made for ToE back in the day.... this is code directly taken from those scripts..... Never the less it's nothing but leeched content that I released like over a year ago....

Lol.

TheIxinoe you are officially off of our project. Pack you bags, newb!

P.S. You should also note these were made for the 6.3 server files.... they are totally out dated for current systems.

You can find these files here:

[Only registered and activated users can see links. Click Here To Register...]

[Only registered and activated users can see links. Click Here To Register...]

[Only registered and activated users can see links. Click Here To Register...]

[Only registered and activated users can see links. Click Here To Register...]
05/12/2013 05:12 Xijezu#5
^Since it's obviously Heaven's work:

#closed