Clary
New Member
- Joined
- Mar 7, 2008
- Messages
- 1,007
- Reaction score
- 1
Suicide(with battle check!)
For the first, I'd like to thank Black Luster for the basic idea and nice piece of code.
Second important thing - the function was made for TFS, I don't know will it work on other cores!
As third... I've decided to release the code today, after I rebuilded it, and its almost different than Black Luster one.
and last, i would to thank Marcinek Paladinek for helping me in making this script work.
Go data/talkactions/scripts
Copy any file and put this:
Save and name to "Suicide"
Go data/talkactions/talkactions.xml
And paste this:
Credits :
Major Credits :
Me(Clary) : for making the script.
Marcinek Paladinek : for helping making it work.
Minor Credits :
AGS : for giving me the idea to add a battle check.
NOTES :
1- Tested with TFS Tags Rev 220 (compiled by me)
2- I think <talkaction words="Goodbye cruel world!" script="suicide.lua" />
should be changed to something else since it is long
any suggestions?
3- this is my first script
4-Can any moderator change the title to Suicide(with battle check!)
Post with ur comments.
For the first, I'd like to thank Black Luster for the basic idea and nice piece of code.
Second important thing - the function was made for TFS, I don't know will it work on other cores!
As third... I've decided to release the code today, after I rebuilded it, and its almost different than Black Luster one.
and last, i would to thank Marcinek Paladinek for helping me in making this script work.
Go data/talkactions/scripts
Copy any file and put this:
PHP:
function onSay(cid, words, param)
if getCreatureCondition(cid, CONDITION_INFIGHT) > 0 then
doPlayerSendCancel(cid, "You cannot use this while in battle.")
else
doCreatureAddHealth(cid, - getCreatureMaxHealth(cid))
doCreatureAddMana(cid, - getCreatureMaxMana(cid))
doCreatureSay(cid, "Goodbye cruel world!", 1)
return 0
end
return 1
end
Save and name to "Suicide"
Go data/talkactions/talkactions.xml
And paste this:
Code:
<talkaction words="Goodbye cruel world!" script="suicide.lua" />
Major Credits :
Me(Clary) : for making the script.
Marcinek Paladinek : for helping making it work.
Minor Credits :
AGS : for giving me the idea to add a battle check.
NOTES :
1- Tested with TFS Tags Rev 220 (compiled by me)
2- I think <talkaction words="Goodbye cruel world!" script="suicide.lua" />
should be changed to something else since it is long
any suggestions?
3- this is my first script
4-Can any moderator change the title to Suicide(with battle check!)
Post with ur comments.
Last edited: