wc3campaigns
WC3C Homepage - www.wc3c.netUser Control Panel (Requires Log-In)Engage in discussions with other users and join contests in the WC3C forums!Read one of our many tutorials, ranging in difficulty from beginner to advanced!Show off your artistic talents in the WC3C Gallery!Download quality models, textures, spells (vJASS/JASS), systems, and scripts!Download maps that have passed through our rigorous approval process!

Go Back   Wc3C.net > Resources > Code Resources > Systems
User Name
Password
Register Rules Get Hosted! Chat Pastebin FAQ and Rules Members List Calendar



Reply
 
Thread Tools Search this Thread
Old 12-07-2007, 02:01 PM   #31
Malf
I LIKE PIZZA! | >
 
Malf's Avatar
 
Join Date: Sep 2007
Posts: 625

Submissions (2)

Malf has a spectacular aura about (92)Malf has a spectacular aura about (92)Malf has a spectacular aura about (92)Malf has a spectacular aura about (92)

Send a message via AIM to Malf
Default

Make a CreateTornado(x,y,windforce) function else you get pwnd.

The users may be able to do this by themselves, but most people using this probably don't know advanced math so.. Pwn.
__________________
Malf is offline   Reply With Quote
Sponsored Links - Login to hide this ad!
Old 12-10-2007, 10:35 AM   #32
Onihero
User
 
Join Date: Oct 2007
Posts: 16

Onihero has little to show at this moment (0)

Default

So in this version you need to declare a unit as an entity in order for another unit to collide or bounce off it? I was testing it and it seemed as if the unit needed to be an entity, can you post some code that allows all entities to interact with all units?
Onihero is offline   Reply With Quote
Old 12-10-2007, 12:09 PM   #33
HINDYhat
User
 
HINDYhat's Avatar
 
Join Date: Aug 2007
Posts: 225

Submissions (2)

HINDYhat will become famous soon enough (48)HINDYhat will become famous soon enough (48)

Default

The way the system is made, that can't happen. Entities have radius, mass and other things important in collisions. Units just don't have that data stored anywhere. I'll try to add static entities for the next version, so you can declare rocks and things like that.
__________________
Quote:
Originally Posted by Chat Room
[19-17-58] Da)sniper: not go blistic because ur a raciest vs all guiers
HINDYhat is offline   Reply With Quote
Old 12-11-2007, 06:34 AM   #34
Onihero
User
 
Join Date: Oct 2007
Posts: 16

Onihero has little to show at this moment (0)

Default

True but could the system get the units within Coll.Radius and then perform Collision Functions? Also, how much lag would these static entities cause? Oh, and how long until the next version's release?
Onihero is offline   Reply With Quote
Old 12-11-2007, 12:21 PM   #35
HINDYhat
User
 
HINDYhat's Avatar
 
Join Date: Aug 2007
Posts: 225

Submissions (2)

HINDYhat will become famous soon enough (48)HINDYhat will become famous soon enough (48)

Default

Static entities shouldn't lag much, anyway alot less than regular entities.

I can't run the onCollision method with a unit, since units don't have radius... so I couldn't detect exactly when I get in range of one. I suppose I'll make it possible to add units as entities to the onCollision...
__________________
Quote:
Originally Posted by Chat Room
[19-17-58] Da)sniper: not go blistic because ur a raciest vs all guiers
HINDYhat is offline   Reply With Quote
Old 12-12-2007, 08:51 AM   #36
Onihero
User
 
Join Date: Oct 2007
Posts: 16

Onihero has little to show at this moment (0)

Default

damn, so could the system support about 250 static entities and 30 normal entities without noticeable lag on B.Net?

Edit: Is there anyway I could change it so the entity detects units in its collision radius (like GetUnitsIn the coll.radius of the entity)?

Last edited by Onihero : 12-12-2007 at 09:38 AM.
Onihero is offline   Reply With Quote
Old 12-17-2007, 04:58 AM   #37
HINDYhat
User
 
HINDYhat's Avatar
 
Join Date: Aug 2007
Posts: 225

Submissions (2)

