etrex2k4

Server FPS ++ Remove Trigger and use this Script until 0.9.36

14 posts in this topic

/*
    Autor: Flo i.A. www.ruhrpott-life.de    
*/
in_safe_1 = false;
in_safe_2 = false;
in_safe_3 = false;
waitUntil {time > 0};
[] spawn
{
    while {true} do
    {
        uiSleep 5;
        if (player distance2d [14599.8,16794.6,0] > 175)  then
        {    
            if (!in_safe_2 && !in_safe_3) then
            {
                in_safe_1 = false;
                [] call ExileClient_object_player_event_onLeaveSafezone;
            };
        }else
        {
            in_safe_1 = true;
            [] call ExileClient_object_player_event_onEnterSafezone;        
        };
    };
};
[] spawn
{
    while {true} do
    {
        uiSleep 5;
        if (player distance2d [23335.4,24189,0] > 175)  then
        {
            if (!in_safe_1 && !in_safe_3) then
            {
                in_safe_2 = false;
                [] call ExileClient_object_player_event_onLeaveSafezone;
            };
        }else
        {            
            in_safe_2 = true;
            [] call ExileClient_object_player_event_onEnterSafezone;        
        };
    };
};
[] spawn
{
    while {true} do
    {
        uiSleep 5;
        if (player distance2d [2999,18173.2,0] > 175)  then
        {
            if (!in_safe_1 && !in_safe_2) then
            {
                in_safe_3 = false;
                [] call ExileClient_object_player_event_onLeaveSafezone;
            };
        }else
        {
            in_safe_3 = true;
            [] call ExileClient_object_player_event_onEnterSafezone;        
        };
    };
};

--> open your mission.sqm in Arma 3 Editor

--> delete all trigger

--> safe mission and replace it

--> then put this script in a file  "fps.sqf" 

--> put it in the same dir with your mission.sqm

--> open initplayerlocal.sqf

--> [] execVM "fps.sqf";

 

 

Edited by etrex2k4

Share this post


Link to post
Share on other sites
Advertisement

In Exile, the SafeZone is activated by a trigger. This is the trigger in the mission.sqm, this is triggered on the server, not just the client.
So you should remove the trigger in the mission.sqm.
I just built only a mini script what the Safe Zones enabled via a script. Only Client Side

Edited by etrex2k4

Share this post


Link to post
Share on other sites

The trigger is what defines the blue circle for the safezone. For example:

 class Sensors
 {
  items = 3;
  class Item0
  {
       position[]={6330.98, 0, 7800.99}; //Stary
       a = 175;
       b = 175;
       rectangular = 1;
       activationBy = "ANY";
       repeating = 1;
       interruptable = 1;
       age = "UNKNOWN";
       name = "ExileTrader";
       expCond = "(vehicle player) in thisList";
       expActiv = "call ExileClient_object_player_event_onEnterSafezone";
       expDesactiv = "call ExileClient_object_player_event_onLeaveSafezone";
       class Effects{};
  };

 

Removing this will indeed mess with mission systems that detect safezones because they search for the trigger or sensor named "ExileTrader". Moreover, this script that you posted spawns 4(?) threads, why? You don't need it to do that, if you're working on getting a performance increase and FPS increase I suggest you may want to rework it slightly.
 

I would like to see a detailed report on the differences in using triggers VS constantly checking the distance like this. I'm not sure the difference is that large tbh. Altough, kudos for doing a work around if it works :D

  • Like 2

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

  • Recently Browsing   0 members

    No registered users viewing this page.