First FPS project off to a bad start

Posted By: OblivionDrake

First FPS project off to a bad start - 12/18/08 23:44

Hi Im just begining my first game project in Lite-C and I appear to have been shot down before I even got in the plan so to speek. I was trying to test and ent creat method to have my gun show in FPS mode when I got the message that my Testlvl.wmb can't be opened and its nothing but a hollow cube and a camera I striped the code down to this:

#include <acknex.h>
#include <default.c>

function main()
{
video_mode = 7;
level_load ("Testlvl.wmb");
}

And it still doesnt work.
Now Iv saved the script as ShooterProject.c cause it kept wating to save it as ShooterProject *.wdl

Any thoughts

O and mostlikely this being my first project ill continue to post on this thread as I make it over one hurtal and then get closelined by the next considern my plan is to make a FPS with One seme gun,One Full Auto gun,and One maylay weapone(Knife)
And also 2 types of enemys ranged and maylay with basic Ai in other words they stand there till they see you then attack.

thanks in advanced
Posted By: Quad

Re: First FPS project off to a bad start - 12/19/08 00:02

if the wdl still exists delete it. and make sure you compiled the map.
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/19/08 00:29

the wdl file was deleted and I built then saved the map which is what I think you meant by compiling the map Quadraxas. If not what step am I missing? the lvl plays in WED no problems.
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/19/08 01:07

The messages that I get are

Malfunction W1301

and

Error E1100
Posted By: flits

Re: First FPS project off to a bad start - 12/19/08 11:47

are you sure the lvl is in the same folder as your script
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/19/08 17:17

thanks flits didnt know they had to be in the same folder to work.
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/20/08 02:01

Ok this is were I am so far lvl loads now and I placed the cbabe model in and am trying to get it to move with the c_move comand but it doesnt seem to attach to the cbabe model cause all it does is cycle though its animations.

also while I was tinkering I tried to make my pistal model appear in the corner of the screen I just dont know were to put this

ent_create (drone_mdl, temp, start_drone);

and what to change on it well other than the drone_mdl to my pistal_mdl.

And lastly I wanted to put a mouse mode in my game just not sure how to do it in workshop14 they spend more time explaining how to make a program change from one mouse mode to the other they never really explain how to just implement the mouse mode you want in your project or at least thats all I got out of it.

any help would be appreashated


and heres my current scripte:

#include <acknex.h>
#include <default.c>

ENTITY* pistal_ent =

{
type = "pistal.mdl";
layer = 10;
view = camera;
x = 20;
y = -10;
z = -10;
}
action my_cbabe()
{
while (1)
{
if (key_a)
my.pan += 3*time_step;
if (key_s)
my.pan -= 3*time_step;
if (key_space)
c_move (my, vector(15 * time_step, 0, 0), nullvector, GLIDE);
wait (1);
}
}
function main()
{
video_mode = 7;
level_load ("Testlvl.wmb");
while (1)
}
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/20/08 02:22

Update I got a mouse mode to work just dont know which one it is or how to change it to the one I want. heres the current script.

#include <acknex.h>
#include <default.c>

ENTITY* pistal_ent =

{
type = "pistal.mdl";
layer = 10;
view = camera;
x = 20;
y = -10;
z = -10;
}
action my_cbabe()
{
while (1)
{
if (key_a)
my.pan += 3*time_step;
if (key_s)
my.pan -= 3*time_step;
if (key_space)
c_move (my, vector(15 * time_step, 0, 0), nullvector, GLIDE);
wait (1);
}
}
function main()
{
video_mode = 7;
level_load ("Testlvl.wmb");
while (1) //
{ //
//
camera.pan -= mouse_force.x; //this is were Im having the mouse mode
camera.tilt += mouse_force.y; //problems
//
wait (1); //
}



}

P.S. still havent figured out the other problems from last post.
Posted By: Ottawa

Re: First FPS project off to a bad start - 12/22/08 00:43

Hi!

For cbabe model : you have to create ACTION in SED
then go into WED and attach this action to the model.

For the pistol position : place a bloc in your world and read it's
position from the properties panel. Delete the bloc but hold on to
the coordinates. place these in the script.

Is this what your looking for? smile

Ottawa
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/22/08 01:25

When it comes down to it I was trying to do everything in SED but that action thing sounds easyer I just dont know how to use it if you could so me or point me in the direction of a tutorial cause right now I'm just working off of the Lite-C tutorial knowledge and I thought since the movement script worked for the car .mdl that it would work for the cbabe also.

As for the pistol I used the script in the Lite-C tutorial except for the ent_creat part which as far as I know should work in terms of location on the screen not the lvl. Which brings me to the problem of my pistal code which is I cant figure out were put the ent_creat(----,----,----) and what to put in those blanks?

thanks for answering.
Posted By: Ottawa

Re: First FPS project off to a bad start - 12/22/08 23:46

Hi! smile

Look in the manual under
[b] Attaching entities to each other [\b]
for more information on ACTIONS

Where to put ent_creat : Put it in a function that is part
of the activities that your entity will be doing

[b] Make a plan [\b] of what you want your entity to do... make that a function
and...

Ottawa smile
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/24/08 00:49

Thanks to everyone for your help but my goals are now seeming a little high for my experence so Im gona put this off for now till Im for comfortable with Entity movement.
Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/24/08 00:58

Well it figures that once Im about to give up I solve one of my problems. I was able to get my pistal to show on screen with this code if anyone else was having the same problem.

ENTITY* pistal_ent =

{
type = "pistal.mdl";
layer = 2;
flags2 = VISIBLE;
flags = VISIBLE;
view = camera;
albedo = 50;
x = 100;
y = -50;
z = 0;
}

But Im still gona put this off till I get a little better with Lite-C.
Posted By: Tobias

Re: First FPS project off to a bad start - 12/24/08 09:14

Originally Posted By: OblivionDrake

flags2 = VISIBLE;
flags = VISIBLE;

It's only "flags2 = VISIBLE;" in lite-C. VISIBLE belongs to flags2.

http://manual.conitec.net/aentities-intro.htm

Posted By: OblivionDrake

Re: First FPS project off to a bad start - 12/24/08 19:20

Thanks for clarifying. In my rush I just sliped them both in there just to be safe.
© 2024 lite-C Forums