Page 2 of 4

Posted: Thu Jan 08, 2009 11:08 pm
by ForTheSwarm
I would make stuff with this. In fact, it's an important part of my mod. But NO... the triggers never work.

Posted: Fri Jan 09, 2009 12:23 am
by poiuy_qwert
Well obviously you are doing something wrong, or the conditions/actions you used are not working in melee. If you actually provided info I might be able to help, but really your post is useless. You need to learn how to get help correctly. Did you try what I told you at SEN? You never told me the results if you even did the test. If you still want help please post/pm your test exe and steps you used to create it and I will see if you set it up correctly. You could also check out the tests posted above to see a working example. Worst comes to worst it would be simple for me to modify LocUnlock for your usage.

Posted: Fri Jan 09, 2009 10:30 pm
by ForTheSwarm
I did tell you the results of my test- it didn't work. The marine wasn't created. The trigger file is at SEN. The test exe you gave didn't work. It said MPQDraft couldn't load the plugins? So I recreated the exe and the triggers worked.

Results of my test:
1. Added triggers to .mpq.
2. Opened Firegraft.
3. Opened mod.
4. Added LocUnlock to list of MPQDraft plugins.
5. Saved.
6. Ran mod, triggers failed to work.

Posted: Sat Jan 10, 2009 3:38 am
by ForTheSwarm
SEN is a big place with thousands of posts. Post them here or at the least link to the file at SEN?
poiuy_qwert, however, knows where I attached the file.

I couldn't just put it in the sempq because it required special conditions, a.k.a. my mod.
Is it possible that setting the shield % of units that don't normally have shields doesn't work?

Posted: Sat Jan 10, 2009 3:47 pm
by ForTheSwarm
Sorry for being too vague. I will try to explain my problem as best as I can.

In the mod, many of the Terran units have shields. However, I want them to be set to 0% until a building ("Shield Generator") is built. When the building is built, the shields are set to 100%.

I am pretty sure that I am using the plugin correctly because when I tested the sample triggers included in the test zip, they worked.

Here are the two possible problems:
1. The Set Shield Percentage action does not work on units that did not previously have shields.
2. My triggers are messed up.

Can you check my triggers to see if I did something wrong?

Posted: Sun Jan 11, 2009 2:09 am
by modmaster50
It seems that "Anywhere" doesnt work (at least in actions). Since the default deaths of start location is 0, wouldnt running EnableDebugMode() with no death settings create "Location 0"?

Code: Select all

Trigger(All Players):
      Command(Current Player, At Least, 2, Terran Civilian)
      RemoveUnitAtLocation(Current Player, 1, Terran Civilian, Anywhere)

All of my other remove actions use RemoveUnit (which removes all). But this one was the only one that uses RemoveUnitAtLocation and the Anywhere location (I wanted to specify a specific amount of units to remove). And...Its the only remove that fails. Im associating it with the "Anywhere" location for now. Baja's problem with the giving units seems to me also to be caused by this "Anywhere" location.

Its supposed to remove excess commanders. When ur commander dies, you get the unit that the commander requires, so you can respawn him (Supposing you have lives left, which reminds me...My life reducer depends on this Anywhere location too). The build time was long, so ppl could queue multiple commanders.

EDIT: To fix the commander part, Ive decided to make the build time so short no one can click fast enough to make 2. Im going to try using location 0 and see if it works.

EDIT2: Location 0 fails. Could this be fixed? I think the ability to use "Anywhere" is useful. One last try: Making Location 0 cover the whole map.

EDIT3: Doesnt work. Im beginning to suspect the action isnt melee compatible. Also, I used v1

EDIT4: I cant center a location either! Its either "Anywhere" doesnt work. Or centering AND remove unit dont work. This time tested on V2. Im getting frustrated now...

Im using: SC BW 1.15.1 No-CD with FireGraft 0.93b and LocUnlock V2

Posted: Sun Jan 11, 2009 6:38 am
by modmaster50
Can you help me compile this? Its a modified LocUnlockV1 that puts a 16x16 centered on all command centers and a 2x2 over all flag captures. I dont have a version of VC++ that supports using the solution file you gave me.

This will provide all of the functionality I need for coding the AI triggers for my mod and AITaunt.

EDIT: Code update! Code edited to also find flags. Check implemented to only find players 1-8. Ill use gas for lives instead of these weird units that I cant even remove one at a time.

EDIT2: Solved!