Jump to content

Need help to water


Clay

Recommended Posts

Posted

need to 700 height

 

Water = {{-2998.0,-2998.0,5.0,-2500.0,-2998.0,5.0,-2998.0,-2500.0,5.0,-2500.0,-2500.0,5.0},
{-2998.0,-2500.0,5.0,-2500.0,-2500.0,5.0,-2998.0,-2000.0,5.0,-2500.0,-2000.0,5.0},
{-2998.0,-2000.0,5.0,-2500.0,-2000.0,5.0,-2998.0,-1500.0,5.0,-2500.0,-1500.0,5.0},
{-2998.0,-1500.0,5.0,-2500.0,-1500.0,5.0,-2998.0,-1000.0,5.0,-2500.0,-1000.0,5.0},
{-2998.0,-1000.0,5.0,-2500.0,-1000.0,5.0,-2998.0,-500.0,5.0,-2500.0,-500.0,5.0},
{-2998.0,-500.0,5.0,-2500.0,-500.0,5.0,-2998.0,0.0,5.0,-2500.0,0.0,5.0},
{-2998.0,0.0,5.0,-2500.0,0.0,5.0,-2998.0,500.0,5.0,-2500.0,500.0,5.0},
{-2998.0,500.0,5.0,-2500.0,500.0,5.0,-2998.0,1000.0,5.0,-2500.0,1000.0,5.0},
{-2998.0,1000.0,5.0,-2500.0,1000.0,5.0,-2998.0,1500.0,5.0,-2500.0,1500.0,5.0},
{-2998.0,1500.0,5.0,-2500.0,1500.0,5.0,-2998.0,2000.0,5.0,-2500.0,2000.0,5.0},
{-2998.0,2000.0,5.0,-2500.0,2000.0,5.0,-2998.0,2500.0,5.0,-2500.0,2500.0,5.0,},
{-2998.0,2500.0,5.0,-2500.0,2500.0,5.0,-2998.0,2998.0,5.0,-2500.0,2998.0,5.0},
{-2500.0,-2998.0,5.0,-2000.0,-2998.0,5.0,-2500.0,-2500.0,5.0,-2000.0,-2500.0,5.0},
{-2500.0,-2500.0,5.0,-1500.0,-2500.0,5.0,-2500.0,-1500.0,5.0,-1500.0,-1500.0,5.0},
{-2500.0,-1500.0,5.0,-2000.0,-1500.0,5.0,-2500.0,-1000.0,5.0,-2000.0,-1000.0,5.0},
{-2500.0,-1000.0,5.0,-2000.0,-1000.0,5.0,-2500.0,-500.0,5.0,-2000.0,-500.0,5.0},
{-2500.0,-500.0,5.0,-2000.0,-500.0,5.0,-2500.0,0.0,5.0,-2000.0,0.0,5.0},
{-2500.0,0.0,5.0,-2000.0,0.0,5.0,-2500.0,500.0,5.0,-2000.0,500.0,5.0},
{-2500.0,500.0,5.0,-2000.0,500.0,5.0,-2500.0,1000.0,5.0,-2000.0,1000.0,5.0},
{-2500.0,1000.0,5.0,-2000.0,1000.0,5.0,-2500.0,1500.0,5.0,-2000.0,1500.0,5.0},
{-2500.0,1500.0,5.0,-2000.0,1500.0,5.0,-2500.0,2000.0,5.0,-2000.0,2000.0,5.0},
{-2500.0,2000.0,5.0,-2000.0,2000.0,5.0,-2500.0,2500.0,5.0,-2000.0,2500.0,5.0},
{-2500.0,2500.0,5.0,-2000.0,2500.0,5.0,-2500.0,2998.0,5.0,-2000.0,2998.0,5.0},
{-2000.0,-2998.0,5.0,-1500.0,-2998.0,5.0,-2000.0,-2500.0,5.0,-1500.0,-2500.0,5.0},
{-2000.0,-1500.0,5.0,-1800.0,-1500.0,5.0,-2000.0,-1000.0,5.0,-1800.0,-1000.0,5.0},
{-2000.0,-1000.0,5.0,-1800.0,-1000.0,5.0,-2000.0,-500.0,5.0,-1800.0,-500.0,5.0},
{-2000.0,-500.0,5.0,-1500.0,-500.0,5.0,-2000.0,0.0,5.0,-1500.0,0.0,5.0},
{-2000.0,0.0,5.0,-1500.0,0.0,5.0,-2000.0,500.0,5.0,-1500.0,500.0,5.0},
{-2000.0,500.0,5.0,-1500.0,500.0,5.0,-2000.0,1000.0,5.0,-1500.0,1000.0,5.0},
{-2000.0,1000.0,5.0,-1500.0,1000.0,5.0,-2000.0,1500.0,5.0,-1500.0,1500.0,5.0},
{-2000.0,1500.0,5.0,-1500.0,1500.0,5.0,-2000.0,2000.0,5.0,-1500.0,2000.0,5.0},
{-2000.0,2000.0,5.0,-1500.0,2000.0,5.0,-2000.0,2500.0,5.0,-1500.0,2500.0,5.0},
{-2000.0,2500.0,5.0,-1500.0,2500.0,5.0,-2000.0,2998.0,5.0,-1500.0,2998.0,5.0},
{-1500.0,-2998.0,5.0,-1000.0,-2998.0,5.0,-1500.0,-2500.0,5.0,-1000.0,-2500.0,5.0},
{-1500.0,-2500.0,5.0,-1000.0,-2500.0,5.0,-1500.0,-2000.0,5.0,-1000.0,-2000.0,5.0},
{-1500.0,-2000.0,5.0,-1000.0,-2000.0,5.0,-1500.0,-1500.0,5.0,-1000.0,-1500.0,5.0},
{-1600.0,-1500.0,5.0,-980.0,-1500.0,5.0,-1600.0,-1330.0,5.0,-980.0,-1330.0,5.0},
{-1500.0,-500.0,5.0,-1130.0,-500.0,5.0,-1500.0,0.0,5.0,-1130.0,0.0,5.0},
{-1500.0,0.0,5.0,-1080.0,0.0,5.0,-1500.0,500.0,5.0,-1080.0,500.0,5.0},
{-1500.0,500.0,5.0,-1040.0,500.0,5.0,-1500.0,1000.0,5.0,-1040.0,1000.0,5.0},
{-1500.0,1000.0,5.0,-1000.0,1000.0,5.0,-1500.0,1500.0,5.0,-1000.0,1500.0,5.0},
{-1500.0,1500.0,5.0,-1000.0,1500.0,5.0,-1500.0,2000.0,5.0,-1000.0,2000.0,5.0},
{-1500.0,2000.0,5.0,-1000.0,2000.0,5.0,-1500.0,2500.0,5.0,-1000.0,2500.0,5.0},
{-1500.0,2500.0,5.0,-1000.0,2500.0,5.0,-1500.0,2998.0,5.0,-1000.0,2998.0,5.0},
{-1000.0,-2998.0,5.0,-500.0,-2998.0,5.0,-1000.0,-2500.0,5.0,-500.0,-2500.0,5.0},
{-1000.0,-2500.0,5.0,-500.0,-2500.0,5.0,-1000.0,-2000.0,5.0,-500.0,-2000.0,5.0},
{-1000.0,-2000.0,5.0,-500.0,-2000.0,5.0,-1000.0,-1500.0,5.0,-500.0,-1500.0,5.0},
{-800.0,-1500.0,5.0,-500.0,-1500.0,5.0,-800.0,-1000.0,5.0,-500.0,-1000.0,5.0},
{-800.0,-1000.0,5.0,-500.0,-1000.0,5.0,-800.0,-500.0,5.0,-500.0,-500.0,5.0},
{-850.0,-500.0,5.0,-500.0,-500.0,5.0,-850.0,0.0,5.0,-500.0,0.0,5.0},
{-670.0,0.0,5.0,-500.0,0.0,5.0,-670.0,500.0,5.0,-500.0,500.0,5.0},
{-670.0,500.0,5.0,-500.0,500.0,5.0,-670.0,610.0,5.0,-500.0,610.0,5.0},
{742.0,1078.0,5.0,1000.0,1078.0,5.0,742.0,1230.0,5.0,1000.0,1230.0,5.0},
{-1000.0,1500.0,5.0,-500.0,1500.0,5.0,-1000.0,2000.0,5.0,-500.0,2000.0,5.0},
{-1000.0,2000.0,5.0,-500.0,2000.0,5.0,-1000.0,2500.0,5.0,-500.0,2500.0,5.0},
{-1000.0,2500.0,5.0,-500.0,2500.0,5.0,-1000.0,2998.0,5.0,-500.0,2998.0,5.0},
{-500.0,-2998.0,5.0,0.0,-2998.0,5.0,-500.0,-2500.0,5.0,0.0,-2500.0,5.0},
{-500.0,-2500.0,5.0,0.0,-2500.0,5.0,-500.0,-2000.0,5.0,0.0,-2000.0,5.0},
{-500.0,-2000.0,5.0,0.0,-2000.0,5.0,-500.0,-1500.0,5.0,0.0,-1500.0,5.0},
{-500.0,-1500.0,5.0,0.0,-1500.0,5.0,-500.0,-1450.0,5.0,0.0,-1450.0,5.0},
{-500.0,-1500.0,5.0,-210.0,-1500.0,5.0,-500.0,-1060.0,5.0,-210.0,-1060.0,5.0},
{-500.0,-1060.0,5.0,0.0,-1060.0,5.0,-500.0,-500.0,5.0,0.0,-500.0,5.0},
{-500.0,-500.0,5.0,0.0,-500.0,5.0,-500.0,0.0,5.0,0.0,0.0,5.0},
{-500.0,0.0,5.0,0.0,0.0,5.0,-500.0,500.0,5.0,0.0,500.0,5.0},
{-500.0,500.0,5.0,0.0,500.0,5.0,-500.0,1000.0,5.0,0.0,1000.0,5.0},
{-380.0,1000.0,5.0,0.0,1000.0,5.0,-380.0,1500.0,5.0,0.0,1500.0,5.0},
{-500.0,1500.0,5.0,0.0,1500.0,5.0,-500.0,2000.0,5.0,0.0,2000.0,5.0},
{-500.0,2000.0,5.0,0.0,2000.0,5.0,-500.0,2500.0,5.0,0.0,2500.0,5.0},
{-500.0,2500.0,5.0,0.0,2500.0,5.0,-500.0,2998.0,5.0,0.0,2998.0,5.0},
{0.0,-2998.0,5.0,500.0,-2998.0,5.0,0.0,-2500.0,5.0,500.0,-2500.0,5.0},
{0.0,-2500.0,5.0,500.0,-2500.0,5.0,0.0,-2000.0,5.0,500.0,-2000.0,5.0},
{0.0,-2000.0,5.0,500.0,-2000.0,5.0,0.0,-1500.0,5.0,500.0,-1500.0,5.0},
{880.0,1000.0,5.0,1000.0,1000.0,5.0,880.0,1078.0,5.0,1000.0,1078.0,5.0},
{0.0,-870.0,5.0,350.0,-870.0,5.0,0.0,-500.0,5.0,350.0,-500.0,5.0},
{0.0,-500.0,5.0,500.0,-500.0,5.0,0.0,0.0,5.0,500.0,0.0,5.0},
{0.0,0.0,5.0,440.0,0.0,5.0,0.0,500.0,5.0,440.0,500.0,5.0},
{0.0,500.0,5.0,300.0,500.0,5.0,0.0,1000.0,5.0,300.0,1000.0,5.0},
{0.0,1000.0,5.0,280.0,1000.0,5.0,0.0,1500.0,5.0,280.0,1500.0,5.0},
{0.0,1500.0,5.0,500.0,1500.0,5.0,0.0,2000.0,5.0,500.0,2000.0,5.0},
{0.0,2000.0,5.0,500.0,2000.0,5.0,0.0,2500.0,5.0,500.0,2500.0,5.0},
{0.0,2500.0,5.0,500.0,2500.0,5.0,0.0,2998.0,5.0,500.0,2998.0,5.0},
{500.0,-2998.0,5.0,1000.0,-2998.0,5.0,500.0,-2500.0,5.0,1000.0,-2500.0,5.0},
{500.0,-2500.0,5.0,1000.0,-2500.0,5.0,500.0,-2000.0,5.0,1000.0,-2000.0,5.0},
{500.0,-2000.0,5.0,1000.0,-2000.0,5.0,500.0,-1500.0,5.0,1000.0,-1500.0,5.0},
{540.0,-1500.0,5.0,1000.0,-1500.0,5.0,540.0,-1000.0,5.0,1000.0,-1000.0,5.0},
{730.0,-1000.0,5.0,1000.0,-1000.0,5.0,730.0,-500.0,5.0,1000.0,-500.0,5.0},
{890.0,-500.0,5.0,1000.0,-500.0,5.0,890.0,0.0,5.0,1000.0,0.0,5.0},
{900.0,0.0,5.0,1000.0,0.0,5.0,900.0,500.0,5.0,1000.0,500.0,5.0},
{900.0,500.0,5.0,1000.0,500.0,5.0,900.0,1000.0,5.0,1000.0,1000.0,5.0},
{500.0,1230.0,5.0,1000.0,1230.0,5.0,500.0,1500.0,5.0,1000.0,1500.0,5.0},
{500.0,1500.0,5.0,1000.0,1500.0,5.0,500.0,2000.0,5.0,1000.0,2000.0,5.0},
{500.0,2000.0,5.0,1000.0,2000.0,5.0,500.0,2500.0,5.0,1000.0,2500.0,5.0},
{500.0,2500.0,5.0,1000.0,2500.0,5.0,500.0,2998.0,5.0,1000.0,2998.0,5.0},
{1000.0,-2998.0,5.0,1500.0,-2998.0,5.0,1000.0,-2500.0,5.0,1500.0,-2500.0,5.0},
{1000.0,-2500.0,5.0,1500.0,-2500.0,5.0,1000.0,-2000.0,5.0,1500.0,-2000.0,5.0},
{1000.0,-2000.0,5.0,1500.0,-2000.0,5.0,1000.0,-1500.0,5.0,1500.0,-1500.0,5.0},
{1000.0,-1500.0,5.0,1500.0,-1500.0,5.0,1000.0,-1000.0,5.0,1500.0,-1000.0,5.0},
{1000.0,-1000.0,5.0,1500.0,-1000.0,5.0,1000.0,-500.0,5.0,1500.0,-500.0,5.0},
{1000.0,-500.0,5.0,1500.0,-500.0,5.0,1000.0,0.0,5.0,1500.0,0.0,5.0},
{1000.0,0.0,5.0,1500.0,0.0,5.0,1000.0,500.0,5.0,1500.0,500.0,5.0},
{1000.0,500.0,5.0,1500.0,500.0,5.0,1000.0,1000.0,5.0,1500.0,1000.0,5.0},
{1000.0,1000.0,5.0,1500.0,1000.0,5.0,1000.0,1500.0,5.0,1500.0,1500.0,5.0},
{1000.0,1500.0,5.0,1500.0,1500.0,5.0,1000.0,2000.0,5.0,1500.0,2000.0,5.0},
{1000.0,2000.0,5.0,1500.0,2000.0,5.0,1000.0,2500.0,5.0,1500.0,2500.0,5.0},
{1000.0,2500.0,5.0,1500.0,2500.0,5.0,1000.0,2998.0,5.0,1500.0,2998.0,5.0},
{1500.0,-2998.0,5.0,2000.0,-2998.0,5.0,1500.0,-2500.0,5.0,2000.0,-2500.0,5.0},
{1500.0,-2500.0,5.0,2000.0,-2500.0,5.0,1500.0,-2000.0,5.0,2000.0,-2000.0,5.0},
{1500.0,-2000.0,5.0,2000.0,-2000.0,5.0,1500.0,-1500.0,5.0,2000.0,-1500.0,5.0},
{1500.0,-1500.0,5.0,2000.0,-1500.0,5.0,1500.0,-1000.0,5.0,2000.0,-1000.0,5.0},
{1500.0,-1000.0,5.0,2000.0,-1000.0,5.0,1500.0,-500.0,5.0,2000.0,-500.0,5.0},
{1500.0,-500.0,5.0,2000.0,-500.0,5.0,1500.0,0.0,5.0,2000.0,0.0,5.0},
{1500.0,0.0,5.0,2000.0,0.0,5.0,1500.0,500.0,5.0,2000.0,500.0,5.0},
{1500.0,500.0,5.0,2000.0,500.0,5.0,1500.0,1000.0,5.0,2000.0,1000.0,5.0},
{1500.0,1000.0,5.0,2000.0,1000.0,5.0,1500.0,1500.0,5.0,2000.0,1500.0,5.0},
{1500.0,1500.0,5.0,2000.0,1500.0,5.0,1500.0,2000.0,5.0,2000.0,2000.0,5.0},
{1500.0,2000.0,5.0,2000.0,2000.0,5.0,1500.0,2500.0,5.0,2000.0,2500.0,5.0},
{1500.0,2500.0,5.0,2000.0,2500.0,5.0,1500.0,2998.0,5.0,2000.0,2998.0,5.0},
{2000.0,-2998.0,5.0,2500.0,-2998.0,5.0,2000.0,-2500.0,5.0,2500.0,-2500.0,5.0},
{2000.0,-2500.0,5.0,2500.0,-2500.0,5.0,2000.0,-2000.0,5.0,2500.0,-2000.0,5.0},
{2000.0,-2000.0,5.0,2500.0,-2000.0,5.0,2000.0,-1500.0,5.0,2500.0,-1500.0,5.0},
{2000.0,-1500.0,5.0,2500.0,-1500.0,5.0,2000.0,-1000.0,5.0,2500.0,-1000.0,5.0},
{2000.0,-1000.0,5.0,2500.0,-1000.0,5.0,2000.0,-500.0,5.0,2500.0,-500.0,5.0},
{2000.0,-500.0,5.0,2500.0,-500.0,5.0,2000.0,0.0,5.0,2500.0,0.0,5.0},
{2000.0,0.0,5.0,2500.0,0.0,5.0,2000.0,500.0,5.0,2500.0,500.0,5.0},
{2000.0,500.0,5.0,2500.0,500.0,5.0,2000.0,1000.0,5.0,2500.0,1000.0,5.0},
{2000.0,1000.0,5.0,2500.0,1000.0,5.0,2000.0,1500.0,5.0,2500.0,1500.0,5.0},
{2000.0,1500.0,5.0,2500.0,1500.0,5.0,2000.0,2000.0,5.0,2500.0,2000.0,5.0},
{2000.0,2000.0,5.0,2500.0,2000.0,5.0,2000.0,2500.0,5.0,2500.0,2500.0,5.0},
{2000.0,2500.0,5.0,2500.0,2500.0,5.0,2000.0,2998.0,5.0,2500.0,2998.0,5.0},
{2500.0,-2998.0,5.0,2998.0,-2998.0,5.0,2500.0,-2500.0,5.0,2998.0,-2500.0,5.0},
{2500.0,-2500.0,5.0,2998.0,-2500.0,5.0,2500.0,-2000.0,5.0,2998.0,-2000.0,5.0},
{2500.0,-2000.0,5.0,2998.0,-2000.0,5.0,2500.0,-1500.0,5.0,2998.0,-1500.0,5.0},
{2500.0,-1500.0,5.0,2998.0,-1500.0,5.0,2500.0,-1000.0,5.0,2998.0,-1000.0,5.0},
{2500.0,-1000.0,5.0,2998.0,-1000.0,5.0,2500.0,-500.0,5.0,2998.0,-500.0,5.0},
{2500.0,-500.0,5.0,2998.0,-500.0,5.0,2500.0,0.0,5.0,2998.0,0.0,5.0},
{2500.0,0.0,5.0,2998.0,0.0,5.0,2500.0,500.0,5.0,2998.0,500.0,5.0},
{2500.0,500.0,5.0,2998.0,500.0,5.0,2500.0,1000.0,5.0,2998.0,1000.0,5.0},
{2500.0,1000.0,5.0,2998.0,1000.0,5.0,2500.0,1500.0,5.0,2998.0,1500.0,5.0},
{2500.0,1500.0,5.0,2998.0,1500.0,5.0,2500.0,2000.0,5.0,2998.0,2000.0,5.0},
{2500.0,2000.0,5.0,2998.0,2000.0,5.0,2500.0,2500.0,5.0,2998.0,2500.0,5.0},
{2500.0,2500.0,5.0,2998.0,2500.0,5.0,2500.0,2998.0,5.0,2998.0,2998.0,5.0},
{280.0,1300.0,5.0,500.0,1300.0,5.0,280.0,1500.0,5.0,500.0,1500.0,5.0},
{300.0,500.0,5.0,390.0,500.0,5.0,300.0,640.0,5.0,390.0,640.0,5.0},
{-750.0,0.0,5.0,-670.0,0.0,5.0,-750.0,270.0,5.0,-670.0,270.0,5.0}}


