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

Solved TFS 1.0 Help withscript functions

Xarly

Member
Joined
Mar 9, 2015
Messages
360
Reaction score
20
Hello guys, well im fixing my warzone from tfs 1.1 to tfs 1.0 but i got stuck on shooting.lua can't find the correct function for fix it i changed local playerPos = player:getPosition() to local playerPos = getPlayerPosition(cid)
that fixed my error on line 2 aniway im not sure if its correct after it now im getting error on line 3
if player:getStorageValue(Storage.BigfootBurden.Shooting) < 6 then and i dont know why because if im correct this function its correct >.< too on movements shooting i fixed the error on stepin ect.. the only problem its , this is not creating the dummies -.-" i post there the 2 scripts will be great if someone can help me! thanks
First problem script:http://pastebin.com/sdKdk9rA action script
Second problem script:http://pastebin.com/gviA50XE movement script (dummies problem)
Thanks in advance guys
 
This works for me. I just tested it in my server. Transforms the corpse and everything. It's identical to the original. Can you post the exact console error you got?
Code:
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
    local player = Player(player)

    if target.itemid ~= 18484 then
        return false
    end

    local extractedCount = player:getStorageValue(Storage.BigfootBurden.ExtractedCount)
    if extractedCount == 7 or player:getStorageValue(Storage.BigfootBurden.MissionRaidersOfTheLostSpark) ~= 1 then
        return false
    end

    player:setStorageValue(Storage.BigfootBurden.ExtractedCount, math.max(0, extractedCount) + 1)
    player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You gathered a spark.')
    target:transform(18485)
    toPosition:sendMagicEffect(CONST_ME_ENERGYHIT)
    return true
end
idk why but i still getting error on function transform >.< maybe its any problem with compat.lua? u are using tfs 1.0 too? if you using pls send me your compat.lua i think it was my problem
 
item:transform shouldn't be related to compat.lua. I'm using tfs 1.1, don't know if that makes a difference or not. item:transform should be available in 1.0. What revision/commit of tfs 1.0 are you using? maybe you have a version that's older and doesn't have item:transform?
 
item:transform shouldn't be related to compat.lua. I'm using tfs 1.1, don't know if that makes a difference or not. item:transform should be available in 1.0. What revision/commit of tfs 1.0 are you using? maybe you have a version that's older and doesn't have item:transform?
well im not sure about my source xd i will try download the lastest source tfs 1.0 and lets see ..
 
Any errors in console? If it isn't printing test3, it should be printing test4 for sure. unless it's erroring on the if statement.
nope bro just the prints if it print test test1 test3 won't print anything more and if i add the optin u said to me it just print test test1 >.< without errors on distr
 
I just tested this one on my server. I get all the test prints with "if target.actionid ~= 8013 then"

I'm starting to think it's your revision. I don't know why, but something is messing up.
 
I just tested this one on my server. I get all the test prints with "if target.actionid ~= 8013 then"

I'm starting to think it's your revision. I don't know why, but something is messing up.
yea its working on your server because u are using tfs 1.1 and its a script of tfs 1.1 for that im tryng to conver this to tfs 1.0 i tried to use last revision of tfs 1.0 but don't work correctly for me gives alot of errors the problem its on this line
if player:getStorageValue(Storage.ChildrenoftheRevolution.Questline) == 16 then
but i dont know why -.-" tried to change storages and still wont work
 
what's the error it gives you at that line?
no its not giving errors but i think there is the problem on line
if player:getStorageValue(Storage.ChildrenoftheRevolution.Questline) == 16 then
print("test4")

because im not getting this print only test test1 test 3
 
if the player has storage key 1050 value 16, it should print test4. If the player has the storage and it doesn't print, either something is seriously wrong or the script is not running. I don't know what to tell you at this point. It's 2am, I'm going to sleep :p best of luck
 
no its not giving errors but i think there is the problem on line
if player:getStorageValue(Storage.ChildrenoftheRevolution.Questline) == 16 then
print("test4")

because im not getting this print only test test1 test 3
You can add this above it and look what it shows.
Code:
print(player:getStorageValue(Storage.ChildrenoftheRevolution.Questline))

For the transform
Code:
Item(target.uid):transform(18485)
 
You can add this above it and look what it shows.
Code:
print(player:getStorageValue(Storage.ChildrenoftheRevolution.Questline))

For the transform
Code:
Item(target.uid):transform(18485)
woked perfect thanks bro! about first script i know, now what's the problem because i changed just these script and its problem with the storages haha so i need change al l scripts xd, thanks for all
 
Back
Top