Autor Beitrag
uall@ogc
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1826
Erhaltene Danke: 11

Win 2000 & VMware
Delphi 3 Prof, Delphi 7 Prof
BeitragVerfasst: So 27.03.05 14:42 
der ogc q3 hack warn en client hack
eigentlich kannste bei q3 alles mit gldrawelements machen

_________________
wer andern eine grube gräbt hat ein grubengrabgerät
- oder einfach zu viel zeit
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5285
Erhaltene Danke: 29

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: So 27.03.05 14:45 
wie unterscheide ich denn wände usw ?

ich dachte es wäre eine funktion hiervon (weil du von loggen sprachst, muss ich das ja etwas eingrenzen)

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
{ BeginMode }
  GL_POINTS      = $0000;
  GL_LINES      = $0001;
  GL_LINE_LOOP      = $0002;
  GL_LINE_STRIP             = $0003;
  GL_TRIANGLES             = $0004;
  GL_TRIANGLE_STRIP    = $0005;
  GL_TRIANGLE_FAN             = $0006;
  GL_QUADS      = $0007;
  GL_QUAD_STRIP             = $0008;
  GL_POLYGON      = $0009;


hast du irgendwelche quellen wo ich nachlesen könnte ?
uall@ogc
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1826
Erhaltene Danke: 11

Win 2000 & VMware
Delphi 3 Prof, Delphi 7 Prof
BeitragVerfasst: So 27.03.05 14:49 
das sidn die parameter von glBegin, bei halflife unterscheided man da,

GL_TRIANGLE_STRIP = $0005;
GL_TRIANGLE_FAN = $0006;

für models

GL_POLYGON = $0009; für wände
GL_LINES = $0001; fürs xhair
GL_QUADS = $0007; fürs hud und text


bei q3 wird alles mit glDrawElements gezeichnet die anzahl der elemente zeigen um was es sich handelt wenn da z.b. > 1000 polygone sind dann wirds nen model sein, die anzahl ist dabei immer die selbe

_________________
wer andern eine grube gräbt hat ein grubengrabgerät
- oder einfach zu viel zeit
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5285
Erhaltene Danke: 29

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: So 27.03.05 14:50 
stimmt, ne wand hat dann 6 polygone, oder ?

aber wie frage ich das ab, gib mal beispiel :?
uall@ogc
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1826
Erhaltene Danke: 11

Win 2000 & VMware
Delphi 3 Prof, Delphi 7 Prof
BeitragVerfasst: So 27.03.05 14:53 
nen hook auf:

procedure {nicht gebraucht}glDrawElements(mode: GLenum; count: GLsizei; atype: GLenum; indices: Pointer); stdcall; external opengl32 name 'glDrawElements'


if count = 1232 then
// railgun
else
if count = 1333 then
// rocketlauncher


die anzahl stimmen net mussu selbst rausfinden

_________________
wer andern eine grube gräbt hat ein grubengrabgerät
- oder einfach zu viel zeit
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5285
Erhaltene Danke: 29

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: So 27.03.05 14:56 
ja ok, also so finde ich raus, wann ein model und wann eine wand gezeichnet wird, soweit ich haben verstanden, aber wie verhindere ich jetzt, dass erst die models und dann die wände gezeichnet werden, also die modlz zuletzt ?
ist ja egal welches model, hauptsache nach den wänden, die wenn sie etwas mehr archiektur haben, nich mehr als 1000 polygone habe dürften
uall@ogc
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1826
Erhaltene Danke: 11

Win 2000 & VMware
Delphi 3 Prof, Delphi 7 Prof
BeitragVerfasst: So 27.03.05 14:58 
wenn du nen model hast schaltest den tiefentest ab

gl_disable (GL_DEPTH_TEST);

// model zeichenn lassen

gl_enable (GL_DEPTH_TEST);



dann ist das model über allem, d.h. du siehst es durche wand
aber am besten schaust dir erstmal nen paar opengl tutorials an damit du weißt wie das alles funktioniert

_________________
wer andern eine grube gräbt hat ein grubengrabgerät
- oder einfach zu viel zeit
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5285
Erhaltene Danke: 29

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: So 27.03.05 16:12 
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
procedure glDrawElements(mode: GLenum; count: GLsizei; atype: GLenum; indices: Pointer); stdcall;
begin
  if count > 1000 then 
    gl_disable(GL_DEPTH_TEST) else
      gl_enable(GL_DEPTH_TEST);
  oldglDrawElements(mode, count, atype, indices);
end;

Stimmt das so ?
uall@ogc
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1826
Erhaltene Danke: 11

