Turbesz Posted August 5, 2016 Share Posted August 5, 2016 i put this in fr_client.lua but doesn't working --------------------------- -- Warp toggle ------------------------- function warpTo(leaf) if not leaf then leaf = getSelectedGridListLeaf(wndWarp, 'playerlist') if not leaf then return end end local player = getPlayerFromNick(leaf.name) if player then if getElementData(player,"warp.status") then outputChatBox ( "This player has disabled warping.", player, 255, 0, 0 ) return end -- added server.warpMe(player) end closeWindow(wndWarp) end function warpToCommand(cmd, player) if player then player = getPlayerFromNick(player) if player then if getElementData(player,"warp.status") then outputChatBox ( "This player has disabled warping.", player, 255, 0, 0 ) return end --added server.warpMe(player) end else createWindow(wndWarp) showCursor(true) end end addCommandHandler('warpto', warpToCommand) addCommandHandler('wt', warpToCommand) and {'chk', id='warponoff', text='Warp', onclick=toggleWarpOnOff, width=50}, how to fix?:c /sorry for my bad english/ Link to comment
Ab-47 Posted August 5, 2016 Share Posted August 5, 2016 Is this: getSelectedGridListLeaf A self defined function (I'm guessing it is, because it doesn't exist on the wiki), if it is, please show the code to that here. The fact that it's returning the function, it could be the reason why the script isn't working. Could you also post any errors that occurred, would be great help. Link to comment
Rataj Posted August 6, 2016 Share Posted August 6, 2016 And are you sure you set element data "warp.status" properly? Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now