HINDYhat will become famous soon enough (48)HINDYhat will become famous soon enough (48)

Default

You could always GroupEnumUnitsInRange of the <Entityname>.Unit member.

Anyway, no updates this week. Last week of school before Christmas break, and I have loads of exams. Hopefully I'll get working on this system after this week.
__________________
Quote:
Originally Posted by Chat Room
[19-17-58] Da)sniper: not go blistic because ur a raciest vs all guiers
HINDYhat is offline   Reply With Quote
Old 01-09-2008, 10:21 AM   #38
Panda[Leaf]
User
 
Join Date: Dec 2007
Posts: 28

Panda[Leaf] has little to show at this moment (0)

Send a message via AIM to Panda[Leaf]
Default

Perhaps include a jump plugin in a future release?
Correct me if I'm wrong, but currently there's no way to detect collision with non entitative objects? Seems like the entire projectile aspect is killed by the inability to inflict damage using functions inside of SEE.
Nice system though, very user friendly. +Rep
__________________
The Leaf Pandaren

Last edited by Panda[Leaf] : 01-09-2008 at 01:35 PM.
Panda[Leaf] is offline   Reply With Quote
Old 01-09-2008, 06:07 PM   #39
Pyritie
Doesn't come here often
 
Pyritie's Avatar
 
Join Date: Jan 2007
Posts: 451

Submissions (9)

Pyritie will become famous soon enough (47)Pyritie will become famous soon enough (47)

Send a message via MSN to Pyritie
Default

Quote:
Originally Posted by Panda[Leaf]
Seems like the entire projectile aspect is killed by the inability to inflict damage using functions inside of SEE.
Trigger:
Collapse Event
Unit - A unit dies
Collapse Conditions
(Unit type of Triggering Unit) Equal to YourProjectile
Collapse Actions
Unit - deal damage of type blah over area blah...

Simple.
Pyritie is offline   Reply With Quote
Old 01-09-2008, 10:00 PM   #40
Panda[Leaf]
User
 
Join Date: Dec 2007
Posts: 28

Panda[Leaf] has little to show at this moment (0)

Send a message via AIM to Panda[Leaf]
Default

First off, there isn't a function to detect when an entity collides with a unit.
Second, if I didn't want to deal damage everytime a particle died, then that trigger wouldn't work. I'd have to go extensively into "call GroupEnumUnitsInRange" so it's really just a suggestion to include collision with objects like that, even if it's just basic IsPointInSphere checks.. It'd still be much appreciated.
__________________
The Leaf Pandaren
Panda[Leaf] is offline   Reply With Quote
Old 01-09-2008, 10:06 PM   #41
HINDYhat
User
 
HINDYhat's Avatar
 
Join Date: Aug 2007
Posts: 225

Submissions (2)

HINDYhat will become famous soon enough (48)HINDYhat will become famous soon enough (48)

Default

There is no possibiliy to check collisions with units/destructables, because those widgets don't have any declared radius (unless I'm wrong...) and so I couldn't effectively find when a certain entity would enter in collision range with a widget (spherical collisions).

If you want to use GroupEnumUnitsInRange, you could of course use it with an entity's unit member, which is listed in the member list trigger (I currently don't remember it's name :P).
__________________
Quote:
Originally Posted by Chat Room
[19-17-58] Da)sniper: not go blistic because ur a raciest vs all guiers
HINDYhat is offline   Reply With Quote
Old 01-09-2008, 10:15 PM   #42
Panda[Leaf]
User
 
Join Date: Dec 2007
Posts: 28

Panda[Leaf] has little to show at this moment (0)

Send a message via AIM to Panda[Leaf]
Default

Hmmm... I found this in a tutorial for Infrane's particle system a while back... The source eludes me, and it uses vectors but perhaps you can make some use of it.

