Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.
GTAONLINE.PL
Tematy otagowane jako: teleportacji
1. blokada teleportacji pojazdu do interioru
dzie? dobry, mam problem xd..
mo?e jest do?? prosty do rozwi?zania ale utkn??em kombinuj?c ju? ze wszystkim co mi wpad?o do g?owy...
za ka?dym razem mi to nie dzia?a, i wgl, sprawa prosta chce zablokowa? mo?liwo?? wej?cia albo zbugowania postaci po przez wjazd do markera pojazdem, r??ne cuda si? dziej? np wywala do limbo itd, to kod;

[lua]
addEventHandler("onMarkerHit", getRootElement(),
function(hitPlayer, matchingDimension)
if ( getElementData(source, "weaponshop") ) then
if isPedInVehicle(hitPlayer) then
-- // effect
fadeCamera(hitPlayer, false)
setTimer(fadeCamera, 1000, 1, hitPlayer, true)
-- // entrance/exit
if ( getElementData(source, "entrance") ) then
setTimer(setElementInterior, 1000, 1, hitPlayer, 1)
setTimer(setElementPosition, 1000, 1, hitPlayer, getElementData(source, "x"), getElementData(source, "y"), getElementData(source, "z"))
setTimer(setElementRotation, 1000, 1, hitPlayer, 0, 0, 0)
elseif ( getElementData(source, "exit") ) then
setTimer(setElementInterior, 1000, 1, hitPlayer, 0)
setTimer(setElementPosition, 1000, 1, hitPlayer, getElementData(source, "x"), getElementData(source, "y"), getElementData(source, "z"))
...
2. Brak Teleportacji
Witam u?ywam panelu logowania, kt?ry jest tutaj na forum i mam jeden problem. Nie chce on teleportowa?..

[lua]local sx,sy=guiGetScreenSize()
local data={ showed=nil, button={}, info=nil, misc=nil, }

function isMouseIn(psx,psy,pssx,pssy,abx,aby)
if not isCursorShowing() then return end
cx,cy=getCursorPosition()
cx,cy=cx*sx,cy*sy
if cx >= psx and cx <= psx+pssx and cy >= psy and cy <= psy+pssy then
return true,cx,cy
else
return false
end
end

function renderZoneBox()
dxDrawImage(0/1440*sx, 0/900*sy, 1440/1440*sx, 900/900*sy, "tlo.png", 0, 0, 0, tocolor(255, 255, 255, 255), false)
if data.info then dxDrawText(data.info, sx*252/1024, sy*232/768, sx*800/1024, sy*255/768, tocolor(237, 0, 0, 255), 1.00, "default", "center", "center", false) end
if not isMouseIn(sx*98/1024, sy*294/768, sx*225/1024, sy*92/768) then dxDrawRectangle(sx*98/1024, sy*294/768, sx*225/1024, sy*92/768, tocolor(35, 35, 35, 193), false)
else dxDrawRectangle(sx*98/1024, sy*294/768, sx*225/1024, sy*92/768, tocolor(0, 155, 200, 193), false) end
if not isMouseIn(sx*415/1024, sy*294/768, sx*225/1024, sy*92/768) then dxDrawRectangle(sx*415/1024, sy*294/768, sx*225/1024, sy*92/768, tocolor(35, 35, 35, 193), false)
else dxDrawRectangle(sx*415/1024, sy*294/768, sx*225/1024, sy*92/768, tocolor(0, 155, 200, 193), false) end
if not isMouseIn(sx*710/1024, sy*294/768, sx*225/1024, sy*92/768) then dxDraw...
3. Predkość po teleportacji
Mam do was pytanie czy jest mo?liwo?? ?e gdy gracz jedzie pojazdem i wpisze komend? na teleportacje to po teleporcie gracz ma t? sam? pr?dko?? co tuz przed teleportacj? ?

Aby nie by?o zatrzymania pojazdu.
4. Panel Teleportacji
Zrobilem pelny kod ale tak to juz u mnie jest, bez bledow sie nie obejdzie :)

