• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

[8.60] The Forgotten Server 0.3.6 (Crying Damson) V8

You can edit all this at config and the potions at actions.
 
now i creat new char, no voc and take 8 lvl and have 16 sword 16 shield skill, go to Oracle take knight voc, kill one rat by one hit and take sword skill from 16 to 26 just with one hit, next rat dont take so big jump at skill.
 
omg everything is configureable at config :S

Code:
	accountManager = true   <-- do you want use account manager?
	namelockManager = true   <-- Do you want that account manager search for invaild names?
	newPlayerChooseVoc = true <-- Do you want new player chose vocation at account manager?
	newPlayerSpawnPosX = 1000 <-- X: posistion at the map you want place the account manager?
	newPlayerSpawnPosY = 1000 <-- Y: posistion at the map you want place the account manager?
	newPlayerSpawnPosZ = 7 <-- Z: posistion at the map you want place the account manager?
	newPlayerTownId = 1 <-- Which town do you want player begin at when they create character at account manager?
	newPlayerLevel = 8 <-- New player level when the create character at account manager
	newPlayerMagicLevel = 0 <-- How much do you want new player recive magic when they create character at account manager
	generateAccountNumber = false <-- Do you want that account manager give random account number to new players at account manager?

Code:
	experienceStages = true <-- Do you want use exp stage higher you are lower or high exp is it configureable at data/xml/stages.xml
	rateExperience = 1 <-- How much exprience do you want it to be if the exp stage is false. 1x is real tibia exp!
	rateExperienceFromPlayers = 0 <-- Do you want player recive exp when they kill another player?
	rateSkill = 30 <-- How fast should player recive skill exprience, higher amout faster skill level!
	rateMagic = 15 <-- How fast should player recive magic exprience, higher amout faster magic level!
	rateLoot = 1 <-- How fast should player loot items from dead monsters?
	rateSpawn = 1
<-- Leave it 1!
 
