View unanswered posts | View active topics It is currently Sat Dec 28, 2024 4:19 pm



Reply to topic  [ 140 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6 ... 10  Next
 Quick Console Commands 
Author Message
User avatar

Joined: Fri Apr 27, 2007 4:55 pm
Posts: 1178
Location: America!
Reply with quote
Post Re: Quick Console Commands
Huh, AddParticle works? Cause so does AddMO.


Sun Aug 24, 2008 5:55 pm
Profile
User avatar

Joined: Fri Jan 26, 2007 3:22 am
Posts: 1451
Reply with quote
Post Re: Quick Console Commands
Yeah. You can enumerate MovableMan.Particles too. Kylegar is just DUMB and doesn't know how to enumerate obviously.


Sun Aug 24, 2008 6:29 pm
Profile

Joined: Thu Aug 21, 2008 2:19 am
Posts: 14
Reply with quote
Post Re: Quick Console Commands
Daman wrote:
Yeah. You can enumerate MovableMan.Particles too. Kylegar is just DUMB and doesn't know how to enumerate obviously.


Wow, just...Wow

If there are no particles on the scene, MovableMan.Particles returns nil, not an empty table.

gg though

EDIT: and its not Enumerate, its Iterate. Enumerate means to assign a number to it.


Sun Aug 24, 2008 7:05 pm
Profile
User avatar

Joined: Sat Nov 03, 2007 9:44 pm
Posts: 1916
Location: Flint Hills
Reply with quote
Post Re: Quick Console Commands
How would one go about changing the angle/angular velocity of objects?
In analogy form,
Velocity is to Vel as Angular Velocity is to ___?
Position is to Pos as Angle is to ___?

Also what would be the equivalent of this
Code:
    for actor in MovableMan.Actors do
        if SceneMan.Scene:WithinArea("areaname", actor.Pos) then

but for all mass objects?


Sun Aug 24, 2008 11:02 pm
Profile
User avatar

Joined: Fri Jan 26, 2007 3:22 am
Posts: 1451
Reply with quote
Post Re: Quick Console Commands
MadKylegar wrote:
Daman wrote:
Yeah. You can enumerate MovableMan.Particles too. Kylegar is just DUMB and doesn't know how to enumerate obviously.


Wow, just...Wow

If there are no particles on the scene, MovableMan.Particles returns nil, not an empty table.

gg though

EDIT: and its not Enumerate, its Iterate. Enumerate means to assign a number to it.


To specify each member of a sequence individually in incrementing order; To determine the amount of

Hi I'm kylegar and know nothing?

It's ok though I know you're trying to cover your ass after being completely wrong on IRC. Just stick with handing Tim copypasted Lua, it's the best option when trying to be correct.

Oh and by the way--

Image


Last edited by Daman on Mon Aug 25, 2008 12:45 am, edited 1 time in total.



Mon Aug 25, 2008 12:19 am
Profile
User avatar

Joined: Wed Dec 27, 2006 10:05 pm
Posts: 100
Reply with quote
Post Re: Quick Console Commands
azzuki,
Code:
for actor in MovableMan.MOs do if SceneMan.Scene:WithinArea("areaname") then actor


Mon Aug 25, 2008 12:45 am
Profile

Joined: Thu Aug 21, 2008 2:19 am
Posts: 14
Reply with quote
Post Re: Quick Console Commands
Daman wrote:
MadKylegar wrote:
Daman wrote:
Yeah. You can enumerate MovableMan.Particles too. Kylegar is just DUMB and doesn't know how to enumerate obviously.


Wow, just...Wow

If there are no particles on the scene, MovableMan.Particles returns nil, not an empty table.

gg though

EDIT: and its not Enumerate, its Iterate. Enumerate means to assign a number to it.


To specify each member of a sequence individually in incrementing order; To determine the amount of

Hi I'm kylegar and know nothing?

It's ok though I know you're trying to cover your ass after being completely wrong on IRC. Just stick with handing Tim copypasted Lua, it's the best option when trying to be correct.

Oh and by the way--

Image



Iterate: To say or perform again; repeat.
For is an Iterative loop, in the code
Code:
 for Actors in MovableMan.Actors do Actors:GibThis() end

You are Iterationg through MovableMan.Actors and doing the GibThis() on every Actor in the table.

Enumerate: to ascertain the number of And to specify one after another (From http://www.merriam-webster.com/dictionary/enumerate).

Meaning, You are assigning or getting the number of that object.

in the code
Code:
for k , v in ipairs(TableHere) do print(k,v) end

K would be the enumeration, because ipairs only iterates through keys with an interger value.

Also, in C++, an Enumeration is a interger type variable, so the code:
Code:
enum TestEnum
{
Run = 1,
Walk,
Stand,
Die,
Whatever
};

means that each of those interger type variables, (Run, Walk, Stand, Die, Whatever) is a value of LastEnum+1, or, in this cames, Run == 1, Walk == 2, Stand == 3, Die == 4, Whatever == 5.

CC's Lua uses Enumerations as Teams, Types of Controllers, and Types of Activites, and Players.
If you were to print one of the enumerations (Lets say, Activity.PLAYER_1), you would probably get a number, like 1.

That my friend, is an enumeration.


Also, with your picture, there is obviously particles in the world scene somewere (Dropships coming down from the sky?) and its returning those.

Like I said, when theres no particles, it returns nil, not an empty table. You haven't proved to me that it doesn't, only proved to me that you didn't check for that case, and are trying to scrape up an arguement as to why I'm dumb. The only thing you have succeeded in doing is looking like an ass, and someone who doesn't know what hes talking about.


Mon Aug 25, 2008 1:23 am
Profile
User avatar

Joined: Fri Jan 26, 2007 3:22 am
Posts: 1451
Reply with quote
Post Re: Quick Console Commands
That's not even what the argument is about, fairweather argument starter. You didn't say OH UH IT JUST RETURNS AN EMPTY TABLE BECAUSE THERE'S NOTHING HAPPENING ON MINE the night before. Hurrr. Stop trying to change your view. Great job making yourself look even more dumb.

You said MovableMan.Particles doesn't do anything. When it clearly did. I said no, I just used it to count the 189 particles on my screen.

Oh hey wait-- 189 particles. I enumerated. To ascertain the value of.

Hey great job typing all that to prove yourself wrong.


Mon Aug 25, 2008 1:32 am
Profile

Joined: Thu Aug 21, 2008 2:19 am
Posts: 14
Reply with quote
Post Re: Quick Console Commands
Daman wrote:
That's not even what the argument is about, fairweather argument starter. You didn't say OH UH IT JUST RETURNS AN EMPTY TABLE BECAUSE THERE'S NOTHING HAPPENING ON MINE the night before. Hurrr. Stop trying to change your view. Great job making yourself look even more dumb.

You said MovableMan.Particles doesn't do anything. When it clearly did. I said no, I just used it to count the 189 particles on my screen.

Oh hey wait-- 189 particles. I enumerated. To ascertain the value of.

Hey great job typing all that to prove yourself wrong.


What?

EDIT: Oh, I did say that there were no particles in my game, and that it returned nil instead of an empty table. My code was:
Code:
print(type(MovableMan.Particles))

and it returned nil.

In the middle of the game, I did that code again, and it returned function (That confuses me as to why MovableMan.Particles returns function and not table...check it out yourself.)
Edit2: Huh, For In statements work over functions called Iterators http://www.lua.org/manual/5.1/manual.html#2.4.5


Mon Aug 25, 2008 1:37 am
Profile
User avatar

Joined: Fri Jan 26, 2007 3:22 am
Posts: 1451
Reply with quote
Post Re: Quick Console Commands
MadKylegar wrote:
Daman wrote:
That's not even what the argument is about, fairweather argument starter. You didn't say OH UH IT JUST RETURNS AN EMPTY TABLE BECAUSE THERE'S NOTHING HAPPENING ON MINE the night before. Hurrr. Stop trying to change your view. Great job making yourself look even more dumb.

You said MovableMan.Particles doesn't do anything. When it clearly did. I said no, I just used it to count the 189 particles on my screen.

Oh hey wait-- 189 particles. I enumerated. To ascertain the value of.

Hey great job typing all that to prove yourself wrong.


What?

EDIT: Oh, I did say that there were no particles in my game, and that it returned nil instead of an empty table. My code was:
Code:
print(type(MovableMan.Particles))

and it returned nil.

In the middle of the game, I did that code again, and it returned function (That confuses me as to why MovableMan.Particles returns function and not table...check it out yourself.)


They're both functions. They are probably set when a game is started.

Quote:
Edit2: Huh, For In statements work over functions called Iterators http://www.lua.org/manual/5.1/manual.html#2.4.5


Hey guys I'm going to call if then else statements in my programming language ♥♥♥♥ CHECKS and that means using them means you're ♥♥♥♥ checking it's in the dictionary you guys.


Mon Aug 25, 2008 2:17 am
Profile
User avatar

Joined: Sat Nov 03, 2007 9:44 pm
Posts: 1916
Location: Flint Hills
Reply with quote
Post Re: Quick Console Commands
casey wrote:
azukki,
Code:
for actor in MovableMan.MOs do if SceneMan.Scene:WithinArea("areaname") then actor

Not working for me. Is this right? It works fine for actors when "MOs" is "Actors"
Code:
    for actor in MovableMan.MOs do
        if SceneMan.Scene:WithinArea("bounce", actor.Pos) then
         actor.Vel.Y = actor.Vel.Y * -0.95;      
        end   
    end


Mon Aug 25, 2008 2:27 am
Profile

Joined: Thu Aug 21, 2008 2:19 am
Posts: 14
Reply with quote
Post Re: Quick Console Commands
Daman wrote:
Hey guys I'm going to call if then else statements in my programming language walrus CHECKS and that means using them means you're walrus checking it's in the dictionary you guys.


Great arguement...If you didn't know that the term Iterator is a standard across most programming languages:
http://www.cppreference.com/iterators.html
http://java.sun.com/j2se/1.4.2/docs/api ... rator.html
http://msdn.microsoft.com/en-us/library/dscyy5s0.aspx

Theres a few examples.


Mon Aug 25, 2008 2:41 am
Profile
User avatar

Joined: Fri Jan 26, 2007 3:22 am
Posts: 1451
Reply with quote
Post Re: Quick Console Commands
MadKylegar wrote:
Daman wrote:
Hey guys I'm going to call if then else statements in my programming language walrus CHECKS and that means using them means you're walrus checking it's in the dictionary you guys.


Great arguement...If you didn't know that the term Iterator is a standard across most programming languages:
http://www.cppreference.com/iterators.html
http://java.sun.com/j2se/1.4.2/docs/api ... rator.html
http://msdn.microsoft.com/en-us/library/dscyy5s0.aspx

Theres a few examples.


Who cares. Java is not even a real language. You must have some kind of extra 21st chromosome if you think it is.

And by the way I said you can't enumerate properly which is done using for in so uh great job arguing that for is an iterator to yourself. It's not even relevant.

I'm right as usual though. Nice one.


Mon Aug 25, 2008 2:56 am
Profile
User avatar

Joined: Sat Dec 02, 2006 11:51 pm
Posts: 204
Reply with quote
Post Re: Quick Console Commands
is it just me or is damen a bit more dickish then usual.


Mon Aug 25, 2008 3:28 am
Profile WWW
User avatar

Joined: Sun Dec 09, 2007 3:31 pm
Posts: 19
Reply with quote
Post Re: Quick Console Commands
Daman wrote:
Who cares. Java is not even a real language. You must have some kind of extra 21st chromosome if you think it is.

And by the way I said you can't enumerate properly which is done using for in so uh great job arguing that for is an iterator to yourself. It's not even relevant.

I'm right as usual though. Nice one.

Please stop posting, you've ignored half the valid points he's made and instead spew pointless insults and self-contradictions.


Mon Aug 25, 2008 3:28 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 140 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6 ... 10  Next

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.043s | 14 Queries | GZIP : Off ]