CLIENT:
[lua]
GUIEditor = {
button = {},
window = {}
}
GUIEditor.window[1] = guiCreateWindow(481, 309, 654, 434, "Teleport Panel", false)
guiWindowSetMovable(GUIEditor.window[1], false)
guiWindowSetSizable(GUIEditor.window[1], false)
guiSetAlpha(GUIEditor.window[1], 1.00)
guiSetVisible ( GUIEditor.window[1], false)

local fc = guiCreateButton(53, 158, 152, 55, "Fort Carson", false, GUIEditor.window[1])
local lp = guiCreateButton(254, 157, 150, 56, "Las Paysadas", false, GUIEditor.window[1])
local sl = guiCreateButton(448, 158, 139, 55, "Stare Lotnisko", false, GUIEditor.window[1])
local ls = guiCreateButton(54, 260, 151, 55, "Los Santos", false, GUIEditor.window[1])
local sf = guiCreateButton(256, 260, 148, 55, "San Fierro", false, GUIEditor.window[1])
local lv = guiCreateButton(449, 262, 138, 53, "Las Venturas", false, GUIEditor.window[1])
local bull = guiCreateButton(375, 349, 232, 63, "Bullet", false, GUIEditor.window[1])


function xd()
dxDrawText("Teleport", 596, 333, 1015, 404, tocolor(255, 255, 255, 255), 3.00, "bankgothic", "left", "top", false, false, true, false, false)
dxDrawText("BONUS :", 555, 642, 809, 705, tocolor(2...
5. [DM] Zablokowanie możliwości teleportacji
Chcia?em zablokowa? mo?liwo?? teleportacji za pomoc? komendy /idzdo lub po przez klikni?cie na nick gracza podobnie jak jest z zablokowaniem odbierania prywatnych wiadomo?ci w mapie PP.

Wygl?da to tak.

[code]COMMAND:pmoff(playerid, params[])
{
if(!Player[playerid][Vip] && !IsAdmin(playerid))
{
SendClientMessage(playerid, COLOR_ERROR, " (b??d) Komenda dost?pna tylko dla Vip?w.");
return 1;
}

Player[playerid][PMOff] = true;
SendClientMessage(playerid, COLOR_GREEN, " [PES info] Wy??czy?e?/a? prywatne wiadomo?ci.");
return 1;
}

COMMAND:pmon(playerid, params[])
{
if(!Player[playerid][Vip] && !IsAdmin(playerid))
{
SendClientMessage(playerid, COLOR_ERROR, " (b??d) Komenda dost?pna tylko dla Vip?w.");
return 1;
}

Player[playerid][PMOff] = false;
SendClientMessage(playerid, COLOR_GREEN, " [PES info] W??czy?e?/a? prywatne wiadomo?ci.");
return 1;
}[/code]

A teraz komenda na teleportacje.

[code]COMMAND:idzdo(playerid, params[])
{
new PlayerId;
if(sscanf(params, "u", PlayerId))
{
SendClientMessage(playerid, COLOR_ERROR, " (b??d) U?yj: /idzdo [id gracza]");
return 1;
}

if(PlayerId == INVALID_PLAYER_ID)
{
SendClientMessage(playerid, COLOR_ERROR, " (b??d) Nie ma gracza o podanym ID.");
return 1;
}

if(playerid == PlayerId)
{
SendClientMessage(playerid, COLOR_ERROR, " (b??d) Poda?e?/a? swoje id!");
return 1;
}

if(Player[PlayerId][TPRefu...
6. [INNE] Jak zrobić teleport/usunac go/zmienic miejsce telepor
Witam chcia?bym si? was spytac jak zrobi? teleport lub zmieni? jego miejsce teleportacji lub go usun??. Mam mapk? pt-rp (polish truck role play 2011). I chcia?bym zmieni? ten teleport (?eby teleportowa? mnie gdzie indziej):





Kod:

http://hosting-zdjec.pl/images/803sa_mp_014.png
http://hosting-zdjec.pl/images/229sa_mp_016.png
http://hosting-zdjec.pl/images/386sa_mp_015.png