Newbwc3's Help Thread

Status
Not open for further replies.

PurgeandFire

zxcvmkgdfg
Reaction score
509
I think you can calculate the time using "Distance/Speed." Then you can attach the special effect to the target unit. I think that is how you figure it out, sorry if I'm wrong..

btw: The "Distance" and "Speed" are variables. (Integer I think or maybe Real)

___________________________

HEAD BANGER!!! :banghead: :banghead:
 

Newbwc3

Sephiroth_VII
Reaction score
157
Code:
Gernade explosion graphic
    Events
        Unit - A unit Begins casting an ability
    Conditions
        (Ability being cast) Equal to Gernade 
    Actions
        Set Timetaken = ((Current acquisition range of (Casting unit)) / 200.00)  <<< 200 is the missle speed
        Wait Timetaken seconds
        Special Effect - Create a special effect at (Target point of ability being cast) using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl

With this code the explosion grapic only works sometimes.How to fix so U see the the explosion graphic when the missle art impacts the target?

(O and the target type is not one single unit it is a small area that U select.)
SOLVED
 
D

dariidar

Guest
the ChaosSpaceOrcs projectile art for his attack is part of his model file.Like Attack-2 or somthin. So I cannot simply change the ChaosSpaceOrcs model file to Shredder. I wish Someone could give me a projectile art "flamethrower" that would be real cool.

Even if I did have the right Projectile art I wouldnt be able to get the shredder to do a ranged attack and a melee attack...help.
Give the guy 2 attacks. First is melee, second is ranged.
Then you set:
Attacks Enabled- Both
in the unit editor.
First attack:
Targets allowed- ground
Range: 100 (melee)

Second attack:
Targets allowed- ground, air
Range: X (more than 100)
If you set the attack art to the Dragon's flames, then I think you get the sound file for it too.

As for the flamethrower, I don't know if you can do that, but I do know that the dragon flames or frost wyrm attacks look similar. Change the attack animation to that instead.
 

Tom Jones

N/A
Reaction score
437
Why are you using acquisition range?
Let's try something else. I presume that your ability is using a missile, so go to the object editor and find the field called Art - Missile Speed. Remember this value. Now go to the trigger editor. We need to know the excact time the missile will travel before hitting the target. This is actually really simple, all you gotta do is this:
Code:
If your ability is a unit target ability use this:
Wait ((Distance between (Position of (Triggering unit)) and (Position of (Target unit of ability being cast))) / *Missile Speed*) seconds

If your ability is a point target ability use this:
Wait ((Distance between (Position of (Triggering unit)) and (Target point of ability being cast)) / *Missile Speed*) seconds
And then create the special effect after the wait.
 

Newbwc3

Sephiroth_VII
Reaction score
157
Still doesnt work. The timing of the effect gets better the closer the target point is.
Code:
Gernade explosion graphic
    Events
        Unit - A unit Begins casting an ability
    Conditions
        (Ability being cast) Equal to Gernade 
    Actions
        Wait ((Distance between (Position of (Casting unit)) and (Target point of ability being cast)) / 200.00) seconds
        Special Effect - Create a special effect at (Target point of ability being cast) using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl

This code looks like it should work perfectly to me.
SOLVED
 

Newbwc3

Sephiroth_VII
Reaction score
157
It works, Somewhat, but I think it leaks

Code:
Gernade explosion graphic
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Gernade 
    Actions
        Wait ((Distance between (Position of (Casting unit)) and (Target point of ability being cast)) / 200.00) seconds
        Special Effect - Create a special effect at (Target point of ability being cast) using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl

Or it could be because of the 0.35 arc on the missle?Or maybe because I'm using an ability mdl?:confused:
SOLVED
 

elmstfreddie

The Finglonger
Reaction score
203
Edit your first post with questions please! And if they are solved, edit out the question with -=Solved!=-

(I have no clue what you need to know!)
 

Duwenbasden

Ver 6 CREATE energy AS SELECT * FROM u.energy
Reaction score
165
Code:
Gernade explosion graphic
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Gernade 
    Actions
        Wait ((Distance between (**LEAK**Position of (Casting unit)) and (**LEAK**Target point of ability being cast)) / 200.00) seconds
        Special Effect - Create a special effect at (**LEAK**Target point of ability being cast) using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl

You asked for leaks... you get leaks. Put all the location things in variables and destroy them after.
 

Newbwc3

Sephiroth_VII
Reaction score
157
Ok Ill try and elaborate a bit. Im trying to make a graphic effect happen at the target of the ability when the missile art impacts. The following code is what i got so far:

Code:
Gernade explosion graphic
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Gernade 
    Actions
        Wait ((Distance between (Position of (Casting unit)) and (Target point of ability being cast)) / 200.00) seconds
        Special Effect - Create a special effect at (Target point of ability being cast) using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl

When testing out this ability in my map the graphic effect doesnt always happen at the right time and sometimes doesnt even happen at all!

