Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   move dx,dy,time,options; (https://forums.graalonline.com/forums/showthread.php?t=46642)

Chrisz 07-30-2003 10:08 PM

move dx,dy,time,options;
 
x.x This command is STRANGE >:O

move dx,dy,time,options

time = speed / dist;

Well in graal thats not the case, something is wrong.. :\

NPC Code:

if (created) {
this.speed = 2;
this.options = 1;
Move();
}
function Move() {
dx = int(random(-5,5)*2)/2;
dy = int(random(-5,5)*2)/2;
dist = (dx*dx+dy*dy/)^0.5;
time = this.speed/dist;
move dx,dy,time,this.options;
sleep time+0.1;
Move();
}



Nice little snippet that doesnt work properly, it either goes really slow or really fast, and it has confused Chrisz. I want the speed to work like... normal?? x.x;

Alexander 07-30-2003 10:49 PM

Re: move dx,dy,time,options;
 
Quote:

Originally posted by Chrisz

time = speed / dist;

Silly Chrisz, isn't time distance devided my speed o.O

Tseng 07-30-2003 11:01 PM

Re: Re: move dx,dy,time,options;
 
Quote:

Originally posted by Alexander


isn't time distance devided my speed o.O

Yes, it is.

tlf288 07-31-2003 12:34 AM

I don't think anyone has really put any good use into the command move other than the Kingdoms furniture movement system. Atleast, that is the only thing I have saw that uses it well.

Tseng 07-31-2003 12:35 AM

Quote:

Originally posted by tlf288
I don't think anyone has really put any good use into the command move other than the Kingdoms furniture movement system. Atleast, that is the only thing I have saw that uses it well.
Uh...you mean...2k1's villa furniture movement system...

2k2's just warps it to the new location when you move it with the mouse...

tlf288 07-31-2003 01:00 AM

Quote:

Originally posted by Tseng


Uh...you mean...2k1's villa furniture movement system...

Never seen it :\ .


Quote:


2k2's just warps it to the new location when you move it with the mouse...

It sures looks like it uses move to me. But then again, I haven't seen it since it was first realesed considering I never play Kingdoms. Are you sure about what you said Tseng? I can almost remember it perfectly, but I could be wrong.

Tseng 07-31-2003 01:05 AM

Quote:

Originally posted by tlf288
It sures looks like it uses move to me. But then again, I haven't seen it since it was first realesed considering I never play Kingdoms. Are you sure about what you said Tseng? I can almost remember it perfectly, but I could be wrong.
Um, I'm moving furniture around right now. It warps it.

2k1's uses the move command.

Loriel 07-31-2003 03:04 AM

move is pretty useful, and still, time is distance divided by speed. Otherwise, you would arrive earlier if you travelled farther.

tlf288 07-31-2003 04:25 AM

Quote:

Originally posted by Tseng


Um, I'm moving furniture around right now. It warps it.

Then it used to use the move command. I am almost 100% sure it did.

screen_name 07-31-2003 07:25 AM

Quote:

Originally posted by tlf288


Then it used to use the move command. I am almost 100% sure it did.

Why on earth would you use the move command when it just reloactes it? Move is not used and if it were, it isn't necessary.

Tseng 07-31-2003 07:27 AM

Quote:

Originally posted by screen_name


Why on earth would you use the move command when it just reloactes it? Move is not used and if it were, it isn't necessary.

The 2k1 villa system uses move...it adds a nice effect. :)

tlf288 07-31-2003 07:36 AM

Quote:

Originally posted by screen_name


Why on earth would you use the move command when it just reloactes it? Move is not used and if it were, it isn't necessary.

Because it looks cool, dude.

TribulationStaff 07-31-2003 07:43 AM

Just to show off a little ;)


I think Stefan was very clever in his design of move options, showstats and other similar functions. He relied on the linear independance of x,x^2,...x^n to guarantee that no matter what combination of options you choose, you never get two that have the same sum.

Props also to Kai, for I recall he used the same property for one of his scripts.

Kaimetsu 07-31-2003 07:52 AM

Quote:

Originally posted by TribulationStaff
Props also to Kai, for I recall he used the same property for one of his scripts.
It's pretty fundamental thing in Computer Science, of course. The move options are equivalent to a one-byte flag with individual bits representing different options (though the concept is clearer in enablefeatures).

TribulationStaff 07-31-2003 08:00 AM

I suppopse it would be, but to a mathematician, its something you don't see until late sophomore or early junior year.

tlf288 07-31-2003 08:04 AM

Quote:

Originally posted by TribulationStaff

Props also to Kai, for I recall he used the same property for one of his scripts.

Hey, I did it before to!

Kaimetsu 07-31-2003 08:04 AM

Quote:

Originally posted by TribulationStaff
I suppopse it would be, but to a mathematician, its something you don't see until late sophomore or early junior year.
No? I would think it would be obvious as soon as the person is taught about different numeric bases. Personally I invented the principle for myself when I was working on a VB project four years ago ^_^

TribulationStaff 07-31-2003 08:10 AM

Well, linear independance of sets, and set theory at all, for that matter, isn't discussed at all until college. In fact, I would be surprised if any pure mathematics beyond geometry is taught anywhere in the USA's K-12 educational system.

