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

[TFS 1.x] Free Scripting and Support

RazorBlade

Retired Snek
Joined
Nov 7, 2009
Messages
2,015
Solutions
3
Reaction score
629
Location
Canada
Until further notice, I will not be taking any further requests, and any incomplete requests will be put on hold. Due to serious medical concerns with some of my pets, I will not be actively using the forums or doing any scripting. Sorry for the inconvenience.





Well hello everyone. This seems to be a popular trend lately, and I basically already do it anyways. So why not, right?

I'm here to offer my scripting services and/or support, free of charge. I will make basic-medium scripts/systems for free. I may do large and more advanced systems as well, depending on how busy I am.

I support only LUA at this time. My PHP and C++ are both a little rusty.

I also offer support and bugfixing for existing scripts. I accept requests here or via PM and nothing will be released unless you agree to it.

I only support TFS 1.x and 1.1 or higher is preferred.

I'm not looking to reinvent the wheel. If the system you're requesting is already in existence and easily accessible, I won't make it. I can maybe make modifications to it, but that all depends on what you need.

Want to see some of my work? Check my signature.

First come, first served. I will not accept payment for priority service.

Want to thank me? Toss me a like on the post that helped you, and feel free to recommend me to your friends if you found my service to be fast and accurate to your request.

Have at it! :D
 
Last edited:
So I just have some noobie questions...

I use TFS 1.1 -

So im making a movement script from this action script I found...

What it does is when player steps on square, they get some map marks to let them know where stuff is..

Code:
function onStepIn(cid, item, position, fromPosition)

local Mark = {
[1]={{x=32360,y=31547,z=7},"Temple",MAPMARK_TEMPLE},
[2]={{x=32282,y=31508,z=7},"Depot",MAPMARK_LOCK},
[3]={{x=32282,y=31481,z=7},"Shops",MAPMARK_BAG}, 
[4]={{x=32348,y=31454,z=7},"Teleporter",MAPMARK_STAR}, 
[5]={{x=32229,y=31575,z=7},"Hell Mountain",MAPMARK_EXCLAMATION}, 
[6]={{x=32339,y=31630,z=7},"Cactus Beach",MAPMARK_EXCLAMATION},
[7]={{x=32360,y=31403,z=7},"Jungle",MAPMARK_EXCLAMATION},
}

for i = 1, #Mark do
player:addMapMark(cid, Mark[i][1], Mark[i][3], Mark[i][4], Mark[i][5], Mark[i][6], Mark[i][7]) 
end
player:sendTextMessage(cid, MESSAGE_INFO_DESCR, "Welcome too Oasis.")
return true
end

but I get an error saying attempt to index global 'player' is a nil value?

What causes this?

I want a better understanding of this so I can deal with them on my own...

I tried like adding local player = Player(cid)

into the script but it didnt do anything...
 
So I just have some noobie questions...

I use TFS 1.1 -

So im making a movement script from this action script I found...

What it does is when player steps on square, they get some map marks to let them know where stuff is..

Code:
function onStepIn(cid, item, position, fromPosition)

local Mark = {
[1]={{x=32360,y=31547,z=7},"Temple",MAPMARK_TEMPLE},
[2]={{x=32282,y=31508,z=7},"Depot",MAPMARK_LOCK},
[3]={{x=32282,y=31481,z=7},"Shops",MAPMARK_BAG},
[4]={{x=32348,y=31454,z=7},"Teleporter",MAPMARK_STAR},
[5]={{x=32229,y=31575,z=7},"Hell Mountain",MAPMARK_EXCLAMATION},
[6]={{x=32339,y=31630,z=7},"Cactus Beach",MAPMARK_EXCLAMATION},
[7]={{x=32360,y=31403,z=7},"Jungle",MAPMARK_EXCLAMATION},
}

for i = 1, #Mark do
player:addMapMark(cid, Mark[i][1], Mark[i][3], Mark[i][4], Mark[i][5], Mark[i][6], Mark[i][7])
end
player:sendTextMessage(cid, MESSAGE_INFO_DESCR, "Welcome too Oasis.")
return true
end

but I get an error saying attempt to index global 'player' is a nil value?

What causes this?

I want a better understanding of this so I can deal with them on my own...

I tried like adding local player = Player(cid)

into the script but it didnt do anything...

