Kidztime รักเเละห่วงใยกันตลอดไป
[เทคนิค] การปรับ ค่า Status Plus ต่างๆ และปรับลิมิตสูงสุดของ HP + SP ใน Script E 8show

Join the forum, it's quick and easy

Kidztime รักเเละห่วงใยกันตลอดไป
[เทคนิค] การปรับ ค่า Status Plus ต่างๆ และปรับลิมิตสูงสุดของ HP + SP ใน Script E 8show
Kidztime รักเเละห่วงใยกันตลอดไป
Would you like to react to this message? Create an account in a few clicks or log in to continue.

[เทคนิค] การปรับ ค่า Status Plus ต่างๆ และปรับลิมิตสูงสุดของ HP + SP ใน Script E

Go down

[เทคนิค] การปรับ ค่า Status Plus ต่างๆ และปรับลิมิตสูงสุดของ HP + SP ใน Script E Empty [เทคนิค] การปรับ ค่า Status Plus ต่างๆ และปรับลิมิตสูงสุดของ HP + SP ใน Script E

ตั้งหัวข้อ by JTR Sat Aug 06, 2011 8:54 am

ในกระทู้นี้ ผมจะบอกวิธีการเพิ่มค่า Plus ต่างๆ และลิมิต สำหรับตัวละครตอนเริ่มต้นนะครับ

ก่อนอื่น กด F11 เรียก Script Editor ขึ้นมา และเข้าไปตรง Game_Actor
ดูตรงบรรทัดที่ 59 - 64 @maxhp_plus = 500

@maxsp_plus = 50

@str_plus = 15

@dex_plus = 25

@agi_plus = 35

@int_plus = 45ในส่วนนี้คือการปรับค่า Plus หรือค่าพิเศษ สำหรับตัวละครทุกตัวในเกมครับ เดิมทีมันจะเป็น 0 แต่เราสามารถเข้าไปปรับได้ครับ
@maxhp_plus = 500 << เพิ่ม MaxHP
@maxsp_plus = 50 << เพิ่ม MaxSP
@str_plus = 15 << เพิ่ม Str
@dex_plus = 25 << เพิ่ม Dex
@agi_plus = 35 << เพิ่ม Agi
@int_plus = 45 << เพิ่ม Int

และ ถ้าคุณไม่พอใจกับจำนวน Max HP ที่สูงสุดได้แค่ 9999 หรือไม่ครับ?
ไม่ยากครับ เลื่อนลงมาดูบรรทัด 176 - 183 def maxhp

n = [[base_maxhp + @maxhp_plus, 1].max, 99999].min

for i in @states

n *= $data_states.maxhp_rate / 100.0

end

n = [[Integer(n), 1].max, 99999].min

return n

endในส่วน .max 99999 ทั้งสองอัน ให้ปรับเป็นตามจำนวนที่ต้องการนะครับ ในที่นี้ผมปรับให้เป็น 99999
.max อันแรก คือ HP ที่เพิ่มได้สูงสุด จาก HP Plus ในสคริปต์ และ ในคำสั่งเพิ่มค่าพลังของตัวละคร
อันที่สองคือ HP สูงสุดที่มีได้ รวมจาก HP ทุกชนิดแล้วครับ
และลงมาดู 199 - 212 นะครับ ในส่วนนี้จะเป็นค่า Plus สำหรับ Armor def base_str

n = $data_actors[@actor_id].parameters[2, @level]

weapon = $data_weapons[@weapon_id]

armor1 = $data_armors[@armor1_id]

armor2 = $data_armors[@armor2_id]

armor3 = $data_armors[@armor3_id]

armor4 = $data_armors[@armor4_id]



n += weapon != nil ? weapon.str_plus : 0 << ค่า Str ที่ได้เพิ่มเมื่อใส่อาวุธ

n += armor1 != nil ? armor1.str_plus : 0 << เมื่อใส่โล่

n += armor2 != nil ? armor2.str_plus : 0 << เมื่อใส่เกราะ

