UUUHHHH!!! HHHHMMMMMM!!!! I don't have a comms file or folder or anything like that except a .pas for comms. It will be very difficult without this file to make any comms.
That is correct. Using special comms is a more advanced stage of editing. You need to use WCPPas to decode various WCP files and such. I don't know why your ship disappears. Either you've bound it to the wrong actionsphere, or you simply forgot to activate it. I also have no idea why m_Spawn doesn't work at Nav 2. One guess would be, you've altered the functions used by the spawned ships, assigning them to the wrong actionsphere. For ships to show up at this navpoint, they must be either actionsphere 0 or (presumably) 2. Alternatively, it might be simply because the Nav 2 function is utterly fucked up. Here is a list of problems with your Nav 2: - You're using 'setup' incorrectly. In fact, you're not using it at all. Either get rid of that setup := false line, or do something with setup. - 'If (NAV_Withinsphere...)' only checks if the player has entered the actionsphere. It doesn't check if he's still in it. The player could visit this navpoint and leave, and the navpoint wouldn't even notice that he's gone. - That second 'while (1)' loop will prevent the navpoint from ever being activated again. The thing about while (1) loops is that there's no way out of them. - 'until (NAV_Withinsphere...)', is even worse here. Why is it there? You keep the function waiting until the player enters the navpoint's actionsphere, and then the very next thing you do is deactivate that actionsphere? - Furthermore, the 'until (NAV_Withinsphere...)' loop doesn't have anything in it. This will crash the mission complaining about an infinite loop. Try this code, don't just copy and paste it into your mission. Look at it, compare it to your Nav 2 code, and try to figure out why I made each change. Code: function M_Nav2; var setup = true; begin while(1) do begin if (NAV_WithinSphere(Alpha1)) then begin Nav_ActivateSelf; if (setup) then begin M_Spawn(2,17,23000,23000,233); M_Spawn(30,10,23222,23222,233); setup := false; end; NAV_SetPlayerNav(1); while(NAV_WithinSphere(Alpha1)) do begin AI_WaitSeconds(1); end; NAV_DeactivateSelf; end; AI_WaitSeconds(1); end; end;
Using that Nav2 function it didn't work except the bugs did spawn. As I said before I got the navs to work but with the improper code -although I can't revisit navs . Well, I can go to nav2 kill bugs and just return to nav1 which is what needs to happen in this mission anyway-no need to go back to nav2 because mission is accomplished. Or at least it will be when I get the objectives to work. Hold on a second it is now doing multiple nav movement again-wierd! No idea with those bind to spheres for the cap. We will deal with this issue later-just keep the binds out for the time being. Time for objectives-I'll report the problems as they come.
I have no idea what how to make the objective go complete when all enemies are dead. I have tried everthing you said and what is in the lib. Maybe something else is the problem. objective mobj_Defend hidden: false; type: MOBJ_Primary; text: 1; status: MOBJ_Incomplete; counter: false; end; function M_Nav1; var setup = true; begin while(1) do begin if (NAV_WithinSphere(Alpha1)) then begin Nav_ActivateSelf; if (setup) then begin SF_ActivateObject(Midway, 0); SF_ActivateObject(Destoryer, 1); SF_ActivateObject(Cruiser, 0); AI_WaitSeconds(30); M_FSpawnLaunchFrom(17, 3, Midway); M_FWSpawnLaunchFrom(20, 3, Midway); AI_WaitSeconds(5); M_SpawnNearObject(2, 15, Destoryer); M_SpawnNearObject(30, 8, Cruiser); M_SpawnNearObject(11, 6, Cruiser); if(M_WaitUntilDead) then begin SF_ObjectiveSetComplete(mobj_defend); SF_SetMissionSuccess; setup := false; end; end; while(1) do begin NAV_SetPlayerNav(2); while(NAV_WithinSphere(Alpha1)) do begin end; NAV_DeactivateSelf; end; end; end; end;
So what exactly didn't work? That's pretty much irrelevant. Remember, you're designing missions for other people, not for yourself. That means your mission must be able to handle that one crazy player who decides to revisit all the navpoints after completing the mission. As for objectives, are you still doing this as a sim mission? If yes, then you can't get objectives to work. The objectives screen is disabled in the sim, just like the nav map.
Well I know you don't see them-even in sim missions you have success and failure objectives and I also want to add in a landing too. Even though this will only be a sim-it is also a stepping stone to learn how to do most of the important mission aspects of a mission: launch, land, objectives, multiple navs, and everything else that is in most every single mission for the main game. As far as these objectives go, though, only the destruction of the 2 capships, protection of the Midway and destorying an enemy strike force that is inbond is needed. Well, you can never auto back to the other navs in any of the games, and plus they can't even see the nav coordinates. Well, the player would still have to use a nav map to select the other coordinates anyway-and I am sure it would work with using a nav map to select it.
Actually, you don't. The mission might end after the player performed a particular action, and you can even have a trigger for the "mission complete" message, but there won't be any objectives as such. If you're not getting the "mission complete" message right now, or if you're getting them too early, it's because you've put 'M_WaitUntilDead' into the code again. We've told you before, M_WaitUntilDead doesn't return a variable, so it just won't work in an 'if' statement. M_WaitUntilDead is a function which basically makes its caller wait until all spawned enemies are dead. It doesn't work that way. Sim missions can be used to get a hang of the basics, but that's all. You can't use sim missions to learn about things that are disabled in sim missions. Also, at this stage, I wouldn't advise you to move onto real missions. First you need to really understand what you've been doing so far - and that means being able to find and fix just about any bug in your code. You can't go back automatically, that's right. And yes, you can't select a navpoint in the sim, so unless somebody was really good at navigating by the stars, they couldn't revisit a navpoint. But that's not the point, unless you intend to stick with sim missions permanently. And no, this navpoint wouldn't have worked had you used the nav map to select it.
*Computer: Mission Accomplished. Maniac: Oh yeah! Mission Accomplished!* Bad code, yet I am one my way. I now understand the workings of vars. Objectives should soon follow. a few errors-that are extremely confusing. The ships now act like they don't even have a bind to sphere yet it is there plain as day. function M_Midway; begin SF_SetObjectFlag (OF_alignment,ALIGN_Confed); SF_BindToActionSphere(1); while(1) do begin AI_WaitSeconds(1); end; end; function M_Nav1; var setup = true; begin while(1) do begin if (NAV_WithinSphere(Alpha1)) then begin Nav_ActivateSelf; if (setup) then begin SF_ActivateObject(Midway, 0); SF_ActivateObject(Destoryer, 1); SF_ActivateObject(Cruiser, 0); AI_WaitSeconds(30); AI_WaitSeconds(5); setup := false; end; while(1) do begin NAV_SetPlayerNav(2); if(return) then begin SF_SetMissionSuccess; AI_WaitSeconds(5); SF_Exit; while(NAV_WithinSphere(Alpha1)) do begin end; NAV_DeactivateSelf; end; end; end; end; end;
Well, then obviously bind to actionsphere is not the problem. What are the symptoms? Do the ships always show up, or do they not show up after you return to nav 1?
Well, what is wierd is that before they disappeared when I left nav1, but now they don't go away at all. They are seen in nav1 and nav2 always.
Well, I did tell you that your nav functions are screwed up . The problem lies (among other things) in the way you placed the NAV_DeactivateSelf line. But here's something to cheer you up - had you placed the NAV_DeactivateSelf line correctly, you wouldn't find the navpoint at all after returning to it. There's really no problems here that we haven't pointed out to you before. I've even rewritten Nav 2 for you, so you would have an example to work from. So, this time I'm not going to help you fix this navpoint. These are simple mistakes, and if we keep fixing them for you, we'll actually be slowing down your progress. Look at the code I've posted before, compare it to your Nav 1, and you should be able to find the problems yourself.
Ooohhhh! thank you again O'Lord of Pascal! *chuckles nervously at his error* I think I know what the problem was before. It didn't work right at first this time either, but when I changes nav1's code, it works. Most every problem is now taken care of. And thank you again. Only one unusual problem-that does not make any since and a question. The bind to sphere for the jump point doesn't work. Oh! And can you set certain SF and/or AI traits for spawned units: like bind to sphere or add to wing in this case? P.S. I think I am no pretty ready and should be able to get past most problems as I come to them-nonbasic problems may come up though and some I should be able to handle.
If you're referring to the buoy, sure it does. If all else fails, just use the 'actionsphere:' property in the object declaration. Why wouldn't you be able to? You can't have a spawned ship leading a wing, but it certainly can be added to another wing.
Man I got a very stupid problem. How do you get skates and skate cluster-in the code I mean? I have no idea how to so that and it should be in the game's programming no something that has to be programmed in!
Skate and Ray clusters are somewhat different to ordinary fighters. First up, they're their own object type ('cluster'). Second, they need two additional properties in their object declaration: EVENT_1: <insert name of child object's death function here>; EVENT_0: <insert name of child object's main function here>; (the child object functions are pretty much the same as ordinary object functions, but, IIRC, the child object main function does not require the SF_ActivateSelf command - they're automatically activated by the death of the parent object) Third, they need to be piloted by a specific alien pilot - 117. No other pilot will work for them. Keep in mind, BTW, that 'skate' and 'skateb' are actually the names of the two Barracuda variants. Skates are called 'triraym', 'trirayb' and 'trirayt'. Finally, I'm not sure if they'll work at all in a sim mission (though that shouldn't stop you from trying).
O__O WWHHAA????? Okay, it will take a while to figure out for spawning these pests. Luckly, though, Kilrathi don't have anything like this, so there should be no problem , here. Do you happen to have a list for the basic variable types and keywords of this pascal editor?
Look up wcp.pas in \lib. Also look up Thomas' not-quite-comprehensive but still very useful documentation.
One simple question. Does Pascal require, for refueling, a cutscene sequence when it is done inside the nav function using "AI_ReplenishMissilesAndFuelObj(Alpha1);"?
Man. I have no idea how to implement a refuel. UUUmmm.. here is the code-for some reason he gives me a stupid error message about unknown AI when I play the mission. if (setup2) then begin M_Spawn(2,17,300000,300000,23300); M_Spawn(30,10,302220,302220,23300); M_WaitUntilDead; M_FRSpawn(22, 2, 130000,130000,4550); M_FPSpawn(38, 3, 140000,134450,4550); AI_WaitSeconds(6); AI_ReplenishMissilesAndFuelObj(Alpha1); setup2 := false; end;