Jump to content

Photo

R&D to Increase Squad Size


  • Please log in to reply
428 replies to this topic

#81
johnnylump

johnnylump

    Resident poster

  • Supporter
  • PipPipPipPipPip
  • 7,425 posts

I'm all for the scrolling dropship UI if it's possible. Although he hasn't been on here in a while, you might message twinj to see if he would share exactly what he accomplished a few months ago.

 

And while you're in there, a nice small enhancement in the loadout text would be to replace the word "backpack" with space for a soldier's third small item. (Might take an adjustment on the upk side, as well, to get the string across.)



#82
Bertilsson

Bertilsson

    Old hand

  • Members
  • PipPipPip
  • 616 posts

Edit: Warning the below mod resulted in soldiers spawning under ground on rare occasions.

Use the update code which moves soldier 7-12 a full tile instead, found here: http://forums.nexusm...size/?p=8633351

 

1. Throw out a little multiplayer code.

2. Replace kSpawn = arrSpawnPoints[I]; with kSpawn = arrSpawnPoints[I % 6];

3. Replace kSoldier = SpawnUnit(class'XGUnit', m_kPlayerController, kSpawn.Location, kSpawn.Rotation, kChar, m_kSquad,, kSpawn); with this:

    if(I > 5)
    {
      kSoldier = SpawnUnit(class'XGUnit', m_kPlayerController, kSpawn.Location + vect(-24.0, -24.0, 0.0), kSpawn.Rotation, kChar, m_kSquad,, kSpawn);
    }
    else
    {
      kSoldier = SpawnUnit(class'XGUnit', m_kPlayerController, kSpawn.Location + vect(24.0, 24.0, 0.0), kSpawn.Rotation, kChar, m_kSquad,, kSpawn);
    }

And now up to 12 soldiers share spawn locations without standing on each other :smile:

 

If they are spawned next to a wall like in the rooftop construction mission, they will be a little inside the wall (screenshot 3) but they are still mostly inside the spawn tile and there is no risk of them getting stuck.

 

<Broken code removed use this code instead: http://forums.nexusm...size/?p=8633351 >

 

In case anyone wants to improve the function to support additional soldiers or move soldiers in directions relative to rotation and put them back to back or something like that, then there is certainly enough room for it as 107 0B tokens are still unused at the end of the function :smile:

[/spoiler]

Attached Files


Edited by Bertilsson, 01 August 2013 - 07:15 PM.


#83
johnnylump

johnnylump

    Resident poster

  • Supporter
  • PipPipPipPipPip
  • 7,425 posts

Eureka! Well done, sir. That's a breakthrough and half the battle, right there. With your permission, will incorporate into Long War 2.0 and provide full credit in the readme.



#84
Bertilsson

Bertilsson

    Old hand

  • Members
  • PipPipPip
  • 616 posts

Yes, you should most definitively add it to long war :smile:

 

But make sure to use the updated code (that I just edited in the previous post).

 

The only difference in the updated code is that I moved all left over 0B tokens to after the 53 instead of before it so that they do not add 300+ extra lines to the token view.


Edited by Bertilsson, 28 July 2013 - 05:14 PM.


#85
Amineri

Amineri

    Resident poster

  • Premium Member
  • 3,927 posts

That does looks pretty awesome. Kind of messes with your head after being so used to thinking in terms of tiles, but if it works it works!



#86
Bertilsson

Bertilsson

    Old hand

  • Members
  • PipPipPip
  • 616 posts

I realized the possibility when I noticed that soldiers are not centered in the spawn tiles in the Slingshot subway mission.



#87
Bertilsson

Bertilsson

    Old hand

  • Members
  • PipPipPip
  • 616 posts

A little status update on this topic.

I've done some experimenting in ChooseSquadForNewMission() and OrderedHigher().

 

The result is that I'm 99% sure I will have a working mod very soon (like tomorrow) which allows selecting which soldiers will be picked for next mission by adding * in front of last name and nothing else (like being on last mission, which they will be anyways since they will still be named *LastName after the mission).

This together with changed sorting algorithm to put those soldiers on top will make it easy to keep track on who is going or not.

 

However SHIV's cannot be renamed so I've been brainstorming a few alternatives using amineris superconductive brain and I think that SHIVs should be possible to add more or less intuitively as well, one way or another.


Edited by Bertilsson, 29 July 2013 - 11:43 PM.


#88
Bertilsson

Bertilsson

    Old hand

  • Members
  • PipPipPip
  • 616 posts

The good news

  • SHIVs have first And last Names like any soldiers but only gets Last name assigned when built.
  • Unlocking customize-button for SHIVs allow changing both first and last name, all other options are locked.

 

The bad news

  • Getting really weird results when unlocking the customize-button for SHIV's
    • Need to investigate more (the problem is getting the button unlocked, once unlocked there is no problem)

The really bad news

  • Seems to be back on square one regarding soldiers placement
    • 2 out of 12 soldiers literally falls thru the cracks between tiles during spawn, getting stuck below ground, on 5-10% of missions
    • Will do some testing to see if it is always same spawn locations having the issue and if it makes any difference putting the soldiers a tiny bit closer to center of tiles, but not very optimistic.

Edited by Bertilsson, 30 July 2013 - 09:06 PM.


#89
johnnylump

johnnylump

    Resident poster

  • Supporter
  • PipPipPipPipPip
  • 7,425 posts

Y'know on certain maps the soldiers always start a little higher than the map surface. Maybe give them all 1 increment of "Z" and see if it still happens?



#90
Amineri

Amineri

    Resident poster

  • Premium Member
  • 3,927 posts

That's how the alien spawns are set ... it adds a bit to the z value and then calls a function to check for the ground height at that (x,y) position.. I recall it adds 128.0 to units indoors and 560.0 to units outdoors. Probably something more like 8.0 or 16.0 should be safe for soldiers and should prevent them from floating too high in the air to start.






IPB skins by Skinbox
Page loaded in: 1.067 seconds