itsLong Posted December 15, 2015 Share Posted December 15, 2015 I just know about basic things about C/C++. And I don't know any API about DST and the only way to get something useful is to search specific functions in forums and look about worked mods. So hard for me I've tried to modify Action Queue. I used AddPlayerPostInit & DoTaskInTime instead of AddSimPostInit in modmain.lua and the mod won't crash, but it just does nothing with selection box. And then I skimed components/actionqueuer.lua, using the method that "printing" some intermediate values that I usually used in C/C++ and gradually, I figured out that, lines between 368 and 372 doesn't work normally. The amount of "members" of actions in line 368 is always 0 no matter what you select with selection box (but the amount of "members" of ents changed), and entities won't be highlighted. (entities will be highlighted in function SelectEntity and I think after that actions will be done one by one)local cur_ents = {}local ents = TheSim:FindEntities(x, y, z, math.sqrt(radiussq), nil, UNSELECTABLE_TAGS)for _, target in ipairs(ents) do if target.Transform and target:IsValid() and not target:IsInLimbo() and isBounded(target:GetPosition()) then local actions = getAction(target, is_right) -- line 368 if actions[1] then cur_ents[target] = true self.parent:SelectEntity(target, is_right) end -- line 372 endendfor inst in pairs(previous_ents) do if not cur_ents[inst] then self.parent:DeselectEntity(inst) endendAnd now I think it is too hard for me to figure out what in fact I should modify. And my English is not good . So here comes the title. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now