change cid to creature in onStepIn
Code:
function onStepIn(creature, item, position, fromPosition)

then
Code:
local player = Player(creature)
if not player then
return true
end
Another thing is to remove cid from any functions. It isn't needed when calling metamethods.
so like
Code:
player:addMapMark(cid, Mark[i][1], Mark[i][3], Mark[i][4], Mark[i][5], Mark[i][6], Mark[i][7])
make it
Code:
player:addMapMark(Mark[i][1], Mark[i][3], Mark[i][4], Mark[i][5], Mark[i][6], Mark[i][7])
I also don't believe you can do it like that.
Code:
player:addMapMark(position, type, description)
you'd need something like
Code:
for i = 1, #Mark do
player:addMapMark(Mark[i][1], Mark[i][3], Mark[i][2])
end

and then also change this
Code:
player:sendTextMessage(cid, MESSAGE_INFO_DESCR, "Welcome too Oasis.")
to this
Code:
player:sendTextMessage(MESSAGE_INFO_DESCR, "Welcome to Oasis.")
 
Hello,

Can you help me to convert the auto loot mod to use on tfs 1.2?
Link of mod:
https://otland.net/threads/mod-auto-loot.164289/

And:
https://otland.net/threads/autoloot.91385/

It's two different models of the same system.

Thank you!

Regards,
Xtr3m3

I'll take a look.

@Xtr3m3
I have it basically converted. Only thing that's going to be a problem is the saving of the autoloot lists. The old version saved it as a string in a storage in the database. new storages only support integers. I may have to recode a good chunk of it to make a workaround and it may not be possible to save it across server shutdowns. the alternative would be saving to a text field in the player table which would have to be created. that would allow saving across shutdowns. will take some time to find the best solution and execute it.
 
Last edited:
A bit easier script for community, what would save my time if somebody is willing to do it.

I need new function.

function deathPenalty(player) end --(player is player userdata)

function features:
1. Looks trough all item slots on player.
feature config:
option1: slot item is removed.
option2: slot item is removed with % chance.
option3: random amount of stacked slot items is removed.
option4: random amount of stacked slot items is removed with % diminishing return. (example1* below)
option5: slot item will get item:getAttribute(TEXT, "soulbound") instead of remove.
option6: slot item has chance to be removed when item has TEXT "soulbound".
option7: slot item is removed when item has TEXT "soulbound".
option8: leave me nice ordered cap in function, where I can start scripting gem/stone upgrade removals.
2. Checks slot items:
feature config:
option1: Do nothing when itemID isInArray(item id array here)
option2: Do nothing when itemID with itemAID is in table = {k = {v}}
option3: attach [1.] config to itemID
option4: attach [1.] config to itemID with itemAID
option5: run custom function to itemID (I will make the custom functions) table = {itemID = functionName} (all custom functions use 2 parameters, itemID and player)​

3. Looks trough the equipped bag on player (NB! don't start looping bag into bag. In my server players can't put bag into bag, unless its special type of bag.)
feature config:
option1: item is removed.
option2: random amount of stacked item is removed.
option3: random amount of stacked item is removed with % diminishing return. (example1* below)
option4: item is placed on player body instead of removing from game.
option5: item has chance to be removed.
option6: item is removed when item has TEXT "soulbound".
option7: item has chance to be removed when item has TEXT "soulbound".
option8: leave me nice ordered cap in function, where I can start scripting gem/stone upgrade removals.​

Example 1 formula:
DR= 10
first removes DR% of stack (math.floor).
then with 100-DR % chance it will decide will it remove DR% again.
Now the chance of removing DR% will be 100-DR*2
unless it doesn't fail.
next chance is 100-DR*3
etc.
prefer this formula with while loop.

Uhm, I guess that is it for now.
 
Last edited:
@RazorBlade
I'm wondering if you have time/intrest in creating an npc for me.

I'm using TFS 0.2.7 but I'm guessing there isn't much of a difference in npc lua scripts between this version and tfs 1+.
But if there excists a difference and you're not willing to do this because of that I would tottaly understand.

But on the otherhand if you are willing to take a look at it I would be very gratefull :)
Here is the link to the thread I created to explain the idea for the npc.
https://otland.net/threads/npc-lua-advanced-stuff-for-me-atleast-d.234441/