Win 2000 & VMware
Delphi 3 Prof, Delphi 7 Prof
BeitragVerfasst: So 27.03.05 16:14 
keine ahnung musst schon selbst testen

_________________
wer andern eine grube gräbt hat ein grubengrabgerät
- oder einfach zu viel zeit
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5285
Erhaltene Danke: 29

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: So 27.03.05 16:16 
ich mein von der idee her und vom code isses doch korrekt, oda ?

die polygone sind geschätzt, kann aber hinhaun, ich teste es gleich mal :D
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5285
Erhaltene Danke: 29

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: So 27.03.05 16:34 
funzt net, ich erhalte 2 fehlermeldungen(screenshot) und im spiel ist alles normal, hab die polygone auch schon auf 100 runtergesetzt, also daran liegts net :(

ich habe deinen wrapper genommen und folgendes geändert:
ausblenden Delphi-Quelltext
1:
2:
//vorher oldglBegin
procedure {ka}glBegin (mode: GLenum); stdcall; external opengl32 name 'glBegin';

ausblenden Delphi-Quelltext
1:
2:
//vorher glDrawElements
procedure {nicht gebraucht}oldglDrawElements(mode: GLenum; count: GLsizei; atype: GLenum; indices: Pointer); stdcall; external opengl32 name 'glDrawElements';

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
//vorher das example
procedure glDrawElements(mode: GLenum; count: GLsizei; atype: GLenum; indices: Pointer); stdcall;
begin  
  if count > 100 then   
    glDisable(GL_DEPTH_TEST) else
      glEnable(GL_DEPTH_TEST);  
  oldglDrawElements(mode, count, atype, indices);
end;


aber so scheint es net zu funktionieren :?

warum kann man denn net abfragen, "was" er zeichnet:
ausblenden Delphi-Quelltext
1:
GL_POINTS, GL_LINE_STRIP, GL_LINE_LOOP, GL_LINES, GL_TRIANGLE_STRIP, GL_TRIANGLE_FAN, GL_TRIANGLES, GL_QUAD_STRIP, GL_QUADS, GL_POLYGON					

oder ist das immer GL_POLYGON ?

//EDIT:

ich habe wieder cs zum laufen bekommen (leider nur mit der mp.dll :( ), und habe mal n bissl was mit dem wrapper probiert, funzt alles wunderbar :) nur wäre so ein enemy radar oder ein map overview noch ganz net ^^ wie du den speedhack gemacht hast, da steige ich noch net ganz durch :?

hier erstmal meine results:
ausblenden volle Höhe Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
var
  wallhack, whitewalls, noflash: boolean;

procedure keycheck;
var
  i: byte;
begin
  while true do
    begin
      if boolean(getasynckeystate(vk_f9)) then
        wallhack:= not wallhack;
      if boolean(getasynckeystate(vk_f10)) then
        whitewalls:= not whitewalls;
      if boolean(getasynckeystate(vk_f11)) then
        noflash:= not noflash;
      sleep(50);
    end;
end;

procedure Pwallhack(mode: glenum); stdcall;
begin
  if wallhack then
    if (mode = GL_TRIANGLE_STRIP) or (mode = GL_TRIANGLE_FAN) then
      glDisable(GL_DEPTH_TEST) else
        glEnable(GL_DEPTH_TEST);
end;

procedure Pwhitewalls(mode: glenum); stdcall;
begin
  if whitewalls then
    if (mode = GL_POLYGON) then
      glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_DECAL);
end;

procedure Pnoflash(mode: cardinal; curcol: array of single; t: boolean);
begin
  if noflash then
    if (not t) and (curcol[0] = curcol[1]) and (curcol[1] = curcol[2]) and (curcol[1] = 1.0) then
      glColor4f(curcol[0], curcol[1], curcol[2], 0.001);
end;

procedure glBegin(mode: glenum); stdcall;
var
  curcol: array[0..3] of single;
  t: boolean;
begin
  glGetFloatv(GL_CURRENT_COLOR, @curcol);
  glGetBooleanv(GL_TEXTURE_2D, @t);

  Pwallhack(mode);
  Pwhitewalls(mode);
  Pnoflash(mode, curcol, t);

  oldglBegin(mode);
end;

ausblenden Delphi-Quelltext
1:
createthread(nil, 0, @keycheck, nil, 0, tid);					

soweit funzt alles ^^

wie kann ich jetzt zb spielbefehle ausführen, zb +attack oder echo ? geht das überhaupt ? ich möchte das nähmlich gerne anzeigen lassen, und als
developer 1 + echo + developer 0 fände ich das net schlecht :)