Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Closed Thread
 
Thread Tools Search this Thread Display Modes
  #1  
Old 04-16-2004, 02:58 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
Heh my bum bot, a class, decides to quit working after a while

Well my remote control bum works for a couple seconds(random short couple seconds), and im not sure why it just stops working. basically help.
NPC Code:

if (playerchats&&strequals(#c,/bum boom)&&strequals(#a,gman4pwnu)){
destroy;
}

if (created){
setshape 1,32,48;
}

if (actionmoveplace){
if (strequals(#p(0),up)){
dir=0;
setcharani walk,;
move 0,-.8,.1,;
sleep .1;
setcharani idle,;
} else
if (strequals(#p(0),left)){
dir=1;
setcharani walk,;
move -.8,0,.1,;
sleep .1;
setcharani idle,;
} else
if (strequals(#p(0),down)){
dir=2;
setcharani walk,;
move 0,.8,.1,;
sleep .1;
setcharani idle,;
} else
if (strequals(#p(0),right)){
dir=3;
setcharani walk,;
move .8,0,.1,;
sleep .1;
setcharani idle,;
}
}

//#CLIENTSIDE
if (created) {
setshape 1,32,48;
showcharacter;
setcharprop #3,head13.png;
setcharprop #C0,orange;
setcharprop #C1,gray;
setcharprop #C2,gray;
setcharprop #C3,white;
setcharprop #C4,lightgray;
setcharprop #n,Bum;
setcharprop #2,no-shield.gif;
shieldpower = 1;
dir = 2;
timeout=.05;
}

if (timeout){
if (strequals(#a,gman4pwnu)){
if (keydown(0)){
triggeraction x+.5,y+.5,moveplace,up;
} else
if (keydown(1)){
triggeraction x+.5,y+.5,moveplace,left;
} else
if (keydown(2)){
triggeraction x+.5,y+.5,moveplace,down;
} else
if (keydown(3)){
triggeraction x+.5,y+.5,moveplace,right;
}
}
timeout=.1;
}


  #2  
Old 04-16-2004, 03:07 AM
osrs osrs is offline
Graalian since 1998
osrs's Avatar
Join Date: Mar 2002
Location: Brazil
Posts: 2,724
osrs is on a distinguished road
Send a message via ICQ to osrs Send a message via AIM to osrs Send a message via MSN to osrs Send a message via Yahoo to osrs
Quote:
Rules:

1) Don't post here just asking for scripts, or asking for people to fix scripts that are beyond your skill level. The posters here aren't just some handy resource for scripting shortcuts. If you can't script something then don't try to produce it. If you're trying to make it to aid your learning then set your sights lower. If you want it for a server then go get a NAT. Likewise, don't post whole scripts for people. Post wordy solutions, certainly, but not things that people can just copy & paste into their levels without any effort.
Follow the rules. You will never learn if you always runs here and post your whole script and tell people to fix it. x-x'

Note: Remember that minimum timeout that can be used client-side is 0.05;
__________________
"Ability is what you are capable of doing. Motivation determines what you do. Attitude determines how well you do it."
Facebook: facebook.com/raysilvadotnet /
  #3  
Old 04-16-2004, 03:12 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
i didn't know .10 is below .05.

before trying to make me look like an idiot, look at what you typed or you might just be doin that to yourself.

oh and go to atrius, yea, look at every script there, just about every single script created by me excluding the gang system and several guns. Im pretty sure this is my skill level. What im not understanding is why does the timeout quit working after a while.

Im not asking to fix it, tell me where I said that, im asking why it stops working.
  #4  
Old 04-16-2004, 03:44 AM
DarkShadows_Legend DarkShadows_Legend is offline
Cult of the Winky
DarkShadows_Legend's Avatar
Join Date: Apr 2003
Location: Florida
Posts: 614
DarkShadows_Legend is on a distinguished road
Send a message via AIM to DarkShadows_Legend
NPC Code:
sleep real;


That tends to break a lot of my loops so I use a different method for slowing down instead of using sleep now.
I don't know if that is the problem though. Maybe someone can comment on that.
__________________
- Criminal X

"I rather be hated for being myself, than be liked for being what you like best. I go above the influence, not under." - Me
  #5  
Old 04-16-2004, 03:52 AM
screen_name screen_name is offline
is watching you
Join Date: Mar 2002
Location: The 3rd Dimension
Posts: 2,160
screen_name is on a distinguished road
Send a message via AIM to screen_name Send a message via MSN to screen_name
Quote:
Originally posted by Gman4pwnu
i didn't know .10 is below .05.

before trying to make me look like an idiot, look at what you typed or you might just be doin that to yourself.
Enough said?
__________________
[signature]insert here[/signature]
  #6  
Old 04-16-2004, 04:09 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
I removed the sleep but it still doesn't work right. Its a Class just so you know
  #7  
Old 04-16-2004, 05:05 AM
DIABLO2099 DIABLO2099 is offline
Registered User
Join Date: Sep 2002
Location: New York
Posts: 290
DIABLO2099 is on a distinguished road
NPC Code:
triggeraction x+.5,y+.5,moveplace,,up;


Hm, try doing that. (Remember to switch the others as well.)
__________________
-Former UnholyNation Server Manager.

Call me Xecutor.
  #8  
Old 04-16-2004, 05:25 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
and how would this change anything? Besides making me change all my parameters #'s and adding a comma in each trigger action it did absolutely nothing.
  #9  
Old 04-16-2004, 05:43 AM
DIABLO2099 DIABLO2099 is offline
Registered User
Join Date: Sep 2002
Location: New York
Posts: 290
DIABLO2099 is on a distinguished road
No, don't change the parameter numbers in the actions serverside. I've tried something like this before and the script didn't recognize the position where the weapon paremeter is as the parameter with the index 0, just something to try >.>.
__________________
-Former UnholyNation Server Manager.

Call me Xecutor.
  #10  
Old 04-16-2004, 06:44 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
It really didn't change anything except that It wont move with diff param number than triggeraction param position. What it does how i have it, is it goes for a random amount of seconds works perfect, then it says FU i quit.
  #11  
Old 04-16-2004, 08:34 AM
R0bin R0bin is offline
Banned
R0bin's Avatar
Join Date: Oct 2002
Location: Wales, UK
Posts: 828
R0bin is on a distinguished road
Send a message via AIM to R0bin
that whole thing could be serversided.
have a serverside loop of maybe 1 or 2 seconds, and make it getplayer(youraccount) and just make thiso.newdir=playerdir; then outside the with, have a function with like
move vecx(thiso.newdir),vecy(thiso.newdir),0.5,1;
  #12  
Old 04-16-2004, 09:08 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
Strange, setting it to move by .5 or 1 or 2, it never froze.
  #13  
Old 04-16-2004, 02:09 PM
Spark910 Spark910 is offline
Ex-Graal Global
Spark910's Avatar
Join Date: Oct 2001
Location: England
Posts: 10,892
Spark910 has a spectacular aura about
hmm.. why do you need/want a 'bum bot'
__________________
--Spark911
  #14  
Old 04-16-2004, 02:53 PM
VeX_RaT_Boy VeX_RaT_Boy is offline
WannaBe Scripter
VeX_RaT_Boy's Avatar
Join Date: Aug 2002
Location: Norway
Posts: 960
VeX_RaT_Boy is on a distinguished road
Send a message via ICQ to VeX_RaT_Boy Send a message via AIM to VeX_RaT_Boy Send a message via Yahoo to VeX_RaT_Boy
Quote:
Originally posted by Gman4pwnu
Strange, setting it to move by .5 or 1 or 2, it never froze.
That's what I told you on AIM! Serverside the coordinates is only every .5 (0.5, 1, 1.5, 2, 2.5 and so on)....So that's why.
__________________
-Kjetil Valen
  #15  
Old 04-16-2004, 06:52 PM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
Yes i know, sorry I forgot to give you credit, but thanks so much! Now I can work on my car.
  #16  
Old 04-16-2004, 07:00 PM
osrs osrs is offline
Graalian since 1998
osrs's Avatar
Join Date: Mar 2002
Location: Brazil
Posts: 2,724
osrs is on a distinguished road
Send a message via ICQ to osrs Send a message via AIM to osrs Send a message via MSN to osrs Send a message via Yahoo to osrs
Quote:
Originally posted by Gman4pwnu
i didn't know .10 is below .05.
Eh, i misread the number.

Quote:

before trying to make me look like an idiot, look at what you typed or you might just be doin that to yourself.
That was not my intention, i was just trying you make you use your brain, by the way, i think you are an idiot now, because you seem to do not like to use your brain. (If you have one)

Quote:

oh and go to atrius, yea, look at every script there, just about every single script created by me excluding the gang system and several guns. Im pretty sure this is my skill level. What im not understanding is why does the timeout quit working after a while.
Oh yea, you seem to be a great scripter.

Quote:

Im not asking to fix it, tell me where I said that, im asking why it stops working.
You should have posted the part that you think that is bugging, not the whole code?
__________________
"Ability is what you are capable of doing. Motivation determines what you do. Attitude determines how well you do it."
Facebook: facebook.com/raysilvadotnet /
  #17  
Old 04-16-2004, 07:09 PM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
String Based Item System, Drop System, Inventory System, HP System, Day Night System, in works a movement system, A swear filter that I scrapped, Housing System using database, Item sell class, Safes using database, Stocking item class, Stocking using database, a lottery, a working car thats a class.

A few of the things i did on atrius.... Either help or **** off, thanks.
  #18  
Old 04-16-2004, 07:11 PM
osrs osrs is offline
Graalian since 1998
osrs's Avatar
Join Date: Mar 2002
Location: Brazil
Posts: 2,724
osrs is on a distinguished road
Send a message via ICQ to osrs Send a message via AIM to osrs Send a message via MSN to osrs Send a message via Yahoo to osrs
Quote:
Originally posted by Gman4pwnu
String Based Item System, Drop System, Inventory System, HP System, Day Night System, in works a movement system, A swear filter that I scrapped, Housing System using database, Item sell class, Safes using database, Stocking item class, Stocking using database, a lottery, a working car thats a class.

A few of the things i did on atrius.... Either help or **** off, thanks.
I tried to help with a suggestion, but your ignorance failed to notice.
Ow, lots of systems, congratulations.
__________________
"Ability is what you are capable of doing. Motivation determines what you do. Attitude determines how well you do it."
Facebook: facebook.com/raysilvadotnet /
  #19  
Old 04-16-2004, 09:47 PM
screen_name screen_name is offline
is watching you
Join Date: Mar 2002
Location: The 3rd Dimension
Posts: 2,160
screen_name is on a distinguished road
Send a message via AIM to screen_name Send a message via MSN to screen_name
Quote:
Originally posted by Gman4pwnu
String Based Item System, Drop System, Inventory System, HP System, Day Night System, in works a movement system, A swear filter that I scrapped, Housing System using database, Item sell class, Safes using database, Stocking item class, Stocking using database, a lottery, a working car thats a class.

A few of the things i did on atrius.... Either help or **** off, thanks.

You've scripted all these things, but yet, you are still unable to find your own problems, that aren't that complex?
__________________
[signature]insert here[/signature]
  #20  
Old 04-16-2004, 09:59 PM
Dach Dach is offline
call me Chad, it's cooler
Dach's Avatar
Join Date: Aug 2002
Posts: 1,899
Dach is on a distinguished road
meh, you really ought to learn how to debug

go into the offline editor(if you're afraid of killing the npc server) and try things out before calling it quits
__________________
Scripting Documents:Old Script Documentation-Movement Tutorial
  #21  
Old 04-16-2004, 10:01 PM
screen_name screen_name is offline
is watching you
Join Date: Mar 2002
Location: The 3rd Dimension
Posts: 2,160
screen_name is on a distinguished road
Send a message via AIM to screen_name Send a message via MSN to screen_name
Another thing also, learn how to optimize your scripts. The above script could use that.
__________________
[signature]insert here[/signature]
  #22  
Old 04-17-2004, 08:46 AM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
hey chad, I go into offline mode a lot, and use the test button and the style button. Screen_name, i doubt you even script ive never seen a post of yours on this forum, then again i havn't looked here in a while.
  #23  
Old 04-17-2004, 01:01 PM
WanDaMan WanDaMan is offline
Master Tux
WanDaMan's Avatar
Join Date: Aug 2002
Location: England, United Kingdom
Posts: 5,571
WanDaMan is a jewel in the roughWanDaMan is a jewel in the rough
Send a message via MSN to WanDaMan
Quote:
Originally posted by Gman4pwnu
hey chad, I go into offline mode a lot, and use the test button and the style button. Screen_name, i doubt you even script ive never seen a post of yours on this forum, then again i havn't looked here in a while.
he's one of the best scriptors on graal *****.. well in my opinion he is
don't say crap without looking in previous posts, atleast he knows how to do timeout's correctly
__________________
V$:CONFL16T
  #24  
Old 04-17-2004, 01:16 PM
VeX_RaT_Boy VeX_RaT_Boy is offline
WannaBe Scripter
VeX_RaT_Boy's Avatar
Join Date: Aug 2002
Location: Norway
Posts: 960
VeX_RaT_Boy is on a distinguished road
Send a message via ICQ to VeX_RaT_Boy Send a message via AIM to VeX_RaT_Boy Send a message via Yahoo to VeX_RaT_Boy
Quote:
Originally posted by Gman4pwnu
hey chad, I go into offline mode a lot, and use the test button and the style button. Screen_name, i doubt you even script ive never seen a post of yours on this forum, then again i havn't looked here in a while.
Lol, that was stupid said.
__________________
-Kjetil Valen
  #25  
Old 04-17-2004, 03:45 PM
screen_name screen_name is offline
is watching you
Join Date: Mar 2002
Location: The 3rd Dimension
Posts: 2,160
screen_name is on a distinguished road
Send a message via AIM to screen_name Send a message via MSN to screen_name
Quote:
Originally posted by Gman4pwnu
hey chad, I go into offline mode a lot, and use the test button and the style button. Screen_name, i doubt you even script ive never seen a post of yours on this forum, then again i havn't looked here in a while.
You know why you don't see me asking questions often? Well, I actually debug my scripts until I find what's wrong. I do need help every once in a while, but very rarely.
__________________
[signature]insert here[/signature]
  #26  
Old 04-17-2004, 05:59 PM
Dach Dach is offline
call me Chad, it's cooler
Dach's Avatar
Join Date: Aug 2002
Posts: 1,899
Dach is on a distinguished road
Quote:
Originally posted by Gman4pwnu
hey chad, I go into offline mode a lot, and use the test button and the style button. Screen_name, i doubt you even script ive never seen a post of yours on this forum, then again i havn't looked here in a while.
wasn't meant to be demeaning, or assumptuous.. I mean that alot of the questions you ask could be solved with some good debugging. Debugging isn't a simple task either, it involves rather complex problem solving skills that separate the men from the boys in programming (so to speak). Oh, using the test button and style button isn't really debugging :|. I know you do more, but you're digging yourself deeper with that.

Meh, you don't need to chastize any scripter who will come unannounced and say something like screen_name has. I don't pretend to know all the scripters on graal, so don't throw your neck out like that.
__________________
Scripting Documents:Old Script Documentation-Movement Tutorial
  #27  
Old 04-17-2004, 08:37 PM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
Quote:
Originally posted by WanDaMan

he's one of the best scriptors on graal *****.. well in my opinion he is
don't say crap without looking in previous posts, atleast he knows how to do timeout's correctly
You truly are a ****ing *****, maybe if you read, you would see that there was NOTHING WRONG WITH THE TIMEOUT loop. ****in ****.
  #28  
Old 04-17-2004, 08:45 PM
Gman4pwnu Gman4pwnu is offline
Banned
Join Date: Jan 2004
Posts: 434
Gman4pwnu is on a distinguished road
Send a message via AIM to Gman4pwnu
I need a mod to close this thread, nothing good is coming from it now, just a flame war starting. my question has been answered, close it.
  #29  
Old 04-17-2004, 09:02 PM
Python523 Python523 is offline
Banned
Join Date: Aug 2001
Location: Illinois
Posts: 3,498
Python523 is on a distinguished road
Quote:
Originally posted by Gman4pwnu
I need a mod to close this thread, nothing good is coming from it now, just a flame war starting. my question has been answered, close it.
If you continue to cuss and swear in all your threads when you get frustrated I will request for this forum to be screened from you.
Closed Thread


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 07:14 AM.


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