Jump to content

[HELP]Warp system


Recommended Posts

Posted

addCommandHandler. setElementPosition. setElementFrozen.

Do NOT PM ME for help unless invited. - New MTA Script Editor

Scripting help "etiquette": understandable language, relevant code (ALL code if unsure), [Lua] tags, error messages with line numbers. Super simple stuff.

Posted

Server side:

  
function warp() 
setElementPosition ( 0, 0, 0 ) 
setElementFrozen ( source, true ) 
end 
addCommandHandler ( "warp", warp ) 

Need paid scripter just pm me i will accept every job!

Posted
Server side:
  
function warp() 
setElementPosition ( 0, 0, 0 ) 
setElementFrozen ( source, true ) 
end 
addCommandHandler ( "warp", warp ) 

  
function warp() 
setElementPosition ( source, 0, 0, 0 ) -- add argument eelement= source 
setElementFrozen ( source, true ) 
end 
addCommandHandler ( "warp", warp ) 

Actual Nick: [XGN]BorderLine

Actual Clan: XLatino

Actual Status: Staff, Mod Level 1

(BOSS)Yakuza - [vS]Yakuza - [sXE]Yakuza - [uG]Yakuza - [FTLS]Racing - [XGN]Borderline

Posted

type /debugscript 3 and tell us what happen.. and why you say nothing

and make sure to add in meta like server side

Actual Nick: [XGN]BorderLine

Actual Clan: XLatino

Actual Status: Staff, Mod Level 1

(BOSS)Yakuza - [vS]Yakuza - [sXE]Yakuza - [uG]Yakuza - [FTLS]Racing - [XGN]Borderline

Posted
  
function warp(player) 
setElementPosition ( player, 0, 0, 0 ) -- add argument eelement= source 
setElementFrozen ( player, true ) 
end 
addCommandHandler ( "warp", warp ) 

CiTLh.png
Posted
Server side:
  
function warp() 
setElementPosition ( 0, 0, 0 ) 
setElementFrozen ( source, true ) 
end 
addCommandHandler ( "warp", warp ) 

  
function warp() 
setElementPosition ( source, 0, 0, 0 ) -- add argument eelement= source 
setElementFrozen ( source, true ) 
end 
addCommandHandler ( "warp", warp ) 

Woops!I forgot it

Need paid scripter just pm me i will accept every job!

Posted

Try this:

  
function warp( player, command, dimension ) 
setElementPosition ( player, 0, 0, 0 ) 
setElementFrozen ( player, true ) 
end 
addCommandHandler ( "warp", warp ) 

Need paid scripter just pm me i will accept every job!

Posted

Try this:

  
function warp( thePlayer, command, dimension ) 
setElementPosition ( thePlayer, 0, 0, 0 ) 
setElementFrozen ( thePlayer, true ) 
end 
addCommandHandler ( "warp", warp ) 

Need paid scripter just pm me i will accept every job!

Posted (edited)
again nothing

realy?

show your meta.

TheIceman1@ your is same.

Edited by Guest
CiTLh.png
Posted
/warp working but i am not frozen

your meta look fine.

try it with timer

function warp(player) 
setElementPosition(player,0,0,0) 
setTimer(setElementFrozen,200,1,player,true) 
end 
addCommandHandler("warp", warp) 

CiTLh.png
Posted
/warp working but i am not frozen

your meta look fine.

try it with timer

function warp(player) 
setElementPosition(player,0,0,0) 
setTimer(setElementFrozen,200,1,player,true) 
end 
addCommandHandler("warp", warp) 

Its wont work!

Try this:

function warp( player, command, dimension ) 
setElementPosition(player,0,0,0) 
setTimer(setElementFrozen,200,1,player,true) 
end 
addCommandHandler("warp", warp) 

[/lua]

Need paid scripter just pm me i will accept every job!

Posted
/warp working but i am not frozen

your meta look fine.

try it with timer

function warp(player) 
setElementPosition(player,0,0,0) 
setTimer(setElementFrozen,200,1,player,true) 
end 
addCommandHandler("warp", warp) 

Its wont work!

Try this:

function warp( player, command, dimension ) 
setElementPosition(player,0,0,0) 
setTimer(setElementFrozen,200,1,player,true) 
end 
addCommandHandler("warp", warp) 

[/lua]

lol'ed.

CiTLh.png
Posted
  
function warp(source,cmd,x,y,z,interior,dimension) 
    if not z then return end 
    setElementFrozen(source,true) 
    setElementPosition(source,tonumber(x),tonumber(y),tonumber(z)) 
    if interior then 
        setElementInterior(source,tonumber(interior)) 
    end 
    if dimension then 
        setElementDimension(source,tonumber(dimension)) 
    end 
    setTimer(function(player) if isElement(player) then setElementFrozen(player,false) end end,3000,1,source) 
end 
addCommandHandler("warp",warp) 
  

Retired

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...