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, 12521682 views, last view: 11/01/2024 19:25

for questions, announcements etc.

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

#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

#10881: Re: Help Command?

by Jomskylark on 07/09/2008 00:20, refers to #10880

Okay, I thought there was a little menu that popped up during each gametype or something, but thanks anyway!

reply to this message

#10882: Simple texture ( aka picmip-like)

by DavZ on 07/09/2008 10:27

Is it possible to set same textures for all maps? I mean one texture by wall /ground/sky etc...

I want to make my game to simple texture like this: http://img233.imageshack.us/my.php?image=ezquake007hi2.jpg

Thank\'s in advance :)

reply to this message

#10883: ..

by Osbios on 07/09/2008 12:19

Sounds like a attempt of "visual cheating" to me... sorry but I wont tell you. Except you can tell me a good (non cheating) use for it!

reply to this message

#10884: Re: ..

by a~baby~rabbit on 07/09/2008 13:08, refers to #10883

usage: so your maps load really fast :P

reply to this message

#10885: Re: ..

by Hirato Kirata on 07/09/2008 13:33, refers to #10884

solution: /texreduce 12 ;P

reply to this message

#10886: Reducing gridpower?

by ingsoc on 07/09/2008 14:26

Hi,
I've been trying to get a new mode of game working where each player has an 'edit gun' that can modify the terrain. I've been hacking on the source for a while, but I can't find where the maximum gridpower is set. This means that most games end by some idiot wiping out the entire map :)
Can anyone help me out?

reply to this message

#10887: Re: ..

by DavZ on 07/09/2008 15:33, refers to #10885

@Osbios: do you really think that if i wanted to cheat i'd post on a public forum?

Ho thx Hirato! How can i turn off my skyboxe?

reply to this message

#10888: re: gridpower

by Osbios on 07/09/2008 15:44

For the current CTF release you find the gridpower command here:

src/engine/octaedit.cpp line 93

The VARF works like this:

VARF( variable_name, min_value, standard_value, max_value

so you could change

VARF(gridpower, 3-VVEC_FRAC, 3, VVEC_INT-1,

to

VARF(gridpower, 3, 3, 3,

If you change the standard value also take care to change the standard value of gridsize!

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

4 multiplied by 6 =


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