Kind regards,
Exoltes
 
I'll take a look.

@Xtr3m3
I have it basically converted. Only thing that's going to be a problem is the saving of the autoloot lists. The old version saved it as a string in a storage in the database. new storages only support integers. I may have to recode a good chunk of it to make a workaround and it may not be possible to save it across server shutdowns. the alternative would be saving to a text field in the player table which would have to be created. that would allow saving across shutdowns. will take some time to find the best solution and execute it.
Some success my friend?
 
Actually that teleports you if you shift+click (onlook).
I want to be able to teleport on my screen by, let's say, left clicking, and also on the map, by literally map clicking.
/cliport
-- I use this all the time. It makes it so left click teleports you to location if possible.
If you are pushing ctrl/alt/shift when left clicking, it will do the normal functions.
 
A bit easier script for community, what would save my time if somebody is willing to do it.

I need new function.

function deathPenalty(player) end --(player is player userdata)

function features:
1. Looks trough all item slots on player.
feature config:
option1: slot item is removed.
option2: slot item is removed with % chance.
option3: random amount of stacked slot items is removed.
option4: random amount of stacked slot items is removed with % diminishing return. (example1* below)
option5: slot item will get item:getAttribute(TEXT, "soulbound") instead of remove.
option6: slot item has chance to be removed when item has TEXT "soulbound".
option7: slot item is removed when item has TEXT "soulbound".
option8: leave me nice ordered cap in function, where I can start scripting gem/stone upgrade removals.
2. Checks slot items:
feature config:
option1: Do nothing when itemID isInArray(item id array here)
option2: Do nothing when itemID with itemAID is in table = {k = {v}}
option3: attach [1.] config to itemID
option4: attach [1.] config to itemID with itemAID
option5: run custom function to itemID (I will make the custom functions) table = {itemID = functionName} (all custom functions use 2 parameters, itemID and player)​

3. Looks trough the equipped bag on player (NB! don't start looping bag into bag. In my server players can't put bag into bag, unless its special type of bag.)
feature config:
option1: item is removed.
option2: random amount of stacked item is removed.
option3: random amount of stacked item is removed with % diminishing return. (example1* below)
option4: item is placed on player body instead of removing from game.
option5: item has chance to be removed.
option6: item is removed when item has TEXT "soulbound".
option7: item has chance to be removed when item has TEXT "soulbound".
option8: leave me nice ordered cap in function, where I can start scripting gem/stone upgrade removals.​

Example 1 formula:
DR= 10
first removes DR% of stack (math.floor).
then with 100-DR % chance it will decide will it remove DR% again.
Now the chance of removing DR% will be 100-DR*2
unless it doesn't fail.
next chance is 100-DR*3
etc.
prefer this formula with while loop.

Uhm, I guess that is it for now.
very specific yet still confusing. I have a bunch of requests still on my list to do, but once I have some time freed up I'll come bug you for some specifics

@RazorBlade
I'm wondering if you have time/intrest in creating an npc for me.

I'm using TFS 0.2.7 but I'm guessing there isn't much of a difference in npc lua scripts between this version and tfs 1+.
But if there excists a difference and you're not willing to do this because of that I would tottaly understand.

But on the otherhand if you are willing to take a look at it I would be very gratefull :)
Here is the link to the thread I created to explain the idea for the npc.
https://otland.net/threads/npc-lua-advanced-stuff-for-me-atleast-d.234441/

Kind regards,
Exoltes
If i had more time I might give it a look but I'm pretty overloaded with requests so I'll have to decline on non-tfs 1.x scripts at this time.

Some success my friend?
been awful busy, but I believe I have a solution. should only take a couple hours to finish the whole thing. depending on how busy I am at work tonight.
 
I totally made your thing ;'(

But not with the love and heart you usually have. It's okay. I get it. Suddenly ur this big celebrity and everyone wants a piece of that tail. I was just the fluffer. I cant help it my ass isn't what it was when we we're 18
 
Very cool. I myself have this death penalty script planned for next month. Starting to make new npc system and lore system my own this week, so I will be pretty busy for hundreds of scripting hours. xD

BTW did you stream scripting at some point or was it zibizu? I have had opportunity to script together with few ppl. Pretty cool to do it if both know what they doing :D
 
Back
Top