for i,v in ipairs(Water) do
    local water = createWater (v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],v[9],v[10],v[11],v[12])
        local x,y,z = getElementPosition(water)
              setElementPosition(water,x,y,z)
end

Posted
There is a problem did everything as you said everything went forth from the beginning of the server came through a new destination for the missing water
What could be the problem

?

Posted

 

but the thing is when I do them before everything went lining here setElementPosition (water, x, y, z + 700) and everything went as but stepped out of the server and came through a new water stopped running

Posted

 

But I really need to have the vice city map simply problem is that when the output from the server and the arrival of a new water stopped running then I have a question as to prepare for it so that the water does not disappear when you go out from the server?

Posted

I have a problem about whater script. Problem is when i go out for server and go back to server the whater  missing. I hope you understand what i mean? And can help me fix the problem.

Posted

Add this to the end

 

WaterB = {}
ObjectB = {}
Blip = {}

for i,v in pairs(Water) do
local WaterA = createWater (v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],v[9],v[10],v[11],v[12] )
local x,y,z = getElementPosition(WaterA)
setElementPosition(WaterA,x,y,z)

local theObject = createObject ( 3003,x,y,z)
WaterB[theObject] = WaterA
ObjectB[theObject] = i
end

function fixWater()
local v = Water[ObjectB[source]]
local water = createWater (v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],v[9],v[10],v[11],v[12])
local x,y,z = getElementPosition(water)
setElementPosition(water,x,y,z)
destroyElement(WaterB[source])
WaterB[source] = water
end

