ID:268544
 
process?
This is as much as I know..
client
Center()
/*I don't know what to do
from here on down... >_<*/

Help will be appreciated...
Oi, this is one of the few things I don't get...
By default, it stops the player from moving.
Hell Ramen wrote:
process?
This is as much as I know..
> client
> Center()
> /*I don't know what to do
> from here on down... >_<*/

Help will be appreciated...
Oi, this is one of the few things I don't get...

I have never heard about a Center() in the client. is that something new in the lastest Byond version. lol i don't know much about using the client but oh well good luck.
In response to DeathAwaitsU
Okay... let me be more descriptive...
I really want to learn how to make it so "Center" makes the person do things... as in Open Doors.
=/
I hope that's more descriptive.
In response to ElderKain
ElderKain wrote:
Hell Ramen wrote:
process?
This is as much as I know..
> > client
> > Center()
> > /*I don't know what to do
> > from here on down... >_<*/

Help will be appreciated...
Oi, this is one of the few things I don't get...

I have never heard about a Center() in the client. is that something new in the lastest Byond version. lol i don't know much about using the client but oh well good luck.

I was told that Center() is supposed to be put in Client...
In response to Hell Ramen
Hell Ramen wrote:
Okay... let me be more descriptive...
I really want to learn how to make it so "Center" makes the person do things... as in Open Doors.
=/
I hope that's more descriptive.

opening doors..... i don't think that involves a client action. i believe that uses a mob/Bump() action.
In response to Hell Ramen
Center proc (client)
See also:
walk proc
Format:
Center()
When:
Called when the player presses the "center" key or cursor.
Default action:
Cancels any automated movement by calling walk(usr,0).

You can thank mr. Reference, and yeah its a proc in Client according to the reference
In response to N1ghtW1ng
Nono, I want to know how to make Numpad5(the center button) do that. X_X
In response to Hell Ramen
.> oh heh, They have that in alot of games umm...i think i use to remember it involves a macro i think


[Edit]

I searched for the default macro list on Bwicki and the site is http://bwicki.byond.com/ByondBwicki.dmb?DefaultMacros
In response to Hell Ramen
client
Center()
var/turf/door/D
var/Dloc = locate(D.x-1,D.y,D.z)
if(mob.loc==Dloc)
D.open()


That basicly means that if the door is on the right of the client, then it'll call the open process.
In response to N1ghtW1ng
Erm... I mean like..
obj
Door
icon_state = "asdf"
Center()
//Insert door coding here

That's what I mean. X_X
In response to DeathAwaitsU
DeathAwaitsU wrote:
> client
> Center()
> var/turf/door/D
> var/Dloc = locate(D.x-1,D.y,D.z)
> if(mob.loc==Dloc)
> D.open()
>

That basicly means that if the door is on the right of the client, then it'll call the open process.
That brings up horrid errors(In-game) whenever the user presses the center key... X_x
In response to Hell Ramen
it would help you'd tell us those errors.
This is as much as I know..

The reference is your friend.
http://www.byond.com/docs/ref/info.html#/client/proc/Center

If you want help you need to be a bit more specific as to what you don't understand.
In response to DeathAwaitsU
<font color = red>runtime error: Cannot read null.x
proc name: Center (/client/Center)
usr: Hell Ramen (/mob)
src: Hell Ramen (/client)
call stack:
Hell Ramen (/client): Center()</font>
x_x And that's what it says...
In response to ElderKain
ElderKain wrote:
opening doors..... i don't think that involves a client action. i believe that uses a mob/Bump() action.

It can be triggered by whatever you want.
In response to Hell Ramen
Oh sorry

client
Center()
for(var/client/C)//make a variable for the client
for(var/turf/door/D in world)//checks for the door
if(get_dist(C.mob,D) <= 1)//if the distance between the client and the door is less than or equal to 1...
D.open()//call the process to open it. you could also add the door's opening process here if you wanted.
turf/door
proc
open()//the door's opening process
world << "Change this to the actual opening code"
In response to DeathAwaitsU
That is just lag waiting to happen, and will(would) be abused if they caught it. Why loop through all the worlds contents to check for the door, then check the mobs distance from it when you could just loop through the objects in a certain view of the mob?
In response to SSJ2GohanDBGT
Ok then

client
Center()
for(var/client/C)//make a variable for the client
for(var/turf/door/D in oview(1))//checks for the door
D.open()//call the process to open it. you could also add the door's opening process here if you wanted.
turf/door
proc
open()//the door's opening process
world << "Change this to the actual opening code"
In response to DeathAwaitsU
client
Center()
for(var/client/C)
for(var/obj/door/D in oview(1)
D.open
obj
door
proc
open()//the door's opening process
usr << "Whee, test"

And the errors I get...
Game Test.dm:5:error:open :undefined proc
Game Test.dm:5:error::invalid expression

Which is defined as the "D.open" part...
Thanks for your help so far. =/
Page: 1 2