-
Posts
4,961 -
Joined
-
Last visited
Everything posted by Jaysds1
-
MTA works now?
-
When does this error occur?
-
A: Ya, I have beer and Vodka. Q:Do you want some?
-
try this: local facing = 0 local distance = 5; local height = 1; local speed = 0.0002 function rotateCameraAroundPlayer() local x, y, z = getElementPosition(localPlayer) if isPedInVehicle(localPlayer) then x, y, z = getElementPosition(getPedOccupiedVehicle(localPlayer)) end local camX = x + math.cos(facing / math.pi * 180) * distance; local camY = y + math.sin(facing / math.pi * 180) * distance; setCameraMatrix(camX, camY, z + height, x, y, z) facing = facing + 0.0002 end function startRotatingCamera() addEventHandler("onClientPreRender", root, rotateCameraAroundPlayer) end function stopRotatingCamera() removeEventHandler("onClientPreRender", root, rotateCameraAroundPlayer) end addEventHandler("onClientResourceStart", resourceRoot,function() --Use onClientResourceStart for localPlayer fadeCamera(true, 3) --no need for source if the client is localPlayer startRotatingCamera() setPlayerNametagColor(0, 204, 0) --If it's client-side, don't add source end) I add comments to let you know the stuff your missing
-
bool setCameraMatrix ( float positionX, float positionY, float positionZ [, float lookAtX, float lookAtY, float lookAtZ, float roll, float fov ] )
-
ok, try the code I previously posted. If you restart the code, your going to have to do /reconnnct while in-game. function elplayer( thePlayer ) attachElements ( thePlayer, elobjeto, 0, 0, 0) end addEventHandler("onPlayerJoin",root,function() bindKey(source,"z", "down", elplayer) end)
-
All your crashes are on your GTA, Do you have Mods?
-
When you type in the command "/o", Do you want to make the z button available? or do you want the key to be pressed anytime?
-
when you type in "/o" in the chat, you could press "z". Do you want it by it's self? if so: function elplayer( thePlayer ) attachElements ( thePlayer, elobjeto, 0, 0, 0) end addEventHandler("onPlayerJoin",root,function() bindKey(source,"z", "down", elplayer) end)
-
try again, I've put it in the /o command
-
ya, but you don't need those zero's --Server vehiculo = createVehicle( 497, 691.71069, -2794.62891, 8.90768) function ponere() elobjeto = createObject(2669, 0, 0, 0 ) elmarker = createMarker( 0, 0, -7, "cylinder", 1.5, 255,255,255,100 ) setElementID ( elmarker, "elmarker" ) attachElements ( elobjeto, vehiculo, 0, 0, -2 ) attachElements ( elmarker, elobjeto, 0, 0, 0 ) addCommandHandler("i",function() local objeto2 = createObject(3029, 0, 0, -3, 0, 0, 0) attachElements ( objeto2, elobjeto, 0, 0, 0) end) bindKey(sourc,"z", "down", elplayer) end addCommandHandler("o", ponere) function elplayer() attachElements (source, elobjeto) end ----------- --ElMisil-- function tankHat () local misilero = createVehicle ( 470, 646.61682, -3012.08838, 8.50924 ) setVehicleColor( misilero, 255, 0, 0 ) setElementID ( misilero, "misilero" ) local lanzamisiles = createObject ( 359, 2224.51, 2459.16, 10.668, 0, 0, 90) local lanzamisiles2 = createObject ( 359, 2225.51, 2459.16, 10.668, 0, 0, 90) attachElements ( lanzamisiles, misilero, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles2, misilero, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat ) function tankHat2 () local misilero2 = createVehicle( 470, 649.54480, -2736.32739, 8.78277) setVehicleColor( misilero2, 255, 0, 0 ) setElementID ( misilero2, "misilero2" ) local lanzamisiles3 = createObject ( 359, 2224.51, 2459.16, 12.668, 0, 0, 90) local lanzamisiles4 = createObject ( 359, 2225.51, 2459.16, 11.668, 0, 0, 90) attachElements ( lanzamisiles3, misilero2, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles4, misilero2, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat2 )
-
What's your object? A gate? Gun? Box?
-
lol, I found my mistake --Server vehiculo = createVehicle( 497, 691.71069, -2794.62891, 8.90768) function ponere() elobjeto = createObject(2669, 0, 0, 0 ) elmarker = createMarker( 0, 0, -7, "cylinder", 1.5, 255,255,255,100 ) setElementID ( elmarker, "elmarker" ) attachElements ( elobjeto, vehiculo, 0, 0, -2 ) attachElements ( elmarker, elobjeto, 0, 0, 0 ) addCommandHandler("i",function() local objeto2 = createObject(3029, 0, 0, -3, 0, 0, 0) attachElements ( objeto2, elobjeto, 0, 0, 0) end) end addCommandHandler("o", ponere) ----------- --ElMisil-- function tankHat () local misilero = createVehicle ( 470, 646.61682, -3012.08838, 8.50924 ) setVehicleColor( misilero, 255, 0, 0 ) setElementID ( misilero, "misilero" ) local lanzamisiles = createObject ( 359, 2224.51, 2459.16, 10.668, 0, 0, 90) local lanzamisiles2 = createObject ( 359, 2225.51, 2459.16, 10.668, 0, 0, 90) attachElements ( lanzamisiles, misilero, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles2, misilero, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat ) function tankHat2 () local misilero2 = createVehicle( 470, 649.54480, -2736.32739, 8.78277) setVehicleColor( misilero2, 255, 0, 0 ) setElementID ( misilero2, "misilero2" ) local lanzamisiles3 = createObject ( 359, 2224.51, 2459.16, 12.668, 0, 0, 90) local lanzamisiles4 = createObject ( 359, 2225.51, 2459.16, 11.668, 0, 0, 90) attachElements ( lanzamisiles3, misilero2, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles4, misilero2, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat2 )
-
try this: --Server local vehiculo = createVehicle( 497, 691.71069, -2794.62891, 8.90768) function ponere() local elobjeto = createObject(2669, 0, 0, 0 ) local elmarker = createMarker( 0, 0, -7, "cylinder", 1.5, 255,255,255,100 ) setElementID ( elmarker, "elmarker" ) attachElements ( elobjeto, vehiculo, 0, 0, -2 ) attachElements ( elmarker, elobjeto, 0, 0, 0 ) addEventHandler ("onMarkerHit", elmarker, function(hitPlayer) if ( hitPlayer == source ) then getElementByID ( elmarker ) local objeto2 = createObject(3029, 0, 0, -3) attachElements ( objeto2, elobjeto, 0, 2, 0) end end) addCommandHandler("i",function() local objeto2 = createObject(3029, 0, 0, -3, 0, 0, 0) attachElements ( objeto2, elobjeto, 0, 0, 0) end) end addCommandHandler("o", ponere) ----------- --ElMisil-- function tankHat () local misilero = createVehicle ( 470, 646.61682, -3012.08838, 8.50924 ) setVehicleColor( misilero, 255, 0, 0 ) setElementID ( misilero, "misilero" ) local lanzamisiles = createObject ( 359, 2224.51, 2459.16, 10.668, 0, 0, 90) local lanzamisiles2 = createObject ( 359, 2225.51, 2459.16, 10.668, 0, 0, 90) attachElements ( lanzamisiles, misilero, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles2, misilero, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat ) function tankHat2 () local misilero2 = createVehicle( 470, 649.54480, -2736.32739, 8.78277) setVehicleColor( misilero2, 255, 0, 0 ) setElementID ( misilero2, "misilero2" ) local lanzamisiles3 = createObject ( 359, 2224.51, 2459.16, 12.668, 0, 0, 90) local lanzamisiles4 = createObject ( 359, 2225.51, 2459.16, 11.668, 0, 0, 90) attachElements ( lanzamisiles3, misilero2, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles4, misilero2, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat2 )
-
try this: ----------- --ElMisil-- function lanzamisiles ( ) local vehicle = getPedOccupiedVehicle ( localPlayer ) local x, y, z = getElementPosition (localPlayer) if ( vehicle and vehicle == getElementByID ( "misilero" ) ) then if ( not createProjectile ( localPlayer, 19, x, y + 7.5, z + 6, 70) ) then elseif ( not createProjectile ( localPlayer, 19, x, y + 7.5, z + 6, 70) ) then outputChatBox ( "Ha ocurrido un problema, deja descansar el lanzamisiles" ) end end end function lanzamisiles2 ( ) local vehicle = getPedOccupiedVehicle ( localPlayer ) local x, y, z = getElementPosition (localPlayer) if ( vehicle and vehicle == getElementByID ( "misilero2" ) ) then if ( not createProjectile ( localPlayer, 19, x, y + 7.5, z + 6, 70) ) then elseif ( not createProjectile ( localPlayer, 19, x, y + 7.5, z + 6, 70) ) then outputChatBox ( "Ha ocurrido un problema, deja descansar el lanzamisiles" ) end end end bindKey ( "B", "down", lanzamisiles ) bindKey ( "N", "down", lanzamisiles2 ) --Server local vehiculo = createVehicle( 497, 691.71069, -2794.62891, 8.90768) function ponere() local elobjeto = createObject(2669, 0, 0, 0 ) local elmarker = createMarker( 0, 0, -7, "cylinder", 1.5, 255,255,255,100 ) setElementID ( elmarker, "elmarker" ) attachElements ( elobjeto, vehiculo, 0, 0, -2 ) attachElements ( elmarker, elobjeto, 0, 0, 0 ) addEventHandler ("onMarkerHit", elmarker, function(hitPlayer) if ( hitPlayer == source ) then getElementByID ( elmarker ) local objeto2 = createObject(3029, 0, 0, -3) attachElements ( objeto2, elobjeto, 0, 2, 0) end end) end addCommandHandler("o", ponere) ----------- --ElMisil-- function tankHat () local misilero = createVehicle ( 470, 646.61682, -3012.08838, 8.50924 ) setVehicleColor( misilero, 255, 0, 0 ) setElementID ( misilero, "misilero" ) local lanzamisiles = createObject ( 359, 2224.51, 2459.16, 10.668, 0, 0, 90) local lanzamisiles2 = createObject ( 359, 2225.51, 2459.16, 10.668, 0, 0, 90) attachElements ( lanzamisiles, misilero, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles2, misilero, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat ) function tankHat2 () local misilero2 = createVehicle( 470, 649.54480, -2736.32739, 8.78277) setVehicleColor( misilero2, 255, 0, 0 ) setElementID ( misilero2, "misilero2" ) local lanzamisiles3 = createObject ( 359, 2224.51, 2459.16, 12.668, 0, 0, 90) local lanzamisiles4 = createObject ( 359, 2225.51, 2459.16, 11.668, 0, 0, 90) attachElements ( lanzamisiles3, misilero2, .5, .5, 1.2, 0, 0, 90 ) attachElements ( lanzamisiles4, misilero2, -.5, .5, 1.2, 0, 0, 90 ) end addEventHandler ( "onResourceStart", getRootElement(), tankHat2 )
-
The marker is in the other script...
-
try: local lastTimePlayed local month = {"January","February","March","April","May","June","Juli","August","September","October","November","December"} function timestampToDate(stamp) local time = getRealTime(stamp) return string.format("%d %s %02d:%02d",time.monthday,month[time.month+1],time.hour,time.minute) end addEvent("onMapStarting",true) addEventHandler ( 'onMapStarting', root,function ( mapInfo ) local resource = exports.mapmanager:getRunningGamemodeMap() local mapname = getResourceInfo ( resource, "name" ) local author = getResourceInfo(exports.mapmanager:getRunningGamemodeMap(),"author") local lastTimePlayed = timestampToDate(mapInfo.lastTimePlayed) local xml = xmlLoadFile("data/ratings.xml") if ( xml ) then local index = findIndexByName ( resource ) if ( index ) then local map = xmlFindChild ( xml, "map", index ) local rating = xmlNodeGetAttribute ( map, "rating" ) local ratedBy = xmlNodeGetAttribute ( map, "ratedBy" ) local played = xmlNodeGetAttribute ( map, "played" ) triggerClientEvent(source,"INFO",root,mapname,author,rating,ratedBy,played,lastTimePlayed) else outputChatBox ( "Map not found in our ratings list.", root, 255, 0, 0) end else outputChatBox ( "Unable to load map ratings XML file.", root, 255, 0, 0) end end) function findIndexByName ( resource ) local ratingsFile = xmlLoadFile("data/ratings.xml") if ( ratingsFile ) then for index, map in ipairs ( xmlNodeGetChildren ( ratingsFile ) ) do local name = xmlNodeGetAttribute ( map, "id" ) if ( name == resource ) then return index -1 end end xmlUnloadFile(ratingsFile) end end
-
guiRoot is a new predefined variable: Predefined_variables_list and your welcome
-
ok, I'm so lost now... Reinstall GTA and MTA Download this MTADiag, after when your finish running it, post the generated log either here using or PasteBin.
-
try this: hi_window = guiCreateWindow(354,252,362,272,"Haushaltsinventar",false) guiWindowSetSizable(hi_window,false) guiSetVisible(hi_window,true) --Label hi_lbl = guiCreateLabel(34,25,305,35,"Hallo. Das ist dein Haushaltsinventar.\nVon hier aus kannst du Möbel in dein Haus platzieren.",false,hi_window) guiSetFont(hi_lbl,"default-bold-small") --Grid hi_grid = guiCreateGridList(38,69,290,157,false,hi_window) guiGridListSetSelectionMode(hi_grid,2) hinvName = guiGridListAddColumn(hi_grid,"Name",2) --Button hi_btn = guiCreateButton(90,231,186,22,"Platzieren",false,hi_window) centerWindow(hi_window) addEventHandler("onClientGUIClick",guiRoot,function(button) if(button=="left")then if(source==hi_btn)then guiSetVisible(hi_window,false) textITT() end end end,false) function textITT() outputChatBox("TEXT") end
-
Well, I don't know How your look... Try disabling Norton
-
Well, he said "i have problem, output does not show... why ?" and the main problem was the output