Homeworld Remastered Infection Beam Script


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #1

After a long while, I have FINALLY been able to get a start on a WORKING infection beam script for Homeworld Remastered. As of right now, it needs work. However, when the script is complete, I will post it here.


(Herbyguitar) #2

You should get with @Nathanius (Star Trek Continuum) His assimilation project is related to your infection project.


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #4

Ok, but the script is almost done. I just need to get the bugs out of it so it will work.


(Nathanius) #5

Maybe you’ve come up with a better way than I have! I’m excited to see your work :slight_smile:


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #6

Thanks. I’m basing it off of a bug that I found in my cruise missile script while it was in its early stages.
The bug allowed it to capture any ship that was visible from any range. If I can set a limit on how far the “Infector” needs to be, it will work.


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #7

I also need to find a way of where only one beam will be fired and only targeting one ship.


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #8

May I see your script to use as an example??? I can’t get the ship to change teams.


(Nathanius) #9

Shoot me a PM and I’ll go through it with you in depth :slight_smile:


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #10

THE INFECTION BEAM SCRIPT IS FINALLY COMPLETE AND FULLY OPERATIONAL! I DID IT GUYS!

Now I need to add more infect-able ships to the infection list


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #11

The Virus Is Spreading…


(Caal-Shto) #12

I have seen this video and the Beast Infection works perfectly. I just love the way that it subverted the Taiidan carrier into itself. :smile:


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #13

Thanks. @Nathanius pointed me in the right direction. Now I am using my time to fix the beast carrier and beast heavy cruiser so they can infect ships as well.


(Taiidan Republic Mod) #14

Nice! Well done for your perseverence on this one.

To stop the ship “flipping” round when it gets converted, you can track the coordinate system of the old sobgroup and apply it to the new one.


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #15

Any clue on how to track it?


(Taiidan Republic Mod) #16

Use SobGroup_GetCoordSys(<SobGroup>) to get the coordinate system (rotation) of a ship.

Use SobGroup_SetTransform(<SobGroup>) to set the coordinate system (rotation) of a ship.


(Hero Crafter 1987 (Homeworld Universal Conquest Mod)) #17

@dom2 How could this be used to spawn an infected ship in the position and rotation of the non infected one?


(Taiidan Republic Mod) #18

Sorry I’ve had a busy couple of days. I’ll respond as soon as I can - I’ll need to extract a bit of code from my platform script that will be useful for you.


(ajlsunrise) #19

for reference: [SOLVED][SCRIPTING] Matrix3_GetVector3FromCol


(Taiidan Republic Mod) #20

You don’t even need that probably. You can just store the variables and plug them into the functions to reposition the new ship, e.g.

temppos = SobGroup_GetPosition(OldGroup)
tempcoords = SobGroup_GetCoordSys(OldGroup)

SobGroup_SetPosition(NewGroup, temppos)
SobGroup_SetTransform(NewGroup, tempcoords)

Where OldGroup is the sobgroup of the ship you are capturing, NewGroup is the sobgroup of the ship you are spawning to replace it.


(ajlsunrise) #21

Well, I was posting from my phone, since my computer took a crap, and its hard to type out code on my phone. :smile: