Gamestudio Links
Zorro Links
Newest Posts
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/20/24 20:05
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
0 registered members (), 1,438 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Mortar cannon demo #320353
04/21/10 07:27
04/21/10 07:27
Joined: Apr 2006
Posts: 624
DEEP 13
badapple Offline OP
User
badapple  Offline OP
User

Joined: Apr 2006
Posts: 624
DEEP 13
iI have'nt made a new demo in a while , so here you go.

its one way to make a mortar cannon or catapolt with a targeting system and a neat little radar as well(not perfect but
functional and cool anyway) this was made with lite c free , but
published so you can check it out if you dont have lite c.

the enemies dont attack , they just head towards you and let you obliterate them. but hey at least there's something to shoot at.

these codes are free to use no credit is needed.enjoy

mortar cannon demo

Re: Mortar cannon demo [Re: badapple] #320355
04/21/10 07:53
04/21/10 07:53
Joined: Jun 2008
Posts: 428
Rasch Offline
Senior Member
Rasch  Offline
Senior Member

Joined: Jun 2008
Posts: 428
very nice ^^

Re: Mortar cannon demo [Re: Rasch] #320358
04/21/10 08:09
04/21/10 08:09
Joined: Nov 2008
Posts: 196
the wrong place
Muhsin Offline
Member
Muhsin  Offline
Member

Joined: Nov 2008
Posts: 196
the wrong place
nice!


Come and play my new browsergame - Valley Of Wolves:

http://www.mafiacreator.com/ValleyOfWolves

Hurry and be the first to take over the different business' in the Valley Of Wolves, before anybody else does it!
And be the most feared MafiaBoss in the World!!
Re: Mortar cannon demo [Re: Muhsin] #320360
04/21/10 08:33
04/21/10 08:33
Joined: Apr 2006
Posts: 624
DEEP 13
badapple Offline OP
User
badapple  Offline OP
User

Joined: Apr 2006
Posts: 624
DEEP 13
thanks im glad you like it smile

Re: Mortar cannon demo [Re: badapple] #320361
04/21/10 08:38
04/21/10 08:38
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Nice, only one thing though, they sometime get stuck to the green circlr, look like you forgot to make it passable wink


3333333333
Re: Mortar cannon demo [Re: Quad] #320365
04/21/10 09:22
04/21/10 09:22
Joined: Apr 2006
Posts: 624
DEEP 13
badapple Offline OP
User
badapple  Offline OP
User

Joined: Apr 2006
Posts: 624
DEEP 13
you are right Quadraxas , i geuss because i didnt asingn the
target an action or function of its own i forgot to set its flags
thanks for the bug report.
a new demo has been uploaded with the corrections smile

Re: Mortar cannon demo [Re: badapple] #320768
04/24/10 12:59
04/24/10 12:59
Joined: Nov 2008
Posts: 196
the wrong place
Muhsin Offline
Member
Muhsin  Offline
Member

Joined: Nov 2008
Posts: 196
the wrong place
Hi!

I try to use you explosion code in my project, but when i shoot and the bullet hits something i get this error: "Dangerous intruction in event big_explosion".

( I copied the smoke, big_explosion, big_burn, and shell_event fuctions directly from you code)

what do I do wrong? how can i solve the problem?

thanks!

- Muhsin Kaymak

Last edited by Muhsin; 04/24/10 13:04.

Come and play my new browsergame - Valley Of Wolves:

http://www.mafiacreator.com/ValleyOfWolves

Hurry and be the first to take over the different business' in the Valley Of Wolves, before anybody else does it!
And be the most feared MafiaBoss in the World!!
Re: Mortar cannon demo [Re: Muhsin] #320821
04/25/10 02:23
04/25/10 02:23
Joined: Apr 2006
Posts: 624
DEEP 13
badapple Offline OP
User
badapple  Offline OP
User

Joined: Apr 2006
Posts: 624
DEEP 13
you should post your code with the problem

Re: Mortar cannon demo [Re: badapple] #320831
04/25/10 09:21
04/25/10 09:21
Joined: Dec 2007
Posts: 706
Schortens Germany
Landixus Offline
User
Landixus  Offline
User

Joined: Dec 2007
Posts: 706
Schortens Germany
nice demo, but the ents should only show in the radar pic? laugh


