[Question] - Conditions table

Hi. I have a problem that can not understand and i would be glad if someone could help me.

Ok, let’s say that we have spell 80351 and creature/npc 42900;

I want spell 42900 can only be cast on creature 80351 (else - invalid target/cannot do right now);

I’ve inserted into conditions :

DELETE FROM `conditions` WHERE `SourceEntry` = 80351;

INSERT INTO `conditions` VALUES (17,0,80351,0,0,31,1,3,42900,0,0,0,"","Target only creature 42900");

Without this entry, spell can be casted anywhere. With this condition, i cannot cast spell even on that target, and it says “You can’t do that yet”.

Where i was wrong?

About your code, it is correct, though such spells usually are implicit. Meaning you have to use 13 not 17. Then again you have to also check the specific effects that you want to limit. And best way to check this is a tool called SpellWork.

This topic is for here I suppose: http://www.trinityco…development-4x/

Something like this, though this would limit only effect 0 = 1. Usually spells that are not explicit or opposite give console error on start up in condition table. This spell has chain icon which usually is connected with implicit effects.

INSERT INTO conditions VALUES (13,0,80351,0,0,31,0,3,42900,0,0,0,“”,“Target only creature 42900”);

I can’t click on your link…