• 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!

[IGIVEUP] War PVP-Enf HELP URGENT + SCREENS

ffriozi

New User of Linux OS
Joined
Apr 4, 2008
Messages
96
Reaction score
1
Hey guys im haveing some problem w/t this part of my war script

Code:
end
			if LEVEL.START ~= nil then
				doPlayerSetLevel(cid, LEVEL.START)
			end
			local oldPosition = getCreaturePosition(cid)
			doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid)), FALSE)
			doCreatureAddHealth(cid, getCreatureMaxHealth(cid), TRUE)
			doCreatureAddMana(cid, getCreatureMaxMana(cid))
			doSendMagicEffect(getCreaturePosition(cid), TEAMS[team.get(cid)].EFFECT)
			doSendMagicEffect(oldPosition, 65)
			doRemoveConditions(cid, FALSE)
			doPlayerAddSoul(cid, -getPlayerSoul(cid))
			return FALSE
		end
		return TRUE

the player after reach hp 0 he goes to the temple but the server dont heal his life so the hp stays on zero. he just keep add mana points but no hp here is the ScreenShot

scaled.php


any ideas?
 
Last edited:
Code:
            if LEVEL.START ~= nil then
                doPlayerSetLevel(cid, LEVEL.START)
            end
            local oldPosition = getCreaturePosition(cid)
            doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid)), FALSE)
            doCreatureAddHealth(cid, getCreatureMaxHealth(cid))
            doCreatureAddMana(cid, getCreatureMaxMana(cid))
            doSendMagicEffect(getCreaturePosition(cid), TEAMS[team.get(cid)].EFFECT)
            doSendMagicEffect(oldPosition, 65)
            doRemoveConditions(cid, FALSE)
            doPlayerAddSoul(cid, -getPlayerSoul(cid))
            return FALSE
        end
        return TRUE

maybe D:
 
Code:
end
            if LEVEL.START ~= nil then
                doPlayerSetLevel(cid, LEVEL.START)
            end
            local oldPosition = getCreaturePosition(cid)
            doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid)), FALSE)
            doCreatureAddHealth(cid, getCreatureMaxHealth(cid)), TRUE)
            doCreatureAddMana(cid, getCreatureMaxMana(cid))
            doSendMagicEffect(getCreaturePosition(cid), TEAMS[team.get(cid)].EFFECT)
            doSendMagicEffect(oldPosition, 65)
            doRemoveConditions(cid, FALSE)
            doPlayerAddSoul(cid, -getPlayerSoul(cid))
            return FALSE
        end
        return TRUE

try this,
 
n00b explain to him what was wrong, you placed true in this function:
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid), TRUE)
if you place true in which in the actual function it's like this:
Code:
doCreatureAddHealth(cid, health[, force])
since you stated true this made the script remove his HP instead of adding it.
 
Code:
end
            if LEVEL.START ~= nil then
                doPlayerSetLevel(cid, LEVEL.START)
            end
            local oldPosition = getCreaturePosition(cid)
            doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid)), FALSE)
            doCreatureAddHealth(cid, getCreatureMaxHealth(cid))[COLOR="red"], TRUE)[/COLOR]
            doCreatureAddMana(cid, getCreatureMaxMana(cid))
            doSendMagicEffect(getCreaturePosition(cid), TEAMS[team.get(cid)].EFFECT)
            doSendMagicEffect(oldPosition, 65)
            doRemoveConditions(cid, FALSE)
            doPlayerAddSoul(cid, -getPlayerSoul(cid))
            return FALSE
        end
        return TRUE

try this,

would not work in the first place because of the red highlighted part, it just messes the that function or the whole script.
 
@bogart
i have tried that =P

@sublime
i got this erro

[14/09/2010 01:04:27] data/lib/war.lua:121: unexpected symbol near ','
 
n00b explain to him what was wrong, you placed true in this function:
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid), TRUE)
if you place true in which in the actual function it's like this:
Code:
doCreatureAddHealth(cid, health[, force])
since you stated true this made the script remove his HP instead of adding it.

i replaced and got this error!

[14/09/2010 01:08:28] [Error - MoveEvents Interface]
[14/09/2010 01:08:28] data/lib/200-data.lua
[14/09/2010 01:08:28] Description:
[14/09/2010 01:08:28] data/lib/war.lua:121: unexpected symbol near ','
[14/09/2010 01:08:28] [Warning - LuaScriptInterface::initState] Cannot load data/lib/

this is my data.lua

Code:
dofile(getDataDir() .. "lib/war.lua")

damn ;s
 
[14/09/2010 01:08:28] data/lib/war.lua:121: unexpected symbol near ','
that error is due to this line:
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid)), TRUE)
 
[14/09/2010 01:08:28] data/lib/war.lua:121: unexpected symbol near ','
that error is due to this line:
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid)), TRUE)

i mean i replaced this line for

Code:
doCreatureAddHealth(cid, health[, force])

and got that error :(
any other ideas?
i just want when a player dies he go back to the temple without need relog with full hp/mp
 
change that line to this one, it should work.
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid))
anyways I'ma go to sleep if you still have the problem tell me tomorrow, bye!
 
change that line to this one, it should work.
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid))
anyways I'ma go to sleep if you still have the problem tell me tomorrow, bye!

Damn same problem... he just keeping restoring the mana over and over again =S what could be wrong! cya later ty for help bro
 
hummm

Wrong:
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid)), TRUE)

Should be good
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid), TRUE)
 
hummm

Wrong:
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid)), TRUE)

Should be good
Code:
doCreatureAddHealth(cid, getCreatureMaxHealth(cid), TRUE)

Same Problem :S Thanks for try to help me!

I sent my script to Calandus lets w8 he try to fix it.. if he fix i will post the correction here !

!!
 
Last edited:
Back
Top