weapon equip

Game Editor comments and discussion.

weapon equip

Postby Fabiomafia1298 » Wed Jun 06, 2007 6:24 pm

how can i get my character to equipt a weapon and shoot that weapons when equipped?
PS some nice weapon animations would be nice if anyone can post any. im not that good at drawing.
Fabiomafia1298
 
Posts: 11
Joined: Fri Jun 01, 2007 12:28 am
Score: 0 Give a positive score

Postby Sgt. Sparky » Wed Jun 06, 2007 6:51 pm

weapon drawing:
I could make the Weapons for you! :D

weapon equiping:
make a variable(integer) called Select.

on the event that triggers the weapon change(example, the 1 button.)
Code: Select all
Select = 0;

when the 2 button is pressed,
Code: Select all
Select = 1;

ect.
on the draw actor event of your Gun actor(make is seperate from the player.)
Code: Select all
if(Select == 0)ChangeAnimation("Event Actor", "Gun_1", FORWARD);
if(Select == 1)ChangeAnimation("Event Actor", "Gun_2", FORWARD);
//ect.

or for a Side Scroller make an extra variable called dir(integer).
when the player presses the left key(repeated) dir = 0;
when the player presses the right key(repeated) dir = 1;
and on the draw actor event of the Gun,
Code: Select all
if(Select == 0) {
if(dir == 0)ChangeAnimation("Event Actor", "Gun_1left", FORWARD);
if(dir == 1)ChangeAnimation("Event Actor", "Gun_1right", FORWARD);
if(Select == 1) {
if(dir == 0)ChangeAnimation("Event Actor", "Gun_2right", FORWARD);
if(dir == 1)ChangeAnimation("Event Actor", "Gun_2left", FORWARD);
                      }
//ect.

:D
if that does not help I will make a Demo. :D
Image
Random Links:
viewtopic.php?p=19474#19474
Right now (10/14/2009) I'm working on some C++ projects, but I might be able to help if you have some Game Editor questions. :)
User avatar
Sgt. Sparky
 
Posts: 1850
Joined: Sat Oct 07, 2006 5:28 pm
Location: Somewhere out there, beneath the pale blue sky...
Score: 236 Give a positive score

Postby Fabiomafia1298 » Wed Jun 06, 2007 11:20 pm

a demo would help. this is a little confusing for me.
Fabiomafia1298
 
Posts: 11
Joined: Fri Jun 01, 2007 12:28 am
Score: 0 Give a positive score

Postby Sgt. Sparky » Thu Jun 07, 2007 2:28 am

allrighty,
I will make on real fast. :D
Image
Random Links:
viewtopic.php?p=19474#19474
Right now (10/14/2009) I'm working on some C++ projects, but I might be able to help if you have some Game Editor questions. :)
User avatar
Sgt. Sparky
 
Posts: 1850
Joined: Sat Oct 07, 2006 5:28 pm
Location: Somewhere out there, beneath the pale blue sky...
Score: 236 Give a positive score

Postby Sgt. Sparky » Thu Jun 07, 2007 2:55 am

Image
Random Links:
viewtopic.php?p=19474#19474
Right now (10/14/2009) I'm working on some C++ projects, but I might be able to help if you have some Game Editor questions. :)
User avatar
Sgt. Sparky
 
Posts: 1850
Joined: Sat Oct 07, 2006 5:28 pm
Location: Somewhere out there, beneath the pale blue sky...
Score: 236 Give a positive score

Postby Fabiomafia1298 » Thu Jun 07, 2007 3:15 pm

thanks man
Fabiomafia1298
 
Posts: 11
Joined: Fri Jun 01, 2007 12:28 am
Score: 0 Give a positive score

Postby Sgt. Sparky » Sun Jun 10, 2007 3:13 pm

you are welcome. :D
Image
Random Links:
viewtopic.php?p=19474#19474
Right now (10/14/2009) I'm working on some C++ projects, but I might be able to help if you have some Game Editor questions. :)
User avatar
Sgt. Sparky
 
Posts: 1850
Joined: Sat Oct 07, 2006 5:28 pm
Location: Somewhere out there, beneath the pale blue sky...
Score: 236 Give a positive score


Return to GE - General

Who is online

Users browsing this forum: No registered users and 1 guest

cron