Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > Star Wolves

Star Wolves 3D space RPG with deep strategy and tactical elements

Reply
 
Thread Tools Display Modes
  #1  
Old 04-26-2010, 05:28 PM
Nanaki Nanaki is offline
Approved Member
 
Join Date: Mar 2010
Posts: 338
Default

Update:
The mod is mostly finished. I modified most of the location files and added fleets, convoys, and flights to many of them. Many of these random contacts also have additional waypoints, which means they will loiter in a system longer and visit more places. Certain randomcontacts in certain systems had broken waypoints, so that was fixed as well.

So far, in most systems, flights have a 50% chance to spawn every time it runs the script (varies by system, usually 60 seconds), Fleets and Convoys both have a 10% chance to spawn. Pirates in the Triada systems have a mostly 25% chance of spawning a flight, and a 5% chance of spawning a fleet/convoy, so caution is recommended when travelling in Triada systems.

My Convoy script was gutted and redone to be exactly like the Fleets, except that they have 2-3 escort flights as opposed to 1-4 escort flights. Convoy flights are easier to poach, but the added fleets make gate camping risky and forward reconnassiance a must, since you have no idea weither a convoy is going to come out of a gate, or a very angry fleet consisting of a capital ship and four flights of fighters.

Overall, the only thing that is left is making changes to capital ship loadouts (such as equipping GKGuns to Pirate motherships) and testing the mod.

Update2: It seems like something broke... escorts are not spawning anymore.
Attached Files
File Type: zip FleetModbeta.zip (37.0 KB, 76 views)

Last edited by Nanaki; 04-28-2010 at 08:32 PM.
Reply With Quote
  #2  
Old 05-13-2010, 02:12 PM
Trucidation
Guest
 
Posts: n/a
Default

I agree, space is entirely too damn quiet for a war to be going on - this mod sounds freaking awesome but is it still giving you trouble? I noticed that the convoy mod you posted a couple posts back is larger than the fleetmodbeta attachment.

Last edited by Trucidation; 05-13-2010 at 02:15 PM.
Reply With Quote
  #3  
Old 05-13-2010, 03:48 PM
Nanaki Nanaki is offline
Approved Member
 
Join Date: Mar 2010
Posts: 338
Default

Quote:
Originally Posted by Trucidation View Post
I agree, space is entirely too damn quiet for a war to be going on - this mod sounds freaking awesome but is it still giving you trouble? I noticed that the convoy mod you posted a couple posts back is larger than the fleetmodbeta attachment.
The fleetmodbeta attachment was meant for other people to look at to see if they can fix the issue, unfortunately im just not good enough with Lua to fix it myself. It only comes with the barebones script and does not completely work on its own (it is missing the randomcontact entries for the convoys and fleets). I did complete the work on the location files, but I figure theres no point in distributing a full version of the mod until I (or someone else) figures out how to fix this very serious bug that the mod has.

The issue lies with the GetRandomPortalIndexes function, listed below:
Quote:
function GetRandomPortalIndexes(portalList)
local portalCount = getn(portalList);

if portalCount == 1
then
return {1, 1};
end;

local randomIndex = RAND(portalCount) + 1;
local newPortalIndex = randomIndex;

while (newPortalIndex == randomIndex)
do
randomIndex = RAND(portalCount) + 1; -- RAND is ZERO based
end;
return {randomIndex, newPortalIndex};
end;
The script works fine as long as portalCount does not equal 1. However, if Portalcount equals one, the despawn script for the flight's escorts prematurely triggers, which results in a capital ship's escorts despawning literally milliseconds after they spawn. Thus while this script works perfectly in certain systems (especially with multiple jumpgates), all capital ship spawns that are limited to only one jumpgate will spawn with no escorts whatsoever.

Here is the despawn trigger below:

Quote:
local escort1 = getglobal("flight_randomformation_"..__formation_n umber.."_escort1");
if escort1 ~= null then
local escort1 = getglobal("flight_randomformation_"..__formation_n umber.."_escort1");
local trigger_deleteescort = CreateTrigger();
trigger_deleteescort:AttachEvent(_EVENT_FLIGHTINSI DEOBJECTVOLUME);
trigger_deleteescort:SetObjects(escort1, currentContact[3][portalEndIndex], 120);

trigger_deleteescort:AttachCondition(trigger_delet eescort_Condition);
trigger_deleteescort:AttachAction(trigger_deletees cort_Action);
trigger_deleteescort:Activate();
end;
Quote:
function trigger_deleteescort_Condition()
local myTriggerContext = GetTriggerContext();
local portal = myTriggerContext:GetDestinationObject();
local flight = myTriggerContext:GetFlight();
local pos = flight:GetPosition();

portal:Start(5, 0);
return TRUE;
end;

function trigger_deleteescort_Action()
--SLOG("Action done....");
local myTriggerContext = GetTriggerContext();
local flight = myTriggerContext:GetFlight();
flightelete();
end;
It annoys me because I know what the problem is, but I have not the foggiest idea how to fix it.

Last edited by Nanaki; 05-13-2010 at 08:49 PM.
Reply With Quote
  #4  
Old 05-18-2010, 07:13 AM
skrzacik skrzacik is offline
Approved Member
 
Join Date: Apr 2010
Posts: 31
Default

Nanaki
i need this mod !!!!
do anything what u cn becouse is a little to quiet in space
good luck with modding
Reply With Quote
  #5  
Old 05-18-2010, 10:24 AM
Trucidation
Guest
 
Posts: n/a
Default

Nanaki, if I understand correctly, GetRandomPortalIndexes is to set a destination portal for a convoy/fleet? So in a system with only 1 portal, the destination portal = start portal, right?

I think the problem is when the fleet spawns it also runs through the "are we at the destination portal yet?" check, so it despawns immediately. We need a way of telling the fleet to NOT check for destination until it's reached at least 1 waypoint.
Reply With Quote
  #6  
Old 05-18-2010, 06:38 PM
Nanaki Nanaki is offline
Approved Member
 
Join Date: Mar 2010
Posts: 338
Default

The problem is that Triggers are the only way to have code remain with ships persistently... SW triggers are really limited in what they can do. The only decent solution I have come up with so far involves attaching a timer trigger to the despawn trigger, where it will only activate after 60-120 seconds. Now, if the spawned fleet hangs around the gate for longer than that for whatever reason (fighting, traffic, etc) then it will still bug out, but considering that is mostly rare for the most part, it will definatly reduce the issue to a minimum. Wont eliminate it entirely though, im afraid.
Reply With Quote
  #7  
Old 05-19-2010, 01:43 AM
Trucidation
Guest
 
Posts: n/a
Default

So no flags to check whether they've moved at least 1 waypoint before triggering the despawn?

Oh well, a timer is fine too. The only issue I see is if the spawn is hostile; when the player portals in and fights them, they'll despawn in mid-battle when the timer is finished, right?
Reply With Quote
  #8  
Old 05-19-2010, 02:31 AM
Nanaki Nanaki is offline
Approved Member
 
Join Date: Mar 2010
Posts: 338
Default

Quote:
Originally Posted by Trucidation View Post
So no flags to check whether they've moved at least 1 waypoint before triggering the despawn?
Nope. Triggers are rather limited on what they can and cannot do.

Quote:
Oh well, a timer is fine too. The only issue I see is if the spawn is hostile; when the player portals in and fights them, they'll despawn in mid-battle when the timer is finished, right?
That is correct. As I said, its not a perfect solution, but its the best one that I can do given the limited knowlege and tools at my disposal.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:28 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.