Author Topic: Taking data from dump();  (Read 1387 times)

Can someone please bestow on me the knowledge of taking data from dump(); and putting the wanted data into variables.

For example. I might want to getid someone without looking at them. So I dump their information and extract the id into a variable then display it with

messageclient(%cl,' ',%plid);

You... kinda need the ID to dump it in the first place.

In fact, everything that shows up in dump is already accessible without using dump.

I don't understand what you mean. Please explain further in depth for me. I am not used to programming in C++.
Can you give me an example of what I want if it's possible.

You know I mean the /getid ##, not the BL_ID of the player, right?

I am not used to programming in C++.
Be happy that we don't use C++.

I thought Blockland was programmed in C++ using torque engine syntax or something.

Quote
About TorqueScript?

What is Torque's scripting language like? TorqueScript is a very powerful, flexible language with syntax similar to C++. It provides all of the features listed above, including those on the 'would be nice' list. The following sections will describe all of these features and provide examples to clarify concepts. Additionally, there are scripting references in the appendix.
My bad...

I still need the information on the dump();
« Last Edit: January 21, 2013, 09:14:21 AM by Piston1337 »

Stop trying to get help on the crappy way you are trying to go, instead tell us what the goal is so we can tell you the right way.

You know how if you were to type findclientbyname("Badspot").dump();
it will give you a bunch of information on the player, "Badspot"

And you know if you were to be looking at Badspot and type into the chat /getid
it would give you Badspot's numberthingy which you can use for like '586362.player.addvelocity("0 0 200");'

Basically I want to make a function like where you can do a servercmd and get the numberthingy without looking at the player.
for example I type into the chat /locateid Badspot and it will get me Badspot's /getid, numberthingy...thingy :)

You know how if you were to type findclientbyname("Badspot").dump();
it will give you a bunch of information on the player, "Badspot"

And you know if you were to be looking at Badspot and type into the chat /getid
it would give you Badspot's numberthingy which you can use for like '586362.player.addvelocity("0 0 200");'

Basically I want to make a function like where you can do a servercmd and get the numberthingy without looking at the player.
for example I type into the chat /locateid Badspot and it will get me Badspot's /getid, numberthingy...thingy :)
Just do findClientByName("Badspot").player.addVelocity("0 0 200");

No, that was an example. I want the /getid into a variable.

No, that was an example. I want the /getid into a variable.
findClientByName returns their client object.

You know how when you type /getid the object ID comes up? I want to put that ID into a Variable

You know how when you type /getid the object ID comes up? I want to put that ID into a Variable
%exampleVar = findClientbyName(NAME);

%exampleVar = findClientbyName(NAME);
And that will get me the same numbers as /getid?

You know how if you were to type findclientbyname("Badspot").dump();
it will give you a bunch of information on the player, "Badspot"
You didn't understand the differences between a client, a player, and a string.

Oh, jee. Im sorry for not having a primary resource of learnings, khow2code.