Classic-Burger Posted yesterday at 01:01 Author Report Share Posted yesterday at 01:01 ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Expecting an element Range, got nothing ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Invalid sequence in interleave ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Element Convert failed to validate content ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Expecting an element DefaultStance, got nothing ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Invalid sequence in interleave ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Element UnitAI failed to validate content ERROR: RelaxNGValidator: Validation failed for '(null)' ERROR: Failed to validate entity template 'units/kush/support_healer_b' ERROR: JavaScript error: simulation/helpers/InitGame.js line 48 cmpPlayer.SetCheatsEnabled is not a function InitGame@simulation/helpers/InitGame.js:48:13 ERROR: Error in timer on entity 3, IID94, function UpdateSequences: TypeError: this.sequences is undefined StatisticsTracker.prototype.UpdateSequences@simulation/components/StatisticsTracker.js:522:2 Timer.prototype.OnUpdate@simulation/components/Timer.js:140:44 ERROR: Error in timer on entity 4, IID94, function UpdateSequences: TypeError: this.sequences is undefined StatisticsTracker.prototype.UpdateSequences@simulation/components/StatisticsTracker.js:522:2 Timer.prototype.OnUpdate@simulation/components/Timer.js:140:44 ERROR: Error in timer on entity 5, IID94, function UpdateSequences: TypeError: this.sequences is undefined StatisticsTracker.prototype.UpdateSequences@simulation/components/StatisticsTracker.js:522:2 Timer.prototype.OnUpdate@simulation/components/Timer.js:140:44 ERROR: Error in timer on entity 6, IID94, function UpdateSequences: TypeError: this.sequences is undefined StatisticsTracker.prototype.UpdateSequences@simulation/components/StatisticsTracker.js:522:2 Timer.prototype.OnUpdate@simulation/components/Timer.js:140:44 ERROR: JavaScript error: simulation/components/StatisticsTracker.js line 158 deepcopy requires one argument. StatisticsTracker.prototype.GetSequences@simulation/components/StatisticsTracker.js:158:19 GuiInterface.prototype.GetExtendedSimulationState@simulation/components/GuiInterface.js:193:58 GuiInterface.prototype.GetReplayMetadata@simulation/components/GuiInterface.js:212:32 GuiInterface.prototype.ScriptCall@simulation/components/GuiInterface.js:2131:20 endGame@gui/session/session.js:525:25 onPress@gui/session/message_box/QuitConfirmation.js:26:29 display@gui/session/SessionMessageBox.js:23:35 async*onPress@gui/session/MenuButtons.js:265:22 initButton/button.onPress@gui/session/Menu.js:68:12 ERROR: Error calling component script function ScriptCall ERROR: JavaScript error: simulation/components/StatisticsTracker.js line 158 deepcopy requires one argument. StatisticsTracker.prototype.GetSequences@simulation/components/StatisticsTracker.js:158:19 GuiInterface.prototype.GetExtendedSimulationState@simulation/components/GuiInterface.js:193:58 GuiInterface.prototype.GetReplayMetadata@simulation/components/GuiInterface.js:212:32 GuiInterface.prototype.ScriptCall@simulation/components/GuiInterface.js:2131:20 endGame@gui/session/session.js:528:9 onPress@gui/session/message_box/QuitConfirmation.js:26:29 display@gui/session/SessionMessageBox.js:23:35 async*onPress@gui/session/MenuButtons.js:265:22 initButton/button.onPress@gui/session/Menu.js:68:12 ERROR: Error calling component script function ScriptCall ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) I don't have qny idea what's wrong. Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted yesterday at 02:05 Author Report Share Posted yesterday at 02:05 I'm going to upload the files when I can, the whole mod to some repository. Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted yesterday at 02:51 Author Report Share Posted yesterday at 02:51 46 minutes ago, Classic-Burger said: I'm going to upload the files when I can, the whole mod to some repository. https://gitlab.com/Classic_burger/conversionsys Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted yesterday at 02:54 Report Share Posted yesterday at 02:54 A modding tip or trick: For js files like unit_actions.js, you could just have a file that amends the vanilla file so you don't have to maintain the entire original file. Just name it something like: unit_actions_conversion.js unit_actions_convsys.js unit_actions_amend.js unit_actions_{whatever you want here}.js The file would contain only the sections of code that you change/add. I believe this only works with JS files. @Itms @Stan` anything to add to my description? 1 Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted yesterday at 03:31 Author Report Share Posted yesterday at 03:31 34 minutes ago, wowgetoffyourcellphone said: A modding tip or trick: For js files like unit_actions.js, you could just have a file that amends the vanilla file so you don't have to maintain the entire original file. Just name it something like: unit_actions_conversion.js unit_actions_convsys.js unit_actions_amend.js unit_actions_{whatever you want here}.js The file would contain only the sections of code that you change/add. I believe this only works with JS files. @Itms @Stan` anything to add to my description? And to do this I must do the same thing I did with ConvertUnitAI.js ? Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted yesterday at 03:40 Report Share Posted yesterday at 03:40 9 minutes ago, Classic-Burger said: And to do this I must do the same thing I did with ConvertUnitAI.js ? Ope! didn't see that file yet. So, you pretty much already knew what I said in my other post. 1 Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted yesterday at 03:47 Author Report Share Posted yesterday at 03:47 6 minutes ago, wowgetoffyourcellphone said: Ope! didn't see that file yet. So, you pretty much already knew what I said in my other post. Yes but I didn't know I could do that with all js the files. 1 Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted yesterday at 05:45 Author Report Share Posted yesterday at 05:45 I fixed errors now I have less. Quote ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Expecting an element DefaultStance, got nothing ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Invalid sequence in interleave ERROR: RelaxNGValidator: Validation error: units/kush/support_healer_b:1: Element UnitAI failed to validate content ERROR: RelaxNGValidator: Validation failed for '(null)' ERROR: Failed to validate entity template 'units/kush/support_healer_b' ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) ERROR: OpenAL error: (null); called from COggData::~COggData (line 76) ERROR: OpenAL error: (null); called from COggData::~COggData (line 80) Quote Link to comment Share on other sites More sharing options...
Grapjas Posted 20 hours ago Report Share Posted 20 hours ago 11 hours ago, Classic-Burger said: Yes but I didn't know I could do that with all js the files. You can't, only with components iirc. The important line is `ReRegisterComponent` or `ReRegisterComponentType` all the way at the bottom. 1 Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted 8 hours ago Author Report Share Posted 8 hours ago (edited) The "Convert" order will be processed by an "Order.Convert" handler that must be added in "UnitAI.prototype.UnitFsmSpec". And what is the thing? According to what I saw it defines finite state machines (FSM) for unit behavior. https://en.m.wikipedia.org/wiki/Finite-state_machine "mathematical model of computation. It is an abstract machine that can be in exactly one of a finite number of states at any given time. The FSM can change from one state to another in response to some inputs; the change from one state to another is called a transition". It was hard for me to understand that. So this defines how a unit will behave depending on the variants it encounters in the terrain, basically a series of mathematical and circumstantial variables, which dictate the behavior of the unit on the battlefield. It is not the whole set, but it is the elementary one. For example if the unit encounters allies or enemies you will see how it will behave although it seems to me that the allies or enemies is in another file. Edited 8 hours ago by Classic-Burger Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted 8 hours ago Author Report Share Posted 8 hours ago Quote UnitAI.prototype.Convert = function(target, queued, pushFront) { let cmpFaith = Engine.QueryInterface(this.entity, IID_Faith); if (!cmpFaith || cmpFaith.GetCurrentFaith() < 50) { this.WalkToTarget(target, queued); return; } if (!this.CanConvert(target)) { this.WalkToTarget(target, queued); return; } if (this.order && this.order.type == "Convert" && this.order.data && this.order.data.target === target) { this.order.data.force = true; this.orderQueue = [this.order]; return; } this.AddOrder("Convert", { "target": target, "force": true }, queued, pushFront); }; Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted 8 hours ago Author Report Share Posted 8 hours ago It's funny, but I hadn't thought about defining a faith component, just as there is a health component. Quote Link to comment Share on other sites More sharing options...
Classic-Burger Posted 4 hours ago Author Report Share Posted 4 hours ago (edited) 3 hours ago, Classic-Burger said: It's funny, but I hadn't thought about defining a faith component, just as there is a health component. It is not necessary unless some buildings can to increase the healer's faith, just in case someone in the future wants to implement bonuses to the temple to recover faith. Edited 4 hours ago by Classic-Burger Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.