#Reverse engeineering Boss code for DS3
97 messages · Page 1 of 1 (latest)
If you never got the displayBanner to show up then either you're editing the wrong EMEVD, or the emevd you're editing is not the one the game is using
...or event 0 doesn't work with displayBanner 🤔
I just put DisplayBanner(4); in and nothing showed up
supposedly ds3 displayBanner does work in event 0 so it's one of the other two
I guess the main question would be getting darkscript to work with the mod
its prolly cus I'm using a older Darkscript 3 because the newer ones refuse to work
it should be working. are editing the unpacked EMEVD that is not in your mod folder, so it never gets used
and you probably did not download asp.net that newer versions of darkscript 3 need
I'll download it after I get hit in bb, can you send me a link here or in dms
@obtuse zinc just in case you missed it
found it
still not working
I got the source code for 3.4 and trying to find the error and the intended page its trying to send me to
As of right now, I am trying to figure out why Darkscript 3.4 isn't working, I've tried downloading 7 different .NET shit, inside of the engine, the fog gate I tried adding doesn't show in game but has collision in game
#modmaking-chat message
Event(13805841, Restart, function() {
EndIfEventFlag(EventEndType.End, ON, TargetEventFlagType.EventFlag, 13800830);
IfCharacterHPRatio(MAIN, 3800830, ComparisonType.LessOrEqual, 0.5, ComparisonType.Equal, 1);
SetEventFlag(13805832, ON);
});
This is the phase transition script?
I wish I knew what this did
Event(13805859, Restart, function() {
InitializeEvent(0, 13805857, 13800830, 3801830, 3802830, 13805835, 3801830, 3800830);
InitializeCommonEvent(20005801, 13800830, 3801830, 3802830, 13805835, 3801830, 13805836);
InitializeCommonEvent(20005820, 13800830, 3801830, 4, 0);
SkipIfEventFlag(2, ON, TargetEventFlagType.EventFlag, 13800831);
InitializeCommonEvent(20001836, 13800830, 13805835, 13805836, 13800831, 3804831, 3804832, 13805832);
SkipUnconditionally(1);
InitializeCommonEvent(20005831, 13800830, 13805835, 13805836, 3802830, 3804831, 3804832, 13805832);
InitializeCommonEvent(20005837, 13800830, 3800830, 1094713344, 5290, 5290, 13805835, 13805836);
InitializeCommonEvent(20005810, 13800830, 3801830, 3802830, 10000);
});
I figured out how to find the meaning of events
InitializeEvent(0, 13800830, 0);????
$Event(20005710, Restart, function(X0_4, X4_4, X8_4, X12_4, X16_4) {
EndIf(PlayerIsNotInOwnWorld());
WaitFor(EventFlag(X0_4) && EventFlag(X4_4));
RequestCharacterAICommand(X8_4, 10, 0);
RequestCharacterAIReplan(X8_4);
WaitFor(InArea(X8_4, X16_4));
RotateCharacter(X8_4, X12_4, 60060, true);
time = ElapsedSeconds(3);
WaitFor(InArea(X8_4, X12_4) || time);
RestartIf(time.Passed);
RequestCharacterAICommand(X8_4, -1, 0);
RequestCharacterAIReplan(X8_4);
SetNetworkUpdateRate(X8_4, true, CharacterUpdateFrequency.AlwaysUpdate);
});
Might be fog gate code
I am attempting some code
InitializeCommonEvent(20005840, 3801831);
also known as
$Event(20005840, Restart, function(X0_4) {
WaitFor(CharacterType(10000, TargetType.Alive) && EntityInRadiusOfEntity(10000, X0_4, 5, 1));
Unknown200459(10000, Disabled);
WaitFixedTimeSeconds(1);
RestartEvent();
});
might be a dud
dud
I'm going to attempt to copy all common events over to my entity
if this doesn't work gonna fuck it, go nuclear
fuck it, we ball
Reverse engeineering Boss code for DS3
I have renamed this thread to my current project, as I am Reverse engineineering the boss code right now to understand what everything means
currently focusing on fog gates
Event(13805840, Restart, function() {
GotoIfEventFlag(Label.LABEL0, OFF, TargetEventFlagType.EventFlag, 13800830);
ChangeCharacterEnableState(3800830, Disabled);
ForceCharacterDeath(3800830, false);
EndUnconditionally(EventEndType.End);
Label0();
SetCharacterAIState(3800830, Disabled);
GotoIfEventFlag(Label.LABEL1, ON, TargetEventFlagType.EventFlag, 13800831);
IfPlayerIsNotInOwnWorldExcludesArena(AND_01, false);
IfEntityInoutsideRadiusOfEntity(AND_01, InsideOutsideState.Inside, 3800830, 10000, 22, 1);
IfDamageType(OR_01, 3800830, 10000, DamageType.Unspecified);
IfConditionGroup(OR_01, PASS, AND_01);
IfConditionGroup(MAIN, PASS, OR_01);
SetNetworkconnectedEventFlag(13800831, ON);
ForceAnimationPlayback(3800830, 1700, false, true, false, 0, 1);
GotoUnconditionally(Label.LABEL2);
Label1();
IfEventFlag(AND_02, ON, TargetEventFlagType.EventFlag, 13805835);
IfInoutsideArea(AND_02, InsideOutsideState.Inside, 10000, 3802830, 1);
IfConditionGroup(MAIN, PASS, AND_02);
SetSpEffect(3800830, 10575);
Label2();
SetCharacterAIState(3800830, Enabled);
DisplayBossHealthBar(Enabled, 3800830, 0, 903050);
SetNetworkUpdateRate(3800830, true, CharacterUpdateFrequency.AlwaysUpdate);
});```
I deleted this from the area script entierly
lets go through what changes
more readable for instances later on
Event(13805840, Restart, function() {
GotoIfEventFlag(Label.LABEL0, OFF, TargetEventFlagType.EventFlag, 13800830);
ChangeCharacterEnableState(3800830, Disabled);
ForceCharacterDeath(3800830, false);
EndUnconditionally(EventEndType.End);
Label0();
SetCharacterAIState(3800830, Disabled);
GotoIfEventFlag(Label.LABEL1, ON, TargetEventFlagType.EventFlag, 13800831);
IfPlayerIsNotInOwnWorldExcludesArena(AND_01, false);
IfEntityInoutsideRadiusOfEntity(AND_01, InsideOutsideState.Inside, 3800830, 10000, 22, 1);
IfDamageType(OR_01, 3800830, 10000, DamageType.Unspecified);
IfConditionGroup(OR_01, PASS, AND_01);
IfConditionGroup(MAIN, PASS, OR_01);
SetNetworkconnectedEventFlag(13800831, ON);
ForceAnimationPlayback(3800830, 1700, false, true, false, 0, 1);
GotoUnconditionally(Label.LABEL2);
Label1();
IfEventFlag(AND_02, ON, TargetEventFlagType.EventFlag, 13805835);
IfInoutsideArea(AND_02, InsideOutsideState.Inside, 10000, 3802830, 1);
IfConditionGroup(MAIN, PASS, AND_02);
SetSpEffect(3800830, 10575);
Label2();
SetCharacterAIState(3800830, Enabled);
DisplayBossHealthBar(Enabled, 3800830, 0, 903050);
SetNetworkUpdateRate(3800830, true, CharacterUpdateFrequency.AlwaysUpdate);
});```
First noticable change is that the boss will always be active, this is because the first line of code is never ran
Event(13805840, Restart, function() {
GotoIfEventFlag(Label.LABEL0, OFF, TargetEventFlagType.EventFlag, 13800830);
ChangeCharacterEnableState(3800830, Disabled);
ForceCharacterDeath(3800830, false);
EndUnconditionally(EventEndType.End);
Label0();
SetCharacterAIState(3800830, Disabled);
GotoIfEventFlag(Label.LABEL1, ON, TargetEventFlagType.EventFlag, 13800831);
IfPlayerIsNotInOwnWorldExcludesArena(AND_01, false);
IfEntityInoutsideRadiusOfEntity(AND_01, InsideOutsideState.Inside, 3800830, 10000, 22, 1);
IfDamageType(OR_01, 3800830, 10000, DamageType.Unspecified);
IfConditionGroup(OR_01, PASS, AND_01);
IfConditionGroup(MAIN, PASS, OR_01);
SetNetworkconnectedEventFlag(13800831, ON);
ForceAnimationPlayback(3800830, 1700, false, true, false, 0, 1);
GotoUnconditionally(Label.LABEL2);
the second thing that you might notice is that the fog gate still works? and going through it plays music, but no boss healthbar? this is because Label2 is never played
Label2();
SetCharacterAIState(3800830, Enabled);
DisplayBossHealthBar(Enabled, 3800830, 0, 903050);
SetNetworkUpdateRate(3800830, true, CharacterUpdateFrequency.AlwaysUpdate);
});```
you might also notice that hes not on fire? or cindery?
Image 1 shows the boss without the code enabled, image 2 has the code enabled.
this could be because of Label 1
Label1();
IfEventFlag(AND_02, ON, TargetEventFlagType.EventFlag, 13805835);
IfInoutsideArea(AND_02, InsideOutsideState.Inside, 10000, 3802830, 1);
IfConditionGroup(MAIN, PASS, AND_02);
SetSpEffect(3800830, 10575);```
so lets break down as much of this code as I can on my own
lets start with the shortest and easiest to understand line of code
that will be Label 2
Label2();
SetCharacterAIState(3800830, Enabled);
DisplayBossHealthBar(Enabled, 3800830, 0, 903050);
SetNetworkUpdateRate(3800830, true, CharacterUpdateFrequency.AlwaysUpdate);
});```
break down
```js
Label2();
SetCharacterAIState(3800830, Enabled); //this turns on the AI for the boss
DisplayBossHealthBar(Enabled, 3800830, 0, 903050); //this displays the health bar, I don't know what 903050 means
SetNetworkUpdateRate(3800830, true, CharacterUpdateFrequency.AlwaysUpdate); //this seems to be network code saying to up the update rate for other players
});```
this makes the boss seek and kill you, and display the boss healthbar
but it only goes off when Label 2 is enabled by Label 0
Event(13805840, Restart, function() {
GotoIfEventFlag(Label.LABEL0, OFF, TargetEventFlagType.EventFlag, 13800830);
ChangeCharacterEnableState(3800830, Disabled);
ForceCharacterDeath(3800830, false);
EndUnconditionally(EventEndType.End);
Label0();
SetCharacterAIState(3800830, Disabled);
GotoIfEventFlag(Label.LABEL1, ON, TargetEventFlagType.EventFlag, 13800831);
IfPlayerIsNotInOwnWorldExcludesArena(AND_01, false);
IfEntityInoutsideRadiusOfEntity(AND_01, InsideOutsideState.Inside, 3800830, 10000, 22, 1);
IfDamageType(OR_01, 3800830, 10000, DamageType.Unspecified);
IfConditionGroup(OR_01, PASS, AND_01);
IfConditionGroup(MAIN, PASS, OR_01);
SetNetworkconnectedEventFlag(13800831, ON);
ForceAnimationPlayback(3800830, 1700, false, true, false, 0, 1);
GotoUnconditionally(Label.LABEL2);
Event(13805840, Restart, function() {
GotoIfEventFlag(Label.LABEL0, OFF, TargetEventFlagType.EventFlag, 13800830); //this decides if the boss is alive or not
ChangeCharacterEnableState(3800830, Disabled); //makes sure the boss doesn't attack you, since every single enemy, even bosses, are defualt enabled.
ForceCharacterDeath(3800830, false); //forces enemy to die, and not drop souls
EndUnconditionally(EventEndType.End); //???
Label0();
SetCharacterAIState(3800830, Disabled); //disables the Ai
GotoIfEventFlag(Label.LABEL1, ON, TargetEventFlagType.EventFlag, 13800831); //this decides if the boss is alive or not like eariler
IfPlayerIsNotInOwnWorldExcludesArena(AND_01, false); //online stuff, might literally be able to copy and paste this?
IfEntityInoutsideRadiusOfEntity(AND_01, InsideOutsideState.Inside, 3800830, 10000, 22, 1);
IfDamageType(OR_01, 3800830, 10000, DamageType.Unspecified); //determins damage type of boss. (maybe able to not even copy)
IfConditionGroup(OR_01, PASS, AND_01);
IfConditionGroup(MAIN, PASS, OR_01);
SetNetworkconnectedEventFlag(13800831, ON);
ForceAnimationPlayback(3800830, 1700, false, true, false, 0, 1);
GotoUnconditionally(Label.LABEL2); //go to Label 2
#modmaking-help message
need this link
to note: 380 numbers are entity ids, 138 is the alive state to a character, and anything that starts with a 9 is boss text
this is grossly simplified but its just for notes
I'm going to look into this code while I wait for some responses on the other
Event(13800830, Default, function() {
EndIfEventFlag(EventEndType.End, ON, TargetEventFlagType.EventFlag, 13800830); //deals with boss deat
IfCharacterHPRatio(MAIN, 3800830, ComparisonType.LessOrEqual, 0, ComparisonType.Equal, 1); //deals with boss health
WaitFixedTimeSeconds(1);
PlaySE(3800830, SoundType.s_SFX, 777777777); //Sound effect
IfCharacterDeadalive(MAIN, 3800830, DeathState.Dead, ComparisonType.Equal, 1); //no guess
HandleBossDefeat(3800830); //easy to tell
SetEventFlag(13800830, ON); //if boss is dead
SetEventFlag(9317, ON); //setting flags for living or dead
SetEventFlag(6317, ON);
});
It’s easier for us (maybe just me, i dunno) if you ask one very particular question
Like why one or two lines or commands aren’t working
It’s hard for me to look over a ton of different scripts and find out what’s going on, it’d be easier for me to just rewrite the whole thing
this is just were my insanity got tbh
Right, but it’s more of a blog documenting what you’re making than something we can jump in and give an answer for
as of right now I'm confused on this code I wrote. I know that I activate a "AND_01" and theres mentions of a "AND_02" but I straight up don't understand
Seems way over complicated to me, just simplify the script into something where you understand everything line by line
if I write something I can understand it won't work lol @ebon panther
Then you should write something simpler first and work your way up to your larger goal imho
Writing / copy pasting code you don’t understand is not a good idea
If there’s a single line you’re adding that you don’t understand, you could be screwing up a lot of stuff or creating some wild side effects
I plan on reading some tutorials again, and trying to rewrite it
$Event(13805705, Default, function() {
//Boss defeated flag
if(EventFlag(13800831)){//Check if the boss defeated flag is checked, if so, kill all bosses
ForceCharacterDeath(3800831, false);//Kill boss 1
ForceCharacterDeath(3800832, false);//Kill boss 2
ForceCharacterDeath(3800833, false);//Kill boss 3
EndEvent();//End the event because no other logic needs to run
}
//If the boss defeated flag is not on, let's continue with regular logic for the fight
SetCharacterAIState(3800831, Disabled);//Disable boss 1
SetCharacterAIState(3800832, Disabled);//Disable boss 2
SetCharacterAIState(3800833, Disabled);//Disable boss 3
WaitFor(InArea(10000, 3800151));//3800151 should be the entityid of the region just inside the fog gate, when the player passes the fog gate, the following code will execute
SetCharacterAIState(3800831, Enabled);//Enabled boss 1
SetCharacterAIState(3800832, Enabled);//Enabled boss 2
SetCharacterAIState(3800833, Enabled);//Enabled boss 3
DisplayBossHealthBar(Enabled, 3800831, 0, 906212);//Display boss healthbar 1
DisplayBossHealthBar(Enabled, 3800833, 1, 906213);//Display boss healthbar 2
DisplayBossHealthBar(Enabled, 3800832, 2, 906214);//Display boss healthbar 3
SetNetworkUpdateRate(3800831, true, CharacterUpdateFrequency.AlwaysUpdate); //Network stuff, idk, I hate multiplayer integrations
SetNetworkUpdateRate(3800832, true, CharacterUpdateFrequency.AlwaysUpdate); //Network stuff, idk, I hate multiplayer integrations
SetNetworkUpdateRate(3800833, true, CharacterUpdateFrequency.AlwaysUpdate); //Network stuff, idk, I hate multiplayer integrations
});
Try this, Terra
I'd recommend writing emevd this way, at least until you feel comfortable writing things and understanding commands at first glance
Justify every line you write and if you can't justify why it is there or what it is doing, delete it
let me try it
@ebon panther they're all just dead now
Turn off flag 13800831 and revisit the area
Something else must be killing them then, are you killing them in any other script?
Or did you not fast travel or fully reload the game?
I restart the game between saving code and stuff
Please understand that absolutely nothing in that script will kill them unless 13800831 is on, so either some other script is setting 13800831 to ON before this runs, or something else is killing them
Please go to a bonfire or fast travel, their death state might be maintained in between quitting the game by their instanceids
No idea, you'll have to find proper unused event flags to use, I can't do that for you
I'll look in a second
@ebon panther for the most part, 2/3 bosses are alive, and active
Whelp, poke around and compare what you have to vanilla instances of those enemies and see what’s wrong
Make sure the entityid for the broken enemy is unique so nothing else is interfering with your enemies
tyty @ebon panther
I've been kinda tapped out, its been a lot
Take it easy, it’s just a hobby like cross-stitching or knitting, you mess up a few knots or tangle some strings and you take a break and come back to fix it
Go handle some other aspect of modding you have a better understanding of and come back to the area you are having issues with occasionally
It shouldn’t be anything that feels like a stress or headache imho
@ebon panther there is literally nothing else going on in my life, this is all I am able to do besides crying and worrying, I will do this until it kills me, or I get bored.
Honestly, I've been in this community for about a year and I would recommend against going about modding that way, at least from my personal perspective, I think that's how a lot of people burn out and give up on projects
Play another game, watch a show, play someone else's mod, do something in between banging your head against the wall
Because many other people enter this community for a week or two with very ambitious plans, go insane trying to implement it (usually start on some really cool projects) and then burn out and never come back
I will prolly finish what I set out to do, mostly cus this is the hardest part
Just a word of advice from what I've seen in the past, you don't have to listen to it