--- Log opened Thu Feb 05 00:00:12 2015 20150205 00:23:35-!- prophile [~alynn@oftn/member/prophile] has joined #wesnoth 20150205 01:13:20-!- Tonepoet [~Tonepoet@199-116-72-70.PUBLIC.monkeybrains.net] has quit [Quit: Going offline, see ya! (www.adiirc.com)] 20150205 01:35:23-!- Tonepoet [~Tonepoet@199-116-72-70.PUBLIC.monkeybrains.net] has joined #wesnoth 20150205 01:35:32-!- DreadKnight [~DreadKnig@unaffiliated/dreadknight] has joined #wesnoth 20150205 01:41:45-!- noy [~Noy@wesnoth/developer/noy] has joined #wesnoth 20150205 01:52:37-!- fenzil [~fenzil@unaffiliated/fenzil] has joined #wesnoth 20150205 02:19:01-!- prkc [~prkc@540070EA.dsl.pool.telekom.hu] has quit [Ping timeout: 264 seconds] 20150205 02:41:04-!- sachith500_ [83aa0502@gateway/web/freenode/ip.131.170.5.2] has quit [Ping timeout: 246 seconds] 20150205 02:55:01-!- TheJJ [~rofl@ipb21b7994.dynamic.kabel-deutschland.de] has quit [Ping timeout: 264 seconds] 20150205 02:57:52-!- Wuzzy [~Wuzzy@p549F9266.dip0.t-ipconnect.de] has quit [Ping timeout: 240 seconds] 20150205 02:57:57-!- Wuzzy2 [~Wuzzy@p549F8F4F.dip0.t-ipconnect.de] has joined #wesnoth 20150205 03:03:01-!- fabi [~quassel@wesnoth/developer/fendrin] has quit [Ping timeout: 245 seconds] 20150205 03:03:41-!- fabi [~quassel@p20030051AA5D9C206102BD34832FB5DE.dip0.t-ipconnect.de] has joined #wesnoth 20150205 03:03:58-!- fabi [~quassel@p20030051AA5D9C206102BD34832FB5DE.dip0.t-ipconnect.de] has quit [Changing host] 20150205 03:03:58-!- fabi [~quassel@wesnoth/developer/fendrin] has joined #wesnoth 20150205 03:31:27-!- TheJJ [~rofl@ipb21b7994.dynamic.kabel-deutschland.de] has joined #wesnoth 20150205 03:36:26-!- prophile [~alynn@oftn/member/prophile] has quit [Quit: The Game] 20150205 03:45:36-!- ArneBab_ [~quassel@55d47810.access.ecotel.net] has joined #wesnoth 20150205 03:48:43-!- ArneBab [~quassel@55d463db.access.ecotel.net] has quit [Ping timeout: 255 seconds] 20150205 03:52:11-!- Ivanovic_ [~ivanovic@frnk-5f753053.pool.mediaWays.net] has joined #wesnoth 20150205 03:55:56-!- Ivanovic [~ivanovic@wesnoth/developer/ivanovic] has quit [Ping timeout: 264 seconds] 20150205 03:56:05-!- Ivanovic_ is now known as Ivanovic 20150205 04:06:44-!- ArneBab_ [~quassel@55d47810.access.ecotel.net] has quit [Ping timeout: 252 seconds] 20150205 04:08:48-!- ArneBab [~quassel@55d47810.access.ecotel.net] has joined #wesnoth 20150205 04:24:31-!- noy [~Noy@wesnoth/developer/noy] has quit [Quit: noy] 20150205 04:37:04-!- noy [~Noy@wesnoth/developer/noy] has joined #wesnoth 20150205 05:24:03-!- Johannes13_ [~Johannes@unaffiliated/johannes13] has quit [Ping timeout: 264 seconds] 20150205 05:32:59-!- Sulfur [~Miranda@p5B00945D.dip0.t-ipconnect.de] has joined #wesnoth 20150205 06:14:23-!- Molt [~elektron@c-174-61-60-225.hsd1.fl.comcast.net] has quit [Ping timeout: 246 seconds] 20150205 06:17:53-!- Wuzzy2 [~Wuzzy@p549F8F4F.dip0.t-ipconnect.de] has quit [Quit: Wuzzy2] 20150205 06:31:51-!- oldlaptop [~quassel@50-108-82-79.adr01.mskg.mi.frontiernet.net] has quit [Ping timeout: 264 seconds] 20150205 06:33:03-!- oldlaptop [~quassel@50-108-82-79.adr01.mskg.mi.frontiernet.net] has joined #wesnoth 20150205 07:04:30-!- Ivanovic [~ivanovic@frnk-5f753053.pool.mediaWays.net] has quit [Changing host] 20150205 07:04:30-!- Ivanovic [~ivanovic@wesnoth/developer/ivanovic] has joined #wesnoth 20150205 07:10:46-!- celticminstrel [~celmin@unaffiliated/celticminstrel] has quit [Quit: And lo! The computer falls into a deep sleep, to awake again some other day!] 20150205 07:16:21-!- Haldrik [~haldrik@unaffiliated/haldrik] has joined #wesnoth 20150205 07:26:38-!- Sonderblade [~Sonderbla@h-52-183.a157.priv.bahnhof.se] has quit [Ping timeout: 276 seconds] 20150205 07:35:47-!- fenzil [~fenzil@unaffiliated/fenzil] has quit [Read error: Connection reset by peer] 20150205 07:39:20-!- Sonderblade [~Sonderbla@h-52-183.a157.priv.bahnhof.se] has joined #wesnoth 20150205 07:51:36-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has joined #wesnoth 20150205 07:58:45-!- Batteh [~Batteh@c-67-170-165-157.hsd1.wa.comcast.net] has joined #wesnoth 20150205 08:04:37-!- Batteh is now known as Zuuri 20150205 08:22:49-!- Zuuri [~Batteh@c-67-170-165-157.hsd1.wa.comcast.net] has quit [Quit: Shutting down] 20150205 08:50:51-!- Earlo [~Earlo@213.143.167.6] has joined #wesnoth 20150205 08:54:58-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has quit [] 20150205 08:59:13-!- [Relic] [~Relic]@2602:306:33a3:6d30:2106:7e59:df37:d5c9] has quit [Quit: Leaving] 20150205 09:17:19-!- noy [~Noy@wesnoth/developer/noy] has quit [Quit: noy] 20150205 09:29:33-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has joined #wesnoth 20150205 10:44:33-!- Haudegen [~quassel@85.124.51.57] has quit [Ping timeout: 264 seconds] 20150205 10:49:15-!- Haudegen [~quassel@85.124.51.57] has joined #wesnoth 20150205 11:02:39-!- prophile [~alynn@oftn/member/prophile] has joined #wesnoth 20150205 11:26:40-!- prkc [~prkc@540070EA.dsl.pool.telekom.hu] has joined #wesnoth 20150205 12:23:30-!- HeyCitizen [~HeyCitize@modemcable081.68-161-184.mc.videotron.ca] has quit [Ping timeout: 265 seconds] 20150205 12:30:30-!- Johannes13_ [~Johannes@unaffiliated/johannes13] has joined #wesnoth 20150205 12:32:46-!- HeyCitizen [~HeyCitize@modemcable081.68-161-184.mc.videotron.ca] has joined #wesnoth 20150205 12:36:21-!- Sulfur [~Miranda@p5B00945D.dip0.t-ipconnect.de] has quit [Read error: Connection reset by peer] 20150205 13:34:05-!- TooLmaN [~TooLmaN@mx1.thomsonplastics.com] has joined #wesnoth 20150205 13:40:51-!- HeyCitizen [~HeyCitize@modemcable081.68-161-184.mc.videotron.ca] has quit [Quit: Coyote finally caught me] 20150205 13:42:41-!- HeyCitizen [~HeyCitize@modemcable081.68-161-184.mc.videotron.ca] has joined #wesnoth 20150205 14:09:50-!- hagabaka [quassel@unaffiliated/hagabaka] has quit [Read error: Connection reset by peer] 20150205 14:11:00-!- hagabaka [~hagabaka@unaffiliated/hagabaka] has joined #wesnoth 20150205 14:44:45-!- Sulfur [~Miranda@p5B00945D.dip0.t-ipconnect.de] has joined #wesnoth 20150205 15:18:51-!- noy [~Noy@S01067cb21b205894.vs.shawcable.net] has joined #wesnoth 20150205 15:18:59-!- noy [~Noy@S01067cb21b205894.vs.shawcable.net] has quit [Changing host] 20150205 15:18:59-!- noy [~Noy@wesnoth/developer/noy] has joined #wesnoth 20150205 15:21:18-!- Elouin_ [~Elouin@p200300454427DC00CA6000FFFED11D67.dip0.t-ipconnect.de] has joined #wesnoth 20150205 15:52:31-!- noy [~Noy@wesnoth/developer/noy] has quit [Quit: noy] 20150205 16:34:31-!- [Relic] [~Relic]@2602:306:33a3:6d30:d017:1096:3b86:5ccb] has joined #wesnoth 20150205 16:36:36-!- celticminstrel [~celmin@unaffiliated/celticminstrel] has joined #wesnoth 20150205 16:41:00-!- Wuzzy [~Wuzzy@p549F8F4F.dip0.t-ipconnect.de] has joined #wesnoth 20150205 16:41:16-!- Sulfur [~Miranda@p5B00945D.dip0.t-ipconnect.de] has quit [Read error: Connection reset by peer] 20150205 16:47:11-!- Johannes13_ [~Johannes@unaffiliated/johannes13] has quit [Ping timeout: 246 seconds] 20150205 16:49:14-!- Johannes13_ [~Johannes@141.70.98.52] has joined #wesnoth 20150205 16:49:14-!- Johannes13_ [~Johannes@141.70.98.52] has quit [Changing host] 20150205 16:49:14-!- Johannes13_ [~Johannes@unaffiliated/johannes13] has joined #wesnoth 20150205 16:53:31-!- noy [~Noy@wesnoth/developer/noy] has joined #wesnoth 20150205 17:05:27-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has quit [Ping timeout: 264 seconds] 20150205 17:08:14-!- DreadKnight [~DreadKnig@unaffiliated/dreadknight] has quit [Quit: #AncientBeast - Master Your Beasts ( www.AncientBeast.com )] 20150205 17:24:25-!- vultraz [~chatzilla@124.109.10.167] has joined #wesnoth 20150205 17:24:25-!- vultraz [~chatzilla@124.109.10.167] has quit [Changing host] 20150205 17:24:25-!- vultraz [~chatzilla@wesnoth/developer/vultraz] has joined #wesnoth 20150205 17:25:24-!- ancestral [~ancestral@65-128-208-249.mpls.qwest.net] has joined #wesnoth 20150205 17:37:11-!- DreadKnight [~DreadKnig@unaffiliated/dreadknight] has joined #wesnoth 20150205 17:50:11-!- localuser- [~none@gateway/tor-sasl/localuser-] has joined #wesnoth 20150205 17:53:17-!- ancestral [~ancestral@65-128-208-249.mpls.qwest.net] has quit [Quit: i go nstuf kthxbai] 20150205 17:54:16-!- prophile [~alynn@oftn/member/prophile] has quit [Quit: The Game] 20150205 17:59:26-!- ancestral [~ancestral@65-128-208-249.mpls.qwest.net] has joined #wesnoth 20150205 18:07:08-!- prophile [~alynn@oftn/member/prophile] has joined #wesnoth 20150205 18:24:13-!- Molt [~elektron@c-73-1-200-215.hsd1.fl.comcast.net] has joined #wesnoth 20150205 18:24:26< Molt> hey ya'll! 20150205 18:24:35< Molt> how is everyone doing? 20150205 18:26:54-!- Haudegen [~quassel@85.124.51.57] has quit [Ping timeout: 245 seconds] 20150205 18:28:14< Molt> So i'm grepping like a madman now ;) 20150205 18:28:25< Molt> thanks zookeeper 20150205 18:28:33< celticminstrel> Eh? 20150205 18:31:07-!- Haudegen [~quassel@85.124.51.57] has joined #wesnoth 20150205 18:31:41< vultraz> Molt: grepping for what? 20150205 18:32:44< Molt> trying to figure out how to implement a new ability called Initiative. It is an aura ability (like leadership). All units around the bearer get firststrike with all weapons 20150205 18:33:08< Molt> can't get it to work for the life of me: http://paste.ee/p/txnU5 20150205 18:34:18< vultraz> uhhh 20150205 18:34:25< vultraz> [dummy] is not a valid child of [unit] 20150205 18:35:01< celticminstrel> Your paste looks mixed up somehow. 20150205 18:35:18< celticminstrel> Oh, I see, some are indented with spaces, and some are indented with tabs. 20150205 18:36:25< celticminstrel> It doesn't really matter that much, but I prefer to use descriptive tags for custom "fake" abilities. 20150205 18:36:33< celticminstrel> For example, [initiative] instead of [dummy]. 20150205 18:37:37< vultraz> er, right 20150205 18:37:44< vultraz> Molt: also you define a macro 20150205 18:37:47< vultraz> why do you define a macro 20150205 18:38:12< celticminstrel> Everything between #define and #enddef is being ignored. 20150205 18:38:23< vultraz> yeah 20150205 18:38:25< vultraz> ^ 20150205 18:38:59< celticminstrel> Also, shouldn't he be just using [object] and not [modify_unit]? 20150205 18:39:29< Molt> i pulled the Initiative code from http://wiki.wesnoth.org/WML_Abilities#Initiative 20150205 18:39:41< celticminstrel> Yeah, um. 20150205 18:39:51< celticminstrel> That's not how that works. 20150205 18:40:15< vultraz> Molt: do you know how macros work? 20150205 18:41:31-!- Haudegen [~quassel@85.124.51.57] has quit [Ping timeout: 255 seconds] 20150205 18:41:32< vultraz> you would need to call that macro 20150205 18:42:07< Molt> no i don't 20150205 18:42:18< vultraz> ok, do you see {FOREACH? 20150205 18:42:22< vultraz> that's a macro 20150205 18:42:30< celticminstrel> I wonder if that code is actually tested... 20150205 18:43:07< vultraz> a macro is a parsed substitution code block. It allows you to use the same code in multiple places by saying {MACRO_NAME} 20150205 18:43:10< celticminstrel> I get the impression by looking at it that, if an adjacent unit normally has firststrike, it will lose it completely. 20150205 18:43:23< vultraz> so right now, you have #define AURA_INITIATIVE TYPE 20150205 18:43:51< vultraz> meaning when the code is loaded by the game, a new macro named AURA_INITIATIVE with the argument TYPE is created 20150205 18:44:13< celticminstrel> Also, why does it need TYPE as an argument? You can filter on unit abilities, can't you? 20150205 18:44:32< vultraz> In order to use that code, you would need to put {AURA_INITIATIVE} 20150205 18:44:45< vultraz> well, {AURA_INITIATIVE typeofunit} 20150205 18:44:55< vultraz> but as celticminstrel, you probably don't need a type arg 20150205 18:45:01< vultraz> celticminstrel said* 20150205 18:45:06< vultraz> why do I keep forgetting the said >_> 20150205 18:45:27-!- Haudegen [~quassel@85.124.51.57] has joined #wesnoth 20150205 18:45:40< vultraz> anyway, an important thing to remember about macros in programming in general is that they're parsed TEXT substitution. 20150205 18:47:05< vultraz> when the game loads the file, all instances of {MACRO_NAME ARGUMENTS} are replaced with the defined code, using ARGUMENTS to substitute any variations inside it 20150205 18:47:14< Molt> i got you vultraz. Macros are like functions 20150205 18:47:33< Ravana_> I suspect most of that code is for 1.8 or earlier 20150205 18:47:34< celticminstrel> "macros are parsed TEXT substitution" - that's not true in general in programming; it's true in C, and in WML, but not in general. 20150205 18:47:36< vultraz> except they're not affected by WML logic here 20150205 18:47:53< vultraz> you CANNOT say [if] [then] #define 20150205 18:48:16< Ravana_> as least looking through abilities of mercenaries era that last existed independently for 1.6, it only used type filters too 20150205 18:48:35< celticminstrel> Macros are sort of like functions, but they're functions that are called at load, with the results used to replace their invocations in the file. 20150205 18:48:48< celticminstrel> They're a shortcut for commonly used code segments. 20150205 18:49:00< vultraz> and celticminstrel just explained what I've been trying to say in half the time 20150205 18:49:10< celticminstrel> I did? 20150205 18:49:17< Molt> AWESOME! 20150205 18:49:19< Molt> ok 20150205 18:50:15< zookeeper> celticminstrel, btw, the reason why [dummy] is used is to make it clear that the tag itself does nothing gameplay-wise 20150205 18:50:17< celticminstrel> For runtime functions, look at events. 20150205 18:50:28< vultraz> celticminstrel: yes 20150205 18:50:30< vultraz> :P 20150205 18:51:19< vultraz> short and to-the-point. I'm rambling. 20150205 18:52:00< celticminstrel> zookeeper: Okay, I suppose I can see that... using some other tag makes it possible to easily refer to them as a WML variable, but I'm not sure how often that would be necessary... 20150205 18:52:43< Molt> okay, so now lets talk implementation. since the Initiative code on http://wiki.wesnoth.org/WML_Abilities#Initiative I would drop it in my scenario file - presumably anywhere after [multiplayer], right? , like at 20150205 18:53:00< celticminstrel> Even before [multiplayer] would work. 20150205 18:53:04< Molt> k 20150205 18:53:21< celticminstrel> Usually people put macros in a separate file and include that somewhere. 20150205 18:54:11< celticminstrel> If I recall correctly, the _main.cfg generally has an #ifdef CAMPAIGN_NAME, so you'd want it within that. 20150205 18:54:29< Molt> then I call it on my unit {AURA_INITIATIVE TYPE?}. I'm not understanding the type part 20150205 18:55:06< celticminstrel> The type of the unit that has the ability. 20150205 18:55:35< celticminstrel> But in this case... 20150205 18:55:43< celticminstrel> Doing that will probably not work as you intend. 20150205 18:56:01< Molt> i want to call it on both leaders of the human teams 20150205 18:56:10< celticminstrel> You're adding the ability to a unit; I think the code was written in the assumption that it would be used as a unit's intrinsic abilities. 20150205 19:01:18< celticminstrel> So if used as-is, adding it to any unit of a given type might actually make it work for all units of that type. 20150205 19:01:41< celticminstrel> Plus, as I mentioned before, it looks to me like it would strip firststrike from units that normally have it. 20150205 19:03:01< Molt> brb - neighbor came over 20150205 19:11:20< Molt> back 20150205 19:11:43< Molt> k 20150205 19:12:11< Molt> looks like I need to modify the code so it doesn't strip firststrike and so it only works for units I specify it to work for 20150205 19:12:12< Molt> :( 20150205 19:12:14< Molt> god... 20150205 19:13:24< Ravana_> making it ability id-based would help 20150205 19:18:52< celticminstrel> You can add weapon specials with [object], right? 20150205 19:18:59 * celticminstrel isn't quite sure. 20150205 19:19:34< vultraz> The wiki doesn't mention it 20150205 19:21:06< celticminstrel> Oh. 20150205 19:21:59< celticminstrel> Ah, yes, you can. 20150205 19:22:21< Ravana_> not all abilities, at least not initially 20150205 19:22:37< celticminstrel> [effect]apply_to=attack[set_specials]mode=append 20150205 19:22:58< celticminstrel> And if used in an [object]duration=turn 20150205 19:23:12< celticminstrel> It should get the desired effect of adding firststrike just for that turn, right? 20150205 19:24:17< vultraz> oh 20150205 19:24:19< vultraz> hm 20150205 19:24:22< vultraz> yeah I gues 20150205 19:43:36-!- Panda_ [~IMO@AMontsouris-653-1-179-221.w92-128.abo.wanadoo.fr] has quit [Remote host closed the connection] 20150205 19:48:49< Ravana_> Molt : I can't send remote messages/notices, but it would mean like http://wiki.wesnoth.org/WML_Abilities#Soultaker 20150205 19:49:21< Molt> k 20150205 19:49:42< Molt> ahh.. i think I see why units that are supposed to already have firststrike would have it stipped: {FOREACH unit.attack i} 20150205 19:49:42< Molt> {CLEAR_VARIABLE unit.attack[$i].specials.firststrike} 20150205 19:49:42< Molt> {NEXT i} 20150205 19:50:14< celticminstrel> Yeah. 20150205 19:51:30< Molt> basically the way to fix this would be to only initiate adding/removing firststrike if the unit didn't already have it 20150205 19:51:55< celticminstrel> Or to use [object] instead of WML variable manipulation. 20150205 19:52:04< celticminstrel> [Feb 05@2:22:37pm] celticminstrel: [effect]apply_to=attack[set_specials]mode=append 20150205 19:52:05< celticminstrel> [Feb 05@2:22:58pm] celticminstrel: And if used in an [object]duration=turn 20150205 19:52:58< Molt> that makes sense. just adding the effect for the duration of the turn 20150205 19:53:13< Molt> see, my issue is I am brand new to wml and I don't know LUA 20150205 19:53:26< celticminstrel> Lua is a full-fledged programming language. 20150205 19:53:32< Molt> i know 20150205 19:54:21< Molt> this is turning into an ordeal... 20150205 19:57:43< Ravana_> lua isn't required unless you want to do something either very specific or very complicated or very slow 20150205 20:01:29< Ravana_> I have used it only for "very specific" case 20150205 20:13:37-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has quit [Ping timeout: 264 seconds] 20150205 20:23:20-!- Earlo [~Earlo@213.143.167.6] has quit [Remote host closed the connection] 20150205 20:23:27-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has joined #wesnoth 20150205 20:52:34-!- TooLmaN [~TooLmaN@mx1.thomsonplastics.com] has quit [Quit: Off to save the world!] 20150205 21:05:54< Molt> forget it. getting initiative to work is impossible 20150205 21:06:10< celticminstrel> I doubt that. :P 20150205 21:06:16< DeFender1031> yeah, don't give up. 20150205 21:06:44< Molt> feel like i'm trying to build a rocket with breadcrumbs 20150205 21:07:21-!- ArneBab [~quassel@55d47810.access.ecotel.net] has quit [Ping timeout: 264 seconds] 20150205 21:13:29-!- ArneBab [~quassel@55d47810.access.ecotel.net] has joined #wesnoth 20150205 21:15:57< DeFender1031> I often feel like that until I figure out where the bug is and fix it... 20150205 21:17:22< DeFender1031> It's one of the realities of writing code. 20150205 21:17:58< DeFender1031> But eventually you learn that if you arrange the breadcrumbs just right, you can make an amazing rocket after all. 20150205 21:30:13< zookeeper> well it's not exactly the easiest thing to write... 20150205 21:31:24< zookeeper> (nor do i know what your code looks like) 20150205 21:32:45< vultraz> Molt: why not do as celticminstrel suggested and apply an object for duration=turn that affects attack [set_specials] mode=append for firststrike for allied units who move adjacent to the unit with Initiative that do not already have firststrike 20150205 21:34:24< Molt> vultraz: i'm trying to do that 20150205 21:35:20< vultraz> I'm not sure if events within an ability have access to autostored variables 20150205 21:35:33< celticminstrel> If you use the code you found, the [object] would replace one of the {FOREACH} things. 20150205 21:35:34< vultraz> if they do, it's simpler 20150205 21:35:46< celticminstrel> And the other could be eliminated. 20150205 21:36:06< vultraz> simply use [filter] and [filter_adjacent_locations] 20150205 21:36:16< vultraz> and also [filter_wml] [not] for firsttstrike 20150205 21:36:49< celticminstrel> Your filter would be more like the link Ravana posted. 20150205 21:37:19< celticminstrel> Well. 20150205 21:37:36< celticminstrel> Basically, you'd use ability=initiative instead of type=whatever 20150205 21:39:01< celticminstrel> This is just a single scenario, right? Not a campaign? 20150205 21:39:14< celticminstrel> It might be best just to put the events in normally. 20150205 21:39:56< Molt> it is a single scenario, yes 20150205 21:40:08< zookeeper> since you're a newbie, you can make all sorts of mistakes anywhere which will not become apparent in a high-level discussion 20150205 21:40:14< celticminstrel> Um, I wonder, is it necessary to have two versions of the attack event? 20150205 21:40:55< celticminstrel> Oh wait. The first unit in the event is always the attacker, so you need the second so the ability also works when the unit is defending. 20150205 21:41:16< Molt> right 20150205 21:42:14< celticminstrel> Basically: take the initiative code from the wiki, copy just the two attack events, and replace the {FOREACH} through [/unstore_unit] with your [object]. 20150205 21:42:28< celticminstrel> And type={TYPE} with ability=initiative 20150205 21:42:49< celticminstrel> And just put those events together with the rest of the events in the scenario. 20150205 21:43:09< celticminstrel> As for the dummy tags, you pretty much had that part right already. 20150205 21:43:36< celticminstrel> Wait, no you didn't, you were using [modify_unit[ instead of [object]. 20150205 21:43:57< celticminstrel> Still, you put them in the right place, more or less. >_> 20150205 21:44:15 * celticminstrel checks EffectWML again. 20150205 21:46:44< celticminstrel> Oh, it looks like [modify_unit] can add objects... I'm not sure how that differs from just using [object] though... 20150205 21:49:06< Molt> yeah, i was using [modify_unit] to add the [object] to the two unit's id's 20150205 21:49:14< Molt> via filtering 20150205 21:49:55< celticminstrel> Okay, the dummy tags should go inside the [effect]. 20150205 21:50:02< celticminstrel> Inside [abilities], in fact. 20150205 21:50:25< Molt> celticminstrel: when you say take the two attack events, which ones are you referring to? there are 4. you mean take the 1st two? 20150205 21:50:40< Molt> k 20150205 21:50:42< celticminstrel> There are two attack and two attack_end 20150205 21:50:46< celticminstrel> So yes, first two. 20150205 21:50:51< Molt> k 20150205 21:57:52< zookeeper> contrary to what i said before, i think the HttT version would be better after all. you only need to change a couple of lines to make it work anywhere, and i could easily do that 20150205 22:00:05< Molt> i'm down 20150205 22:00:12< zookeeper> ok, gimme a few minutes 20150205 22:00:17< Molt> thanks 20150205 22:04:14< Molt> celticminstrel: this is what I came up with based on your suggestions http://paste.ee/p/RcAj8 20150205 22:05:12< celticminstrel> Wonderful, but uh, that's the wrong object. 20150205 22:05:24< Molt> ... 20150205 22:05:35< celticminstrel> Actually no, it's a mixture of the right one and the wrong one. 20150205 22:05:51< celticminstrel> You had an object in the [modify_unit] - that's where the dummy tags go. 20150205 22:06:12< celticminstrel> Apart from that I think what you have is... almost right. 20150205 22:07:25< celticminstrel> The [abilities] tag with its [dummy] subtag can move to the other object, and FIRSTSTRIKE needs to go in [set_specials], and the [filter] needs to change - that's the filter you want in [modify_unit], not here. 20150205 22:07:58< celticminstrel> (The abilities tag does still need to be nested inside an effect tag, of course.) 20150205 22:08:26< celticminstrel> Sorry, I guess I wasn't clear enough about distinguishing the two objects, 20150205 22:08:42< zookeeper> urgh, a few more minutes, a movie is distracting me 20150205 22:09:04< celticminstrel> Basically, one object permanently adds initiative to the leaders. The other temporarily adds firststrike to adjacent units. 20150205 22:11:12-!- ancestral [~ancestral@65-128-208-249.mpls.qwest.net] has quit [Quit: i go nstuf kthxbai] 20150205 22:12:49< zookeeper> untested, but i believe this ought to work: http://pastebin.com/xy9Q51d9 20150205 22:13:10< zookeeper> include those macros wherever you want, then: 20150205 22:13:47< zookeeper> use ABILITY_INITIATIVE as any other ability macro, and put WEAPON_SPECIAL_INITIATIVE_EVENTS wherever you want the [event]s in 20150205 22:14:37< celticminstrel> Ah, that only gives firststrike on melee attacks. Which is likely what he wanted anyway, though. 20150205 22:14:47< zookeeper> well, easy to change that 20150205 22:14:54 * celticminstrel nods. 20150205 22:15:11< zookeeper> it also won't give it to allied sides, but that's easy to change too 20150205 22:15:20< celticminstrel> Oh, that doesn't use an object with duration=ture 20150205 22:15:22< celticminstrel> turn 20150205 22:15:41< celticminstrel> Or wait. 20150205 22:15:45< celticminstrel> Where is that macro. 20150205 22:16:26< celticminstrel> Ah, I see, you've given the temporary firststrike id=initiative as well... 20150205 22:16:52-!- Panda_ [~IMO@AMontsouris-653-1-179-221.w92-128.abo.wanadoo.fr] has joined #wesnoth 20150205 22:18:56< celticminstrel> Did you forget duration=turn? 20150205 22:19:28< zookeeper> no, they're supposed to be permanent 20150205 22:20:15< celticminstrel> Oh wait, right, because the special is only active when a unit with initiative is actually adjacent, so you don't need to remove it... 20150205 22:20:16< Molt> permanent as long as the allied unit is next to the unit with initiative 20150205 22:20:32< Molt> right ;) 20150205 22:20:50< celticminstrel> And empty name/description presumably means it won't be shown. 20150205 22:20:55< Molt> yeah, i did want it for all weapons and for all allies - i'll change that 20150205 22:23:23< Molt> range=melee, range will make firststrike for all attacks right? 20150205 22:24:25< zookeeper> eh, probably just remove that line 20150205 22:24:54< zookeeper> it should apply to all attacks then. if not, check. 20150205 22:27:48-!- localuser- [~none@gateway/tor-sasl/localuser-] has quit [Remote host closed the connection] 20150205 22:28:00-!- localuser- [~none@gateway/tor-sasl/localuser-] has joined #wesnoth 20150205 22:32:45< Molt> sorry, don't kill me. I don't really get where to put WEAPON_SPECIAL_INITIATIVE_EVENTS 20150205 22:34:08< celticminstrel> Put it with your events. 20150205 22:34:23< celticminstrel> You could just put the events there without the macro definition, if you want. 20150205 22:34:53< Molt> on turn two i set up a series of dialogs. if the player chooses a specific reply the leaders of both teams will get the initiative ability --> [modify_unit][filter]id=LEADER1,LEADER2 [/filter]{ABILITY_INITIATIVE}[/modify_unit] 20150205 22:35:43< celticminstrel> That might work. Try it? 20150205 22:36:23< Molt> i'm guessing I need a boolean triggered at that event, then say for all turns if the boolean is switched on --> drop the events for initiative ? 20150205 22:36:49< celticminstrel> You can just drop the events in alongside the other events. 20150205 22:37:15< celticminstrel> Or you can put them right after the [modify_unit]. 20150205 22:37:31< celticminstrel> Well, right after the [/modify_unit]. 20150205 22:37:54< Molt> k 20150205 22:37:56< zookeeper> use an [object] 20150205 22:37:56< zookeeper> just grep for new_ability in mainline campaigns, there's quite a few examples there 20150205 22:38:17< celticminstrel> He was using an object initially. (And got it all confused, but still.) 20150205 22:38:47< Molt> {WEAPON_SPECIAL_INITIATIVE_EVENTS} right after [/modify_unit] 20150205 22:39:07< celticminstrel> I think [modify_unit] changes get reset when units are carried to the next scenario in a campaign. 20150205 22:39:12< celticminstrel> Yes, Molt, that should work. 20150205 22:39:35< Molt> only once scenario, so no worries there 20150205 22:39:45 * celticminstrel nods. 20150205 22:39:54< zookeeper> no, don't use {WEAPON_SPECIAL_INITIATIVE_EVENTS} in an event 20150205 22:40:01< zookeeper> just put it where you have your other events 20150205 22:40:01< celticminstrel> Why not? 20150205 22:40:07< zookeeper> substitution 20150205 22:40:24< celticminstrel> ...oh. 20150205 22:41:14< celticminstrel> Well, if you drop it in with the other events, and the leaders don't get initiative, the events won't do anything. (Or rather, what they do will have no effect on anything.) 20150205 22:43:49< Molt> right 20150205 22:47:32-!- prophile [~alynn@oftn/member/prophile] has quit [Ping timeout: 244 seconds] 20150205 22:48:27< Molt> testing... 20150205 22:50:44-!- localuser- [~none@gateway/tor-sasl/localuser-] has quit [Remote host closed the connection] 20150205 22:53:30< Molt> naw. didn't work 20150205 22:53:43< zookeeper> well, no one knows why 20150205 22:54:20< Molt> http://paste.ee/p/B4BSS 20150205 22:54:38< Molt> i put the macro on line 87 20150205 22:55:05< Molt> gave Initiative to both leaders on line 731 20150205 22:55:24< zookeeper> and how do you know that that works? 20150205 22:55:33< Molt> added the events to every turn on line 592 20150205 22:55:50< zookeeper> and that new turn thing makes no sense 20150205 22:56:28< Molt> what? 20150205 22:56:50< zookeeper> no one's ever said anything about you needing to "add events to every turn" 20150205 22:57:29< Molt> sorry, i just saw you line "just put it where you have your other events" 20150205 22:58:37< zookeeper> yes 20150205 22:58:37< Molt> where exactly are you referring to? 20150205 22:58:37< Molt> sorry, I don't get what you mean by that 20150205 22:58:38< zookeeper> that place is just fine, just lose the surrounding event 20150205 22:59:55< Molt> understood 20150205 23:00:31< Molt> testing... 20150205 23:03:37< zookeeper> i see absolutely no reason to assume that ability tags have any meaning inside [modify_unit] 20150205 23:06:18< Molt> yeah, doesn't work 20150205 23:06:24< Molt> what do you suggest. 20150205 23:11:01< zookeeper> use an [object] 20150205 23:14:43< zookeeper> or maybe just wrap that {ABILITY_INITIATIVE} call in an [abilities] tag, but maybe that'll erase existing abilities 20150205 23:15:05< celticminstrel> The wiki says something about [modify_unit] being able to add abilities. 20150205 23:15:21< celticminstrel> On the other hand, [modify_unit] is basically undocumented. 20150205 23:15:32< celticminstrel> So it's kinda hard to figure out how it works. 20150205 23:15:49< Molt> yeah, it does. that is wehere I got that notion from 20150205 23:16:01< celticminstrel> You can definitely do it with an object, too. 20150205 23:16:36< Molt> ... 20150205 23:16:37< Molt> okay 20150205 23:16:53< celticminstrel> Though you probably need to use the object twice, once for each leader. 20150205 23:17:03< Molt> so can i filter to give the object to the two id's? 20150205 23:17:04< zookeeper> umm, where does it say that? 20150205 23:17:23< zookeeper> no, an [object] is always given to only one unit, so you'll have to do it twice 20150205 23:17:44< celticminstrel> Sorry, it was referencing objects, not abilities: http://wiki.wesnoth.org/DirectActionsWML#.5Bmodify_unit.5D 20150205 23:17:50< zookeeper> yep 20150205 23:17:51< Molt> so --> [object][filter] id=Cochise, Goyathlay [/filter] {ABILITY_INITIATIVE} [object] 20150205 23:18:01< zookeeper> noooooooo 20150205 23:18:12< zookeeper> fine, i'll do it, give me a minute 20150205 23:18:25< Molt> but its just like, there is no info 20150205 23:18:28< Molt> lol 20150205 23:19:54< zookeeper> http://pastebin.com/88b7ukD3 20150205 23:25:26-!- prophile [~alynn@oftn/member/prophile] has joined #wesnoth 20150205 23:28:24-!- noy [~Noy@wesnoth/developer/noy] has quit [Quit: noy] 20150205 23:28:26-!- trolling [~alynn@oftn/member/prophile] has joined #wesnoth 20150205 23:28:52-!- prophile [~alynn@oftn/member/prophile] has quit [Read error: Connection reset by peer] 20150205 23:29:01< Molt> thanks zookeeper. you're the best 20150205 23:32:52< celticminstrel> Will that give it to Goyathlay though? 20150205 23:33:16< Molt> it did 20150205 23:33:19< zookeeper> uh, yes... 20150205 23:33:21< celticminstrel> Oh, okay. 20150205 23:33:24< Molt> :) 20150205 23:33:32< celticminstrel> The documentation for [object] says it only takes the first matching unit. 20150205 23:33:35< zookeeper> you have a really low vertical resolution or something? :P 20150205 23:33:46< Molt> lol 20150205 23:33:54< celticminstrel> Hm? 20150205 23:34:04< Molt> oldschool eee pc 20150205 23:34:11< zookeeper> i assumed you simply missed the second object, nevermind 20150205 23:34:12< Molt> now many vertical pixels 20150205 23:34:16< Molt> not 20150205 23:34:21< zookeeper> not you 20150205 23:34:23< celticminstrel> Oh. I was looking at what Molt posted, not at the pastebin. Whoops. >_> 20150205 23:34:29< Molt> zookeeper - i got the joke 20150205 23:34:37< zookeeper> oh, good :p 20150205 23:34:37< Molt> ahh 20150205 23:38:46-!- trolling [~alynn@oftn/member/prophile] has quit [Read error: Connection reset by peer] 20150205 23:39:10-!- prophile [~alynn@oftn/member/prophile] has joined #wesnoth 20150205 23:52:10-!- zookeeper [~lmsnie@wesnoth/developer/zookeeper] has quit [Ping timeout: 252 seconds] 20150205 23:52:38-!- DreadKnight [~DreadKnig@unaffiliated/dreadknight] has quit [Quit: #AncientBeast - Master Your Beasts ( www.AncientBeast.com )] --- Log closed Fri Feb 06 00:00:26 2015