n += armor3 != nil ? armor3.str_plus : 0 << เมื่อใส่หมวก

n += armor4 != nil ? armor4.str_plus : 0 << เมื่อใส่เครื่องประดับ

return [[n, 1].max, 9999].min << ค่า Plus สูงสุด

endในส่วนนี้คือเพิ่มสำหรับเกราะและ อาวุธทุกชนิดเลยนะครับ
สำหรับค่าอื่นๆ เลื่อนลงมาก็จะอยู่ติดๆกันครับ
แล้วมาดูที่ Game_Character 1 บรรทัด 51-52 @move_speed = 4

@move_frequency = 6อันนี้คือการปรับ Speed และ Frequency เริ่มเกม โดยที่ไม่ต้องใช้คำสั่งอี***ท์ปรับครับ
และมาดู 57 - 60 @walk_anime = true << การเดินอย่างปกติ ถ้าปิดจะเป็นการเดินแบบไม่ก้าวเท้า

@step_anime = false << การย่ำเท้าตลอดเวลา

@direction_fix = false << ไม่หันหน้า

@always_on_top = false << อยู่บนเสมอถ้าอยากให้เปิดปรับเป็น True ปิดเป็น False ครับ
และ การดูว่า ค่าตัวเลขของการเดิน เลขอะไรคือการเดินไปทางไหน หรือหันหน้าไปทางไหน ให้ดูที่บรรทัด 211 - 283when 1 # It moves down

move_down

when 2 # It moves left

move_left

when 3 # It moves right

move_right

when 4 # It moves up

move_up

when 5 # It moves left-down

move_lower_left

when 6 # It moves right-down

move_lower_right

when 7 # It moves left-up

move_upper_left

when 8 # It moves right-up

move_upper_right

when 9 # It moves random

move_random

when 10 # It moves toward player

move_toward_player

when 11 # It moves away form hero

move_away_from_player

when 12 # It moves forward

move_forward

when 13 # It moves backword

move_backward

when 14 # Jump

jump(command.parameters[0], command.parameters[1])

end

# Option [ when it cannot move, disregard ] with OFF, in case of the failure ofmovement

if not @move_route.skippable and not moving? and not jumping?

return

end

@move_route_index += 1

return

end

# In case of weight

if command.code == 15

# Setting weight count

@wait_count = command.parameters[0] * 2 - 1

@move_route_index += 1

return

end

# In case of command of direction modification type

if command.code >= 16 and command.code <= 26

# It diverges with the command cord/code

case command.code

when 16 # Face down

turn_down

when 17 # Face left

turn_left

when 18 # Face right

turn_right

when 19 # Face up

turn_up

when 20 # Turn 90 right

turn_right_90

when 21 # Turn 90 left

turn_left_90

when 22 # 180 Turn

turn_180

when 23 # Left-right 90 turn

turn_right_or_left_90

when 24 # Face random

turn_random

when 25 # Face to hero

turn_toward_player

when 26 # Face away from hero

turn_away_from_player

end

@move_route_index += 1

return

end
ในที่นี้จะบอกความหมายของตัวเลขทั้งหมดนะครับ
ตอนนี้ผมจะ เอาลงมาบอกแค่นี้ก่อนนะครับ ไว้เดี๋ยวเจออีกจะเอามาลงเพิ่มคร้าบ ^^



by Quarter
JTR
JTR
Webmaster
Webmaster

ชื่อเล่น ชื่อเล่น : เเอล
อารมณ์ อารมณ์ : ฉันจะฆ่าเเก!!!
โพส โพส : 940
Kidz Kidz : 2797
คะเเนนน้ำใจ คะเเนนน้ำใจ : 3
วันที่สมัคร วันที่สมัคร : 29/07/2011
อายุ อายุ : 24
ที่อยู่ ที่อยู่ : ที่นี่เเหละ
Male

https://kidztime.thai-forum.net

ขึ้นไปข้างบน Go down

ขึ้นไปข้างบน

- Similar topics

 
Permissions in this forum:
คุณไม่สามารถพิมพ์ตอบ