Mod is a 3d first person game i have started woking on. i am an ok scripter and the 3d/walking script is finished except for the constant bugs i would like some help if possible.
i am also a no use artist so any one in that field would like to help come on.
for the script the 3d script is:
if (PRoom != 0) { // if players room is not equal to 0
RawDrawImage(Player_Facingx-200, Player_Facingy-150, 7);// Print the background
File *input = File.Open(String.Format("%d.rom", PRoom), eFileRead);// open the room file
if (input != null) {
while (!input.EOF) {
String line = input.ReadRawLineBack();
String stew = line.Substring(6, 4);//object pos east west
String stns = line.Substring(10, 4);//object pos north south
String stud = line.Substring(14, 4);// object y pos
String std = line.Substring(18, 4);// size
int size_of_the_object = std.AsInt; // size as int
int in5 = Player_Facingx; // player facing degrees named differently
int in6 = Player_Facingy; // player facing degrees named differently
int inox = 123; // objects east, west pos on map(would usaully be 'int inox = stns.AsInt')
int inoy = 1; // same as above except for it is the objects up/down pos on the map
int inoz = 123; // same as above except fo it is the objects north, south pos on the map
int insupportx = inox-Player_PosEW; // objects ew pos - Players ew pos
int insupportz = inoz-Player_PosNS; // objects ns pos - Players ns pos
int insupporty = inoy-Player_PosY; // objects ud pos - Players ud pos
float fl1 = IntToFloat(insupportx);
float fl2 = IntToFloat(insupportz);
float fl51 = IntToFloat(insupporty);
float fl3 = Maths.ArcTan2(fl1, fl2);
float fl4 = Maths.RadiansToDegrees(fl3);
float fl32 = Maths.ArcTan2(fl1, fl51);
float fl61 = Maths.RadiansToDegrees(fl32);
int in7 = FloatToInt(fl4);
int in71 = FloatToInt(fl61);
if (in7 < in5+200) {
if (in7 > in5-200) {
if (in71 < in5+200) {
if (in71 > in5-200) {
int insupportx1 = Player_PosEW-inox;
int insupportz1 = Player_PosNS-inoz;
int insupporty1 = Player_PosY-inoy;
float fl5 = IntToFloat(insupportx1);
float fl6 = IntToFloat(insupporty1);
float fl8 = Maths.RadiansToDegrees(fl3);
int in8 = FloatToInt(fl8);
float fl7 = Maths.ArcTan2(fl2, fl1);
int support2 = insupportx1*insupportx1;
int support3 = insupporty1*insupporty1;
int support31 = insupportz1*insupportz1;
int support4 = support31+support3+support2;
float support51 = Maths.Sqrt(IntToFloat(support4));
int distance = FloatToInt(support51);
String st1 = "";
int in9 = 0;
st1 = line.Substring(0, 4);
if (line.Contains("tree")!= -1) {
in9 = 8;
st1 = "tree";
}
String st3 = String.Format("%s%04d.bmp", st1, in8);
DynamicSprite* ds = DynamicSprite.CreateFromFile(st3);
String st4 = "";
String st5 = "";
if (ds != null) {
int int1 = ds.Height;
int int2 = ds.Width;
distance = distance/90;
distance++;
size_of_the_object++;
int help1 = (int1/distance)*size_of_the_object;
int help2 = (int2/distance)*size_of_the_object;
if (help1 != 0) {
if (help2 != 0) {
RawDrawImageResized(in5-in7, in6-in71, ds.Graphic, help1, help2);
}
}
debug.Text = String.Format("distance %d, help1 = %d, help2 = %d, width = %d, height = %d, size of the object = %d", distance, help1, help2, int1, int2, size_of_the_object);
ds.Delete();
}
}
}
}
}
}
input.Close();
}
in pics
post either to join the team or with a better script
(http://www.givefilestodad.com.googlepages.com/description.PNG)
thanks
matt
Well, I'd suggest player.Room instead of PRoom variable.
~Trent
What exactly are you saying? And why are you using my name? Blasphemy!
Quote from: Mods on Sun 28/12/2008 19:58:21
And why are you using my name? Blasphemy!
sorry, i didn't realise that there was someone called mod and the game is a mod of another game i started a few months ago.
Quote from: Mods on Sun 28/12/2008 19:58:21
What exactly are you saying? And why are you using my name? Blasphemy!
Looks like you'll have to bring the Zero back into your name, Mods.
I must admit for a second there I was expecting a thread about Mods, the person. But I suppose thats like calling myself "Demo".. ooh that'd be fun. And confusing.
"Ask demo" "What demo?"
can we please get back to the topic
But topic deviations are fun and profitable! I believe it to be the mythological second step, illustrated in the following formula:
Stage 1 - Create topic.
Stage 2 - Deviate from above topic.
Stage 3 - PROFIT.
no comment
Im sorry, I cant hear you over the SOUND OF ALL MY PROFIT.
You gunna share that profit, or are we gunna have to make you?
Quote from: matt on Mon 29/12/2008 00:09:54
can we please get back to the topic
Some further info and/or some screenshots of your game so far would help a lot; I admit that I'd feel more inclined to read through all that code with some VISUALS about what it does. You
know what it does. All we can do is guess.
Quote from: Ghost on Mon 29/12/2008 02:04:08
Quote from: matt on Mon 29/12/2008 00:09:54
can we please get back to the topic
Some further info and/or some screenshots of your game so far would help a lot; I admit that I'd feel more inclined to read through all that code with some VISUALS about what it does. You know what it does. All we can do is guess.
Indeed. Post a screenie, tell us
exactly what the bugs are or, even better, upload an .exe.
Quote from: The Invincible Cardboard Urinal on Mon 29/12/2008 01:37:44
You gunna share that profit, or are we gunna have to make you?
YOU'LL NEVER TAKE ME ALIVE G MAN.
I have no idea what is going on with that code.. And to make things easier on yourself and others, you should definitely think about typing a little description for each variable you declare, etc. Like:
int inoy = 1; //this is the integer telling me where the toilet paper roll is
One thing I did notice. You have declared over 45 variables. Some of them you are even declaring as a "0" or "". I'm not the wisest AGS user, but once you declare a variable, isn't it automatically nothing? Null?
i have up dated it with some visuals and more //'s
Quote from: Mods on Sun 28/12/2008 19:58:21
What exactly are you saying? And why are you using my name? Blasphemy!
No no no... He's only using part of you. Remember, you are plural!
Quote from: matt on Mon 29/12/2008 04:07:30
i have up dated it with some visuals and more //'s
Have you?
sorry i had to go
Quote from: matt on Mon 29/12/2008 07:29:52
sorry i had to go
You made me cry / are a bad person.
Quote from: matt on Mon 29/12/2008 07:29:52
sorry i had to go
You make brave men cry at train stations.
Shouldn't this be in the tech forum, really?
And why is matt thanking himself in his first post?
For answers to these questions, stay tuned for the next exciting episode of Mod!
Thanks for the pic! Now:
Quote from: bicilotti on Mon 29/12/2008 02:18:09
Post a screenie, tell us exactly what the bugs are or, even better, upload an .exe.
which, in so many words, means:
1) Post a screenie
2) tell us
exactly what the bugs are
or, even better, upload an .exe.
Quote from: ProgZmax on Mon 29/12/2008 23:18:03
And why is matt thanking himself in his first post?
He's thanking me for what I was about to do, which was the post containing deviation for profit earlier in this thread.
The update in matt's first post makes me wonder if I should continue on my DigitalDNA(tm) Tank Game Project With Teh Uber Frillz. Math seems to be pretty complicated.
Matt, you are using AGS. And you are, apparently, making some 3D code. How is that supposed to look and/or work? Can you show me a screenshot of your game in action, even with placeholder graphics, so that I can get the inkling of an idea what you're trying to do?
bic, come on. Group hug, but manly!
Thanks for clearing that up for us Matt...
I'm sure someone will whip up a new script in no time...
I wouldn't doubt it...
Seriously...
Anytime now...
Anyone?
Quote from: ProgZmax on Mon 29/12/2008 23:18:03
Shouldn't this be in the tech forum, really?
I don't think so. This thread doesn't like contributing any scripting contents (modules, code snippets, etc.) or a request for technical help. In fact it's more like asking for comments and critics on some ideas, but I doubt it would even fit in C+C. I'd rather leave it alone.
Quote from: ManicMatt on Sun 28/12/2008 23:29:38
I must admit for a second there I was expecting a thread about Mods, the person.
Yeah so was I. Imagine my disappointment when instead of reading about one of AGS’s most beloved members …. I get this, another thread gone horribly wrong.
I would be more than happy to give away all my profit to turn this into a thread about Mods.
All hail Mr Mods!
I keep thinking people are talking to me, when it's the other Matt!
ALL HAIL MODS
MODS IS LIFE
ALL HAIL MODS
MODS IS LIFE
Quote from: ManicMatt on Tue 30/12/2008 22:29:34
I keep thinking people are talking to me, when it's the other Matt!
Well, that's not as confusing as it is to me..
But there can only be one true Matt..... otherwise... I think at least one of them would have had to die. ;D
(http://www.highlanders.co.nz/images/highlander_resam.jpg)
I am Matt Mcloud, who will take me on?!!
Freaked out now ::)
In a good way...
There does seem to be a lot of Matt's around here...ManicMatt...3DMatt....Matzy....Matti.....Matt Mathews Mathewson
Is there a pub near your shop Matt? Maybe in 2009 we could have a day meet and then go to the pub after. Someone else suggested this I'm sure but it could be fun. Providing your stocking a load of decent old adventures at the time ;) I don't think any famous developers are visiting the UK in 09 yet but I'm looking for excuses to do similar things. A "Matt" day would be good hehe.
That would be awesome! There is a bar opposite my shop, actually!
Isn't there a Mats as well?
There is always "The dig" at my shop, as nobody wants to buy it, poor thing.
My shop has statues too! Batman (who we could put some clothes on and make him fatter so he's Fatman.. although i'd rather someone photoshopped him instead), Lara croft, Golemn from LOTR, and a broken Link in the back. (broken link haha, no pun intended)
Oh and Solid Snake.
(http://i16.photobucket.com/albums/b37/manicmatt/DSC00603.jpg)
Are you suggesting the Collective Matt's hold a meet-up event... that could be called MATTENS!!!
I wish I were a Matt.
Hahaha yes, Mattens! Good call Layabout :)
Awesome statue thingies! They're always good for a laugh. Well, sad as I am, come summer, I might just pay you a visit. And I might even buy that Dig copy too, because mine is dead. Is it White Label? Is it the only remaining White Label box in the country? Or is it part of that re-release multipack with something else included. Or is it PRE White Label? That'd be awesome, hehe.
Haha, that would be great! Just make sure Im actually working that day! It's a Lucasarts classic blue case, which is quite boring, to be honest. We do have jewel case "Conspiracy" game still, known as "KGB" on the Amiga. And my copy of So Blonde preowned on the shelf.. come on people, buy it pleeease!
Quote from: Layabout on Thu 01/01/2009 23:15:54
Are you suggesting the Collective Matt's hold a meet-up event... that could be called MATTENS!!!
Too late. There is a Mattens planned for later summer in Burnham :P