Forum

> > Stranded II > Scripts > Tower and Arrow damage
ForenübersichtStranded II-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch Tower and Arrow damage

4 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt Tower and Arrow damage

Xephoriah
User Off Offline

Zitieren
I am playing around with the code from the Tower defense gamemode, and I need to make a stronger tower for the stronger enemies i have implemented. however i cannot seem to find the factor for the amount of damage the arrows do, lvl 1 does 5, lvl 2 does 7 and lvl 3 does 9 and so on, but where do I find the code that makes the towers actually do that much damage, the one i want shoots fire arrows and does 19 damage.

alt Re: Tower and Arrow damage

Xephoriah
User Off Offline

Zitieren
yes, the arrow has a base damage, but i think the tower adjusts the damage. Here is the code for the Lvl.3 tower
1
{ projectile 53,$fx,$fy,$fz,5,300,50,0,15,0.5625,0; }
to my understanding, all I really can understand is: 15 is speed, and 53 is the type of projectile, aka the item id. that's pretty much it, the other things...
1
{ projectile 53,?,?,?,?,?,?,?,15,?,?; }
if i could please have an explanation for what the ?s i put are really, it would give me a better understanding on what I'm working with, thanks.

alt Re: Tower and Arrow damage

JasJack67
Super User Off Offline

Zitieren
Zitat
Example 1: Defense Tower shoots at only hostile units:
projectile Item Id,x,y,z,mode,range,damage,drag;

In this example the variable $y has 28 added to it...this is the height of the projectile(arrow) off the ground where it appears to come out of the Defense Tower.

1
2
3
4
5
6
7
8
on:timer {
		local $x,$y,$z;
		$x=getx("self");
		$y=gety("self");
		$z=getz("self");
		$y+=28;
		projectile 53,$x,$y,$z,6,350,15,59;
	}

Also note: The mode for the defense tower is set to 6. Which you can see the modes in the "more +" below. So it shoots at hostile units...units with the behavior of "raptor". The 350 is the Range that they talk about in mode 6.

The Defense Tower arrow does 15 Damage.

Drag is 59, how far before the arrow loses momentum and falls to the ground.


Zitat
Example 2: Native Bowman shoots Fire Arrow at the player

projectile Item Id,x,y,z,mode,speed,damage,drag;

In this example the variable $y has 28 added to it...this is the height of the projectile(arrow) off the ground where it appears to be shot from the bow native.

1
2
3
4
5
6
7
8
9
on:timer {
    if (lives("self")==1){
	local $x,$y,$z;
	$x=getx("self");
	$y=gety("self");
	$z=getz("self");
	$y+=28;
	projectile 56,$x,$y,$z,4,70,10,50;
    }

Also note: The mode for the Native's Arrow is set to 4. Which you can see the modes in the "more +" below. So it shoots at the player. The 70 is the Speed, 10 is the Damage, and 50 is the Drag

}


Mehr >
8× editiert, zuletzt 05.04.15 14:40:41

alt Re: Tower and Arrow damage

Xephoriah
User Off Offline

Zitieren
Thank you, you have explained it very well. I understand now that the arrow itself does 16 damage, so i will try to make an arrow that causes a fixed amount of damage, so it's easier to work with, this also will help me with other things in the future! thanks!
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtStranded II-ÜbersichtForenübersicht