A Community discussion forum for Halo Custom Edition, Halo 2 Vista, Portal and Halo Machinima

Home  Search Register  Login Member ListRecent Posts
  
 
»Forums Index »Halo Custom Edition (Bungie/Gearbox) »Halo CE Technical / Map Design »scripting error

Author Topic: scripting error (3 messages, Page 1 of 1)
Moderators: Dennis

Taleywacker117
Joined: Nov 15, 2009

At least try to appear sentient.


Posted: Nov 17, 2009 07:38 PM    Msg. 1 of 3       
I have a couple of questions about scripting:

The first and foremost is that when I go into sapien and compile scripts, I keep getting an unmatched left parenthasee error. Here is a one of my scripts that keeps giving me that error:

(global long roundnumber 0)

(script static next_round
(set roundnumber (+ roundnumber 1))
(sleep 500)
)

It's no where near complete yet so that's why it doesn't make much sense, but I absolutely cannot figure out why it's giving me this error.


The second is that i can't figure out how to call a script when a button is pushed.
If someone could post a link to a tutorial or something that would be great because I can't seem to find any.

thx


Gamma927
Joined: Jun 12, 2008

Steam: gamma927


Posted: Nov 17, 2009 08:00 PM    Msg. 2 of 3       
You made the script static, but you don't have a script type. You probably meant "static void".


killer kiwi
Joined: Feb 10, 2007

live and let die


Posted: Nov 17, 2009 10:52 PM    Msg. 3 of 3       
As gammer927 said you have to make it a static void script

Now as for calling other scripts here is a examlpe

(global long roundnumber 0)

(script static void next_round
(set roundnumber (+ roundnumber 1))
(sleep 500)
)

(script startup call-next-number
(next_round)
)


for it to complie you have to have the script that it is calling befor the script that calls it.
Hope that was clear.

ok i miss read what you wanted to know so here is what you wont.


(script static void say_something
(begin
(sv_say "somthing")
)
)

(script continuous action
(begin
(sleep_until (= (player_action_test_accept) 1))
(player_action_test_reset)
(sv_say "call say_somthing")
(say_something)
)
)


if you wont more help on scripting add killerkiwi011 to xfire
Edited by killer kiwi on Nov 18, 2009 at 04:23 PM

 

 
Previous Older Thread    Next newer Thread







Time: Thu January 19, 2023 9:37 AM 140 ms.
A Halo Maps Website