function fixWater2()
local Water = WaterB[source]
local x,y,z = getElementPosition(Water)
setElementPosition(Water,x,y,z)
end


addEventHandler( "onClientElementStreamIn",resourceRoot,fixWater2)

 

Wolf Inc Discord

Youtube channel
Github

Posted

ouh... I fixed the whater script. IT worked ,them i go out and try go back and whater  agen missing. maybe i do somthing wrong?

Posted

So I did what you said. I restarted script -water appeared.Reconnected to server-water disappeared. Tryed to restart script again,but water doesnt appear anymore. Can you help me solve this problem?

Posted

Replace

for i,v in ipairs(Water) do
    local water = createWater (v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],v[9],v[10],v[11],v[12])
        local x,y,z = getElementPosition(water)
              setElementPosition(water,x,y,z)
end 

With

WaterB = {}
ObjectB = {}
Blip = {}

for i,v in pairs(Water) do
local WaterA = createWater (v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],v[9],v[10],v[11],v[12] )
local x,y,z = getElementPosition(WaterA)
setElementPosition(WaterA,x,y,z+700)

local theObject = createObject ( 3003,x,y,z+700)
WaterB[theObject] = WaterA
ObjectB[theObject] = i
end

function fixWater()
local v = Water[ObjectB[source]]
local water = createWater (v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],v[9],v[10],v[11],v[12])
local x,y,z = getElementPosition(water)
setElementPosition(water,x,y,z+700)
destroyElement(WaterB[source])
WaterB[source] = water
end

function fixWater2()
local Water = WaterB[source]
local x,y,z = getElementPosition(Water)
setElementPosition(Water,x,y,z)
end


addEventHandler( "onClientElementStreamIn",resourceRoot,fixWater2)

 

Wolf Inc Discord

Youtube channel
Github

Posted

@Cody(L) Water is still nothing  Tryed to restart script again,but water doesnt appear anymore. Can you help me solve this problem?

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...