Kaimetsu 07-31-2003 08:15 AM

Quote:

Originally posted by TribulationStaff
Well, linear independance of sets, and set theory at all, for that matter, isn't discussed at all until college. In fact, I would be surprised if any pure mathematics beyond geometry is taught anywhere in the USA's K-12 educational system.
Perhaps so; I wasn't taught true set theory until partway into my CS degree. On the other hand, set theory is just a way to describe the property in a formal fashion. You can understand it intuitively without being able to represent it mathematically.

tlf288 07-31-2003 08:17 AM

Quote:

Originally posted by TribulationStaff
In fact, I would be surprised if any pure mathematics beyond geometry is taught anywhere in the USA's K-12 educational system.
We have Trig and Calc in my highschool, dude.

TribulationStaff 07-31-2003 08:26 AM

Calculus is an applied math. Calculus is the math behind a great deal of physics and engineering. Admittedly, geometry is too, but the proofs learned in geometry are pure math.

As for trig, well it is an applied math too. All sorts of physical things like sextants are based on trigonometry.

tlf288 07-31-2003 08:43 AM

So, you're saying calculus and trig just tell you how to apply what you already know?

Projectshifter 07-31-2003 08:43 AM

Wow, you guys are getting too deep into math =p
I forgot about the move command o_O... perhaps it will actually be less laggy and more efficient in a baddy.... [ponder]...[/ponder]
I don't really like doing things that move, and I've been meaning to make a baddy forever, but everytime I start I hate it... Maybe move would be beneficial XP.
---Shifter

TribulationStaff 07-31-2003 08:45 AM

Quote:

So, you're saying calculus and trig just tell you how to apply what you already know?
It's a fuzzy line to be sure, but basically, pure math consists of things, like proofs, which have absolutely no relation to reality. Was it Hardy who said that the less math has to do with reality the more beautiful it becomes? Applied maths are basically things, like calculus, that you can use in word problems.

Kaimetsu 07-31-2003 08:47 AM

Quote:

Originally posted by TribulationStaff
It's a fuzzy line to be sure, but basically, pure math consists of things, like proofs, which have absolutely no relation to reality. Was it Hardy who said that the less math has to do with reality the more beautiful it becomes? Applied maths are basically things, like calculus, that you can use in word problems.
I don't like such definitions. If somebody suddenly found a practical use for an area of pure maths, would it suddenly become applied? Maths shouldn't be classified by how it is used.

tlf288 07-31-2003 08:51 AM

Quote:

Originally posted by Projectshifter
Wow, you guys are getting too deep into math =p
I forgot about the move command o_O... perhaps it will actually be less laggy and more efficient in a baddy.... [ponder]...[/ponder]
I don't really like doing things that move, and I've been meaning to make a baddy forever, but everytime I start I hate it... Maybe move would be beneficial XP.
---Shifter

For something like a baddie you end up using the move command just like setting the x and y positions. Contact me on AIM if you want a script I made using the move command like you want to.

TribulationStaff 07-31-2003 08:52 AM

Quote:

Originally posted by Kaimetsu


I don't like such definitions. If somebody suddenly found a practical use for an area of pure maths, would it suddenly become applied? Maths shouldn't be classified by how it is used.

:grin:

Actually that has happened. Boolean algebra lay useless for about a century until computers were invented.

Also, tell that to the mathematicians. Pure mathematicians have a tendency to look down their noses at applied mathematicians like myself. And applied mathematicians tend to wonder why you need more than one way to prove that the square root of two is irrational.

Kaimetsu 07-31-2003 09:06 AM

Quote:

Originally posted by TribulationStaff
Pure mathematicians have a tendency to look down their noses at applied mathematicians like myself. And applied mathematicians tend to wonder why you need more than one way to prove that the square root of two is irrational.
Man, mathematicians are dorks. I'm glad I jumped off that train when I did.

TribulationStaff 07-31-2003 11:31 PM

*ponders*

Is being called a dork by a geek a good thing or a bad thing? Lol.

Is it a cool thing, like being called a mf by George Carlin?

[edit] Yes, Kai you are a geek. If you are the best scripter in any computer language you automatically qualify as a computer geek. Hooray for geeks :D [/edit]:

Projectshifter 08-01-2003 05:37 AM

Complex mathmatics are pointless to majority of people. Good thing there are people like Kai to bug ;)
---Shifter

TribulationStaff 08-01-2003 06:19 AM

*cough cough*

;)

Soul-Blade 08-01-2003 10:54 AM

This thread has explained why I don't plan on learning a ton more about math after high school, and why I intend to forsake the computer world aside from graphics all around. :grin:

Chrisz 08-04-2003 02:25 AM

*hasnt read all the posts* yes i know t = s/d but tried lots of things :(.. so i moved them around and stuff :P but we got it fixed... :)... weird command..

screen_name 08-04-2003 03:23 AM

Quote:

Originally posted by tlf288


Because it looks cool, dude.

Are you truely retarded? All it does it moves it from point A to point B, almost instantly. How does that look cool?

Tseng: It did add a nice effect to the Villa, but for why would it be used for GK?


All times are GMT +2. The time now is 11:03 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.