Jump to content

Wraith_last

Member
  • Content Count

    8
  • Joined

  • Last visited

  • Medals

Posts posted by Wraith_last


  1. Gonna put the TLDR at the start: (Sorry if this problem is posted elsewhere, I did not see it)
    When I make a mission and upload it to my server, I try to log in as normal and I get stuck in a perpetual loading screen
    Details of note: When I click on my server, there is a field in the bottom left of the screen that shows the mission setup for the selected server. This field is empty.
    Shortly before this started happening my game... Reset itself? I don't know how else to discribe it. You know when you create a new profile and you get a popup about Contact or whatever? All my saved addon settings for servers, Ops and all that were gone.

    Now the whole story:
    So I was updating a map I provide to my arma unit as a kinda side project and hobby.
    I uploaded it as normal and when I went to test it, my game crashed as Arma does sometimes. I reopened the game and got the new profile thing of DLC popups appear and the game asked me if I wanted to do boot camp- It was odd but did not think too much of it.
    I realised I had forgotten something when I was updating the map and went back and edited the part i had forgotten and uploaded it to the server.
    I have a server with 40 slots but only make slots for 30 players. That means when my server shows up in the recent server list it should show 0/30 slots but it showed 0/40 slots in use. I then noticed the field on the bottom left was empty of mission presents. No map name or mission type was being shown.
    I went back into eden and looked at the settings and found they were all reset back to the state they are in when you first make a mission.
    I set up everything again, saved and out of paranoia I looked in the addon settings section and found they too were reset back to their respective mod defaults. When I tried to load the saved addon list I found that my saves were all gone too.
    I rebuilt my server addon presets and then loaded it onto the server to be met with the same problem.

    I figured that a mod was causing issues so to test I unloaded ALL mods and build a quick mission file with a single player and respawn, the basics of what you need to test new map, loaded the setting and configured the general and multiplayer setting. When I loaded it on the server I saw the same thing.
    I have also lost "Add items to Zeus" option that I normally click on in the multiplayer tab and I no longer have the option to "Export as .pbo"
    And that is where I am now. I can still test an MP game on my computer but anything I now build and try to upload onto the server does not work, not to mention the loss of options and functionalliy within Eden is annoying.
    Anyone with ideas?


  2. Hello, I have the following script from an old post and it works about 50%.
    It is for saving loadout and position when logging. The Problem is it saves pos data but the loadouts are reset every time I log back in. Meaning I could log out in an area where enemies spawn with high powered rifles and I am running around with the starter pistol.
    He she is:


    TAG_fnc_loadClientData = {
        _this params ["_loadout", "_positionASL", "_dir"];
        player setUnitLoadout _loadout;
        player setDir _dir;
        player setPosASL _positionASL;
    };

    if(isServer) then {
        addMissionEventHandler [
            "HandleDisconnect",
            {
                params ["_body", "_id", "_uid", "_name"];
                
                if(!isNull _body) then {            
                    //Init storage var
                    if(isNil "TAG_disconnectedLoadouts") then {
                        TAG_disconnectedLoadouts = [];
                    };
                    
                    //Get data
                    private _loadout = getUnitLoadout _body;
                    private _position = getPos _body;
                    private _direction = getDir _body;
                        
                    //Find in storage
                    private _uidIndex = TAG_disconnectedLoadouts find _uid;
                    if(_uidIndex > -1) then {
                        //Found -> update
                        private _loadoutIndex = _uidIndex + 1;
                        TAG_disconnectedLoadouts set [_loadoutIndex, [_loadout, _position, _direction]];
                    } else {
                        //Not found -> Add new
                        TAG_disconnectedLoadouts pushBack _uid;
                        TAG_disconnectedLoadouts pushBack [_loadout, _position, _direction];
                    };
                };
                false
            }
        ];

        addMissionEventHandler [
            "PlayerConnected",
            {
                params ["_id", "_uid", "_name", "_jip", "_owner"];
                if(_jip) then {
                    private _clientData = missionNamespace getVariable ["TAG_disconnectedLoadouts", []];
                    private _uidIndex = _clientData find _uid;
                    if(_uidIndex > -1) then {
                        private _loadoutIndex = _uidIndex + 1;
                        (_clientData select _loadoutIndex) remoteExec ["TAG_fnc_loadClientData", _owner];
                    };
                };
            }
        ];
    };

     

    Any help would be gladly recived.


  3. Awesome, you guys are the best!
    One last question (that I can think of), is it possible to add a player specific Arsenal/Storage box? For example a box assigned to a slot or a box simular to the save player inventory script on logout that will act like a personal locker for the individual players to store extra equipment in? This one is way out of my skills to even attempt TBH but it would add a nice finishing touch to the player base.


  4. 8 hours ago, RCA3 said:
    
    params["_box"];
    while {true} do{
    	clearMagazineCargo _box;
    	private _magazine = selectRandom ["TIOW_OCC_CarbineMag_40rnd","TIOW_OCC_CarbineMag_40rnd_Tracer","M36KantRifle_mag","TIOW_LongLas_Mag"];
    	_box addMagazineCargo [_magazine, [0,3] select (round (random 1) isEqualTo 1)];
    	sleep 5400;      
    };

     

    Interesting.. will give it a go, though I gotta admit I have no idea what the new commands do or how they influence the way gear spawns. Would you explain the [_magazine, [0,3] select (round (random 1) isEqualTo 1)]; part to me?
    Why is there no whole number after _magazine? Spawn percentage chance?
    The other two I have no idea.


  5. Thanks! I ended up using this in a .sqf

    params["_box"];
    while {true} do
    {
      clearMagazineCargo _box;
      _Magazine = ["TIOW_OCC_CarbineMag_40rnd","TIOW_OCC_CarbineMag_40rnd_Tracer","M36KantRifle_mag","TIOW_LongLas_Mag"] call BIS_fnc_selectRandom;
     
      _box addMagazineCargo [_Magazine, 3];  

      sleep 5400;
    };
    With the variations for medical, weapons ect.
    How would I add an empty slot? as if there is a chance nothing would spawn in the box.
    "", For example?

    I figured I could further randomise the loot by making the compo spawn in and have only a 40% chance that the boxes would be there. That way every time I restart the server the boxes would be organised as if in different buildings and as many of the buildings are the same, I could copy and paste the compo to save time. So the next set will be working out how to save the designated equipment boxes between server restarts. I found a code for player inventory between logings (not tried it yet.)
    I have timed respawning enemies now too for the enemy bases, timed to about twenty five mins to allow for looting but not so fast they will respawn while the players are still there.


  6. When a player is 500m away, the box is empty/not there. when they are within 500m loot spawns in a box/the box spawns in. Each time it respawns there is a different loot list in said box.
    I know how to make a loot list, and that I can use addItemCargo to achive at least part of this, though I am not sure how yet. I am still learning and need all the help I can get, but a point in the right direction would be enough.
    I also wanna save the players inventory on logout using saveNameSpace but have not figured out what you actually do with it yet.


  7. So I pulled this script and am building a little persistant map for me and some friends to play on and have got stuck with the loot spawning. (Its a warhammer 40k mod pack in case that makes a difference.)
    Here is what I got so far...
    gun = ["arifle_MX_F", "arifle_MX_GL_F", "arifle_MXC_F", "arifle_TRG20_F", "arifle_TRG21_F", "arifle_TRG21_GL_F", "arifle_MXM_F", "srifle_EBR_F", "LMG_Mk200_F", "hgun_P07_F", "arifle_Khaybar_F", "arifle_Khaybar_C_F", "arifle_Khaybar_GL_F", "hgun_rook40_F"] call BIS_fnc_selectRandom;  
    Waffe1 = "groundweaponholder" createVehicle getpos this;
    Waffe1 addWeaponCargo [gun,1];
    Waffe1 setPos [getPos this select 0,getPos this select 1,0.00];

    (I know none of those are from a 40k mod pack but it is the code I used to test and it works)
    I put that into something like an invisible helipad and I spawn a random weapon from the list.

    My problem begins when I try to get the script to repeat after say an hour. I have tried, unsuccessfully, to pack it in an execVM only to have it slap me with errors.
    What I really want is loot boxes that spawn and despawn when the player is 500m away every 60 minutes. But baby steps as I am new to scripting.
    Can anyone help?

×