6648905c87679

6648905c87c2e
1 Guest is here.
 

Topic: SS2 Big Droid Immortality Protocol
Page: « 1 [2]
Read 11486 times  

6648905c8832fZylonBane

6648905c883ab
I can't imagine that not looking very silly.

6648905c887daunn_atropos

6648905c8882f
Looks cool.  :)
Can the droid fire it? Can you exchange them when they are broken? Different ammunition types?  :lordy:

6648905c888d5voodoo47

6648905c88924
they are dummy guns, just to see how they would look attached to the droid. also, looks like I had some youtube vid playing in the background when recording.

6648905c88a4aGuyFawkesGaming

6648905c88a98
So I take the dark scripting engine restricts the modifiable "tag" to weapon objects only. I see now why the repairman mod lists broken turrets as containers.
Anyways, not too bad voodoo. I was expecting much worse. Regardless, what if instead of guns attached to it's hands it had a discrete "access panel" dummy gun on it's back?

6648905c88bb1voodoo47

6648905c88c09
it's just the original script, which only handles weapons - so to be able to modify other objects, you would have to write a custom squirrel script that would do whatever you want to do with the droid or any other target object. not sure what do you mean by those broken turrets - they are containers (with loot), so they should be registered as such.

anyway, no extended functionality from my side anytime soon, as it will be years before I'll be able to do anything more complex in squirrel - I have no coding background, so trying to learn these things takes immense amount of time and effort.
« Last Edit: 08. May 2018, 19:11:44 by voodoo47 »

6648905c88cf8GuyFawkesGaming

6648905c88d49
Ok, so it is modifiable, just complex. I'm no expert programmer, but I was wondering why you didn't just make npcs modifiable/hackable, then 'tag' turrets and droids so only they can be modified, and hacked ones at that. Never touched squirrel, I'm more into Python and HTML, but if it's more complex then it sounds I understand.

For the turrets, I was actually referring to the window that pops up when you select the upper half to repair it; the side says "container" rather than "security".

6648905c88e18voodoo47

6648905c88e78
I have no idea whether it's more difficult - as I don't know any coding language, I don't have anything I could compare it to.

I actually have no idea why the rim on the repair interface says "container", will investigate a bit. //not fixable by simple means.
« Last Edit: 03. July 2021, 07:38:01 by voodoo47 »

6648905c8905dGuyFawkesGaming

6648905c890b9
I've managed to hack the repairman mod's 'turretheal.nut' script to allow droids to be repaired. It was pretty simple actually; their was a short "list" with only 2 entries; allow turrets to be repaired and allow guns. Adding the proper entries for the droids allowed them to be repairable:
Code: [Select]
                // maintenance droids
else if (Object.InheritsFrom(fixObj, "Maintenance")) {
hp = Property.Get(fixObj, "HitPoints");
maxHP = Property.Get(fixObj, "MAX_HP");
if (playerMaintSkill < objSkillRequired) {
addMiscText("WrenchierSkillReq", "Maintaining this device requires a skill of %d.", objSkillRequired);
}
else if (hp >= maxHP) {
addMiscText("WrenchierUnused", "Device already in good condition.");
}
else {
// repair droid 5 HP per point of maint skill (default droids have a max HP of 100)
hp += playerMaintSkill * 5;
if (hp > maxHP) {
hp = maxHP;
}
Property.SetSimple(fixObj, "HitPoints", hp);
consumeTool();
}
}
// security droids
else if (Object.InheritsFrom(fixObj, "Security")) {
hp = Property.Get(fixObj, "HitPoints");
maxHP = Property.Get(fixObj, "MAX_HP");
if (playerMaintSkill < objSkillRequired) {
addMiscText("WrenchierSkillReq", "Maintaining this device requires a skill of %d.", objSkillRequired);
}
else if (hp >= maxHP) {
addMiscText("WrenchierUnused", "Device already in good condition.");
}
else {
// repair droid 5 HP per point of maint skill (default droids have a max HP of 160)
hp += playerMaintSkill * 5;
if (hp > maxHP) {
hp = maxHP;
}
Property.SetSimple(fixObj, "HitPoints", hp);
consumeTool();
}
}
// assault droids
else if (Object.InheritsFrom(fixObj, "Assault")) {
hp = Property.Get(fixObj, "HitPoints");
maxHP = Property.Get(fixObj, "MAX_HP");
if (playerMaintSkill < objSkillRequired) {
addMiscText("WrenchierSkillReq", "Maintaining this device requires a skill of %d.", objSkillRequired);
}
else if (hp >= maxHP) {
addMiscText("WrenchierUnused", "Device already in good condition.");
}
else {
// repair droid 5 HP per point of maint skill (default droids have a max HP of 200)
hp += playerMaintSkill * 5;
if (hp > maxHP) {
hp = maxHP;
}
Property.SetSimple(fixObj, "HitPoints", hp);
consumeTool();
}
}
Don't know if it has any negative side effects or if I made any mistakes so you may want to check it.