My Blog German: http://blog.quakeit.de/
www.quakeit.de ||
Airfix Game in Cooperation with:
www.3drt.com
Models Levels and Textures
Re: Mortar cannon demo [Re: Landixus] #320834
04/25/10 09:57
04/25/10 09:57
Joined: Nov 2008
Posts: 196
the wrong place
Muhsin Offline
Member
Muhsin  Offline
Member

Joined: Nov 2008
Posts: 196
the wrong place
here is the code i took from you and my rocket code:

------------------------------------------
function fade_smoke(PARTICLE *p)//fade the smoke
{
p.alpha -= .2 * time_step;
p.size+= .4 * time_step;
if (p.alpha < 0) p.lifespan = 0;
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////
function smoke(PARTICLE *p)//smoke partical effect
{
p->vel_x = ( .1 )-random(.2) ;
p->vel_y = ( .1 )-random(.2) ;
p->vel_z = random( .1 );
p.alpha = 10 + random(10);
p.bmap = smoke_tga;
p.size = 10+random(2);
p.flags |= ( MOVE);
p.event = fade_smoke;
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////
function big_explosion()//explosion from the mortar shell
{
my.roll=random(360); //make it look a little different each time
my.scale_x=1.2;my.scale_y=my.scale_x;my.scale_z=my.scale_x; //scale it up a bit
c_trace(my.x,vector(my.x,my.y,my.z-1000),IGNORE_ME|IGNORE_SPRITES|IGNORE_MODELS); my.z = hit.z +2;//place just above ground
VECTOR temp; //a temporary vector
set(my,PASSABLE | BRIGHT | TRANSLUCENT | UNLIT);//attributes
my.alpha=100;//fully visible
vec_set(temp,camera.x);vec_sub(temp,my.x);vec_to_angle(my.pan,temp); //look at the cam
while(my.frame<20)//play all its frames
{
my.alpha -= 1 * time_step;
my.frame+=1*time_step;
wait(1);
}
my.frame=0;
wait(1);
ent_remove(my); //bye bye
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////
function big_burn() //burn from the mortar shell
{
my.scale_x=4;my.scale_y=my.scale_x;my.scale_z=my.scale_x;
c_trace(my.x,vector(my.x,my.y,my.z-1000),IGNORE_ME|IGNORE_SPRITES|IGNORE_MODELS); my.z = hit.z +1;
VECTOR temp;
set(my,PASSABLE | TRANSLUCENT);
my.alpha=100;
my.pan=random(360);
while(my.alpha>0) //fade it out slowly
{
my.tilt=-90;
my.alpha-=.4*time_step;
wait(1);
}
wait(1);
ent_remove(my);//bye bye burn
}

function rocket_event()//event triggered when shell makes contact
{
my.event=NULL;//stop future instances of this function
//vec_set(my.x,my_target.x);
//snd_play(exploend_wav,100,NULL);
ent_create("explo+20.tga",my.x,big_explosion);//this explosion is upright and faces cam
you=ent_create("explo+20.tga",my.x,big_explosion);you.tilt=-90;//same explosion tilted and placed on the ground
ent_create("burn.tga",my.x,big_burn);//burn tilted and placed on the ground
c_scan(my.x,my.pan,vector(360,180,400),SCAN_ENTS | SCAN_LIMIT);
wait(1);
ent_remove(my);//bye bye shell
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////

action player_rocket()
{
var fall_speed = 0.9;
VECTOR procket_speed;

wait (1);
my.skill40 = 1;
my.pan = you.pan;
my.tilt = you.tilt;
my.emask |= ENABLE_BLOCK | ENABLE_ENTITY;
my.event = rocket_event;
my.skill5 = 0;

procket_speed.x = 100 * time_step;
procket_speed.y = 0 * time_step;
procket_speed.z = 0 * time_step;
//procket_speed = * time_step;
while (my != NULL)
{

c_setminmax(me);

my.skill5 += time_step;

if (my.skill5 > 20)
{
procket_speed.z -= fall_speed * time_step;
}
move_mode = IGNORE_YOU + IGNORE_PASSABLE;
ent_move (procket_speed.x, nullvector);


wait (1);
}
}
------------------------------------------

thanks!

- Muhsin Kaymak


Come and play my new browsergame - Valley Of Wolves:

http://www.mafiacreator.com/ValleyOfWolves

Hurry and be the first to take over the different business' in the Valley Of Wolves, before anybody else does it!
And be the most feared MafiaBoss in the World!!
Page 1 of 2 1 2

Moderated by  adoado, checkbutton, mk_1, Perro 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1