Mines

master maste

New Member
Reaction score
32
Thanks, it works now without crashing. I'll go try it out and see if it works :)

edit: trigger didnt do anything.
 

Waaaaagh

I lost all my rep and my title being a jerk
Reaction score
70
It should. I'm sorry about the crash. I just forgot a few parenthesis and tried to convert a region to a rect... SILLY ME!!! :D
 

master maste

New Member
Reaction score
32
kk still doing some testing, but whats wrong with the trigger and it not working (also the map goes super slow when I enter game, just checking if its my other triggers (all I did was remove locust from the unit to see what would happen))
 

Halo_king116

Working As Intended
Reaction score
153
Theres two thoughts to this post.

First;

and the footman has locust

In GUI, the trigger won't notice if a unit that has locust comes within range of one who doesn't, or maybe it's vice versa?

Well, either way - Locust complicates things. In a maze I made, I had to remove locust for my unit could just walk right by it. When I removed it, the trigger worked. Though this was in GUI, and it may not affect JASS. Just test it without locust, once. It would take a second to reverse so the unit has locust again. It would be worth testing (Assuming that trigger is correct in the first place).




Secondly;

Stop some of your stupid posts! This thread is to help Master_Maste with his trigger problem, not waste time by having to read pointless posts to get to what we need to help. Had I came now, without originally seeing this thread, I wouldn't have read it all for 23 posts seem like quite a few for me. An example is:

"Cool Indeed."

Keep the posts important, I beg of you.


Last but not least, good luck! :) Beware of the locust.
 

master maste

New Member
Reaction score
32
If this does not work I will code post my code Icyculyr, but I would prefer to keep as much as possible in Jass.

anyways my old trigger was making it go slow.
umm still not doing anything (btw what is this supposed to do exactly)

only 30 units on the map and only 1 of them is a footman and 1 usually get create in game by my ability.

also I tried removing locust and nothing changed.
 

master maste

New Member
Reaction score
32
at the moment, but as the footman gets created by an ability I want it to work for any footmen that will ever get created.:)
 

Icyculyr

I'm a Mac
Reaction score
68
"Cool Indeed."

I replied simply to what Waaaaagh had said, I reply to everything, it is rude to not reply.

And as much help as Master Maste needs, continuing posting, will keep this thread up the top aswell


>> Master Maste, You can have that trigger in jass, I can try and write it for you in Jass, let me go download JassCraft
 

Waaaaagh

I lost all my rep and my title being a jerk
Reaction score
70
Bah shit. I don't know what I did.... It stopped working...

Ima make it normal... no hijacked conditions
 

Icyculyr

I'm a Mac
Reaction score
68
I thought it may have been the 'Hijacked conditions' :p

We will see soon, hopefully it is, because JassCraft is playing up lol, so I can not write in jass now:(
 

Waaaaagh

I lost all my rep and my title being a jerk
Reaction score
70
JASS:
function CreateMine_MineId takes nothing returns integer
    return 'hkni'
endfunction

function CreateMine_DetonationRange takes nothing returns real
    return 300.
endfunction

function CreateMine_AlwaysTrue takes nothing returns boolean
    return true
endfunction

function CreateMine_Detonate takes nothing returns nothing
    local unit footy=GetTriggerUnit()
    if(GetUnitTypeId(footy)=='hfoo')then
        call SetUnitExploded(footy,true)
        call KillUnit(footy)
    endif
    set footy=null
endfunction

function CreateMine takes nothing returns nothing
    local unit mine=GetEnteringUnit()
    local trigger t
    if(GetUnitTypeId(mine)==CreateMine_MineId())then
        set t=CreateTrigger()
        call TriggerRegisterUnitInRange(t,mine,CreateMine_DetonationRange(),Condition(function CreateMine_AlwaysTrue))
        call TriggerAddAction(t,function CreateMine_Detonate)
    endif
    set mine=null
endfunction
                                                    
//========================================================================================================
function InitTrig_CreateMine takes nothing returns nothing
    local trigger t=CreateTrigger()
    local region rectRegion=CreateRegion()
    call RegionAddRect(rectRegion,GetPlayableMapRect())
    call TriggerRegisterEnterRegion(t,rectRegion,Condition(function CreateMine_AlwaysTrue))
    call TriggerAddAction(t,function CreateMine)
    set rectRegion=null
    set t=null
endfunction


It works for sure. 'hkni' is a Knight.
 

master maste

New Member
Reaction score
32
what on earth am I doing wrong. I got the new trigger and changed "hkni" to h009 and "h00f" to h009, what am I doing wrong?
 

Waaaaagh

I lost all my rep and my title being a jerk
Reaction score
70
dont change 'hfoo'. 'hfoo' means footman. I just used a knight to test it.
 

Halo_king116

Working As Intended
Reaction score
153
I apologize for my lack of knowledge, but...

Perhaps try to narrow down what you are doing wrong? If you can't get this to work, try GUI. I know what you are thinking, so please read this fully. I know you don't wish to use GUI, but ONLY use it as a test then, perhaps?

If you try it in GUI, then you can know if it's something with the trigger, or something somewhere else. It's like the locust test - You're trying to know what you are generally doing wrong so you can find the problem specifically.

Sorry I don't know JASS - But this is a technique I use when I can't find the error of my WE ways.


Well, I hope you get it to work! :) It defiantly should not be as troublesome as it's being. :(


Edit: Sorry if I didn't read all previous posts before this, I am working on a map at the moment.
 
General chit-chat
Help Users

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top