Archived copy of war3source.com, the War3Source forum (2009–2020), rebuilt from the Internet Archive by wc3mods.net. This page was captured on 2012-10-24 (original capture). Forum · All archived topics · Wiki · Bug tracker · Blog
Chat

War3:Source
October 24, 2012, 03:22:04 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Download: http://war3source.com/index.php?board=9.0
What is War3Source?: http://war3source.com/index.php?topic=200.0
Sample Stats: http://war3source.com/war3stats
Steam Community Group: http://steamcommunity.com/groups/war3source
War3Source SVN Checkout: http://ownageclan.com/svn/war3source/
War3Source servers: http://www.game-monitor.com/search.php?vars=war3_version=
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Falling Smoke  (Read 209 times)
zero
Full Member
***
Posts: 191



View Profile WWW Email
« on: November 26, 2011, 04:50:46 PM »

I want to try to make smoke that falls instead of rising. I also want to try to parent it to a player.

I am able to make the smoke:

Code:
new String:gas_name[128];
Format(gas_name, sizeof(gas_name), "SpawnGas%i", client);
new String:originData[64];
Format(originData, sizeof(originData), "%f %f %f", VectorPos[0], VectorPos[1], VectorPos[2]);
new String:colorData[64];
Format(colorData, sizeof(colorData), "%i %i %i", 220, 100, 110);
new gascloud = CreateEntityByName("env_smokestack");
DispatchKeyValue(gascloud,"targetname", gas_name);
DispatchKeyValueVector(gascloud,"Origin", VectorPos);
DispatchKeyValueFloat(gascloud,"BaseSpread", 15.0);
DispatchKeyValue(gascloud,"SpreadSpeed", "100");
DispatchKeyValue(gascloud,"Speed", "50");
DispatchKeyValueFloat(gascloud,"StartSize", 15.0);
DispatchKeyValueFloat(gascloud,"EndSize", 25.0);
DispatchKeyValue(gascloud,"Rate", "200");
DispatchKeyValue(gascloud,"JetLength", "500");
DispatchKeyValueFloat(gascloud,"Twist", 5.0);
DispatchKeyValue(gascloud,"RenderColor", colorData);
DispatchKeyValue(gascloud,"RenderAmt", "100");
DispatchKeyValue(gascloud,"SmokeMaterial", "particle/fire.vmt");
DispatchSpawn(gascloud);
TeleportEntity(gascloud, VectorPos, NULL_VECTOR, NULL_VECTOR);
AcceptEntityInput(gascloud, "TurnOn");

However when it comes to parenting the smoke or making it go a different direction I am lost. Here is the valve page for the entity: https://developer.valvesoftware.com/wiki/Env_smokestack

Can I get some help plez?
Logged

Vulpone
Full Member
***
Posts: 140



View Profile Email
« Reply #1 on: November 27, 2011, 02:19:35 AM »

As far as parenting goes, try this:

Code:
SetVariantString("!activator");
AcceptEntityInput(gascloud, "SetParent", client, gascloud, 0);
« Last Edit: November 27, 2011, 02:22:53 AM by Vulpone » Logged

Sapere aude!
qwerty
Jr. Member
**
Posts: 87


View Profile
« Reply #2 on: November 28, 2011, 08:07:10 AM »

I want to try to make smoke that falls instead of rising. I also want to try to parent it to a player.

I am able to make the smoke:

Code:
new String:gas_name[128];
Format(gas_name, sizeof(gas_name), "SpawnGas%i", client);
new String:originData[64];
Format(originData, sizeof(originData), "%f %f %f", VectorPos[0], VectorPos[1], VectorPos[2]);
new String:colorData[64];
Format(colorData, sizeof(colorData), "%i %i %i", 220, 100, 110);
new gascloud = CreateEntityByName("env_smokestack");
DispatchKeyValue(gascloud,"targetname", gas_name);
DispatchKeyValueVector(gascloud,"Origin", VectorPos);
DispatchKeyValueFloat(gascloud,"BaseSpread", 15.0);
DispatchKeyValue(gascloud,"SpreadSpeed", "100");
DispatchKeyValue(gascloud,"Speed", "50");
DispatchKeyValueFloat(gascloud,"StartSize", 15.0);
DispatchKeyValueFloat(gascloud,"EndSize", 25.0);
DispatchKeyValue(gascloud,"Rate", "200");
DispatchKeyValue(gascloud,"JetLength", "500");
DispatchKeyValueFloat(gascloud,"Twist", 5.0);
DispatchKeyValue(gascloud,"RenderColor", colorData);
DispatchKeyValue(gascloud,"RenderAmt", "100");
DispatchKeyValue(gascloud,"SmokeMaterial", "particle/fire.vmt");
DispatchSpawn(gascloud);
TeleportEntity(gascloud, VectorPos, NULL_VECTOR, NULL_VECTOR);
AcceptEntityInput(gascloud, "TurnOn");

However when it comes to parenting the smoke or making it go a different direction I am lost. Here is the valve page for the entity: https://developer.valvesoftware.com/wiki/Env_smokestack

Can I get some help plez?

...i'm trying to think of the race this would be for

edit: wait!  d-fly?

edit edit: try Pitch Yaw Roll <-180, 0, 0>  (this puts it 180 degrees off of the verticle X-axis)
« Last Edit: November 28, 2011, 08:16:37 AM by qwerty » Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!