Sign in to follow this  
Followers 0
jus61

Random Spawn

1 post in this topic

Hallo Community!!

Ich habe auf meinem Server das Standart Spawn System deaktiviert da ich es wie in A2 DayZ Epoch haben will. So weit alles gut jedoch habe ich das Problem das ich jedes mal unten Links im Wasser lande!

So schaut das Script aus:

ExileClient_gui_selectSpawnLocation_show.sqf

/**
 * ExileClient_gui_selectSpawnLocation_show
 *
 * Exile Mod
 * www.exilemod.com
 * © 2015 Exile Mod Team
 *
 * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. 
 * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
 */
 
private["_display","_spawnButton","_listBox","_listItemIndex","_numberOfSpawnPoints","_randNum","_randData","_randomSpawnIndex"];
//disableSerialization;
ExileClientSpawnLocationSelectionDone = true;
ExileClientSelectedSpawnLocationMarkerName = "";

_spawnPos = [getMarkerPos "middleMarker", 0, 6000, 20, 0, 5, 0] call BIS_fnc_findSafePos;
player setPos _spawnPos;  

/*
createDialog "RscExileSelectSpawnLocationDialog";
waitUntil
{
	_display = findDisplay 24002;
	!isNull _display
};
_spawnButton = _display displayCtrl 24003;
_spawnButton ctrlEnable false;
_display displayAddEventHandler ["KeyDown", "_this call ExileClient_gui_loadingScreen_event_onKeyDown"];
_listBox = _display displayCtrl 24002;
lbClear _listBox;
{
	if (getMarkerType _x == "ExileSpawnZone") then
	{
		_listItemIndex = _listBox lbAdd (markerText _x);
		_listBox lbSetData [_listItemIndex, _x];
	};
}
forEach allMapMarkers;
_numberOfSpawnPoints = {getMarkerType _x == "ExileSpawnZone"} count allMapMarkers;
if (_numberOfSpawnPoints > 0) then 
{
	_randNum = floor(random _numberOfSpawnPoints);
	_randData = lbData [24002,_randNum];
	_randomSpawnIndex = _listBox lbAdd "Random";
	_listBox lbSetData [_randomSpawnIndex, _randData];
};
*/
true

Den Marker mit dem namen "middleMarker" habe ich in der missions.sqm so gemacht:

		class Item10
		{
			position[]={12400.547,109.94063,13355.841};
			name="middleMarker";
			type="mil_warning";
		};

 

Kann mir jemand helfen warum ich immer unten Links im Wasser Spawne?????

Edited by jus61

Share this post


Link to post
Share on other sites
Advertisement

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
Sign in to follow this  
Followers 0

  • Recently Browsing   0 members

    No registered users viewing this page.