Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- File: fn_gasolineraPro.sqf
- Author: life
- */
- _param = _this select 0;
- if (_param == "solicitarGas") then
- {
- _boquilla = "pop_tiburon" createVehicle position player;
- _boquilla attachTo [player, [-0.1, 0.1, 0.15], "RightHand"];
- player addAction ["Poner gasolina",' ["ponerGas"] spawn life_fnc_gasolineraPro;', "", 9,false,true,"",""];
- };
- if (_param == "ponerGas") then {
- _objeto = cursorObject;
- if(player distance _objeto > 2) exitWith {hint "Te has alejado";};
- if(_objeto isKindOF "LandVehicle") then {
- deleteVehicle _boquilla;
- _boquilla = "pop_tiburon" createVehicle position player;
- _boquilla attachTo _objeto;
- _gasolina = fuel _objeto;
- _gasolinaxcien = _gasolina * 100;
- _dinero = _gasolinapuesta;
- hint format ["Usted tiene un %1% de gasolina\n Le va a costar: %2", _gasolinaxcien, _dinero]
- player addAction ["Cojer boquilla",' ["cojer"] spawn life_fnc_gasolineraPro;', "", 9,false,true,"",""];
- }else{
- hint "Debes apuntar al coche para ponerle gasolina. El aire corre solo";
- };
- };
- if (_param == "cojer") then{
- deleteVehicle _boquilla;
- _boquilla = "pop_tiburon" createVehicle position player;
- player addAction ["Devolver boquilla",' ["devolver"] spawn life_fnc_gasolineraPro;', "", 9,false,true,"",""];
- };
- if (_param == "devolver") then{
- deleteVehicle _boquilla;
- };
Advertisement
Add Comment
Please, Sign In to add comment