home home

downloads files

forum forum

docs docs

wiki wiki

faq faq

Cube & Cube 2 FORUM


General Thread

by Aardappel on 01/05/2002 01:55, 15527 messages, last message: 03/01/2024 13:02, 12531141 views, last view: 11/02/2024 13:17

for questions, announcements etc.

Go to first 20 messagesGo to previous 20 messages    Board Index    Go to next 20 messagesGo to last 20 messages

#10861: Setting up dedicated Windows server

by Yoda_Glenn on 07/07/2008 05:49

I want to setup a dedicated windows server, but after I turn off my Windows Fire Wall, I get this error message:

"master server reply:

you server did not respond to ping - check your firewall settings."

By the way, I am using a LinkSys WRT 150N router. Could the firewall settings that the program is referring to pertain to the router? Thanks.

reply to this message

#10862: re zoom

by Osbios on 07/07/2008 14:55

@Red October:
What do you want? The script is supposed to change the weapon to the sniper and zoom in!
If you try to say that it won't zoom out and change the weapon back try this:

alias "snip_and_zoom" [ cw = getweapon);
cf = $fov;
cs = $sensitivity;
setweapon 4;
fov 30;
sensitivity 2;
onrelease [ setweapon $cw;
fov $cf;
sensitivity $cs;
]
]

bind "SPACE" snip_and_zoom;

reply to this message

#10863: missing (

by Osbios on 07/07/2008 15:06