otswe can you write the corrected potions script? becoause i try change it with others potions.lua and it won`t work and write it by my self I do not know how... :/
 
Code:
local config = {
	removeOnUse = "yes", <-- You want potions to be removed when player using them?
	usableOnTarget = "yes", -- can be used on target? (fe. healing friend) <-- Can potion be used on other players?
	splashable = "yes", <-- If you miss potion on the ground do you want it splash and be empty vial?
	realAnimation = "no", -- make text effect visible only for players in range 1x1
	healthMultiplier = 1.0, <-- This is math so figure out your self.
	manaMultiplier = 1.0 <-- This is math so figure out your self.
}

config.removeOnUse = getBooleanFromString(config.removeOnUse)
config.usableOnTarget = getBooleanFromString(config.usableOnTarget)
config.splashable = getBooleanFromString(config.splashable)
config.realAnimation = getBooleanFromString(config.realAnimation)

local POTIONS = {
	[8704] = {empty = 7636, splash = 2, health = {50, 100}}, -- small health potion <-- {50, 100}}, Means 50~~100 between those number just change the numbers to increase or decrease the healing.
	[7618] = {empty = 7636, splash = 2, health = {100, 200}}, -- health potion
	[7588] = {empty = 7634, splash = 2, health = {200, 400}, level = 50, vocations = {3, 4, 7, 8}, vocStr = "knights and paladins"}, -- strong health potion <-- {50, 100}}, Means 50~~100 between those number just change the numbers to increase or decrease the healing. level = 50, how much level should the player to be to use this potion.  vocations = {3, 4, 7, 8}, <-- Which vocations can use the potion 1: Sorcerer 2: Druid 3: Paladin 4: Knight 5: Master Sorcerer 6: Elder Druid 7: Royal Paladin 8: Elite Knight. vocStr = "knights and paladins" <-- this is description when you use the potion.
	[7591] = {empty = 7635, splash = 2, health = {500, 700}, level = 80, vocations = {4, 8}, vocStr = "knights"}, -- great health potion
	[8473] = {empty = 7635, splash = 2, health = {800, 1000}, level = 130, vocations = {4, 8}, vocStr = "knights"}, -- ultimate health potion

	[7620] = {empty = 7636, splash = 7, mana = {70, 130}}, -- mana potion
	[7589] = {empty = 7634, splash = 7, mana = {110, 190}, level = 50, vocations = {1, 2, 3, 5, 6, 7}, vocStr = "sorcerers, druids and paladins"}, -- strong mana potion
	[7590] = {empty = 7635, splash = 7, mana = {200, 300}, level = 80, vocations = {1, 2, 5, 6}, vocStr = "sorcerers and druids"}, -- great mana potion

	[8472] = {empty = 7635, splash = 3, health = {200, 400}, mana = {110, 190}, level = 80, vocations = {3, 7}, vocStr = "paladins"} -- great spirit potion
}

local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions') - 100))

function onUse(cid, item, fromPosition, itemEx, toPosition)
	local potion = POTIONS[item.itemid]
	if(not potion) then
		return false
	end

	if(not isPlayer(itemEx.uid) or (not config.usableOnTarget and cid ~= itemEx.uid)) then
		if(not config.splashable) then
			return false
		end

		if(toPosition.x == CONTAINER_POSITION) then
			toPosition = getThingPos(item.uid)
		end

		doDecayItem(doCreateItem(2016, potion.splash, toPosition))
		doTransformItem(item.uid, potion.empty)
		return true
	end

	if(hasCondition(cid, CONDITION_EXHAUST_HEAL)) then
		doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED)
		return true
	end

	if(((potion.level and getPlayerLevel(cid) < potion.level) or (potion.vocations and not isInArray(potion.vocations, getPlayerVocation(cid)))) and
		not getPlayerCustomFlagValue(cid, PLAYERCUSTOMFLAG_GAMEMASTERPRIVILEGES))
	then
		doCreatureSay(itemEx.uid, "Only " .. potion.vocStr .. (potion.level and (" of level " .. potion.level) or "") .. " or above may drink this fluid.", TALKTYPE_ORANGE_1)
		return true
	end

	local health = potion.health
	if(health and not doCreatureAddHealth(itemEx.uid, math.ceil(math.random(health[1], health[2]) * config.healthMultiplier))) then
		return false
	end

	local mana = potion.mana
	if(mana and not doPlayerAddMana(itemEx.uid, math.ceil(math.random(mana[1], mana[2]) * config.manaMultiplier))) then
		return false
	end

	doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_MAGIC_BLUE)
	if(not realAnimation) then
		doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_ORANGE_1)
	else
		for i, tid in ipairs(getSpectators(getCreaturePosition(cid), 1, 1)) do
			if(isPlayer(tid)) then
				doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_ORANGE_1, false, tid)
			end
		end
	end

	doAddCondition(cid, exhaust)
	if(not potion.empty or config.removeOnUse) then
		doRemoveItem(item.uid)
		return true
	end

	doTransformItem(item.uid, potion.empty)
	return true
end
 
can you write which a variable what to do at vocations.xml too :) Skill id=0 and etc. thx a lot

Code:
<vocation id="6" name="Druid" description="an druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="2" gainmanaticks="3" gainmanaamount="5" manamultiplier="1.1" attackspeed="2000" soulmax="100" gainsoulticks="15" fromvoc="2" lessloss="30">
		<formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" armor="1.0"/>
		<skill id="0" multiplier="1.5"/>
		<skill id="1" multiplier="1.8"/>
		<skill id="2" multiplier="1.8"/>
		<skill id="3" multiplier="1.8"/>
		<skill id="4" multiplier="1.8"/>
		<skill id="5" multiplier="1.5"/>
		<skill id="6" multiplier="1.1"/>
	</vocation>
 
Hey otswe,
I know maybe you're sick and tired of answering all questions and so; but really, we appreciate it a lot!
I'm just wondering if it's possible to insert an Account Manager to a server. If you don't wanna answer it, it's ok.
 
If you mean about my server, yes it possible at config: accountManager = true <-- do you want use account manager?
If you want insert on a other server that require c++ edits.

About this only knight and pallys need edit and do this: <formula meleeDamage="2.0" <-- For knights increase this will give knight more deal of damage, i usally use 2.0
distDamage="2.1" <-- Paladin increase this will give paladin more deal of damage, i usally use 2.1
attackspeed="2000" <-- You can edit how fast you will attack with your weapon by decrease the value of the attack speed, 2000 = 2seconds.
lessloss="30"> <-- How much less exprience % will they lose when they die, increase will make them lose less exprience
gaincap="10" <-- How much cape should this vocation get when they level up!
gainhp="5" <-- How much hp will they get when they level up!
gainmana="30" <-- How much hp will they get when they level up!
gainhpticks="6" <-- How much fast do you want the health gain when player eat food!
gainhpamount="2" <-- How much health should a player get by eating food! example 50hp every 6 seconds
gainmanaticks="3" <-- How much fast do you want the health gain when player eat food!
gainmanaamount="5" <-- How much health should a player get by eating food! example 50mana every 3 seconds
soulmax="100" <-- how much should a player have max soul!
gainsoulticks="15" <-- How fast will soul go up when killing a monster!

Code:
<vocation id="6" name="Druid" description="an druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="2" gainmanaticks="3" gainmanaamount="5" manamultiplier="1.1" attackspeed="2000" soulmax="100" gainsoulticks="15" fromvoc="2" lessloss="30">
		<formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" armor="1.0"/>
		<skill id="0" multiplier="1.5"/>
		<skill id="1" multiplier="1.8"/>
		<skill id="2" multiplier="1.8"/>
		<skill id="3" multiplier="1.8"/>
		<skill id="4" multiplier="1.8"/>
		<skill id="5" multiplier="1.5"/>
		<skill id="6" multiplier="1.1"/>
	</vocation>
 
@kirrebati
shouldn't it already be implented?
try to login with login data "1" for account number/name
and "1" for password ;)

and if not working check in your config.lua if there is:
"accountmanager= true"

if its "false" set it to "true".
if it doesn't exist idk :D
 
I found the Tutorial and did as you say until I see there is no "Gm Tutorial" at the SQLstudio, so I cannot change the value to 6 and even if I'd do that, how could I create the account of a god?
 
That tutorial its wrong OTswe I had to click not on the folder of step 3 but the other folder to the right with the green arrow, I could create my god that way just, anyway thanks :)
 
By the way anyone has gotten a debug everytime you buy any kind of potion or create it with the God? I do :|
 
But if I want this server's Account Manager for another server, how do I do? (With all respect to this server's publisher).
 
Sorry i cant answer that question, i dont know how the account manager is implanted at the source file :(
 
It still has the problem of "auto-ammount"?, I mean, there are lot of ots that hasn't that function...

greets~
 
Can you explain what do you mean with auto ammount.
 
Hey otswe, thanks for the upload. I'am tying it right now but after a few hours the server frezzes or laggs, no error mesesages in the log or anything it just freezes, then i have to shut it down and restart the server. do you have any idea what the problem might be? thanks alot for the help

Regards
 
Back
Top