The Begin,
Download The Tibia RPG Script
http://www.unrealsoftware.de/files_show.php?file=1135
Then Open Your Wrapper.txt delete the 2 functions about map.
Now, Let's Edit!
Make Your Own Map(if you want)
Lua ScriptsSection : sys/lua/cs2dtibia/config.lua
Edit Your MSG (if you want)
Change Maxmonsters or Maxitems(if you want)
EXP,STATS,STATSMENU (Never Edit!)
Playerinit:
Experience = 0,(if you want)
Level = 1,(if you want)
Money = 1000,(if you want)
HP = 100,(never)(not reccomend to change)
MP = 100,(never)(not reccomend to change)
Inventory = {}, (if you want)
Equipment = {}, (if you want)
Spawn = {1632, 1600}, (if you want)(need if you changed the original map as how i sayd)
Tutorial = {},(never)(not reccomend to change)
Info = {},(never)(not reccomend to change)
Slots:
Edit Them!
Add Your Own If You Want!
Don't Add More than 9 (but if you want go to functions.lua section)
HUDTEXT,PIXELS (don't change them)
COLOURS: Mine Look Like This :
COLOURS = {},
Rates:
EXPRATE = 1,
MONEYRATE = 1,
DROPRATE = 1,
PLAYERMONEYRATE = 1,
PLAYERDROPRATE = 2000,
(Change Them If You Want)
Exhaust
EXHAUST = {
TALK = 500,
PICK = 500,
USE = 2000,
},
(Don't Change)
Range:
WEAPONRANGE = {
[34] = 350,
[46] = 128,
[50] = 27,
[69] = 32,
[78] = 32,
},
WEAPONWIDTH = {
[34] = math.pi/12,
[46] = math.pi/8,
[50] = math.pi*2/3,
[69] = math.pi*2/3,
[78] = math.pi*2/3,
}
}
(Go To Bugs/Suggestions Section For This!)
SAFEZONE = {
{{0,0},{77,75}},
}
PVPZONE = {
{{0,0},{0,0},{0,0}},
}
HOUSES = {}
(Change Them If You Want) ( These are mine )
Finish With The Config!
Section : sys/lua/cs2dtibia/server.lua
The Original :
We'll go edit from Line : HUDImage
HUDImage:
(Change It If you want)(Its The Image Where Shows You Exp,Lvl,Gold...)
HUDRadar:
The PokeBall As Ur Radar
(Change It If you want)
Section : sys/lua/cs2dtibia/commands.lua
Don't Change Them...Most Player Know Just These commands!
Section : sys/lua/cs2dtibia/admin.lua
Add Or Edit Here The Commands!
I Will Give you later some usefull commands to add!(eg !noclip,!vip)
Section : sys/lua/cs2dtibia/functions.lua
Here are the commands used in this script anyway...dont change them please!
Section : sys/lua/cs2dtibia/hooks.lua
Finaly...hooks! Arshhh Hate Them
You can Edit Them and add your own ( I will add here some too )
Don't Change Their Basic!
Weiwen Work much to do them!
Section : sys/lua/cs2dtibia/items.lua
Most of peoples has some troubles there
Click Here to see how I helped here!
Let's See How To add Items!
Comestible Items:
1
2
3
4
5
6
7
8
9
10
2
3
4
5
6
7
8
9
10
[1] = {
		name = "apple",
		article = "an",
		desc = "No visible worms.",
		r = 255, g = 0, b = 0,
		action = "eat",
		food = function() return math.random(10,20) end,
		fimage = "gfx/weiwen/apple.png",
		func = eat,
	},
Let me edit it a little
1
2
3
4
5
6
7
8
9
2
3
4
5
6
7
8
9
[1] = {
		name = "Milk Box",
		article = "A",
		desc = "For Strong Health.",
		action = "eat",
		food = function() return math.random(40,50) end,
		fimage = "gfx/food/milkbox.png",
		func = eat,
	},
1
food = function() return math.random(40,50)
Easy!
Equipament:
1
2
3
4
5
6
7
8
9
10
11
12
2
3
4
5
6
7
8
9
10
11
12
[300] = {
		name = "leather helmet",
		desc = "Protect yourself from headshots!",
		r = 128, g = 64, b = 0,
		action = "equip",
		slot = 1,
		eimage = "gfx/weiwen/helmet.png",
		fimage = "gfx/weiwen/helmet.png",
		def = 0.05,
		speed = -1,
		func = equip,
	},
Swords:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
2
3
4
5
6
7
8
9
10
11
12
13
14
15
[304] = {
		name = "wooden sword",
		desc = "Mostly used for training.",
		r = 128, g = 64, b = 0,
		action = "equip",
		slot = 3,
		eimage = "gfx/weiwen/sword.png",
		fimage = "gfx/weiwen/sword.png",
		offsetx = 6,
		offsety = 17,
		equip = 69,
		atk = 0.25,
		speed = -1,
		func = equip,
	},
do same as Equipament but here replace def to atk...and offsets you dont need them always, depends on the png you use! you can use with black background (RGB 0 0 0)It still make Translucent Color
Shooting Weapons:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
2
3
4
5
6
7
8
9
10
11
12
13
14
15
[307] = {
		name = "wooden crossbow",
		desc = "It requires you to hold it with two hands.",
		r = 128, g = 64, b = 0,
		action = "equip",
		slot = 3,
		twohand = true,
		eimage = "gfx/weiwen/bow.png",
		fimage = "gfx/weiwen/bow.png",
		offsety = 9,
		equip = 34,
		atk = 0.1,
		speed = -2.5,
		func = equip,
	},
Mounts:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
2
3
4
5
6
7
8
9
10
11
12
13
14
[401] = {
		name = "white horse",
		desc = "You move faster with it, but are unable to attack with it. Your defence is also reduced significantly.",
		r = 255, g = 255, b = 255,
		action = "ride",
		slot = 7,
		ground = true,
		fimage = "gfx/weiwen/horse.png",
		eimage = "gfx/weiwen/horse.png",
		speed = 20,
		def = -0.5,
		level = 10,
		func = equip,
	},
1
level = 10,
Section : sys/lua/cs2dtibia/npcs.lua
add your own or edit them
Position: just get into the game go to the tile u want for npc and say !n then the coordoinates will show! or
be clever and open editor then go to tile eg 0|0 and let's make it! 0*32=32+16 = 48 so the npc's pos is {48,48}
Section : sys/lua/cs2dtibia/monsters.lua
ah hard just edit them i dont know what to say here...
Bugs & SuggestionsWEAPONWIDTH & WEAPONRANGE
Do this theory:
Well if you find another... please post them here
Sry for my bad english
If something is wrong please escuse me!
With sinceritly Hano.ro
edited 3×, last 28.04.11 11:52:17 am
CS2D Tibia Helр For Begginers!
1 
CS2D Tibia Helр For Begginers!
Offline

Bobakrome