Hidden information:
Code:
function ParticleCollisionCond takes nothing returns boolean
  local group g = CreateGroup()
  local unit u = GetEnumUnit()
  local unit f
  local integer p = udg_clsParticlePlace[GetUnitUserData(u)]
  local integer tv
  local location l
  call GroupEnumUnitsInRange(g, udg_vectorX[p], udg_vectorY[p], 60, null)

  loop
    set f = FirstOfGroup(g)
    exitwhen f == null
    set l = GetUnitLoc(f)
    set tv = VectorCreate(GetLocationX(l), GetLocationY(l), GetLocationZ(l)+GetUnitFlyHeight(f))
    call RemoveLocation(l)

    if IsPointInSphere(tv, p, 60) then

      call VectorDestroy(tv)

      set udg_TUnit = f //This is a temp global to be used in the conditionfuncs
      if IsPlayerAlly(GetOwningPlayer(f),GetOwningPlayer(u))==false then
      set u = null
      set l = null
      set f = null

      return true

    
    
    endif
    endif
  call VectorDestroy(tv)
    call GroupRemoveUnit(g,f)
  endloop

  set u = null
  set l = null
  set f = null

  return false
endfunction

function ParticleCollision takes nothing returns trigger
  if udg_conditionCollision == null then
    set udg_conditionCollision = CreateEvalTrig(function ParticleCollisionCond)
  endif
  return udg_conditionCollision
endfunction


And it called the function with

Hidden information:
Code:
function Collision_Damage80 takes nothing returns nothing
  local unit u = GetEnumUnit()
  call UnitDamageTarget(u, udg_TUnit, 80, true, false, ATTACK_TYPE_CHAOS, DAMAGE_TYPE_NORMAL, WEAPON_TYPE_WHOKNOWS)
  call DestroyEffect(AddSpecialEffectTarget("Abilities\\Weapons\\CannonTowerMissile\\CannonTowerMissile.mdl", udg_TUnit, "chest"))
  call KillUnit(u)
  call RemoveParticle(u,true)
  set u = null
endfunction
__________________
The Leaf Pandaren
Panda[Leaf] is offline   Reply With Quote
Old 01-09-2008, 11:11 PM   #43
MaD[Lion]
MaD Da ViNci
 
MaD[Lion]'s Avatar


Respected User
 
Join Date: Apr 2003
Posts: 1,699

Submissions (10)

MaD[Lion] is a jewel in the rough (225)MaD[Lion] is a jewel in the rough (225)MaD[Lion] is a jewel in the rough (225)MaD[Lion] is a jewel in the rough (225)

Default

hm you can easily assign radius to units using structs. and their user data.
__________________
Current Projects:
MaDOS (outdated)System for object movements & effects - NEW VERSION IS UNDER W.I.P
Cinematic SystemSystem for making better cinematics and with fancy effects
Timing SystemTiming system that simulates the usage of PolledWait just with 0.01 accuracy
MaD[Lion] is offline   Reply With Quote
Old 01-10-2008, 12:48 AM   #44
HINDYhat
User
 
HINDYhat's Avatar
 
Join Date: Aug 2007
Posts: 225

Submissions (2)

HINDYhat will become famous soon enough (48)HINDYhat will become famous soon enough (48)

Default

Of course you can, but regular units don't have radius directly assigned to them via the unit editor...

So units with a radius struct attached to them would basically be entities...
__________________
Quote:
Originally Posted by Chat Room
[19-17-58] Da)sniper: not go blistic because ur a raciest vs all guiers
HINDYhat is offline   Reply With Quote
Old 01-10-2008, 01:12 AM   #45
Panda[Leaf]
User
 
Join Date: Dec 2007
Posts: 28

Panda[Leaf] has little to show at this moment (0)

Send a message via AIM to Panda[Leaf]
Default

Which is perfectly fine so long as their ability to be controlled by a player is unaltered...
__________________
The Leaf Pandaren
Panda[Leaf] is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off


All times are GMT. The time now is 07:47 AM.


Affiliates
The Hubb The JASS Vault Clan WEnW Campaign Creations Clan CBS GamesModding Flixreel Videos

Powered by vBulletin (Copyright ©2000 - 2019, Jelsoft Enterprises Ltd).
Hosted by www.OICcam.com
IT Support and Services provided by Executive IT Services