One ( was missing by getweapon:


alias "snip_and_zoom" [ cw = (getweapon);
cf = $fov;
cs = $sensitivity;
setweapon 4;
fov 30;
sensitivity 2;
onrelease [ setweapon $cw;
fov $cf;
sensitivity $cs;
]
]

bind "SPACE" snip_and_zoom;

reply to this message

#10864: Re: missing (

by SanHolo on 07/07/2008 19:12, refers to #10863

I have something similiar, works since ever (just added the setweapon-thing, nice idea)


bind MOUSE2 [
oldfov = $fov;
oldsize = $crosshairsize;
oldsens = $sensitivity;
oldweapon = (getweapon);
hudgun 0; fov 25; crosshairsize 40; sensitivity 1;
onrelease [
setweapon $oldweapon; hudgun 1; fov $oldfov; crosshairsize $oldsize; sensitivity $oldsens;
]
]

reply to this message

#10865: ..

by Osbios on 07/07/2008 19:40

Well you just forgot to use the setweapon in the first place. :P

reply to this message

#10866: edit

by nick12345 on 07/08/2008 03:06

how do you edit stuff

reply to this message

#10867: Re: missing (

by Red October on 07/08/2008 06:04, refers to #10864

Those scripts work pretty well; however, what I originally intended for the zoom was that you have to be holding the sniper in order to be able to zoom in, and for other weapons there are varying levels of zoom.

Inside the C++ snipe function, I have another couple sections for the chaingun and rocket launcher, each with different zoomed-in FoVs. Is it possible to check the identity of the weapon being held using CubeScript? If so, I wouldn't need to use the C++.

One more thing; how can I add a mask over the zoomed-in view, so that it looks like a scope with a large crosshair over it? They have that effect in AssaultCube, and I wonder if it'll work for Sauerbraten too.

Thank you!

reply to this message

#10868: ..

by Osbios on 07/08/2008 09:07

Did you even read the scripts? :(
What do you think (getweapon) does?

Expect the mask you can do to all the things with scripts.

reply to this message

#10869: Re: ..

by Red October on 07/08/2008 13:11, refers to #10868

Yeah, I did... but I missed \"setweapon.\" XD. Thanks. So I guess the way to do this is check if the weapon is the sniper, and if it is, then to change the FOV. But how do I compare the value of cw? Do I do:
if ($cw = \"rifle\") [ ]
?

Thanks.

reply to this message

#10870: Re: ..

by Red October on 07/08/2008 13:13, refers to #10869

Or
if ($cw = 4) [ ]
?

reply to this message

#10871: ..

by Osbios on 07/08/2008 14:20

T_T

Exactly that was written in my first script example...

if (= (getweapon) 4) [ ...

]


This could work, too (not tested) :

if (= $cw 4) [ ...

]


You just have to get along with the syntax:

if (= X Y) [ ... ]

reply to this message

#10872: Re: ..

by Red October on 07/08/2008 15:48, refers to #10871

Well I tried adding that in, but now it zooms no matter what weapon you're holding.

This is what I have in zoom.cfg:

alias "zoom"
bind MOUSE2 [ cw = (getweapon);
cf = $fov;
cs = $sensitivity;
if (= (getweapon) 4)
fov 30;
sensitivity 1;
hudgun 0;
onrelease [ setweapon $cw;
fov $cf;
sensitivity $cs;
hudgun 1;
]
]
]

As far as I can see it should work; I don't know why it doesn't.

reply to this message

#10873: re

by Osbios on 07/08/2008 16:36

At first don't use the word zoom because the native command for zoom is called the same!


Alias don't work like that.
Use it like this:

alias my_alias [ DO SOMETHING ]

and then us it with bindings

bind MOUSE2 my_alias


There is a "[" missing after the "if" statement.

And you overwrite the hudgun value. Why not save it, too?

Would look like this in the end:


alias my_zoom [ cw = (getweapon);
cf = $fov;
cs = $sensitivity;
ch = $hudgun
if (= (getweapon) 4) [ fov 30;
sensitivity 1;
hudgun 0;
onrelease [ setweapon $cw;
fov $cf;
sensitivity $cs;
hudgun $ch;
]
]
]

bind "MOUSE2" my_zoom;

reply to this message

#10874: ..

by Osbios on 07/08/2008 16:40

Grrr... I formatted the script with spaces but the forum ate all of them. D:

Some [script][/script] would be nice to prevent this bad looking code!

reply to this message

#10875: Re: ..

by Red October on 07/08/2008 16:56, refers to #10874

The script works perfect now. Thanks so much! Even though it took me like 10 posts to figure it out... XD

So how can I add a mask while zoomed in?

I really wish there were a list of commands and vars like getweapon - the docs don't help much (or maybe I'm missing something).

Thanks again,
RO

reply to this message

#10876: Re: ..

by SheeEttin on 07/08/2008 17:24, refers to #10875

If you grep the source for 'COMMANDN?(' and 'I?VAR[FP]*(', you'll get a list of all commands and vars... Most you can figure out what they do by looking at them. Any that you can't figure out what they do, well, you probably shouldn't mess with them. :P

reply to this message

#10877: ..

by Osbios on 07/08/2008 18:06

I know the getweapon and how to use it from "solaris hudguns".

You could get some of the scripts from quadropolis and try to understand them.

reply to this message

#10878: Help Command?

by Jomskylark on 07/08/2008 20:25

It's probably right there in front of me, but what's the default help command to type? I've tried /help and #help, but neither works.

For example, #stats works to show stats.

Thanks!

reply to this message

#10879: Re: Help Command?

by Jomskylark on 07/08/2008 20:34, refers to #10878

Ok, so I found #info. But what command can I type to bring up the info ABOUT the gametype?

If you press tab, it lets you see WHAT gametype. But how do I figure out what I'm supposed to do in that certain gametype?

Thanks.

reply to this message

#10880: Re: Help Command?

by jbuk2k7s cookie has gone on 07/08/2008 21:32, refers to #10879

http://sauerbraten.org/docs/game.html#mode

reply to this message

Go to first 20 messagesGo to previous 20 messages    Board Index    Go to next 20 messagesGo to last 20 messages


Post a Message

Username

Email

Subject

Body

6 plus 1 is?


content by Aardappel & eihrul © 2001-2024
website by SleepwalkR © 2001-2024
58342427 visitors requested 76294265 pages
page created in 0.126 seconds using 10 queries
hosted by Boost Digital