Best way to show U this is to Show U the map

Just look on my map project post
SOLVED
 

Newbwc3

Sephiroth_VII
Reaction score
157
Code:
Gernade explosion graphic
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Gernade 
    Actions
        Set point = (Position of (Casting unit))
        Set point = (Target point of ability being cast)
        Wait ((Distance between (Position of (Casting unit)) and (Target point of ability being cast)) / 200.00) seconds
        Special Effect - Create a special effect at (Target point of ability being cast) using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl

I see no "destroy variable" action:confused:
SOLVED
 

Duwenbasden

Ver 6 CREATE energy AS SELECT * FROM u.energy
Reaction score
165
Create variable for each location! 1 for 1, 2 for 2, 3 for 3!
====================
you need a custom script:

Code:
call RemoveLocation (LOCATION_VARIABLE_YOU_WANT_REMOVED)
 

Newbwc3

Sephiroth_VII
Reaction score
157
Code:
Gernade explosion graphic
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Gernade 
    Actions
        Set pointone = (Position of (Casting unit))
        Set pointtwo = (Target point of ability being cast)
        Set pointthree = (Target point of ability being cast)
        Wait ((Distance between pointone and pointtwo) / 200.00) seconds
        Special Effect - Create a special effect at pointthree using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl
        Custom script:   call RemoveLocation (udg_pointone)
        Custom script:   call RemoveLocation (udg_pointtwo)
        Custom script:   call RemoveLocation (udg_pointthree)
Heres what I did is this correct? When I try out the ability it takes like 3 seconds after impact to show the graphic. I WANT it to show the graphic right when the art missle impacts.

Duwenbasden: You forgot to tell me to put udg_ in front of the varible name. What does udg mean anyway?
SOLVED
 
Z

Zell

Guest
"udg_" refers to "user defined global". All variables created in the variable editor are global. There are no GUI locals. A global, as the name implies, is used across all triggers. A local is specifically used by one instance of a trigger, and therefore makes JASS MUI automatically since each time the trigger fires, a new instance with unique locals is que'd (?).
 

Newbwc3

Sephiroth_VII
Reaction score
157
Ok now how do I reduce the time it takes to show the graphic so U'll see the explosion effect right when the missile art impacts.
SOLVED
 

Newbwc3

Sephiroth_VII
Reaction score
157
(I solved the last one on my own)

NEW QUESTION:
When ever you use event-locations in triggers is it always necissary to put them in varibles and then call-remove location afterwards?
----------------------------------------EXAMPLE--------------------------------------
This code:
Code:
[B]Events-[/B] unit uses ability
[B]conditions-[/B]ability equal to firebolt
[B]actions-[/B] Wait distance between (position of triggering unit)and (position of point being targeted)
changed to this:
Code:
[B]Events- [/B]unit uses ability
[B]conditions-[/B] ability equal to firebolt
[B]actions-[/B] Set Varible "point1"=(position of triggering unit)
Set Varible "point2"= (position of point being targeted)
Wait distance between (point1) and (point2)
call RemoveLocation (udg_point1)
call RemoveLocation (udg_point2)
SOLVED
 

trb92

Throwing science at the wall to see what sticks
Reaction score
142
Technically, you do not HAVE to remove the locations, but doing so reduces lag in the map and is a VERY VERY VERY good idea, so i suggest you always remove them.
 

Newbwc3

Sephiroth_VII
Reaction score
157
Ok are there any other methods of making a map "not lag" and enhancing triggers that I am not aware of? (this is the only method i know)
SOLVED
 
Status
Not open for further replies.
General chit-chat
Help Users
  • No one is chatting at the moment.
  • WildTurkey WildTurkey:
    is there a stephen green in the house?
    +1
  • The Helper The Helper:
    What is up WildTurkey?
  • The Helper The Helper:
    Looks like Google fixed whatever mistake that made the recipes on the site go crazy and we are no longer trending towards a recipe site lol - I don't care though because it motivated me to spend alot of time on the site improving it and at least now the content people are looking at is not stupid and embarrassing like it was when I first got back into this like 5 years ago.
  • The Helper The Helper:
    Plus - I have a pretty bad ass recipe collection now! That section of the site is 10 thousand times better than it was before
  • The Helper The Helper:
    We now have a web designer at my job. A legit talented professional! I am going to get him to redesign the site theme. It is time.
  • Varine Varine:
    I got one more day of community service and then I'm free from this nonsense! I polished a cop car today for a funeral or something I guess
  • Varine Varine:
    They also were digging threw old shit at the sheriff's office and I tried to get them to give me the old electronic stuff, but they said no. They can't give it to people because they might use it to impersonate a cop or break into their network or some shit? idk but it was a shame to see them take a whole bunch of radios and shit to get shredded and landfilled
  • The Helper The Helper:
    whatever at least you are free
  • Monovertex Monovertex:
    How are you all? :D
    +1
  • Ghan Ghan:
    Howdy
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top