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

Lua beginner is havinng trouble

tnecniiv

scripter to be
Joined
Jan 6, 2012
Messages
294
Solutions
3
Reaction score
23
why is my client debugging after i pull a certain lever

function onUse(cid, item, fromPos, item2, toPos)


if item.itemid == 9827 then

doPlayerSendTextMessage(cid, 21, "It worked!")
doTransformItem(item.uid, 9828)

elseif item.itemid == 9828 then


doPlayerSendTextMessage(cid, 21, "You pulled it back!")
doTransformItem(item.uid, 9827)

end

return True
end
i am learning to script so i am still really new at i was following the lua guide in the resources section
 
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
    if item.itemid == 9827 then
        doPlayerSendTextMessage(cid, TALKTYPE_MONSTER, "It worked!")
        doTransformItem(item.uid, 9828)
    elseif item.itemid == 9828 then
        doPlayerSendTextMessage(cid, TALKTYPE_MONSTER, "You pulled it back!")
        doTransformItem(item.uid, 9827)
    end
    return true
end
return True <- pretty sure this was your problem
tfs has TRUE = true in compat lib but not True, programming languages are case sensitive
use true, not True
 
the cause of the debug was the number 21
but now it doesn't display a message no debug but no message im sorry to be a burden. trying to get into scripting.
using tfs 0.2.14
 
the cause of the debug was the number 21
but now it doesn't display a message no debug but no message im sorry to be a burden. trying to get into scripting.
using tfs 0.2.14
maybe function names arent the same or same arguments
i dont know about 0.2~ sry bud
 
i checked the function list for the server those are all codes for that server well besides the monter_talktype
 
Click the "Clone or Download" and choose download as zip
For RME, go to Map->Properties and change the version there. It'll ask you to browse to the folder containing the appropriate file version.
what client do you recomend me starting and can i update my map along with it? i put alot of work into my map and dont want to restart it
 
what client do you recomend me starting and can i update my map along with it? i put alot of work into my map and dont want to restart it
Open up a blank map in RME in the version you want. File->Import->Import Map
choose your map file, press ok, save the map as a new map
the new map is now a copy of your old map but in the version of your choosing
 
last question im sorry you seem full of knowledge.
now why is there no server to run for localhosting do i have to use znote to connect ?
4OSLnf0.png

as youo can see i dont see the forgotten server application to run like you would previously?? im so lost right now? :(
 
Last edited:
last question im sorry you seem full of knowledge.
now why is there no server to run for localhosting do i have to use znote to connect ?
Yeah, you'll need an AAC and a database setup in order to create accounts/players
Znote AAC 1.5 is what you'll want. And you'll need uniform server as well
https://github.com/Znote/ZnoteAAC/archive/master.zip (will download directly)
https://sourceforge.net/projects/miniserver/files/latest/download?source=files (will download directly)
once uniserver is setup delete everything in its www folder and replace it with everything in the znote aac, then configure your server path in config.php and make sure mysql and apache are running in uniserver. go to localhost in your web browser and follow the instructions. you can also access phpmyadmin from the uniserver control panel thing.
 
i feared as much that i would have to relearn znotes. the web design side im not scared of those was designing web pages for years now =D thats why im doing all the sccripting in my server while my bro does most of the mapping. do i have to update my uniserver or could i use my previous one?
 

Similar threads

Back
Top