-
Posts
21,935 -
Joined
-
Last visited
-
Days Won
6
Everything posted by Castillo
-
addEventHandler ( "onResourceStart", resourceRoot, function ( ) local radarXML = xmlLoadFile ( "radars.xml" ) if ( radarXML ) then for index, child in ipairs ( xmlNodeGetChildren ( radarXML ) )do name = xmlNodeGetAttribute ( child, "name" ) px = xmlNodeGetAttribute ( child, "posX" ) py = xmlNodeGetAttribute ( child, "posY" ) sx = xmlNodeGetAttribute ( child, "sizeX" ) sy = xmlNodeGetAttribute ( child, "sizeY" ) clr = xmlNodeGetAttribute ( child, "color" ) dim = xmlNodeGetAttribute ( child, "dimension" ) team = xmlNodeGetAttribute ( child, "team" ) ra = createRadarArea ( px, py, sx, sy, clr, 100 ) setElementData ( ra, "team", team ) setElementData ( ra, "turfName", name ) cX = tonumber ( xmlNodeGetAttribute ( child, "colX" ) ) cY = tonumber ( xmlNodeGetAttribute ( child, "colY" ) ) -- You had "coY" instead of "colY". cW = tonumber ( xmlNodeGetAttribute ( child, "colW" ) ) cH = tonumber ( xmlNodeGetAttribute ( child, "colH" ) ) colR = createColRectangle ( cX, cY, 40, 40 ) addEventHandler ( "onColShapeHit", colR, turf ) -- You added the event after ending the loop. end end xmlUnloadFile ( radarXML ) end ) Read the comments.
-
I don't understand what do you mean, though, if you don't post part of your script we can't help you.
-
This resource is my script but only changed the interface: https://community.multitheftauto.com/index.php?p= ... ls&id=4490 Original: https://community.multitheftauto.com/index.php?p= ... ils&id=811
-
Que se supone que tiene que hacer eso? "string" no esta definido en ningun lugar, tu script no tiene sentido.
-
You're welcome.
-
You forgot to define and pass the "player" argument. function destroy10 ( player ) removeEventHandler ( "onMarkerHit", Marker10, destroy10 ) destroyElement ( Marker10 ) checkVehicle ( player ) Marker2 = createMarker ( 1728.5, -6244.6000976563, 149.30000610352, "cylinder", 2.5, 150, 10, 10, 125 ) addEventHandler ( "onMarkerHit", Marker2, destroy2 ) end function checkVehicle ( player ) local vehicle = getPedOccupiedVehicle ( player ) local id = math.random( 400, 611 ) if id == 430 or id == 435 or id == 450 or id == 591 or id == 606 or id == 607 or id == 610 or id == 584 or id == 608 then setElementModel ( vehicle, 480 ) if id == 611 or id == 592 or id == 577 or id == 511 or id == 512 or id == 553 or id == 593 or id == 519 or id == 460 or id == 513 then setElementModel ( vehicle, 517 ) if id == 548 or id == 417 or id == 563 or id == 477 or id == 478 or id == 472 or id == 473 or id == 493 or id == 595 or id == 484 then setElementModel ( vehicle, 600 ) if id == 453 or id == 552 or id == 446 or id == 454 or id == 539 or id == 538 or id == 537 or id == 590 or id == 569 or id == 570 then setElementModel ( vehicle, 547 ) if id == 449 or id == 441 or id == 464 or id == 594 or id == 501 or id == 564 or id == 465 then setElementModel ( vehicle, 567 ) end end end end end end
-
You must trigger a server side event with triggerServerEvent and add the event server side with addEvent and addEventHandler, then trigger back the value with triggerClientEvent.
-
Pasa que esto no funciona asi, para editar la columna del nombre para que use la cuenta vas a tener que editar la scoreboard.
-
Para que es eso? lo que veo que es enviara el mensaje al log del servidor con el nombre de la cuenta. Que es esto: "accountName(source)" ?? que hace "(source)" ahi? P.D: Te falto el evento.
-
Mira, un inventario se puede hacer como quieras, si queres que sea una grid list con rows, entonces hacelo asi.
-
That's because getPlayerWantedLevel client side only returns the local player wanted level, it has no arguments.
-
"source" is not defined there. ammumarker = createMarker ( 1367.34094, -1279.96411, 12.54688, "cylinder", 1.5, 255, 255, 0, 170 ) function teleportMeToAmmunationInterior ( thePlayer ) setElementInterior ( thePlayer, 6 ) setElementPosition ( thePlayer, 317.2380, -168.0520, 999.5930 ) end addEventHandler ( "onMarkerHit", ammumarker, teleportMeToAmmunationInterior )
-
La unica manera es crear tu PROPIA fuente con guiCreateFont.
-
You want to set the velocity of the vehicle to 0? if so, use setElementVelocity.
-
Topic moved to "Support for MTA:SA 1.x > Linux-Server".
-
Topic moved to "Support for MTA:SA 1.x > Server".
-
That's wrong. function assignTeam ( thePlayer, commandName, playerName, teamName ) local team = getTeamFromName ( teamName ) local player = getPlayerFromName ( playerName ) -- Get the player element from a name. if ( team and player and hasObjectPermissionTo ( thePlayer, "function.kickPlayer" ) ) then setPlayerTeam ( player, team ) outputChatBox ( "You have been moved to ".. getTeamName ( team ).." team by ".. getPlayerName ( thePlayer ), player, 128, 206, 206 ) end end addCommandHandler ( "team", assignTeam )
-
Eso no tiene sentido mishael.
-
Put back the original "spawn_locations.map" and make the spawns again with the same syntax as current.
-
function enter ( player, seat ) if ( seat == 0 ) then setVehicleEngineState ( source, false ) local eniginestate = getVehicleEngineState ( source ) if ( eniginestate == false ) then outputChatBox ( "Press J to start the ".. getVehicleName ( source ) .."'s engine.", player, 255, 255, 0 ) end end end addEventHandler ( "onVehicleEnter", getRootElement(), enter )
-
@Alexs_Steel: Siempre tenes que mirar los argumentos requeridos en la wiki.