6648905c8915dZylonBane

6648905c891ab
All that duplicated code because you don't know how to do OR in an if statement. Sigh.

6648905c89242GuyFawkesGaming

6648905c89293
Hey, I said I've done programming before. Never said I was a pro.
Acknowledged by: JML
6648905c8965d
All that duplicated code because you don't know how to do OR in an if statement. Sigh.
What about quickly simplifying the code so people in this forum can actually learn something by it? Having a code that works and having a simplified code that also works is super easy to learn from. :thumb:

6648905c898b7ZylonBane

6648905c89909
Hey, I said I've done programming before. Never said I was a pro.
This is like someone trying to make toast, burning their house down, then claiming "I never said I was a pro!" Booleans in conditionals are barely one step up from HELLO WORLD. If you actually have Python experience, you should already know how to do this.

else if (Object.InheritsFrom(fixObj, "Turrets") || Object.InheritsFrom(fixObj, "Maintenance") || Object.InheritsFrom(fixObj, "Security") || Object.InheritsFrom(fixObj, "Assault")) {

There. Just modify one line of code from the original script.

6648905c899c3GuyFawkesGaming

6648905c89a10
Considering the game didn't crash from my method, I'd say it's more like someone trying to cook an egg but not knowing what a spatula is and using their hands instead (imagine the screaming).  :P
Acknowledged by: JML

6648905c89c6fGuyFawkesGaming

6648905c89cbc
After observing the hacked droids more, I've noticed one extremely annoying issue. There are times when a droid is being attacked but it will just sit there frozen and not attack it's enemy until it's finally destroyed. Not sure what causes this and it doesn't always happen, but wow. I'd also suggest making the droids able to see in the dark. It makes no scene that turrets can activate and attack you in dark places but droids can't, in addition to all the "infrared" messages in the security monitors. I still think making them modifiable would be a good idea but I can wait on that.

6648905c89d6cvoodoo47

6648905c89dbb
it  certainly would be possible to make all AIs ignore how much light is on other AIs. will maybe have a look once I have more time.

6648905c89e71voodoo47

6648905c89f07
updated to 1.01, the mod is now no longer SCP exclusive. requires a game patched with SS2tool (NewDark v2.48+, NVscript loaded), should work with SCP, vanilla, Secmod, Alyamod etc.
Acknowledged by: JML

6648905c8a03fDeu sex

6648905c8a08c
Yo, I've been digging this mod and it's really cool! However I may have one complain, could it be possible that the robots you repaired follow you a bit? They are kind of static otherwise.
Another minor thing, but while not everything requires the same skill level, everything costs 50 nanites to repair, could it be slightly less expensive for low tier, this for mid tier, and slightly more expensive for high tier? (something along those lines).

6648905c8a130voodoo47

6648905c8a1b0
I decided against follow as I think it would be too good (right now, they should just patrol their area). prices can be changed easily by literally anyone who can edit the dml with a text editor.

6648905c8a2ccDeu sex

6648905c8a31c
I'll do that then, as for following I can totally understand the argument of robots being too good (even if their movements would be limited since they can't travel between loadings and can't use gravlifts), though I wish a middleground could exist.
I'll try to mod it out from the files though, just to see if it would be interesting.

-> damn I looked at the files, but reading them I can get a vague idea what is going on in there but I have 0 clue on how to script on SS2 :D I was expecting something like "FollowPlayer=FALSE" in the entity's parameters lol.
The cost values can be modified easily indeed though.
« Last Edit: 21. January 2021, 19:31:49 by Deu sex »

Your name:
This box must be left blank:

How can you ____ a perfect, immortal machine? (Fill in the missing word):
1 Guest is here.
And good luck, good luck, good luck, good luck, good luck. I heard you needed some.
Contact SMF 2.0.19 | SMF © 2016, Simple Machines | Terms and Policies
FEEP
6648905c8a442